Note
Go to the end to download the full example code or to run this example in your browser via JupyterLite.
Pacioli’s rule of 72#
Luca Pacioli’s Summa de arithmetica (1494) gives, without proof, a rule for how long money takes to double: divide 72 by the annual interest rate in percent. The exact doubling time with annual compounding is \(\ln 2 / \ln(1 + r)\), and since \(\ln(1 + r) \approx r - r^2/2\) the best constant drifts upward with the rate; 72 is close to right near 8% and has many convenient divisors.
import matplotlib.pyplot as plt
import numpy as np
from financialkit.time_value import doubling_time, rule_of_72
The rule against the exact answer#
for r in (0.02, 0.06, 0.08, 0.12, 0.24):
print(f"{r:5.0%}: rule {rule_of_72(r):6.2f} years, exact {doubling_time(r, compounding=1):6.2f} years")
2%: rule 36.00 years, exact 35.00 years
6%: rule 12.00 years, exact 11.90 years
8%: rule 9.00 years, exact 9.01 years
12%: rule 6.00 years, exact 6.12 years
24%: rule 3.00 years, exact 3.22 years
Relative error of the rules of 69.3, 70 and 72#
69.3 is exact for continuous compounding; with annual compounding a larger constant is better.
r = np.linspace(0.01, 0.30, 300)
exact = doubling_time(r, compounding=1)
fig, ax = plt.subplots(figsize=(7, 4.5))
for c in (69.3, 70.0, 72.0):
ax.plot(100 * r, 100 * (rule_of_72(r, numerator=c) / exact - 1), label=f"rule of {c:g}")
ax.axhline(0.0, color="k", lw=0.8)
ax.set_xlabel("annual rate (%)")
ax.set_ylabel("error vs exact doubling time (%)")
ax.set_title("Pacioli's rule of 72")
ax.legend()
plt.show()

Total running time of the script: (0 minutes 0.031 seconds)