FA-61156 / Bond day-count conventions / Open access
Business/252 day count with daily compounding factor: the exponent uses calendar days over 365 · case 01
Accrual factors disagree with the business-day basis on every span containing weekends.
ROOT CAUSE
The exponent uses calendar days divided by 365.
VERIFIED REPAIR
Use business days divided by 252.
Unsuccessful approach: Dividing calendar days by 252 overstates the exponent.
Case contract
Inputs start and end [y,m,d], a holiday list (may contain weekend dates and duplicates) and an annual rate in percent. bd counts weekdays in [start, end) that are not holidays. Factor = (1 + rate/100)^(bd/252). Return [bd, factor rounded to 8 decimals].
Why this case matters
Bond accrual and pricing systems depend on exact day-count arithmetic; a single-day error changes settlement cash.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import datetime
N = 1
observations = []
def solve(start, end, holidays, rate):
S = datetime.date(*start)
E = datetime.date(*end)
H = {datetime.date(*h) for h in holidays}
bd = 0
x = S
while x < E:
if x.weekday() < 5 and x not in H:
bd += 1
x += datetime.timedelta(days=1)
factor = (1 + rate / 100) ** ((E - S).days / 365)
return [bd, round(factor, 8)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression compounding exponent basis 1', [[2021, 2, 28], [2021, 10, 29], [[2021, 9, 13], [2021, 7, 30], [2021, 7, 30], [2021, 9, 28], [2021, 7, 16]], 6.5], [170, 1.04339832]], ['regression compounding exponent basis 2', [[2023, 8, 28], [2023, 10, 29], [], 6.5], [45, 1.01130897]], ['partial repair probe 1', [[2028, 6, 28], [2028, 9, 1], [[2028, 8, 26], [2028, 7, 24], [2028, 7, 2], [2028, 7, 10]], 13.65], [45, 1.02311185]], ['partial repair probe 2', [[2028, 8, 31], [2028, 12, 22], [[2028, 10, 16], [2028, 9, 12], [2028, 11, 7], [2028, 9, 8], [2028, 11, 20], [2028, 11, 16]], 13.65], [75, 1.03881575]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2020, 8, 24], [2020, 8, 24], [[2020, 8, 29], [2020, 8, 29], [2020, 8, 21], [2020, 8, 25]], 13.65], [0, 1.0]], ['normal control 2', [[2026, 6, 21], [2026, 6, 21], [], 13.65], [0, 1.0]], ['normal control 3', [[2019, 12, 8], [2019, 12, 8], [[2019, 12, 7], [2019, 12, 3], [2019, 12, 11], [2019, 12, 8], [2019, 12, 8], [2019, 12, 12]], 6.5], [0, 1.0]]], [['regression compounding exponent basis 1', [[2026, 5, 25], [2026, 12, 13], [[2026, 6, 14], [2026, 11, 24], [2026, 9, 23], [2026, 8, 30], [2026, 12, 17]], 6.5], [143, 1.03638189]], ['regression compounding exponent basis 2', [[2023, 3, 30], [2024, 2, 18], [[2023, 12, 29], [2023, 12, 29], [2023, 7, 25], [2023, 7, 25], [2023, 8, 23], [2023, 5, 20], [2023, 4, 25]], 6.5], [228, 1.05863167]], ['partial repair probe 1', [[2022, 6, 4], [2022, 6, 6], [[2022, 6, 4], [2022, 5, 30]], 6.5], [0, 1.0]], ['partial repair probe 2', [[2024, 7, 13], [2024, 12, 3], [[2024, 10, 10], [2024, 7, 26], [2024, 7, 28], [2024, 9, 23], [2024, 9, 23], [2024, 9, 2]], 6.5], [97, 1.02453648]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2022, 7, 3], [2022, 7, 3], [[2022, 7, 1], [2022, 7, 5], [2022, 7, 7]], 2.0], [0, 1.0]], ['normal control 2', [[2020, 8, 31], [2020, 8, 31], [[2020, 9, 2], [2020, 9, 2], [2020, 8, 31], [2020, 8, 31]], 6.5], [0, 1.0]], ['normal control 3', [[2030, 8, 24], [2030, 8, 24], [[2030, 8, 27], [2030, 8, 26], [2030, 8, 19], [2030, 8, 29], [2030, 8, 25]], 2.0], [0, 1.0]]], [['regression compounding exponent basis 1', [[2028, 3, 8], [2029, 2, 22], [[2028, 4, 14], [2028, 10, 23], [2028, 11, 28], [2028, 9, 2], [2028, 9, 2]], 10.75], [248, 1.10570651]], ['regression compounding exponent basis 2', [[2018, 3, 22], [2019, 2, 20], [[2018, 3, 26], [2018, 3, 31]], 13.65], [238, 1.12844981]], ['partial repair probe 1', [[2020, 3, 11], [2021, 1, 24], [[2020, 9, 21], [2020, 11, 25], [2020, 7, 4]], 13.65], [226, 1.12159505]], ['partial repair probe 2', [[2020, 11, 2], [2021, 4, 12], [[2021, 4, 10], [2021, 4, 10], [2021, 3, 24], [2020, 11, 6], [2021, 1, 28]], 6.5], [112, 1.02838417]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2021, 7, 9], [2021, 7, 9], [[2021, 7, 9]], 10.75], [0, 1.0]], ['normal control 2', [[2024, 4, 4], [2024, 4, 4], [[2024, 3, 30], [2024, 3, 30]], 10.75], [0, 1.0]], ['normal control 3', [[2026, 1, 30], [2026, 1, 30], [[2026, 2, 2], [2026, 1, 28], [2026, 1, 30], [2026, 1, 31], [2026, 2, 1], [2026, 2, 4]], 13.65], [0, 1.0]]], [['regression compounding exponent basis 1', [[2027, 2, 28], [2027, 9, 24], [[2027, 4, 18], [2027, 4, 18], [2027, 9, 16], [2027, 5, 31], [2027, 8, 17], [2027, 8, 17]], 6.5], [146, 1.03715916]], ['regression compounding exponent basis 2', [[2025, 1, 18], [2026, 1, 1], [[2025, 11, 30], [2025, 11, 30], [2025, 12, 27], [2025, 3, 2], [2025, 3, 23], [2025, 10, 12]], 13.65], [248, 1.1341941]], ['partial repair probe 1', [[2029, 3, 31], [2029, 4, 29], [[2029, 4, 2], [2029, 3, 26], [2029, 4, 7], [2029, 4, 7]], 2.0], [19, 1.00149417]], ['partial repair probe 2', [[2020, 4, 29], [2020, 5, 7], [], 13.65], [6, 1.00305115]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2028, 11, 30], [2028, 11, 30], [[2028, 11, 27], [2028, 11, 30], [2028, 12, 3], [2028, 12, 5], [2028, 12, 5], [2028, 11, 27], [2028, 11, 29]], 10.75], [0, 1.0]], ['normal control 2', [[2029, 10, 30], [2029, 10, 30], [], 2.0], [0, 1.0]], ['normal control 3', [[2019, 7, 31], [2019, 7, 31], [[2019, 7, 26], [2019, 7, 26], [2019, 7, 30], [2019, 7, 27], [2019, 8, 5], [2019, 8, 4], [2019, 8, 3]], 10.75], [0, 1.0]]], [['regression compounding exponent basis 1', [[2022, 10, 19], [2023, 1, 20], [[2023, 1, 17], [2023, 1, 5], [2023, 1, 5], [2022, 11, 13]], 6.5], [65, 1.01637614]], ['regression compounding exponent basis 2', [[2026, 7, 30], [2027, 2, 1], [[2026, 11, 17], [2026, 11, 17], [2026, 10, 23], [2026, 10, 16], [2026, 10, 15], [2026, 10, 15], [2026, 12, 19]], 13.65], [128, 1.06715068]], ['partial repair probe 1', [[2029, 9, 27], [2030, 4, 14], [[2030, 3, 26], [2030, 3, 26], [2030, 2, 15], [2030, 2, 15]], 13.65], [140, 1.0736727]], ['partial repair probe 2', [[2019, 2, 28], [2020, 4, 3], [[2020, 1, 20], [2019, 11, 27], [2019, 11, 28]], 2.0], [283, 1.02248779]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2027, 5, 13], [2027, 5, 13], [[2027, 5, 16], [2027, 5, 10], [2027, 5, 10]], 2.0], [0, 1.0]], ['normal control 2', [[2023, 5, 30], [2023, 5, 30], [[2023, 6, 3], [2023, 5, 25], [2023, 6, 1], [2023, 6, 2], [2023, 5, 25]], 6.5], [0, 1.0]], ['normal control 3', [[2026, 6, 16], [2026, 6, 16], [], 2.0], [0, 1.0]]]]
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 |
|---|---|---|---|
| regression compounding exponent basis 1 | [170, 1.04281698] | [170, 1.04339832] | Failed |
| regression compounding exponent basis 2 | [45, 1.01075451] | [45, 1.01130897] | Failed |
| partial repair probe 1 | [45, 1.0230478] | [45, 1.02311185] | Failed |
| partial repair probe 2 | [75, 1.04040802] | [75, 1.03881575] | Failed |
| boundary control 1 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 1 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 2 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 3 | [0, 1.0] | [0, 1.0] | Passed |
SHA-256 / b140fd745b8104ae7d2928785aa52b9de13aa07700371e3d1ca4d1f4b529b801
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import datetime
N = 1
observations = []
def solve(start, end, holidays, rate):
S = datetime.date(*start)
E = datetime.date(*end)
H = {datetime.date(*h) for h in holidays}
bd = 0
x = S
while x < E:
if x.weekday() < 5 and x not in H:
bd += 1
x += datetime.timedelta(days=1)
factor = (1 + rate / 100) ** ((E - S).days / 252)
return [bd, round(factor, 8)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression compounding exponent basis 1', [[2021, 2, 28], [2021, 10, 29], [[2021, 9, 13], [2021, 7, 30], [2021, 7, 30], [2021, 9, 28], [2021, 7, 16]], 6.5], [170, 1.04339832]], ['regression compounding exponent basis 2', [[2023, 8, 28], [2023, 10, 29], [], 6.5], [45, 1.01130897]], ['partial repair probe 1', [[2028, 6, 28], [2028, 9, 1], [[2028, 8, 26], [2028, 7, 24], [2028, 7, 2], [2028, 7, 10]], 13.65], [45, 1.02311185]], ['partial repair probe 2', [[2028, 8, 31], [2028, 12, 22], [[2028, 10, 16], [2028, 9, 12], [2028, 11, 7], [2028, 9, 8], [2028, 11, 20], [2028, 11, 16]], 13.65], [75, 1.03881575]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2020, 8, 24], [2020, 8, 24], [[2020, 8, 29], [2020, 8, 29], [2020, 8, 21], [2020, 8, 25]], 13.65], [0, 1.0]], ['normal control 2', [[2026, 6, 21], [2026, 6, 21], [], 13.65], [0, 1.0]], ['normal control 3', [[2019, 12, 8], [2019, 12, 8], [[2019, 12, 7], [2019, 12, 3], [2019, 12, 11], [2019, 12, 8], [2019, 12, 8], [2019, 12, 12]], 6.5], [0, 1.0]]], [['regression compounding exponent basis 1', [[2026, 5, 25], [2026, 12, 13], [[2026, 6, 14], [2026, 11, 24], [2026, 9, 23], [2026, 8, 30], [2026, 12, 17]], 6.5], [143, 1.03638189]], ['regression compounding exponent basis 2', [[2023, 3, 30], [2024, 2, 18], [[2023, 12, 29], [2023, 12, 29], [2023, 7, 25], [2023, 7, 25], [2023, 8, 23], [2023, 5, 20], [2023, 4, 25]], 6.5], [228, 1.05863167]], ['partial repair probe 1', [[2022, 6, 4], [2022, 6, 6], [[2022, 6, 4], [2022, 5, 30]], 6.5], [0, 1.0]], ['partial repair probe 2', [[2024, 7, 13], [2024, 12, 3], [[2024, 10, 10], [2024, 7, 26], [2024, 7, 28], [2024, 9, 23], [2024, 9, 23], [2024, 9, 2]], 6.5], [97, 1.02453648]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2022, 7, 3], [2022, 7, 3], [[2022, 7, 1], [2022, 7, 5], [2022, 7, 7]], 2.0], [0, 1.0]], ['normal control 2', [[2020, 8, 31], [2020, 8, 31], [[2020, 9, 2], [2020, 9, 2], [2020, 8, 31], [2020, 8, 31]], 6.5], [0, 1.0]], ['normal control 3', [[2030, 8, 24], [2030, 8, 24], [[2030, 8, 27], [2030, 8, 26], [2030, 8, 19], [2030, 8, 29], [2030, 8, 25]], 2.0], [0, 1.0]]], [['regression compounding exponent basis 1', [[2028, 3, 8], [2029, 2, 22], [[2028, 4, 14], [2028, 10, 23], [2028, 11, 28], [2028, 9, 2], [2028, 9, 2]], 10.75], [248, 1.10570651]], ['regression compounding exponent basis 2', [[2018, 3, 22], [2019, 2, 20], [[2018, 3, 26], [2018, 3, 31]], 13.65], [238, 1.12844981]], ['partial repair probe 1', [[2020, 3, 11], [2021, 1, 24], [[2020, 9, 21], [2020, 11, 25], [2020, 7, 4]], 13.65], [226, 1.12159505]], ['partial repair probe 2', [[2020, 11, 2], [2021, 4, 12], [[2021, 4, 10], [2021, 4, 10], [2021, 3, 24], [2020, 11, 6], [2021, 1, 28]], 6.5], [112, 1.02838417]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2021, 7, 9], [2021, 7, 9], [[2021, 7, 9]], 10.75], [0, 1.0]], ['normal control 2', [[2024, 4, 4], [2024, 4, 4], [[2024, 3, 30], [2024, 3, 30]], 10.75], [0, 1.0]], ['normal control 3', [[2026, 1, 30], [2026, 1, 30], [[2026, 2, 2], [2026, 1, 28], [2026, 1, 30], [2026, 1, 31], [2026, 2, 1], [2026, 2, 4]], 13.65], [0, 1.0]]], [['regression compounding exponent basis 1', [[2027, 2, 28], [2027, 9, 24], [[2027, 4, 18], [2027, 4, 18], [2027, 9, 16], [2027, 5, 31], [2027, 8, 17], [2027, 8, 17]], 6.5], [146, 1.03715916]], ['regression compounding exponent basis 2', [[2025, 1, 18], [2026, 1, 1], [[2025, 11, 30], [2025, 11, 30], [2025, 12, 27], [2025, 3, 2], [2025, 3, 23], [2025, 10, 12]], 13.65], [248, 1.1341941]], ['partial repair probe 1', [[2029, 3, 31], [2029, 4, 29], [[2029, 4, 2], [2029, 3, 26], [2029, 4, 7], [2029, 4, 7]], 2.0], [19, 1.00149417]], ['partial repair probe 2', [[2020, 4, 29], [2020, 5, 7], [], 13.65], [6, 1.00305115]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2028, 11, 30], [2028, 11, 30], [[2028, 11, 27], [2028, 11, 30], [2028, 12, 3], [2028, 12, 5], [2028, 12, 5], [2028, 11, 27], [2028, 11, 29]], 10.75], [0, 1.0]], ['normal control 2', [[2029, 10, 30], [2029, 10, 30], [], 2.0], [0, 1.0]], ['normal control 3', [[2019, 7, 31], [2019, 7, 31], [[2019, 7, 26], [2019, 7, 26], [2019, 7, 30], [2019, 7, 27], [2019, 8, 5], [2019, 8, 4], [2019, 8, 3]], 10.75], [0, 1.0]]], [['regression compounding exponent basis 1', [[2022, 10, 19], [2023, 1, 20], [[2023, 1, 17], [2023, 1, 5], [2023, 1, 5], [2022, 11, 13]], 6.5], [65, 1.01637614]], ['regression compounding exponent basis 2', [[2026, 7, 30], [2027, 2, 1], [[2026, 11, 17], [2026, 11, 17], [2026, 10, 23], [2026, 10, 16], [2026, 10, 15], [2026, 10, 15], [2026, 12, 19]], 13.65], [128, 1.06715068]], ['partial repair probe 1', [[2029, 9, 27], [2030, 4, 14], [[2030, 3, 26], [2030, 3, 26], [2030, 2, 15], [2030, 2, 15]], 13.65], [140, 1.0736727]], ['partial repair probe 2', [[2019, 2, 28], [2020, 4, 3], [[2020, 1, 20], [2019, 11, 27], [2019, 11, 28]], 2.0], [283, 1.02248779]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2027, 5, 13], [2027, 5, 13], [[2027, 5, 16], [2027, 5, 10], [2027, 5, 10]], 2.0], [0, 1.0]], ['normal control 2', [[2023, 5, 30], [2023, 5, 30], [[2023, 6, 3], [2023, 5, 25], [2023, 6, 1], [2023, 6, 2], [2023, 5, 25]], 6.5], [0, 1.0]], ['normal control 3', [[2026, 6, 16], [2026, 6, 16], [], 2.0], [0, 1.0]]]]
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 |
|---|---|---|---|
| regression compounding exponent basis 1 | [170, 1.0626074] | [170, 1.04339832] | Failed |
| regression compounding exponent basis 2 | [45, 1.01561445] | [45, 1.01130897] | Failed |
| partial repair probe 1 | [45, 1.03355451] | [45, 1.02311185] | Failed |
| partial repair probe 2 | [75, 1.05905385] | [75, 1.03881575] | Failed |
| boundary control 1 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 1 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 2 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 3 | [0, 1.0] | [0, 1.0] | Passed |
SHA-256 / 87c225049319effceb19426d6d07d11199cd2883292b1cfbf7341613b328308d
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
import datetime
N = 1
observations = []
def solve(start, end, holidays, rate):
S = datetime.date(*start)
E = datetime.date(*end)
H = {datetime.date(*h) for h in holidays}
bd = 0
x = S
while x < E:
if x.weekday() < 5 and x not in H:
bd += 1
x += datetime.timedelta(days=1)
factor = (1 + rate / 100) ** (bd / 252)
return [bd, round(factor, 8)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression compounding exponent basis 1', [[2021, 2, 28], [2021, 10, 29], [[2021, 9, 13], [2021, 7, 30], [2021, 7, 30], [2021, 9, 28], [2021, 7, 16]], 6.5], [170, 1.04339832]], ['regression compounding exponent basis 2', [[2023, 8, 28], [2023, 10, 29], [], 6.5], [45, 1.01130897]], ['partial repair probe 1', [[2028, 6, 28], [2028, 9, 1], [[2028, 8, 26], [2028, 7, 24], [2028, 7, 2], [2028, 7, 10]], 13.65], [45, 1.02311185]], ['partial repair probe 2', [[2028, 8, 31], [2028, 12, 22], [[2028, 10, 16], [2028, 9, 12], [2028, 11, 7], [2028, 9, 8], [2028, 11, 20], [2028, 11, 16]], 13.65], [75, 1.03881575]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2020, 8, 24], [2020, 8, 24], [[2020, 8, 29], [2020, 8, 29], [2020, 8, 21], [2020, 8, 25]], 13.65], [0, 1.0]], ['normal control 2', [[2026, 6, 21], [2026, 6, 21], [], 13.65], [0, 1.0]], ['normal control 3', [[2019, 12, 8], [2019, 12, 8], [[2019, 12, 7], [2019, 12, 3], [2019, 12, 11], [2019, 12, 8], [2019, 12, 8], [2019, 12, 12]], 6.5], [0, 1.0]]], [['regression compounding exponent basis 1', [[2026, 5, 25], [2026, 12, 13], [[2026, 6, 14], [2026, 11, 24], [2026, 9, 23], [2026, 8, 30], [2026, 12, 17]], 6.5], [143, 1.03638189]], ['regression compounding exponent basis 2', [[2023, 3, 30], [2024, 2, 18], [[2023, 12, 29], [2023, 12, 29], [2023, 7, 25], [2023, 7, 25], [2023, 8, 23], [2023, 5, 20], [2023, 4, 25]], 6.5], [228, 1.05863167]], ['partial repair probe 1', [[2022, 6, 4], [2022, 6, 6], [[2022, 6, 4], [2022, 5, 30]], 6.5], [0, 1.0]], ['partial repair probe 2', [[2024, 7, 13], [2024, 12, 3], [[2024, 10, 10], [2024, 7, 26], [2024, 7, 28], [2024, 9, 23], [2024, 9, 23], [2024, 9, 2]], 6.5], [97, 1.02453648]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2022, 7, 3], [2022, 7, 3], [[2022, 7, 1], [2022, 7, 5], [2022, 7, 7]], 2.0], [0, 1.0]], ['normal control 2', [[2020, 8, 31], [2020, 8, 31], [[2020, 9, 2], [2020, 9, 2], [2020, 8, 31], [2020, 8, 31]], 6.5], [0, 1.0]], ['normal control 3', [[2030, 8, 24], [2030, 8, 24], [[2030, 8, 27], [2030, 8, 26], [2030, 8, 19], [2030, 8, 29], [2030, 8, 25]], 2.0], [0, 1.0]]], [['regression compounding exponent basis 1', [[2028, 3, 8], [2029, 2, 22], [[2028, 4, 14], [2028, 10, 23], [2028, 11, 28], [2028, 9, 2], [2028, 9, 2]], 10.75], [248, 1.10570651]], ['regression compounding exponent basis 2', [[2018, 3, 22], [2019, 2, 20], [[2018, 3, 26], [2018, 3, 31]], 13.65], [238, 1.12844981]], ['partial repair probe 1', [[2020, 3, 11], [2021, 1, 24], [[2020, 9, 21], [2020, 11, 25], [2020, 7, 4]], 13.65], [226, 1.12159505]], ['partial repair probe 2', [[2020, 11, 2], [2021, 4, 12], [[2021, 4, 10], [2021, 4, 10], [2021, 3, 24], [2020, 11, 6], [2021, 1, 28]], 6.5], [112, 1.02838417]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2021, 7, 9], [2021, 7, 9], [[2021, 7, 9]], 10.75], [0, 1.0]], ['normal control 2', [[2024, 4, 4], [2024, 4, 4], [[2024, 3, 30], [2024, 3, 30]], 10.75], [0, 1.0]], ['normal control 3', [[2026, 1, 30], [2026, 1, 30], [[2026, 2, 2], [2026, 1, 28], [2026, 1, 30], [2026, 1, 31], [2026, 2, 1], [2026, 2, 4]], 13.65], [0, 1.0]]], [['regression compounding exponent basis 1', [[2027, 2, 28], [2027, 9, 24], [[2027, 4, 18], [2027, 4, 18], [2027, 9, 16], [2027, 5, 31], [2027, 8, 17], [2027, 8, 17]], 6.5], [146, 1.03715916]], ['regression compounding exponent basis 2', [[2025, 1, 18], [2026, 1, 1], [[2025, 11, 30], [2025, 11, 30], [2025, 12, 27], [2025, 3, 2], [2025, 3, 23], [2025, 10, 12]], 13.65], [248, 1.1341941]], ['partial repair probe 1', [[2029, 3, 31], [2029, 4, 29], [[2029, 4, 2], [2029, 3, 26], [2029, 4, 7], [2029, 4, 7]], 2.0], [19, 1.00149417]], ['partial repair probe 2', [[2020, 4, 29], [2020, 5, 7], [], 13.65], [6, 1.00305115]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2028, 11, 30], [2028, 11, 30], [[2028, 11, 27], [2028, 11, 30], [2028, 12, 3], [2028, 12, 5], [2028, 12, 5], [2028, 11, 27], [2028, 11, 29]], 10.75], [0, 1.0]], ['normal control 2', [[2029, 10, 30], [2029, 10, 30], [], 2.0], [0, 1.0]], ['normal control 3', [[2019, 7, 31], [2019, 7, 31], [[2019, 7, 26], [2019, 7, 26], [2019, 7, 30], [2019, 7, 27], [2019, 8, 5], [2019, 8, 4], [2019, 8, 3]], 10.75], [0, 1.0]]], [['regression compounding exponent basis 1', [[2022, 10, 19], [2023, 1, 20], [[2023, 1, 17], [2023, 1, 5], [2023, 1, 5], [2022, 11, 13]], 6.5], [65, 1.01637614]], ['regression compounding exponent basis 2', [[2026, 7, 30], [2027, 2, 1], [[2026, 11, 17], [2026, 11, 17], [2026, 10, 23], [2026, 10, 16], [2026, 10, 15], [2026, 10, 15], [2026, 12, 19]], 13.65], [128, 1.06715068]], ['partial repair probe 1', [[2029, 9, 27], [2030, 4, 14], [[2030, 3, 26], [2030, 3, 26], [2030, 2, 15], [2030, 2, 15]], 13.65], [140, 1.0736727]], ['partial repair probe 2', [[2019, 2, 28], [2020, 4, 3], [[2020, 1, 20], [2019, 11, 27], [2019, 11, 28]], 2.0], [283, 1.02248779]], ['boundary control 1', [[2024, 5, 6], [2024, 5, 6], [], 10.0], [0, 1.0]], ['normal control 1', [[2027, 5, 13], [2027, 5, 13], [[2027, 5, 16], [2027, 5, 10], [2027, 5, 10]], 2.0], [0, 1.0]], ['normal control 2', [[2023, 5, 30], [2023, 5, 30], [[2023, 6, 3], [2023, 5, 25], [2023, 6, 1], [2023, 6, 2], [2023, 5, 25]], 6.5], [0, 1.0]], ['normal control 3', [[2026, 6, 16], [2026, 6, 16], [], 2.0], [0, 1.0]]]]
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 |
|---|---|---|---|
| regression compounding exponent basis 1 | [170, 1.04339832] | [170, 1.04339832] | Passed |
| regression compounding exponent basis 2 | [45, 1.01130897] | [45, 1.01130897] | Passed |
| partial repair probe 1 | [45, 1.02311185] | [45, 1.02311185] | Passed |
| partial repair probe 2 | [75, 1.03881575] | [75, 1.03881575] | Passed |
| boundary control 1 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 1 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 2 | [0, 1.0] | [0, 1.0] | Passed |
| normal control 3 | [0, 1.0] | [0, 1.0] | Passed |
SHA-256 / 489512b07883d61b1f4ab47514c1083099be80514ba460643d8098e3be253915
Verification & scope
A deterministic toy contract stated explicitly in the contract field; no claim of conformance to any published convention text. 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:46:52.517446+00:00.
Case digest / 4ad5e64774b5ce58fed5ac85839aa5813020b84d012791aeca396bfba8476eaa