Skip to main content
Systems Guide · Debt & Amortization

How loan amortization works mathematically

Author: WealthSyntax Editorial TeamLast updated: 2026-11-1410 min read
#debt#amortization#compounding

Short answer

Fixed-rate loan amortization models a remaining balance that compounds interest each period before subtracting a constant payment. Solving the recurrence relation so the final balance reaches zero yields a closed-form payment formula using a geometric series. Early payments go mostly toward interest, while later payments steadily shift toward principal reduction.

Mathematical Model & Derivation

Step-by-step derivation and symbol definitions

Fixed Periodic Payment Closed-Form Formula
M = (P * r) / (1 - (1 + r)^(-n))

Symbol Definitions

PInitial loan principal borrowed at time t = 0 (e.g., $300,000)
rPeriodic interest rate as a decimal (for monthly loans: annual rate / 12)
nTotal number of scheduled payment periods (years * 12 for monthly loans)
MConstant total payment due at the end of each period
B_tRemaining unpaid principal balance immediately after payment t
1

State the Period-by-Period Balance Recurrence

Each period, the prior unpaid balance B_(t-1) accrues periodic interest B_(t-1) * r, and the borrower sends a fixed payment M. The remaining principal balance after period t equals the grown balance minus the payment.

Balance Recurrence Relation
B_t = B_(t-1) * (1 + r) - M, with B_0 = P
2

Unroll the Recurrence Across n Periods

Expanding B_1, B_2, up to B_n shows initial principal compounding by (1 + r)^n while each payment M offsets future compounding from its payment date through period n.

Expanded Balance at Period n
B_n = P(1 + r)^n - M * sum from k=0 to n-1 of (1 + r)^k
3

Collapse the Geometric Series

For any r > 0, the sum of (1 + r)^k from k = 0 to n - 1 is a finite geometric series equal to ((1 + r)^n - 1) / r.

Geometric Series Identity
sum from k=0 to n-1 of (1 + r)^k = ((1 + r)^n - 1) / r
4

Impose the Zero-Balance Terminal Condition (B_n = 0)

Setting B_n = 0 and solving for M isolates the fixed payment. Dividing numerator and denominator by (1 + r)^n yields the compact negative-exponent form used in calculators and spreadsheets.

Closed-Form Amortization Payment
M = (P * r) / (1 - (1 + r)^(-n))

Why Early Payments Are Mostly Interest

Although total monthly payment M never changes on a fixed-rate loan, the split between interest and principal shifts continuously. In Month 1 of a $300,000 loan at 6.50% APR (r = 0.065 / 12 = 0.0054167), the interest charge on the full $300,000 balance is $1,625.00. That leaves just $271.20 of the $1,896.20 payment to reduce principal—an interest share of 85.70%.

By Month 360, the remaining balance has fallen to $1,885.99, so interest for the final month drops to $10.22 (0.54% of the payment), while $1,885.99 clears the remaining principal to $0.00.

15-Year vs. 30-Year Terms and Extra Principal Payments

Because total interest paid over a standard schedule equals n * M - P, shortening the term n or applying extra principal directly cuts the balance on which future interest accrues.

Sending just one extra full payment toward principal at the end of each year (equivalent to 13 payments per year) eliminates several years of payments from the back of a 30-year mortgage and saves substantial cumulative interest without altering the monthly contract obligation.

Scenario Comparison: $300,000 Principal at 6.50% Annual Interest
Loan StrategyPayoff HorizonBase Monthly PaymentTotal PaidTotal InterestInterest Saved vs. Base
30-Year Fixed (Baseline)30.0 years (360 mo)$1,896.20$682,633.47$382,633.47Baseline
30-Year + 1 Extra Payment/Yr24.3 years (292 mo)$1,896.20$598,648.95$298,648.95$83,984.52
15-Year Fixed15.0 years (180 mo)$2,613.32$470,397.98$170,397.98$212,235.49
Worked Example · Computed in Code

Worked Schedule: $300,000 Mortgage at 6.50% for 30 Years

Every value below is computed month-by-month from P = $300,000, nominal annual rate 6.50% (r = 0.065 / 12), and n = 360 monthly payments.

