Repository navigation
Conversation
The annuity conversion formula in the pv_to_annuity docstring had an incorrect numerator: i + (1+i)^N instead of i(1+i)^N. The actual implementation was already correct; only the documentation math formula was wrong. Fixes TemoaProject#384
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
WalkthroughThe ChangesAnnuity formula documentation
Priority: ⬇️ Low Estimated code review effort: 1 (Trivial) | ~2 minutes Change: Other · Severity of issue fixed: Low Suggested reviewers: Merge Risk: ⚪ Minimal · up to
|
Description
The annuity conversion formula in the
pv_to_annuitydocstring had an incorrect numerator:Before (wrong):
\frac{A}{P}(i, N) = \frac{i + (1 + i)^N}{(1 + i)^N - 1}
After (correct):
\frac{A}{P}(i, N) = \frac{i(1 + i)^N}{(1 + i)^N - 1}
The actual implementation was already correct; only the documentation math formula was wrong.
Fixes #384
Summary by CodeRabbit