Inspectable Arithmetic for the Mortgage Calculator

Version 1.2
Last verified: May 2026

Transparent arithmetic is the operating system of this calculator.

This document publishes the formulae, computational structure, and assumptions used to generate the outputs displayed on the calculator page.

No opinions. No hidden assumptions. Just arithmetic.

Purpose

This calculator models fixed-rate mortgage amortization under constant interest assumptions. It computes payment amounts by frequency, an amortization schedule, total interest paid, total paid, and payoff time.

For a conceptual walkthrough of mortgage payments in Canada, see How Does a Mortgage Work in Canada?

Definitions

Let:

Canadian Mortgage Rate Convention

Canadian mortgage rates are generally quoted as nominal annual rates compounded semi-annually, not as monthly-compounded rates. This calculator converts the entered nominal annual mortgage rate into an equivalent payment-period rate before calculating interest.

For a payment frequency with n payments per year:

rp = (1 + r / 2)2 / n − 1

where:

For monthly payments:

rm = (1 + r / 2)1 / 6 − 1

For biweekly payments:

rbw = (1 + r / 2)2 / 26 − 1

For weekly payments:

rw = (1 + r / 2)2 / 52 − 1

Payment-size conventions remain separate from interest-rate conversion. Accelerated biweekly and accelerated weekly payments use the same periodic interest-rate conversion as ordinary biweekly and weekly schedules; they simply use larger payment amounts.

Formulae

1. Loan Amount

L = max(0, H − D)

Down payment may be entered as a dollar amount or a percentage of home price.

2. Standard Monthly Payment (Base Payment)

If r = 0:

Pm = L / (12T)

Otherwise:

rm = (1 + r / 2)1 / 6 − 1
Pm = L · rm / (1 − (1 + rm)−12T)

Rationale: This is the standard fixed-rate fully amortizing payment formula for a monthly schedule.

Limitation: Assumes a constant nominal annual mortgage rate and constant amortization horizon.

3. Payment Amount by Frequency

Payment frequency options and payment amount conventions:

Monthly (12/yr):

P = Pm

Bi-weekly (26/yr), “standard”:

P = Pm · 12/26

Weekly (52/yr), “standard”:

P = Pm · 12/52

Accelerated bi-weekly (26/yr):

P = Pm / 2

Accelerated weekly (52/yr):

P = Pm / 4

Rationale: Standard weekly/bi-weekly payments scale the monthly payment to preserve the same annual payment total. Accelerated schedules increase the annual payment total by using the “monthly fraction” convention (monthly/2 or monthly/4).

Limitation: This models payment amount conventions, not lender-specific billing rules.

4. Periodic Interest and Principal

Periodic rate uses the Canadian mortgage-rate conversion for the selected payment frequency:

rp = (1 + r / 2)2 / n − 1

For each payment period t ≥ 1:

Interestt = Bt−1 · rp
Principalt = P − Interestt

Rationale: The entered nominal annual mortgage rate is first converted into an equivalent payment-period rate, then applied period-by-period to the outstanding balance.

5. Balance Update

Bt = Bt−1 − Principalt
with B0 = L

If Principalt > Bt−1, the principal portion is capped at Bt−1 so the balance does not go negative (final-payment clamp).

6. Total Interest Paid and Total Paid

TotalInterest = Σ Interestt
TotalPaid = L + TotalInterest

7. Payoff Time

If the loan amortizes successfully, payoff time in years is:

PayoffYears = (number of payments made) / n

Assumptions

  1. The entered rate is treated as a Canadian nominal annual mortgage rate compounded semi-annually.
  2. The calculator converts that rate into an equivalent payment-period rate for amortization.
  3. Interest rate remains constant over the modeled horizon.
  4. Payments occur at the selected frequency and remain constant under the selected payment convention.
  5. This still does not model lender-specific rounding, payment timing quirks, mortgage insurance, prepayments, refinancing, penalties, taxes, or rate changes.
  6. The amortization schedule is simulated period-by-period until the balance reaches zero (subject to rounding).
  7. Rounding occurs at the display layer; internal calculations use floating-point arithmetic.

Implementation Notes

If any discrepancy is identified between this documentation and the calculator output, the arithmetic here governs.

Sources and References