How much does your invetment grow after contributions?
Equations for computing how much your investment is worth in the future, with rigorous proofs.
· 6 min read
As a quick “first-order approximation” to how much an investment grows over time with regular contributions (from a salary, for example), it can be useful to have a quick closed-form equation ready.
Let \(p\) be the fixed payment amount at the end of a period, \(n\) the number of periods, \(c_0\) the initial balance, and \(r > 0\) the interest rate per period. We claim that the balance at the \(n\)-th period is \[ \boxed{c_n = c_0 \left(1 + r\right)^n + \frac{p}{r} \left( \left(1 + r\right)^n - 1\right).} \] We’ll prove by induction. In the base case \(n = 0\) the equality clearly holds. Now suppose the equation holds for \(n = k\). Then we have \[ \begin{aligned} c_{k+1} &= c_0 \left(1 + r\right)^{k+1} + \frac{p}{r} \left( \left(1 + r\right)^{k+1} - 1 \right) \\ &= \left(1 + r\right) \left( c_0 \left(1 + r\right)^k + \frac{p}{r} \left(1 + r\right)^k \right) - \frac{p}{r} \\ &= \left(1 + r\right) \left( c_0 \left(1 + r\right)^k + \frac{p}{r} \left( \left(1 + r\right)^k - 1 \right) + \frac{p}{r} \right) - \frac{p}{r} \\ &= \left(1 + r\right) \left( c_0 \left(1 + r\right)^k + \frac{p}{r} \left( \left(1 + r\right)^k - 1 \right) \right) + p \\ &= \left(1 + r\right) c_k + p \end{aligned} \] which recovers the expected recurrence relation as required. An equivalent proof in Lean 4 is as follows:
def fv_fixed (n : ℕ) (p r c₀ : ℝ) : ℝ :=
match n with
| 0 => c₀
| n + 1 => (1 + r) * fv_fixed n p r c₀ + p
noncomputable def fv_fixed_sol (n : ℕ) (p r c₀ : ℝ) : ℝ :=
c₀ * (1 + r) ^ n + p / r * ((1 + r) ^ n - 1)
theorem fv_fixed_sol_satisfied (p r c₀ : ℝ) (rpos : 0 < r) :
∀ n, fv_fixed n p r c₀ = fv_fixed_sol n p r c₀ := by
unfold fv_fixed_sol fv_fixed
intro n
induction n with
| zero => simp
| succ => grind [fv_fixed]
We can “standardise” the equation by dividing it by \(p\), the fixed contribution amount. If we start with an initial ratio of \(c_n / p = 10\), we have the following plot:
We can see that a difference of a few percent in \(r\) can be substantial after a few decades, especially at higher rates. This is why keeping the fees low in any investment is paramount.
Looking at the equation again, we can also immediately see that the ending ratio \(c_n/p\) varies linearly with the initial ratio \(c_0/p\).
Let \(c_0 = 10^5\) and \(p = 10^4\). The following plot shows that if we don’t contribute anything, the balance after many years is substantially lower compared to that with regular contributions, even early on:
This shows the importance of continuing to contribute to the investment on a regular basis rather than simply relying on compounding to do the work.
We can also write a similar equation but with increasing contributions. Let \(p_0\) be the initial payment amount at the end of the first period, \(n\) the number of periods, \(c_0\) the initial balance, \(r\) the investment returns, and \(r_p\) the growth rate of contributions. Then we have \[ \boxed{ c_n = c_0 \left(1 + r\right)^n + \begin{dcases} p_0 \frac{\left(1 + r\right)^n - \left(1 + r_p\right)^n}{r - r_p} & r \ne r_p \\ p_0 n \left(1 + r\right)^{n - 1} & r = r_p \end{dcases} } \] When \(n = 0\) the equality is clear. We first consider the case where \(r = r_p\). At \(n = k + 1\) we have \[ \begin{aligned} c_{k+1} &= c_0 \left(1 + r\right)^{k+1} + p_0 \left(k + 1\right) \left(1 + r\right)^k \\ &= \left( c_0 \left(1 + r\right)^k + p_0 k \left(1 + r\right)^{k-1} + p_0 \left(1 + r\right)^{k-1} \right) \left(1 + r\right) \\ &= \left( c_k + p_0 \left(1 + r\right)^{k-1} \right) \left(1 + r\right) \\ &= c_k \left(1 + r\right) + p_0 \left(1 + r\right)^k \end{aligned} \] which recovers the recurrence relation. Now consider the case where \(r \ne r_p\). At \(n = k + 1\) we have \[ \begin{aligned} c_{k+1} &= c_0 \left(1 + r\right)^{k+1} + p_0 \frac{\left(1 + r\right)^{k+1} - \left(1 + r_p\right)^{k+1}}{r - r_p} \\ &= \left( c_0 \left(1 + r\right)^k + p_0 \frac{\left(1 + r\right)^{k+1} - \left(1 + r_p\right)^{k+1}}{\left(r - r_p\right) \left(1 + r\right)} \right) \left(1 + r\right) \\ &= \left( c_0 \left(1 + r\right)^k + p_0 \left( \frac{\left(1 + r\right)^k}{r - r_p} - \frac{\left(1 + r_p\right)^{k+1}}{\left(1 + r\right) \left(r - r_p\right)} \right) \right) \left(1 + r\right) \\ &= \left( c_k + p_0 \frac{\left(1 + r_p\right)^k}{r - r_p} - p_0 \frac{\left(1 + r_p\right)^{k+1}}{\left(1 + r\right) \left(r - r_p\right)} \right) \left(1 + r\right) \\ &= c_k \left(1 + r\right) + p_0 \frac{\left(1 + r\right) \left(1 + r_p\right)^k}{r - r_p} - p_0 \frac{\left(1 + r_p\right)^{k+1}}{r - r_p} \\ &= c_k \left(1 + r\right) + \left( p_0 \frac{1 + r}{r - r_p} - p_0 \frac{1 + r_p}{r - r_p} \right) \left(1 + r_p\right)^k \\ &= c_k \left(1 + r\right) + p_0 \left(1 + r_p\right)^k \end{aligned} \] as required. Equivalently in Lean 4, which interestingly shows that we don’t need the hypotheses \(r > 0\) and \(r_p > 0\) mathematically:
def fv_inc (n : ℕ) (p₀ r rₚ c₀ : ℝ) : ℝ :=
match n with
| 0 => c₀
| n + 1 => (1 + r) * fv_inc n p₀ r rₚ c₀ + p₀ * (1 + rₚ) ^ n
noncomputable def fv_inc_sol (n : ℕ) (p₀ r rₚ c₀ : ℝ) : ℝ :=
c₀ * (1 + r) ^ n +
if r = rₚ then
p₀ * n * (1 + r) ^ (n - 1)
else
p₀ * ((1 + r) ^ n - (1 + rₚ) ^ n) / (r - rₚ)
theorem fv_inc_sol_satisfied (p₀ r rₚ c₀ : ℝ) :
∀ n, fv_inc n p₀ r rₚ c₀ = fv_inc_sol n p₀ r rₚ c₀ := by
intro n
induction n with
| zero => simp [fv_inc, fv_inc_sol]
| succ n ih =>
simp [fv_inc, fv_inc_sol, ih]
by_cases h_r_eq : r = rₚ
· cases n <;> grind
· grind
In the following plot, we have \(c_0 = 5 \times 10^5\) and \(p_0 = 10^5\). Observe that a modest annual contribution increase of 3% doesn’t do a lot to the balance in the first few decades compared to having no contribution increase at all. The difference does start to grow substantially after about 25 years, though.
I want to caveat that the analyses above are not completely realistic, primarily because investments that return more than 5% in the real world tend to have substantial volatility on a year to year basis. Nevertheless, they can improve our intutions on financial planning.