{
  "controller": "amortization",
  "name": "Amortization schedule \u2014 reconciles to the penny (finance)",
  "kind": "theorem",
  "label": "Reconciliation is proven EXACT and rounding-mode-independent (\u03a3 principal = loan, balance closes to exactly $0.00; the final payment absorbs the accumulated rounding). Banker's rounding is separately proven correct to \u00bd\u00a2 per period (roundHalfEven_half_ulp). And the accumulated rounding is now bounded END-TO-END: MachLib.Real.amortization_drift_within_envelope proves the rounded balance never leaves the certified envelope cap_N = c\u00b7(g\u1d3a\u22121)/(g\u22121) (c=\u00bd\u00a2) around exact arithmetic \u2014 the expansion dual of the closed-loop safety envelope. Here the worst-case cap is $5.02 while the measured drift is only ~$0.05 (real roundings mostly cancel \u2014 the margin is the point, as in the safety card). Everything is INTEGER CENTS \u2014 the reconciliation proof never touches a float; all four finance theorems are sorryAx-free and registered in the claim auditor. Honest scope: this certifies the schedule's reconciliation + rounding + drift envelope, NOT a general decimal library, and it is NOT an audit certification.",
  "source": {
    "lean": "MachLib.FinanceAmortization",
    "theorem": "MachLib.Finance.amortization_reconciles"
  },
  "emitted": [],
  "proof": {
    "theorem": "MachLib.Finance.amortization_reconciles",
    "claim": "a fixed-rate amortization schedule's principal payments sum to EXACTLY the loan amount and the balance closes to exactly $0.00 \u2014 in integer cents, for ANY per-period interest rounding",
    "trail_file": "proof/amortization_reconciles.axioms.txt",
    "clean": true,
    "forbidden_axioms_found": [],
    "rederived": "2026-07-02T08:43:32Z",
    "source_artifact": "MachLib.FinanceAmortization   (machlib module; the theorem's own #print axioms)",
    "reverify": "make verify-proof",
    "tier": "REPLAY (re-derive: TOOLCHAIN \u2014 Lean)"
  },
  "sim": {
    "loan": "$250,000.00 @ 6% APR, 360 months",
    "payment": "$1,498.88/mo",
    "final_payment_drift_cents": 366,
    "sum_principal_cents": 25000000,
    "final_balance_cents": 0,
    "samples": 360,
    "trace_csv": "trace.csv",
    "plot_png": "amortization.png",
    "envelope": {
      "per_period_bound_cents": 0.5,
      "growth_g": 1.005,
      "certified_cap_cents": 502.26,
      "certified_cap_usd": 5.02,
      "measured_max_drift_cents": 5.09,
      "measured_max_drift_usd": 0.05,
      "drift_within_cap": true,
      "closed_form": "cap_N = c\u00b7(g\u1d3a\u22121)/(g\u22121), c = \u00bd\u00a2  (MachLib.Real.amortization_drift_within_envelope)"
    },
    "check": {
      "quantity": "final balance & (\u03a3principal \u2212 P), in cents (exact integer arithmetic)",
      "value": 0,
      "relation": "=",
      "bound": 0,
      "holds": true,
      "context": "schedule reconciles to the penny (final balance $0.00, \u03a3principal = $250,000.00, exact integer cents, never float) \u2014 AND the rounded balance provably never leaves the certified envelope around exact arithmetic: measured max drift $0.05 \u2264 certified cap $5.02 = c\u00b7(g\u1d3a\u22121)/(g\u22121)"
    },
    "tier": "LOCAL"
  },
  "hardware": {
    "tier": "none",
    "note": "\u2014 (a money kernel; the receipt is the proof + the reconciling schedule computed in exact integer cents, not hardware)"
  }
}