Expand description
Approximate years to double (Rule of 72 / 69 / 70) and exact doubling time.
Prefer doubling_solution for formulas, comparison tables, and multi-rate scenarios.
Prefer doubling_time when you only need the exact discrete result.
§Error handling (v0.1+)
All public entry points return FinanceResult. Zero or negative rates and non-finite
inputs yield FinanceError — they do not panic.
Structs§
- Doubling
Rate Row - One row of a multi-rate doubling comparison.
- Doubling
Rate Series - Table of doubling estimates across many rates (teaching: when is Rule of 72 “good enough?”).
- Doubling
Solution - Comparison of doubling-time methods at a single rate.
Functions§
- doubling_
compare_ rates - Compare doubling rules across a list of rates (teaching: when is Rule of 72 “good enough?”).
- doubling_
solution - Build a
DoublingSolutioncomparing Rule of 72/70/69 with exact discrete and continuous times. - doubling_
time - Exact periods to double under discrete compounding:
ln(2) / ln(1 + rate). - doubling_
time_ continuous - Exact time to double under continuous compounding:
ln(2) / rate. - rule_
of_ 69 - Approximate years to double using the Rule of 69:
69 / (100 * rate). - rule_
of_ 70 - Approximate years to double using the Rule of 70:
70 / (100 * rate). - rule_
of_ 72 - Approximate years to double using the Rule of 72:
72 / (100 * rate).