Fixed Monthly Payment (M)
$1,896.20
Total Interest (30 Years)
$382,633.47
Month 1 vs Month 360 Interest Share
85.7% → 0.54%
Amortization Milestones: First 12 Months, Then Every 5 Years ($300,000 @ 6.50%)
MonthMonthly PaymentInterest PaidPrincipal PaidEnding Balance
Month 1$1,896.20$1,625.00$271.20$299,728.80
Month 2$1,896.20$1,623.53$272.67$299,456.12
Month 3$1,896.20$1,622.05$274.15$299,181.97
Month 4$1,896.20$1,620.57$275.64$298,906.34
Month 5$1,896.20$1,619.08$277.13$298,629.21
Month 6$1,896.20$1,617.57$278.63$298,350.58
Month 7$1,896.20$1,616.07$280.14$298,070.44
Month 8$1,896.20$1,614.55$281.66$297,788.79
Month 9$1,896.20$1,613.02$283.18$297,505.60
Month 10$1,896.20$1,611.49$284.72$297,220.89
Month 11$1,896.20$1,609.95$286.26$296,934.63
Month 12$1,896.20$1,608.40$287.81$296,646.82
Month 60$1,896.20$1,523.20$373.01$280,832.93
Month 120$1,896.20$1,380.41$515.80$254,328.38
Month 180$1,896.20$1,182.95$713.25$217,677.42
Month 240$1,896.20$909.90$986.30$166,995.85
Month 300$1,896.20$532.33$1,363.87$96,912.49
Month 360$1,896.20$10.22$1,885.99$0.00
Result check: Total cash paid over 360 months is $682,633.47, of which $382,633.47 is interest (matching n*M - P = $382,633.47) and the ending balance reaches $0.00.
Reference Implementations

Amortization Payment Formula (Python & JavaScript)

Closed-form monthly payment calculation from principal, annual nominal rate, and loan years.

PythonStandard library only
def monthly_payment(principal, annual_rate, years):
    r = annual_rate / 12.0
    n = years * 12
    return principal * r / (1.0 - (1.0 + r) ** (-n))

print(round(monthly_payment(300000, 0.065, 30), 2))
JavaScriptZero dependencies
function monthlyPayment(principal, annualRate, years) {
  const r = annualRate / 12;
  const n = years * 12;
  return (principal * r) / (1 - Math.pow(1 + r, -n));
}

console.log(Number(monthlyPayment(300000, 0.065, 30).toFixed(2)));
Output for ($300,000, 6.5%, 30 yr): 1896.20
Analytical Pitfalls

Common mistakes

  • 01.Plugging the annual interest rate (e.g., 0.065) directly into r instead of dividing by 12 for monthly payments.
  • 02.Mixing period counts and payment frequency—such as entering 30 years instead of 360 months alongside a monthly interest rate.
  • 03.Confusing principal-and-interest (P&I) with total housing outflow, which omits property taxes, homeowners insurance, and HOA dues.
  • 04.Assuming prepaying extra principal lowers next month's required contractual payment rather than shortening the remaining schedule.
Model Boundaries

Key assumptions and limits

  • Applies strictly to fixed-rate, fully amortizing loans with uniform end-of-period payments.
  • Excludes adjustable-rate mortgage (ARM) index resets, interest-only periods, and balloon payments.
  • Omits closing costs, discount points, private mortgage insurance (PMI), property taxes, and escrow adjustments.
  • Lender statements may differ by a few cents due to per-payment cent rounding and final-month penny reconciliation.
Further Reading
learnLive

Compound Interest Explained as a Feedback Loop

How the same geometric series machinery governs compounding savings and loan balances.

Open resource
booksLive

The Debt Loop (Money Under the Hood)

Reverse compounding, amortization mechanics, and systematic debt payoff models.

Open resource
questionsLive

How Is the Compound Interest Formula Derived?

Proof of geometric series summation and exponential recurrence relations.

Open resource
glossaryPlanned

Amortization (Glossary)

Gradual repayment of principal and interest through scheduled equal installments.

Plain text reference (coming soon)
glossaryPlanned

APR — Annual Percentage Rate (Glossary)

Annualized borrowing rate versus effective monthly compounding yield.

Plain text reference (coming soon)

Educational content only, not financial advice. Examples use constant or illustrative hypothetical returns.

Author: WealthSyntax Editorial Team · Last updated: 2026-11-14