<!-- function sf(){sample.Length.focus();} // This sets the initial cursor focus to the input tag named 'Length'
function compute()
{
var f = document.sample; // This is the name of the form we'll we working with turned into the variable f.
// line 1, Length to use in the pond calculation
var Length = (f.Length.value);
if (isNaN(Length)) Length = 0; f.Length.value = "0";
f.Length.value = Math.round(Length);
// line 2, Width to use in the pond calculation
var Width = (f.Width.value);
if (isNaN(Width)) Width = 0; f.Width.value = "0";
f.Width.value = Math.round(Width);
// line 3, Depth to use in the pond calculation
var Depth = (f.Depth.value);
if (isNaN(Depth)) Depth = 0; f.Depth.value = "0";
f.Depth.value = Math.round(Depth);
// line 4, Average Depth to use in the pond calculation
var AverageDepth = (f.AverageDepth.value);
if (isNaN(AverageDepth)) AverageDepth = 0; f.AverageDepth.value = "0";
f.AverageDepth.value = Math.round(AverageDepth);
// line 5, turnover to use in the pond calculation
var turnover = (f.turnover.value);
if (isNaN(turnover)) turnover = 0; f.turnover.value = "0";
f.turnover.value = (turnover);
// line 6, overlay to use in the pond calculation
var overlay = (f.overlay.value);
if (isNaN(overlay)) overlay = 0; f.overlay.value = "0";
f.overlay.value = (overlay);
// then compute the Liner Length based upon the formula
var LinerLength = ((1 * Length) + (1 * Depth) + (1 * Depth) + (2 * overlay));
f.LinerLength.value = Math.round(LinerLength);
// then compute the Liner Width based upon the formula
var LinerWidth = ((1 * Width) + (1 * Depth) + (1 * Depth) + (2 * overlay));
f.LinerWidth.value = Math.round(LinerWidth);
// then compute the surface area based upon the formula
var SurfaceArea = (Length * Width);
f. SurfaceArea.value = Math.round(SurfaceArea);
// then compute the plant coverage needed based upon the formula
var PlantCoverage = (Length * Width * .60);
f.PlantCoverage.value = Math.round(PlantCoverage);
// then compute the plants needed based upon the formula
var PlantCoverage2 = (Length * Width * .60 / 10);
f.PlantCoverage2.value = Math.round(PlantCoverage2);
// then compute the gallons based upon the formula
var Gallons = (Length * Width * AverageDepth * 7.48051945);
f.Gallons.value = Math.round(Gallons);
// then compute the pump size based upon the formula
var PumpSize = (Length * Width * AverageDepth * 7.48051945 / turnover);
f.PumpSize.value = Math.round(PumpSize);
// then compute the filter size based upon the formula
var FilterSize = (Length * Width * AverageDepth * 7.48051945 * 1.10 / turnover);
f.FilterSize.value = Math.round(FilterSize);
// then compute the waterfall size based upon the formula
var WaterfallSize = (Length * Width * AverageDepth * 7.48051945 / 100);
f.WaterfallSize.value = Math.round(WaterfallSize);
// then compute the Submerged plants needed based upon the formula
var PlantCoverage3 = (Length * Width / 2);
f.PlantCoverage3.value = Math.round(PlantCoverage3);
// then compute the Sq. foot needed for underlayment based upon the formula
var underlayment = ((LinerLength * 1) * (LinerWidth * 1) * 1.10);
f.underlayment.value = Math.round(underlayment);
// then compute the turnover value based upon the formula
var turnovervalue = (turnover * 1);
f.turnovervalue.value = (turnovervalue);
// then compute the turnover value 2 based upon the formula
var turnovervalue2 = (turnover * 1);
f.turnovervalue2.value = (turnovervalue2);
// then compute the turnover value 3 based upon the formula
var turnovervalue3 = (turnover * 1);
f.turnovervalue3.value = (turnovervalue3);
// then compute the pump size 2 based upon the formula
var PumpSize2 = (Length * Width * AverageDepth * 7.48051945 / turnover);
f.PumpSize2.value = Math.round(PumpSize2);
// then compute the fish load based upon the formula
var Fishload = (Length * Width /25 * 12);
f.Fishload.value = Math.round(Fishload);
// then compute the Koi fish load based upon the formula
var KoiFishload = (Length * Width /25 * 12 / 30);
f.KoiFishload.value = Math.round(KoiFishload);
// then compute the Gold fish load based upon the formula
var GoldFishload = (Length * Width /25 * 12 / 14);
f.GoldFishload.value = Math.round(GoldFishload);
// then compute the Shubunkin fish load based upon the formula
var ShubunkinFishload = (Length * Width /25 * 12 / 12);
f.ShubunkinFishload.value = Math.round(ShubunkinFishload);
}
// -->
