Rate of interest as decimal (not per cent) per period
Number of compounding periods
A fixed payment, paid either at the beginning or ar the end (specified by when
)
Present value
When payment was made
The value at the end of the nper
periods
v0.0.12
What is the future value after 10 years of saving $100 now, with an additional monthly savings of $100. Assume the interest rate is 5% (annually) compounded monthly?
import { fv } from 'financial'
fv(0.05 / 12, 10 * 12, -100, -100) // 15692.928894335748
By convention, the negative sign represents cash flow out (i.e. money not available today). Thus, saving $100 a month at 5% annual interest leads to $15,692.93 available to spend in 10 years.
The future value is computed by solving the equation:
fv + pv * (1+rate) ** nper + pmt * (1 + rate * when) / rate * ((1 + rate) ** nper - 1) == 0
or, when rate == 0
:
fv + pv + pmt * nper == 0
Generated using TypeDoc
Compute the future value.