FA-63646 / Actuarial life tables / Open access
Gompertz-Makeham survival: Hazard integral starts at the wrong age · case 01
Survival from age x is computed as if from age x+t.
ROOT CAUSE
The age factor uses c^(x+t).
THE FAILURE
The age factor uses c^(x+t).
Unsuccessful approach: Dropping c^x computes survival from age zero.
Case contract
Input A, B, c, age, t (floats). B<0, c<1 or A<=-B -> 'invalid parameters'. Cumulative hazard H = A t + B c^x (c^t-1)/ln c (c=1: (A+B) t). Return [exp(-H), mu at x+t = A + B c^(x+t)] rounded to 8.
Why this case matters
Life-table arithmetic compounds across ages, so one misplaced index or assumption shifts every downstream value.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
A=x['A']; B=x['B']; c=x['c']; a=x['age']; t=x['t']
if B<0 or c<1 or A<=-B: return 'invalid parameters'
if c==1: H=(A+B)*t
else: H=A*t+B*c**(a+t)*(c**t-1)/math.log(c)
mu=A+B*c**(a+t)
return [round(math.exp(-H),8),round(mu,8)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['makeham 0', {'A': 0.001, 'B': 3e-05, 'c': 1.12, 'age': 76, 't': 2.5}, [0.61903389, 0.22014725]], ['makeham 1', {'A': 0.001, 'B': 5e-05, 'c': 1.08, 'age': 44, 't': 10}, [0.96826103, 0.00419046]], ['makeham 2', {'A': 0.001, 'B': 0.0001, 'c': 1.12, 'age': 42, 't': 10}, [0.7970066, 0.03725243]], ['makeham 3', {'A': 0.0005, 'B': 5e-05, 'c': 1.12, 'age': 61, 't': 10}, [0.39101048, 0.15661679]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 51, 't': 3}, [0.98222186, 0.00687488]], ['constant force degenerate', {'A': 0.002, 'B': 0.001, 'c': 1.0, 'age': 40, 't': 4}, [0.98807171, 0.003]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.001, 'B': 3e-05, 'c': 1.08, 'age': 35, 't': 2.5}, [0.99628416, 0.00153767]], ['makeham 1', {'A': 0.001, 'B': 3e-05, 'c': 1.1, 'age': 78, 't': 10}, [0.42348454, 0.13272783]], ['makeham 2', {'A': 0.0007, 'B': 0.0001, 'c': 1.08, 'age': 34, 't': 5}, [0.98822133, 0.00271153]], ['makeham 3', {'A': 0.0005, 'B': 3e-05, 'c': 1.08, 'age': 32, 't': 1}, [0.99913436, 0.00088028]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 52, 't': 3}, [0.98046153, 0.00756237]], ['constant force degenerate', {'A': 0.002, 'B': 0.002, 'c': 1.0, 'age': 40, 't': 4}, [0.98412732, 0.004]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.0005, 'B': 0.0001, 'c': 1.12, 'age': 44, 't': 2.5}, [0.95736913, 0.01993739]], ['makeham 1', {'A': 0.0005, 'B': 5e-05, 'c': 1.08, 'age': 40, 't': 5}, [0.99091741, 0.00209602]], ['makeham 2', {'A': 0.0007, 'B': 3e-05, 'c': 1.08, 'age': 42, 't': 2.5}, [0.99616179, 0.00162146]], ['makeham 3', {'A': 0.0005, 'B': 5e-05, 'c': 1.1, 'age': 58, 't': 5}, [0.92026523, 0.02076325]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 53, 't': 3}, [0.9785288, 0.0083186]], ['constant force degenerate', {'A': 0.002, 'B': 0.003, 'c': 1.0, 'age': 40, 't': 4}, [0.98019867, 0.005]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.0007, 'B': 3e-05, 'c': 1.1, 'age': 36, 't': 1}, [0.99832839, 0.00172012]], ['makeham 1', {'A': 0.0007, 'B': 5e-05, 'c': 1.1, 'age': 45, 't': 10}, [0.93431427, 0.01015296]], ['makeham 2', {'A': 0.0005, 'B': 0.0001, 'c': 1.1, 'age': 76, 't': 10}, [0.0958952, 0.36338659]], ['makeham 3', {'A': 0.0005, 'B': 5e-05, 'c': 1.1, 'age': 53, 't': 5}, [0.94881434, 0.01308189]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 54, 't': 3}, [0.9764072, 0.00915046]], ['constant force degenerate', {'A': 0.002, 'B': 0.004, 'c': 1.0, 'age': 40, 't': 4}, [0.97628571, 0.006]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.0005, 'B': 3e-05, 'c': 1.08, 'age': 65, 't': 10}, [0.93033322, 0.01013614]], ['makeham 1', {'A': 0.0005, 'B': 5e-05, 'c': 1.08, 'age': 49, 't': 2.5}, [0.9927903, 0.00313205]], ['makeham 2', {'A': 0.0005, 'B': 5e-05, 'c': 1.12, 'age': 76, 't': 10}, [0.00599143, 0.85501552]], ['makeham 3', {'A': 0.0005, 'B': 3e-05, 'c': 1.12, 'age': 54, 't': 10}, [0.77220735, 0.04287158]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 55, 't': 3}, [0.97407875, 0.01006551]], ['constant force degenerate', {'A': 0.002, 'B': 0.005, 'c': 1.0, 'age': 40, 't': 4}, [0.97238837, 0.007]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']]]
for label, args, expected in fixtures[N-1]:
check(label, solve(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| makeham 0 | [0.52948031, 0.22014725] | [0.61903389, 0.22014725] | Failed |
| makeham 1 | [0.94360863, 0.00419046] | [0.96826103, 0.00419046] | Failed |
| makeham 2 | [0.50477898, 0.03725243] | [0.7970066, 0.03725243] | Failed |
| makeham 3 | [0.05469805, 0.15661679] | [0.39101048, 0.15661679] | Failed |
| gompertz only | [0.9764072, 0.00687488] | [0.98222186, 0.00687488] | Failed |
| constant force degenerate | [0.98807171, 0.003] | [0.98807171, 0.003] | Passed |
| c below one rejected | invalid parameters | invalid parameters | Passed |
| negative total force rejected | invalid parameters | invalid parameters | Passed |
SHA-256 / aa7225a5ca1b2d72fc70b23300afcdd3e746ad4e8007e8e14cfb912989eea014
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
A=x['A']; B=x['B']; c=x['c']; a=x['age']; t=x['t']
if B<0 or c<1 or A<=-B: return 'invalid parameters'
if c==1: H=(A+B)*t
else: H=A*t+B*(c**t-1)/math.log(c)
mu=A+B*c**(a+t)
return [round(math.exp(-H),8),round(mu,8)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['makeham 0', {'A': 0.001, 'B': 3e-05, 'c': 1.12, 'age': 76, 't': 2.5}, [0.61903389, 0.22014725]], ['makeham 1', {'A': 0.001, 'B': 5e-05, 'c': 1.08, 'age': 44, 't': 10}, [0.96826103, 0.00419046]], ['makeham 2', {'A': 0.001, 'B': 0.0001, 'c': 1.12, 'age': 42, 't': 10}, [0.7970066, 0.03725243]], ['makeham 3', {'A': 0.0005, 'B': 5e-05, 'c': 1.12, 'age': 61, 't': 10}, [0.39101048, 0.15661679]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 51, 't': 3}, [0.98222186, 0.00687488]], ['constant force degenerate', {'A': 0.002, 'B': 0.001, 'c': 1.0, 'age': 40, 't': 4}, [0.98807171, 0.003]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.001, 'B': 3e-05, 'c': 1.08, 'age': 35, 't': 2.5}, [0.99628416, 0.00153767]], ['makeham 1', {'A': 0.001, 'B': 3e-05, 'c': 1.1, 'age': 78, 't': 10}, [0.42348454, 0.13272783]], ['makeham 2', {'A': 0.0007, 'B': 0.0001, 'c': 1.08, 'age': 34, 't': 5}, [0.98822133, 0.00271153]], ['makeham 3', {'A': 0.0005, 'B': 3e-05, 'c': 1.08, 'age': 32, 't': 1}, [0.99913436, 0.00088028]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 52, 't': 3}, [0.98046153, 0.00756237]], ['constant force degenerate', {'A': 0.002, 'B': 0.002, 'c': 1.0, 'age': 40, 't': 4}, [0.98412732, 0.004]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.0005, 'B': 0.0001, 'c': 1.12, 'age': 44, 't': 2.5}, [0.95736913, 0.01993739]], ['makeham 1', {'A': 0.0005, 'B': 5e-05, 'c': 1.08, 'age': 40, 't': 5}, [0.99091741, 0.00209602]], ['makeham 2', {'A': 0.0007, 'B': 3e-05, 'c': 1.08, 'age': 42, 't': 2.5}, [0.99616179, 0.00162146]], ['makeham 3', {'A': 0.0005, 'B': 5e-05, 'c': 1.1, 'age': 58, 't': 5}, [0.92026523, 0.02076325]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 53, 't': 3}, [0.9785288, 0.0083186]], ['constant force degenerate', {'A': 0.002, 'B': 0.003, 'c': 1.0, 'age': 40, 't': 4}, [0.98019867, 0.005]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.0007, 'B': 3e-05, 'c': 1.1, 'age': 36, 't': 1}, [0.99832839, 0.00172012]], ['makeham 1', {'A': 0.0007, 'B': 5e-05, 'c': 1.1, 'age': 45, 't': 10}, [0.93431427, 0.01015296]], ['makeham 2', {'A': 0.0005, 'B': 0.0001, 'c': 1.1, 'age': 76, 't': 10}, [0.0958952, 0.36338659]], ['makeham 3', {'A': 0.0005, 'B': 5e-05, 'c': 1.1, 'age': 53, 't': 5}, [0.94881434, 0.01308189]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 54, 't': 3}, [0.9764072, 0.00915046]], ['constant force degenerate', {'A': 0.002, 'B': 0.004, 'c': 1.0, 'age': 40, 't': 4}, [0.97628571, 0.006]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']], [['makeham 0', {'A': 0.0005, 'B': 3e-05, 'c': 1.08, 'age': 65, 't': 10}, [0.93033322, 0.01013614]], ['makeham 1', {'A': 0.0005, 'B': 5e-05, 'c': 1.08, 'age': 49, 't': 2.5}, [0.9927903, 0.00313205]], ['makeham 2', {'A': 0.0005, 'B': 5e-05, 'c': 1.12, 'age': 76, 't': 10}, [0.00599143, 0.85501552]], ['makeham 3', {'A': 0.0005, 'B': 3e-05, 'c': 1.12, 'age': 54, 't': 10}, [0.77220735, 0.04287158]], ['gompertz only', {'A': 0.0, 'B': 4e-05, 'c': 1.1, 'age': 55, 't': 3}, [0.97407875, 0.01006551]], ['constant force degenerate', {'A': 0.002, 'B': 0.005, 'c': 1.0, 'age': 40, 't': 4}, [0.97238837, 0.007]], ['c below one rejected', {'A': 0.001, 'B': 0.0001, 'c': 0.95, 'age': 40, 't': 1}, 'invalid parameters'], ['negative total force rejected', {'A': -0.01, 'B': 0.001, 'c': 1.1, 'age': 40, 't': 1}, 'invalid parameters']]]
for label, args, expected in fixtures[N-1]:
check(label, solve(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| makeham 0 | [0.99741664, 0.22014725] | [0.61903389, 0.22014725] | Failed |
| makeham 1 | [0.98930468, 0.00419046] | [0.96826103, 0.00419046] | Failed |
| makeham 2 | [0.98821185, 0.03725243] | [0.7970066, 0.03725243] | Failed |
| makeham 3 | [0.99408845, 0.15661679] | [0.39101048, 0.15661679] | Failed |
| gompertz only | [0.99986109, 0.00687488] | [0.98222186, 0.00687488] | Failed |
| constant force degenerate | [0.98807171, 0.003] | [0.98807171, 0.003] | Passed |
| c below one rejected | invalid parameters | invalid parameters | Passed |
| negative total force rejected | invalid parameters | invalid parameters | Passed |
SHA-256 / b9a920fc905ca77e47d8c430e0f643badbeaa92c17c1aaaf0fddbbb833700c88
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 8 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.
Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.
Member access is invitation-based. Sign in with your invited account to inspect the repair.
Sign in to the archive ↗Verification & scope
A deterministic bounded teaching model of a stipulated toy actuarial contract. Rates are small synthetic tables, exact rationals are used where practical and floats are rounded at the output; it makes no claim of conformance with any published table, standard of practice or regulation. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.
Observations recorded using Python 3.12.14 at 2026-09-29T14:47:16.478538+00:00.
Case digest / 76e4746b9abb4c5e20182db1da67fbff10c608748cf15b988d20fa8f88986992