How do I calculate the number of periods of a loan given the starting balance, the annual percentage rate, and the monthly payment amount?
I know how to calculate the monthly payment amount given the first two, plus the number of periods.
How do I calculate the number of periods of a loan given the starting balance, the annual percentage rate, and the monthly payment amount?
I know how to calculate the monthly payment amount given the first two, plus the number of periods.
$B = \sum_\limits {i=1}^n \frac {CF_i}{(1+r)^n}$ is your NPV calculation. The NPV of the future cash flows equals the loan balance.
When the cash flows are uniform, the expression can be simplified to: $B = P \frac {(1+r)((1+r)^n-1)}{r}$ Now solve for $n.$
$1+\frac {Br}{P(1+r)} = (1+r)^n\\ \dfrac {\log \left(1+\frac {Br}{P(1+r)} \right)}{\log (1+r)} = n$