function fuelconsumption(form) {
	
	
	form.gph.value = 0;
	if (form.kw.value!=0) {if (form.kw.value=="") {form.kw.value = 0;} else {if (parseInt(form.kw.value)==0) {alert ("Sorry!  All values must be numerical.")
errcode=1;}}}

kw = form.kw.value;
gph = .08433 * kw;
total = gph + .000;
totalstring = "" + total;
lentocent = totalstring.indexOf(".") + 3;
newtotal = totalstring.substring(0,lentocent); 
form.gph.value = newtotal;}
