Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Aug 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    compound interest calculation with regular deposits over different periods

    Hi there,

    I am putting together a calculator which does compound interest calculation with regular deposits over different periods.

    The code below is of working solution based upon changing all periods to weekly and calculating totals weekly. However I want to instead of doing it this way have different periods calculated only in their respected period length ie if 4 year selected than the inflated amount is only added every 4 years.

    Basically I want the second pic to look like first pic or excel attachment

    Can someone please please help me im am stuck with how to do this.

    Thank you in advance

    Code:
       
    	<html>  
          
        <head>  
         
        <script language="javascript" type="text/javascript"> 
    	
    	function calculate(){  
        n=Number(document.calculator.inflation.value);
    	a=Number(document.calculator.petrol.value);  
        c=Number(document.calculator.oilchanges.value);;
    	b=Number(document.calculator.tuneups.value)
    	d=Number(document.calculator.cambelt.value);
    	e=Number(document.calculator.exhaust.value);
    	f=Number(document.calculator.coolingsystem.value);
    	n2=Number(document.calculator.charging.value);
        g=n/100;
    
    	h=Number(document.calculator.period1.value);
    	i=Number(document.calculator.period2.value);
    	j=Number(document.calculator.period3.value);
    	k=Number(document.calculator.period4.value);
    	l=Number(document.calculator.period5.value);
    	m=Number(document.calculator.period6.value);
    	m2=Number(document.calculator.period7.value);
    
    w=1;
    bb=1;
    var ii=0;
    for (ii=0;ii<=50;ii++)
    {
    w=(w*g/52)+w;
    bb=bb+w;
    }
    
    	o=a*h*bb;
    	p=b*i*bb;
    	q=c*j*bb;
    	r=d*k*bb;
    	s=e*l*bb;
    	t=f*m*bb;
    	t21=n2*m2*bb;
        u=t+s+r+q+p+o+t21;
        document.calculator.ytotal1.value=o.toFixed(0);
    	document.calculator.ytotal2.value=p.toFixed(0); 
    	document.calculator.ytotal3.value=q.toFixed(0); 
    	document.calculator.ytotal4.value=r.toFixed(0); 
    	document.calculator.ytotal5.value=s.toFixed(0);
    	document.calculator.ytotal6.value=t.toFixed(0);
    	document.calculator.ytotal7.value=t21.toFixed(0);
    	document.calculator.ytotal.value=u.toFixed(0);
    
    w2=1;
    bb2=1;
    var jj2=0;
    for (jj2=0;jj2<=102;jj2++)
    {
    w2=(w2*g/52)+w2;
    bb2=bb2+w2;
    }
    
    	o2=a*h*bb2-o;
    	p2=b*i*bb2-p;
    	q2=c*j*bb2-q;
    	r2=d*k*bb2-r;
    	s2=e*l*bb2-s;
    	t2=f*m*bb2-t;
    	t22=n2*m2*bb2-t21;
        u2=t2+s2+r2+q2+p2+o2+t22;
        document.calculator.y2total1.value=o2.toFixed(0);
    	document.calculator.y2total2.value=p2.toFixed(0); 
    	document.calculator.y2total3.value=q2.toFixed(0); 
    	document.calculator.y2total4.value=r2.toFixed(0); 
    	document.calculator.y2total5.value=s2.toFixed(0);
    	document.calculator.y2total6.value=t2.toFixed(0);
        document.calculator.y2total7.value=t22.toFixed(0);
    	document.calculator.y2total.value=u2.toFixed(0);
    
    w3=1;
    bb3=1;
    var jj3=0;
    for (jj3=0;jj3<=154;jj3++)
    {
    w3=(w3*g/52)+w3;
    bb3=bb3+w3;
    }
    
    	o3=a*h*bb3-o2-o;
    	p3=b*i*bb3-p2-p;
    	q3=c*j*bb3-q2-q;
    	r3=d*k*bb3-r2-r;
    	s3=e*l*bb3-s2-s;
    	t3=f*m*bb3-t2-t;
    	t23=n2*m2*bb3-t22-t21;
        u3=t3+s3+r3+q3+p3+o3+t23;
        document.calculator.y3total1.value=o3.toFixed(0);
    	document.calculator.y3total2.value=p3.toFixed(0); 
    	document.calculator.y3total3.value=q3.toFixed(0); 
    	document.calculator.y3total4.value=r3.toFixed(0); 
    	document.calculator.y3total5.value=s3.toFixed(0);
    	document.calculator.y3total6.value=t3.toFixed(0);
        document.calculator.y3total7.value=t23.toFixed(0);
    	document.calculator.y3total.value=u3.toFixed(0);
    
    w4=1;
    bb4=1;
    var jj4=0;
    for (jj4=0;jj4<=206;jj4++)
    {
    w4=(w4*g/52)+w4;
    bb4=bb4+w4;
    }
    
    	o4=a*h*bb4-o3-o2-o;
    	p4=b*i*bb4-p3-p2-p;
    	q4=c*j*bb4-q3-q2-q;
    	r4=d*k*bb4-r3-r2-r;
    	s4=e*l*bb4-s3-s2-s;
    	t4=f*m*bb4-t3-t2-t;
    	t24=n2*m2*bb4-t23-t22-t21;
        u4=t4+s4+r4+q4+p4+o4+t24;
        document.calculator.y4total1.value=o4.toFixed(0);
    	document.calculator.y4total2.value=p4.toFixed(0); 
    	document.calculator.y4total3.value=q4.toFixed(0); 
    	document.calculator.y4total4.value=r4.toFixed(0); 
    	document.calculator.y4total5.value=s4.toFixed(0);
    	document.calculator.y4total6.value=t4.toFixed(0);
        document.calculator.y4total7.value=t24.toFixed(0);
    	document.calculator.y4total.value=u4.toFixed(0);
    
    
    w5=1;
    bb5=1;
    var jj=0;
    for (jj=0;jj<=258;jj++)
    {
    w5=(w5*g/52)+w5;
    bb5=bb5+w5;
    }
    
    	o5=a*h*bb5-o4-o3-o2-o;
    	p5=b*i*bb5-p4-p3-p2-p;
    	q5=c*j*bb5-q4-q3-q2-q;
    	r5=d*k*bb5-r4-r3-r2-r;
    	s5=e*l*bb5-s4-s3-s2-s;
    	t5=f*m*bb5-t4-t3-t2-t;
    	t25=n2*m2*bb5-t24-t23-t22-t21;
        u5=t5+s5+r5+q5+p5+o5+t25;
        document.calculator.y5total1.value=o5.toFixed(0);
    	document.calculator.y5total2.value=p5.toFixed(0); 
    	document.calculator.y5total3.value=q5.toFixed(0); 
    	document.calculator.y5total4.value=r5.toFixed(0); 
    	document.calculator.y5total5.value=s5.toFixed(0);
    	document.calculator.y5total6.value=t5.toFixed(0);
        document.calculator.y5total7.value=t25.toFixed(0);
    	document.calculator.y5total.value=u5.toFixed(0);
    
    w6=1;
    bb6=1;
    var jj6=0;
    for (jj6=0;jj6<=310;jj6++)
    {
    w6=(w6*g/52)+w6;
    bb6=bb6+w6;
    }
    
    	o6=a*h*bb6-o5-o4-o3-o2-o;
    	p6=b*i*bb6-p5-p4-p3-p2-p;
    	q6=c*j*bb6-q5-q4-q3-q2-q;
    	r6=d*k*bb6-r5-r4-r3-r2-r;
    	s6=e*l*bb6-s5-s4-s3-s2-s;
    	t6=f*m*bb6-t5-t4-t3-t2-t;
    	t26=n2*m2*bb6-t25-t24-t23-t22-t21;
        u6=t6+s6+r6+q6+p6+o6+t26;
        document.calculator.y6total1.value=o6.toFixed(0);
    	document.calculator.y6total2.value=p6.toFixed(0); 
    	document.calculator.y6total3.value=q6.toFixed(0); 
    	document.calculator.y6total4.value=r6.toFixed(0); 
    	document.calculator.y6total5.value=s6.toFixed(0);
    	document.calculator.y6total6.value=t6.toFixed(0);
        document.calculator.y6total7.value=t26.toFixed(0);
    	document.calculator.y6total.value=u6.toFixed(0);
    
    w7=1;
    bb7=1;
    var jj7=0;
    for (jj7=0;jj7<=362;jj7++)
    {
    w7=(w7*g/52)+w7;
    bb7=bb7+w7;
    }
    
    	o7=a*h*bb7-o6-o5-o4-o3-o2-o;
    	p7=b*i*bb7-p6-p5-p4-p3-p2-p;
    	q7=c*j*bb7-q6-q5-q4-q3-q2-q;
    	r7=d*k*bb7-r6-r5-r4-r3-r2-r;
    	s7=e*l*bb7-s6-s5-s4-s3-s2-s;
    	t7=f*m*bb7-t6-t5-t4-t3-t2-t;
    	t27=n2*m2*bb7-t26-t25-t24-t23-t22-t21;
        u7=t7+s7+r7+q7+p7+o7+t27;
        document.calculator.y7total1.value=o7.toFixed(0);
    	document.calculator.y7total2.value=p7.toFixed(0); 
    	document.calculator.y7total3.value=q7.toFixed(0); 
    	document.calculator.y7total4.value=r7.toFixed(0); 
    	document.calculator.y7total5.value=s7.toFixed(0);
    	document.calculator.y7total6.value=t7.toFixed(0);
        document.calculator.y7total7.value=t27.toFixed(0);
    	document.calculator.y7total.value=u7.toFixed(0);
    
    w8=1;
    bb8=1;
    var jj8=0;
    for (jj8=0;jj8<=414;jj8++)
    {
    w8=(w8*g/52)+w8;
    bb8=bb8+w8;
    }
    
    	o8=a*h*bb8-o7-o6-o5-o4-o3-o2-o;
    	p8=b*i*bb8-p7-p6-p5-p4-p3-p2-p;
    	q8=c*j*bb8-q7-q6-q5-q4-q3-q2-q;
    	r8=d*k*bb8-r7-r6-r5-r4-r3-r2-r;
    	s8=e*l*bb8-s7-s6-s5-s4-s3-s2-s;
    	t8=f*m*bb8-t7-t6-t5-t4-t3-t2-t;
    	t28=n2*m2*bb8-t27-t26-t25-t24-t23-t22-t21;
        u8=t8+s8+r8+q8+p8+o8+t28;
        document.calculator.y8total1.value=o8.toFixed(0);
    	document.calculator.y8total2.value=p8.toFixed(0); 
    	document.calculator.y8total3.value=q8.toFixed(0); 
    	document.calculator.y8total4.value=r8.toFixed(0); 
    	document.calculator.y8total5.value=s8.toFixed(0);
    	document.calculator.y8total6.value=t8.toFixed(0);
        document.calculator.y8total7.value=t28.toFixed(0);
    	document.calculator.y8total.value=u8.toFixed(0);
    
    w9=1;
    bb9=1;
    var jj9=0;
    for (jj9=0;jj9<=466;jj9++)
    {
    w9=(w9*g/52)+w9;
    bb9=bb9+w9;
    }
    
    	o9=a*h*bb9-o8-o7-o6-o5-o4-o3-o2-o;
    	p9=b*i*bb9-p8-p7-p6-p5-p4-p3-p2-p;
    	q9=c*j*bb9-q8-q7-q6-q5-q4-q3-q2-q;
    	r9=d*k*bb9-r8-r7-r6-r5-r4-r3-r2-r;
    	s9=e*l*bb9-s8-s7-s6-s5-s4-s3-s2-s;
    	t9=f*m*bb9-t8-t7-t6-t5-t4-t3-t2-t;
    	t29=n2*m2*bb9-t28-t27-t26-t25-t24-t23-t22-t21;
        u9=t9+s9+r9+q9+p9+o9+t29;
        document.calculator.y9total1.value=o9.toFixed(0);
    	document.calculator.y9total2.value=p9.toFixed(0); 
    	document.calculator.y9total3.value=q9.toFixed(0); 
    	document.calculator.y9total4.value=r9.toFixed(0); 
    	document.calculator.y9total5.value=s9.toFixed(0);
    	document.calculator.y9total6.value=t9.toFixed(0);
        document.calculator.y9total7.value=t29.toFixed(0);
    	document.calculator.y9total.value=u9.toFixed(0);
    
    
    w10=1;
    bb10=1;
    var kk=0;
    for (kk=0;kk<=518;kk++)
    {
    w10=(w10*g/52)+w10;
    bb10=bb10+w10;
    }
    
    	o10=a*h*bb10-o9-o8-o7-o6-o5-o4-o3-o2-o;
    	p10=b*i*bb10-p9-p8-p7-p6-p5-p4-p3-p2-p;
    	q10=c*j*bb10-q9-q8-q7-q6-q5-q4-q3-q2-q;
    	r10=d*k*bb10-r9-r8-r7-r6-r5-r4-r3-r2-r;
    	s10=e*l*bb10-s9-s8-s7-s6-s5-s4-s3-s2-s;
    	t10=f*m*bb10-t9-t8-t7-t6-t5-t4-t3-t2-t;
    	t210=n2*m2*bb10-t29-t28-t27-t26-t25-t24-t23-t22-t21;
        u10=t10+s10+r10+q10+p10+o10+t210;
        document.calculator.y10total1.value=o10.toFixed(0);
    	document.calculator.y10total2.value=p10.toFixed(0); 
    	document.calculator.y10total3.value=q10.toFixed(0); 
    	document.calculator.y10total4.value=r10.toFixed(0); 
    	document.calculator.y10total5.value=s10.toFixed(0);
    	document.calculator.y10total6.value=t10.toFixed(0);
        document.calculator.y10total7.value=t210.toFixed(0);
    	document.calculator.y10total.value=u10.toFixed(0);
    
    ut5=u5+u4+u3+u2+u;
    var ut5 = CurrencyFormatted(ut5);
    G5 = CommaFormatted(ut5);
    ut10=u10+u9+u8+u7+u6+u5+u4+u3+u2+u;
    var ut10 = CurrencyFormatted(ut10);
    G10 = CommaFormatted(ut10);
    	document.calculator.y5tota.value=G5;
    	document.calculator.y10tota.value=G10;
    	document.getElementById("p1").innerHTML="<strong>IT'S SIMPLY AMAZING HOW THESE MUST PAY EXPENSES ADD UP OVER THE YEARS - THEY NEVER STOP</strong>";
        }
    	
    	 function clearMe(formfield){
      if (formfield.defaultValue==formfield.value)
       formfield.value = ""
     }
    
    function returnMe(formfield){
     if (formfield.value=="")
      formfield.value = formfield.defaultValue} 
    
    function CurrencyFormatted(amount)
    {
    	var i = parseFloat(amount);
    	if(isNaN(i)) { i = 0.00; }
    	var minus = '';
    	if(i < 0) { minus = '-'; }
    	i = Math.abs(i);
    	i = parseInt((i + .005) * 100);
    	i = i / 100;
    	s = new String(i);
    	if(s.indexOf('.') < 0) { s += '.00'; }
    	if(s.indexOf('.') == (s.length - 2)) { s += '0'; }
    	s = minus + s;
    	return s;
    }
    
    	function CommaFormatted(amount)
    {
    	var delimiter = ","; // replace comma if desired
    	amount = new String(amount);
    	var a = amount.split('.',2)
    	var d = a[1];
    	var i = parseInt(a[0]);
    	if(isNaN(i)) { return ''; }
    	var minus = '';
    	if(i < 0) { minus = '-'; }
    	i = Math.abs(i);
    	var n = new String(i);
    	var a = [];
    	while(n.length > 3)
    	{
    		var nn = n.substr(n.length-3);
    		a.unshift(nn);
    		n = n.substr(0,n.length-3);
    	}
    	if(n.length > 0) { a.unshift(n); }
    	n = a.join(delimiter);
    	if(d.length < 1) { amount = n; }
    	else { amount = n + '.' + d; }
    	amount = minus + amount;
    	return amount;
    }
    
    var links = document.getElementById('nav').getElementsByTagName('a');
    for ( var i = 0; i < links.length; i++ ) {
        links[i].onmousedown = function () {
            this.blur();
            return false;
        }
        links[i].onclick = function() {
            this.blur();
        }
        if ( /msie/i.test(navigator.userAgent) && !/opera/i.test(navigator.userAgent) ) {
            links[i].onfocus = function() {
                this.blur();
            }
        }
    }
    
        </script> 
    
    
        <style type="text/css">
        .ten {
    	font-size: 10px;
    }
        .ten {
    	font-size: 12px;
    }
        .e18 {
    	font-size: 18px;
    }
        .e18 {
    	font-size: 16px;
    }
        .e18 {
    	font-size: 14px;
    }
        .e18 {
    	font-size: 12px;
    }
        .t12 {
    	font-size: 12px;
    }
    
    #mybut, .mybut .mybut a:focus {
    	background: transparent url(http://www.strategicwebsites.co.nz/voltmotive/button.png) no-repeat center center;
    	border:none;
    	width:230px;
    	height:70px;
    	margin-top:-5px;
    	cursor:pointer;
    	color:transparent;
    	outline: 1px none transparent;
    }
    
    :focus {
        outline: 0px none transparent!important;
    }
    
    #p1, .p1 {
    color:red;}
    
     
        </style>
        </head>
    Attached Thumbnails Attached Thumbnails compound interest calculation with regular deposits over different periods-pic-2.jpg   compound interest calculation with regular deposits over different periods-pic-1.jpg  
    Last edited by ironmurph; 09-26-2011 at 08:03 AM.

  • #2
    New to the CF scene
    Join Date
    Aug 2011
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts
    body section to head above
    Code:
    <body onload="calculate() ;">
    
      
        <form name="calculator">  
        <table width="1000" height="506"" border="0" text-align: center; font-family: Verdana, Geneva, sans-serif; color: #000; padding="0">
    <tr><th colspan="16" bgcolor="#339966"><H2>
        <FONT COLOR="#FFFFFF">THE REAL COST OF RUNNING AN INTERNAL COMBUSTION VEHICLE</FONT>    <H2></TH></TR>
    <tr><td height="7"></td></tr>
    <tr>
    <td bgcolor="#CCFFCC"><strong><FONT COLOR="#000">Vehicle Running Costs</FONT></strong></td>
    <td></td><td></td><th colspan="10" bgcolor="#CCFFCC">Accumulated Yearly Costs - Inflation Adjusted</td>
    </tr>
    <tr><td></td>
    <td width="54"><strong><FONT COLOR="#FF3900">Amount</FONT></strong></td>
    <td width="95"><strong><FONT COLOR="#FF3900">Frequency</FONT></strong></td>
    <tr>
    <td width="257" height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Select Annual Inflation Rate</span></td>
    <td width="54" align="right">
      <span class="ten">
      <input type="text" name="inflation" value = "5.00"  size="2"  onfocus="clearMe(this)" onBlur="returnMe(this)" style="text-align:right; color: #009;" color="#000080">
      %</span></td>
    <td></td><td width="54" class="ten"><span class="ten">Year 1</span></td>
    <td width="54" class="ten"><span class="ten">Year 2</span></td>
    <td width="54" class="ten"><span class="ten">Year 3</span></td>
    <td width="54" class="ten"><span class="ten">Year 4</span></td>
    <td width="54" class="ten"><span class="ten">Year 5</span></td>
    <td width="54" class="ten"><span class="ten">Year 6</span></td>
    <td width="54" class="ten"><span class="ten">Year 7</span></td>
    <td width="54" class="ten"><span class="ten">Year 8</span></td>
    <td width="54" class="ten"><span class="ten">Year 9</span></td>
    <td width="54" class="ten"><span class="ten">Year 10</span></td>
    </tr>
    
    <tr>
    <td height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Petrol or Diesel</span></td>
    <td><span class="ten">$ 
      <input name="petrol" type="text" style="text-align:right;" onFocus="clearMe(this)" onBlur="returnMe(this)" value="100" size="3" onkeyup="calculate()">
    </span></td>
    <td class="ten">  <span class="ten">
      <select name="period1">
        <option value="1" selected>Weekly</option>
        <option value="0.2308">Monthly</option>
        <option value="0.03846">6 Monthly</option>
        <option value="0.01923">Yearly</option>
        <option value="0.009615">2 Yearly</option>
        <option value="0.006410">3 Yearly</option>
        <option value="0.004808">4 Yearly</option>
        <option value="0.003846">5 Yearly</option>
      </select>
    </span></td>
    <td><span class="ten">$ 
      <input name="ytotal1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y2total1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y3total1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y4total1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input type="text" name="y5total1"  size="3" style="text-align:right;" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y6total1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y7total1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y8total1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y9total1" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input type="text" name="y10total1"  size="3" style="text-align:right;">
    </span></td>
    <tr>
    
    <tr>
    <td height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Oil and Air Filter Changes</span></td>
    <td><span class="ten">$ 
      <input name="oilchanges" type="text" style="text-align:right;" onFocus="clearMe(this)" onBlur="returnMe(this)" value="85" size="3" onkeyup="calculate()">
    </span></td>
    <td class="ten">  <span class="ten">
      <select name="period2">
        <option value="1">Weekly</option>
        <option value="0.2308">Monthly</option>
        <option value="0.03846" selected>6 Monthly</option>
        <option value="0.01923">Yearly</option>
        <option value="0.009615">2 Yearly</option>
        <option value="0.006410">3 Yearly</option>
        <option value="0.004808">4 Yearly</option>
        <option value="0.003846">5 Yearly</option>
      </select>
    </span></td>
    <td><span class="ten">$ 
      <input name="ytotal3" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y2total3" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y3total3" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input type="text" name="y4total3" size="3" style="text-align:right;" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y5total3" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y6total3" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y7total3" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y8total3" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y9total3" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y10total3" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    </tr>
    <tr>
    <td height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Engine Tune Ups</span></td>
    <td><span class="ten">$ 
      <input name="tuneups" type="text" style="text-align:right;" onFocus="clearMe(this)" onBlur="returnMe(this)" value="240" size="3" onkeyup="calculate()">
    </span></td>
    <td class="ten">  <span class="ten">
      <select name="period3">
        <option value="1">Weekly</option>
        <option value="0.2308">Monthly</option>
        <option value="0.03846">6 Monthly</option>
        <option value="0.01923">Yearly</option>
        <option value="0.009615">2 Yearly</option>
        <option value="0.006410" selected>3 Yearly</option>
        <option value="0.004808">4 Yearly</option>
        <option value="0.003846">5 Yearly</option>
      </select>
    </span></td>
    <td><span class="ten">$ 
      <input name="ytotal2" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y2total2" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input type="text" name="y3total2" size="3" style="text-align:right;" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input type="text" name="y4total2" size="3" style="text-align:right;" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y5total2" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y6total2" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y7total2" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y8total2" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y9total2" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y10total2" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    </tr>
    
    <tr>
    <td height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Timing and Fab Belt Changes</span></td>
    <td><span class="ten">$ 
      <input name="cambelt" type="text" style="text-align:right;" onFocus="clearMe(this)" onBlur="returnMe(this)" value="180"  size="3" onkeyup="calculate()">
    </span></td>
    <td class="ten">  <span class="ten">
      <select name="period4">
        <option value="1">Weekly</option>
        <option value="0.2308">Monthly</option>
        <option value="0.03846">6 Monthly</option>
        <option value="0.01923">Yearly</option>
        <option value="0.009615">2 Yearly</option>
        <option value="0.006410">3 Yearly</option>
        <option value="0.004808" selected>4 Yearly</option>
        <option value="0.003846">5 Yearly</option>
      </select>
    </span></td>
    <td><span class="ten">$ 
      <input name="ytotal4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y2total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y3total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input type="text" name="y4total4"  size="3" style="text-align:right;" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y5total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y6total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y7total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y8total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y9total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y10total4" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    </tr>
    <tr>
    <td height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Exhaust Repairs</span></td>
    <td><span class="ten">$ 
      <input name="exhaust" type="text" style="text-align:right;" onFocus="clearMe(this)" onBlur="returnMe(this)" value="300" size="3" onkeyup="calculate()">
    </span></td>
    <td class="ten">  <span class="ten">
      <select name="period5">
        <option value="1">Weekly</option>
        <option value="0.2308">Monthly</option>
        <option value="0.03846">6 Monthly</option>
        <option value="0.01923">Yearly</option>
        <option value="0.009615">2 Yearly</option>
        <option value="0.006410">3 Yearly</option>
        <option value="0.004808" selected>4 Yearly</option>
        <option value="0.003846">5 Yearly</option>
      </select>
    </span></td>
    <td><span class="ten">$ 
      <input name="ytotal5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y2total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y3total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y4total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y5total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y6total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y7total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y8total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y9total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y10total5" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    </tr>
    <tr>
    <td height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Cooling System Flush Repairs</span></td>
    <td><span class="ten">$ 
      <input name="coolingsystem" type="text" style="text-align:right;" onFocus="clearMe(this)" onBlur="returnMe(this)" value="95" size="3" onkeyup="calculate()">
    </span></td>
    <td class="ten">  <span class="ten">
      <select name="period6">
        <option value="1">Weekly</option>
        <option value="0.2308">Monthly</option>
        <option value="0.03846">6 Monthly</option>
        <option value="0.01923">Yearly</option>
        <option value="0.009615">2 Yearly</option>
        <option value="0.006410">3 Yearly</option>
        <option value="0.004808" selected>4 Yearly</option>
        <option value="0.003846">5 Yearly</option>
      </select>
    </span></td>
    <td><span class="ten">$ 
      <input name="ytotal6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y2total6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y3total6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y4total6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y5total6" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y6total6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y7total6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y8total6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y9total6" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y10total6" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    </tr>
    
    <tr>
    <td height="25" bgcolor="#CCFFCC" class="t12"><span class="ten">Battery and Charging System Repairs</span></td>
    <td><span class="ten">$ 
      <input name="charging" type="text" style="text-align:right;" onFocus="clearMe(this)" onBlur="returnMe(this)" value="85" size="3" onkeyup="calculate()">
    </span></td>
    <td class="ten">  <span class="ten">
      <select name="period7">
        <option value="1">Weekly</option>
        <option value="0.2308">Monthly</option>
        <option value="0.03846">6 Monthly</option>
        <option value="0.01923">Yearly</option>
        <option value="0.009615">2 Yearly</option>
        <option value="0.006410">3 Yearly</option>
        <option value="0.004808">4 Yearly</option>
        <option value="0.003846" selected>5 Yearly</option>
      </select>
    </span></td>
    <td><span class="ten">$ 
      <input name="ytotal7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y2total7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y3total7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y4total7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y5total7" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y6total7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y7total7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y8total7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y9total7" type="text" style="text-align:right;" size="3" readonly="readonly">
    </span></td>
    <td><span class="ten">$ 
      <input name="y10total7" type="text" style="text-align:right;"  size="3" readonly="readonly">
    </span></td>
    </tr>
    <tr><td height="11"></td></tr>
    <tr>
      <td height="43" bgcolor="#CCFFCC"><span class="ten"><strong><font color="#000000">GRAND TOTAL - PER YEAR</font></strong></span></td>
      <td bgcolor="#CCFFCC"></td>
      <td bgcolor="#CCFFCC">&nbsp;</td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="ytotal" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y2total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y3total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y4total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
     <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y5total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y6total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y7total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y8total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y9total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
     <td bgcolor="#CCFFCC"><span class="ten">$ 
        <input name="y10total" type="text" style="text-align:right;" size="3" readonly="readonly">  
      </span></td>
      </tr>
      <tr><td height="12"></td></tr>
      <tr><th colspan="3" bgcolor="#CCFFCC">GRAND TOTAL - Inflation adjusted over 5 years</th>
      <th colspan="3" bgcolor="#CCFFCC">$ <input name="y5tota" type="text" style="text-align:right;"  size="8" ></th></tr>
      <tr><td height="6"></td></tr>
      <tr><th colspan="3" bgcolor="#CCFFCC">GRAND TOTAL - Inflation adjusted over 10 years</th>
      <th colspan="3" bgcolor="#CCFFCC">$ <input name="y10tota" type="text" style="text-align:right;"  size="8" ></th></tr>
        <tr><th height="37" colspan="13"><p id="p1"></p></th></tr>
            </table> 
     
       
    
          
        </form>  
    
    
          
        </body>  
        </html>


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •