{
  "tool_id": "art-327-tvm-annuity",
  "note": "golden_hash is empty until first golden-parity.test.mjs --update. Vector 1: solve-for-pv, closed-form annuity factor cross-checked against an independent 100*(1-(1+r)^-n)/r calculation. Vector 2: solve-for-fv, cross-checked against an independent -(pv*(1+r)^n + pmt*((1+r)^n-1)/r) calculation.",
  "vectors": [
    {
      "name": "annuity_solve_pv",
      "description": "Ordinary annuity: monthly rate 0.666...% (8%/12), 24 periods, payment -100, fv 0. Solve PV. Independent check: 100*(1-(1.0066667)^-24)/0.0066667 = 2211.054.",
      "policy_parameters": {
        "rate_pct": 0.6666666666666667,
        "nper": 24,
        "pmt": -100,
        "fv": 0,
        "solve_for": "pv"
      },
      "output_payload": {
        "solved_for": "pv",
        "pv": 2211.05,
        "fv": 0,
        "pmt": -100,
        "rate_pct": 0.6666666666666667,
        "nper": 24,
        "due": false,
        "annuity_factor": 22.110544,
        "regulatory_basis": "Standard time-value-of-money annuity identity (Excel PV/FV/PMT semantics), ordinary and annuity-due",
        "note": "One of pv/fv/pmt is solved from the other two plus rate_pct/nper via the closed-form annuity factor (1-(1+r)^-n)/r, adjusted by (1+r) when due=true (annuity-due, payments at period start). Deterministic pow via Taylor-series exp/ln, no engine transcendentals."
      },
      "golden_hash": "42832d63fb85ff935d5bfb71f3eaf64ec21ef45c0e08499c1b1f6dccc537c66b"
    },
    {
      "name": "annuity_solve_fv",
      "description": "Ordinary annuity: monthly rate 0.5% (6%/12), 10 periods, pv -500, pmt -200. Solve FV. Independent check: -(-500*1.005^10 + -200*(1.005^10-1)/0.005) = 2571.175.",
      "policy_parameters": {
        "rate_pct": 0.5,
        "nper": 10,
        "pv": -500,
        "pmt": -200,
        "solve_for": "fv"
      },
      "output_payload": {
        "solved_for": "fv",
        "pv": -500,
        "fv": 2571.18,
        "pmt": -200,
        "rate_pct": 0.5,
        "nper": 10,
        "due": false,
        "annuity_factor": 9.730412,
        "regulatory_basis": "Standard time-value-of-money annuity identity (Excel PV/FV/PMT semantics), ordinary and annuity-due",
        "note": "One of pv/fv/pmt is solved from the other two plus rate_pct/nper via the closed-form annuity factor (1-(1+r)^-n)/r, adjusted by (1+r) when due=true (annuity-due, payments at period start). Deterministic pow via Taylor-series exp/ln, no engine transcendentals."
      },
      "golden_hash": "e60e97ed38cf6a1be4c047b9018bde5afcb8af8bc7e3b16974f4ad7be6a0572f"
    }
  ]
}
