RavenBlog |
|
Comments on Friday 15 March 2002: |
My mathematical skills are a little rusty. Does this formula collapse down to something short, perhaps involving exponentials?((a*m-p)*m-p)... (with the *m-p operation repeated n times)Or the same formula, expressed a different way: a*mn-p*m(n-1)-p*m(n-2)-...-p*m(n-n)(It's the mortgage formula - a is the loan size, p is the monthly payment, m is the monthly interest rate (in a form such that 1.007 would represent 0.7%) and n is the number of months the loan is for - the formula given equals zero. [02:09] |
zx64 |
This is a geometric progression. The three main equations for GPs are for finding the nth term, summing from zero to n terms and summing from zero to infinity (only works if the ratio being exponentiated is less than one). nth term = a*r^(n-1) (montly payment) sum from zeroeth to nth term = (a((r^n) - 1))/(r-1) (current total paid) sum from zeroeth to inf. = a/(1-r) (probably not much use for mortgages) Hope this helps. |
Stefano |
Which is to say, the formula with your data should be a*m^n - p*(m^n-1)/(m-1) (Hope zx64 agrees) |
Pig |
Just in case you wanted to improve your math skills, here's the proof for the formula: ((sum from k=1 to k=n)(p*(1/m)^k))should equal a. This is because we backtracked all the p to their present value. Multiply both sides by 1/m and you get ((sum from k=1 to k=n)(p*(1/m)^(k+1))=((sum from k=0 to k=n-1)(p*(1/m)^k))=a*(1/m) Now subtract the original sum from this one and get: ((sum from k=0 to k=n-1)(p*(1/m)^k))-((sum from k=1 to k=n)(p*(1/m)^k))=a*(1/m)-a As you can see, most of the terms will cancel each other out. This leaves us with only the k=0 term minus the k=n term: p*(1-(1/m)^n)=a*((1/m)-1) I hope that this is right (just got it off the top of my head) and that it helps. |