I'm a developer, and i'm building a snowball debt calculator.
I want a formula to work out what the minimum monthly repayment would be on a debt with a given interest.
And I really want to get the math spot on.
The snowball debt reduction method doesn't necessarily take into account the interest of a debt, as it recommends you pay of the smallest debt first.
However, what I want to use the minimum monthly payment for is error management on the debt calculator i'm building. So when someone is putting in a debt, they have 4 options to fill in:
- Debt name
- Total debt still owed
- Interest
- Monthly payment
If they enter a debt of 20,000 with an interest of 20% APR , and a monthly payment of 1p, it obviously wont cover the minimum payment required to reduce the debt. So in this example I would want to warn the user that it wouldn't meet the criteria.
Any feedback appreciated.
Thanks
Ryan
You can model this with the Bond evaluation formula. It states the following: $$B = \frac{P}{(1+i)} + \frac{P}{(1+i)^2} +...+ \frac{P}{(1+i)^n} = P\sum_{j=1}^n(1+i)^{-j}$$
Where $n$ is the duration of the Bond/loan, $P$ is the value of the payments and $B$ is the value of the Bond/loan.
In your example of the 20,000 with an APR of 20%, if we a consider an open agreement with no theoretical termination, you could calculate that
$$B = P\sum_{j = 1}^\infty(1+i)^{-j} = \frac{1}{1-\frac{1}{1+i}}P = \frac{1+i}{i}P$$ $$ P = \frac{i}{1+i}B = 20000(\frac{.0153}{1 + .0153}) \approx \$301.58$$
Note that the monthly interest rate is $i = (1 + 0.2)^{\frac{1}{12}} - 1 \approx 1.53 \%$
Any payment less than that will cause you problems. Solutions for loans with finite duration are harder to evaluate, but can be done with the exponential summation.
http://www.investopedia.com/university/advancedbond/advancedbond2.asp