FAILURE MAP
← Case archive

FA-61086 / Bond day-count conventions / Open access

Street-convention yield to price with fractional first period: the principal is discounted one period too far · case 01

Prices are too low by roughly one period of discounting on the redemption amount.

Verified by executionVariant 1 · 8 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

The redemption exponent is n+w instead of n-1+w.

VERIFIED REPAIR

Discount principal with the same exponent as the final coupon, n-1+w.

Unsuccessful approach: Dropping the fraction entirely and using n periods is still off.

Case contract

Inputs settle, prev and next coupon dates [y,m,d], n remaining coupons (including next), annual coupon rate, annual yield y and frequency. w = days(settle, next)/days(prev, next); c = 100*rate/freq; v = 1/(1+y/freq). Dirty = sum_{k=0}^{n-1} c*v^(k+w) + 100*v^(n-1+w); accrued = c*(1-w); return [dirty, dirty-accrued] each rounded to 6 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(settle, prev, nxt, n, rate, y, freq):
    S = datetime.date(*settle)
    P = datetime.date(*prev)
    Q = datetime.date(*nxt)
    w = (Q - S).days / (Q - P).days
    c = 100 * rate / freq
    v = 1 / (1 + y / freq)
    dirty = sum(c * v ** (k + w) for k in range(n)) + 100 * v ** (n + w)
    accrued = c * (1 - w)
    return [round(dirty, 6), round(dirty - accrued, 6)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression redemption exponent 1', [[2031, 9, 22], [2031, 2, 28], [2032, 2, 28], 20, 0.06, 0.02, 1], [167.264723, 163.878421]], ['regression redemption exponent 2', [[2038, 7, 15], [2038, 6, 19], [2039, 6, 19], 11, 0.03, 0.08, 1], [64.658678, 64.444979]], ['partial repair probe 1', [[2007, 8, 23], [2006, 10, 13], [2007, 10, 13], 12, 0.06, 0.02, 1], [144.746333, 139.584689]], ['partial repair probe 2', [[2031, 1, 29], [2031, 1, 12], [2031, 4, 12], 21, 0.03, 0.035, 4], [97.77232, 97.630654]], ['normal control 1', [[2008, 11, 7], [2008, 10, 17], [2009, 4, 17], 23, 0.075, 0.005, 2], [178.185834, 177.753142]], ['normal control 2', [[2018, 12, 7], [2018, 11, 1], [2019, 2, 1], 21, 0.03, 0.08, 4], [79.348472, 79.054994]], ['normal control 3', [[2039, 9, 15], [2039, 9, 13], [2040, 3, 13], 18, 0.0, 0.005, 2], [95.60774, 95.60774]], ['normal control 4', [[2030, 2, 12], [2029, 8, 1], [2030, 8, 1], 1, 0.045, 0.02, 1], [103.540613, 101.136503]]], [['regression redemption exponent 1', [[2012, 2, 17], [2011, 9, 30], [2012, 3, 30], 2, 0.03, 0.02, 2], [101.761114, 100.607268]], ['regression redemption exponent 2', [[2021, 6, 29], [2021, 5, 16], [2022, 5, 16], 4, 0.015, 0.05, 1], [88.105852, 87.92503]], ['partial repair probe 1', [[2008, 1, 26], [2007, 8, 13], [2008, 2, 13], 30, 0.075, 0.005, 2], [201.490921, 198.107769]], ['partial repair probe 2', [[2028, 5, 30], [2028, 5, 21], [2028, 11, 21], 17, 0.0, 0.11, 2], [40.350185, 40.350185]], ['normal control 1', [[2007, 5, 29], [2006, 12, 15], [2007, 6, 15], 21, 0.03, 0.005, 2], [125.826261, 124.466371]], ['normal control 2', [[2034, 6, 20], [2034, 2, 20], [2034, 8, 20], 12, 0.06, 0.005, 2], [132.689419, 130.700469]], ['normal control 3', [[2034, 11, 7], [2034, 9, 30], [2034, 12, 30], 9, 0.0, 0.02, 4], [95.809804, 95.809804]], ['normal control 4', [[2016, 5, 23], [2016, 1, 31], [2016, 7, 31], 3, 0.015, 0.005, 2], [101.649993, 101.184334]]], [['regression redemption exponent 1', [[2008, 1, 31], [2008, 1, 31], [2009, 1, 31], 26, 0.075, 0.08, 1], [94.595011, 94.595011]], ['regression redemption exponent 2', [[2027, 12, 22], [2027, 10, 13], [2028, 4, 13], 25, 0.075, 0.08, 2], [97.547002, 96.112576]], ['partial repair probe 1', [[2038, 11, 12], [2038, 11, 1], [2039, 5, 1], 25, 0.03, 0.035, 2], [95.072991, 94.98183]], ['partial repair probe 2', [[2039, 4, 24], [2039, 1, 16], [2039, 7, 16], 1, 0.0, 0.035, 2], [99.207611, 99.207611]], ['normal control 1', [[2036, 5, 31], [2036, 5, 31], [2036, 11, 30], 7, 0.075, 0.08, 2], [98.499486, 98.499486]], ['normal control 2', [[2018, 4, 7], [2018, 2, 9], [2018, 8, 9], 23, 0.06, 0.02, 2], [141.353886, 140.409134]], ['normal control 3', [[2006, 1, 1], [2005, 3, 28], [2006, 3, 28], 17, 0.015, 0.11, 1], [30.635335, 29.48876]], ['normal control 4', [[2009, 8, 3], [2009, 3, 31], [2009, 9, 30], 12, 0.015, 0.05, 2], [83.44453, 82.932235]]], [['regression redemption exponent 1', [[2011, 9, 24], [2011, 7, 9], [2012, 7, 9], 15, 0.075, 0.05, 1], [127.24862, 125.670751]], ['regression redemption exponent 2', [[2012, 3, 15], [2011, 10, 28], [2012, 4, 28], 22, 0.045, 0.02, 2], [125.52057, 123.811554]], ['partial repair probe 1', [[2025, 7, 24], [2025, 4, 30], [2025, 7, 30], 13, 0.015, 0.005, 4], [103.342254, 102.99198]], ['partial repair probe 2', [[2025, 5, 9], [2025, 3, 4], [2025, 6, 4], 21, 0.015, 0.035, 4], [91.013286, 90.744264]], ['normal control 1', [[2035, 7, 7], [2034, 7, 31], [2035, 7, 31], 4, 0.0, 0.005, 1], [98.482573, 98.482573]], ['normal control 2', [[2037, 5, 10], [2037, 2, 9], [2038, 2, 9], 21, 0.075, 0.11, 1], [73.607196, 71.757881]], ['normal control 3', [[2025, 6, 18], [2025, 5, 5], [2026, 5, 5], 6, 0.0, 0.08, 1], [63.604323, 63.604323]], ['normal control 4', [[2023, 5, 30], [2023, 4, 20], [2023, 10, 20], 1, 0.06, 0.05, 2], [101.031633, 100.375896]]], [['regression redemption exponent 1', [[2036, 6, 14], [2036, 3, 18], [2036, 9, 18], 16, 0.0, 0.11, 2], [43.55935, 43.55935]], ['regression redemption exponent 2', [[2014, 1, 31], [2013, 12, 26], [2014, 3, 26], 26, 0.045, 0.05, 4], [97.724231, 97.274231]], ['partial repair probe 1', [[2036, 12, 13], [2036, 11, 14], [2037, 2, 14], 24, 0.03, 0.11, 4], [65.758337, 65.521924]], ['partial repair probe 2', [[2032, 12, 8], [2032, 11, 7], [2033, 5, 7], 21, 0.045, 0.035, 2], [109.047307, 108.661948]], ['normal control 1', [[2037, 9, 4], [2037, 7, 31], [2037, 10, 31], 18, 0.06, 0.02, 4], [117.395307, 116.824655]], ['normal control 2', [[2038, 3, 5], [2037, 10, 18], [2038, 4, 18], 23, 0.045, 0.11, 2], [60.565646, 58.859602]], ['normal control 3', [[2032, 2, 4], [2031, 10, 31], [2032, 4, 30], 8, 0.0, 0.08, 2], [74.596406, 74.596406]], ['normal control 4', [[2038, 10, 12], [2038, 7, 18], [2038, 10, 18], 6, 0.045, 0.035, 4], [102.284714, 101.233084]]]]
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 fixtureActualExpectedOutcome
regression redemption exponent 1[165.930341, 162.544039][167.264723, 163.878421]Failed
regression redemption exponent 2[61.464304, 61.250605][64.658678, 64.444979]Failed
partial repair probe 1[143.173704, 138.01206][144.746333, 139.584689]Failed
partial repair probe 2[97.048743, 96.907077][97.77232, 97.630654]Failed
normal control 1[177.950307, 177.517615][178.185834, 177.753142]Failed
normal control 2[78.044731, 77.751252][79.348472, 79.054994]Failed
normal control 3[95.369317, 95.369317][95.60774, 95.60774]Failed
normal control 4[101.59783, 99.19372][103.540613, 101.136503]Failed

SHA-256 / 26f748bea73e25290c640cd60461e77a887e80b7989fe77f4764f5a175f6615f

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import datetime
N = 1
observations = []
def solve(settle, prev, nxt, n, rate, y, freq):
    S = datetime.date(*settle)
    P = datetime.date(*prev)
    Q = datetime.date(*nxt)
    w = (Q - S).days / (Q - P).days
    c = 100 * rate / freq
    v = 1 / (1 + y / freq)
    dirty = sum(c * v ** (k + w) for k in range(n)) + 100 * v ** n
    accrued = c * (1 - w)
    return [round(dirty, 6), round(dirty - accrued, 6)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression redemption exponent 1', [[2031, 9, 22], [2031, 2, 28], [2032, 2, 28], 20, 0.06, 0.02, 1], [167.264723, 163.878421]], ['regression redemption exponent 2', [[2038, 7, 15], [2038, 6, 19], [2039, 6, 19], 11, 0.03, 0.08, 1], [64.658678, 64.444979]], ['partial repair probe 1', [[2007, 8, 23], [2006, 10, 13], [2007, 10, 13], 12, 0.06, 0.02, 1], [144.746333, 139.584689]], ['partial repair probe 2', [[2031, 1, 29], [2031, 1, 12], [2031, 4, 12], 21, 0.03, 0.035, 4], [97.77232, 97.630654]], ['normal control 1', [[2008, 11, 7], [2008, 10, 17], [2009, 4, 17], 23, 0.075, 0.005, 2], [178.185834, 177.753142]], ['normal control 2', [[2018, 12, 7], [2018, 11, 1], [2019, 2, 1], 21, 0.03, 0.08, 4], [79.348472, 79.054994]], ['normal control 3', [[2039, 9, 15], [2039, 9, 13], [2040, 3, 13], 18, 0.0, 0.005, 2], [95.60774, 95.60774]], ['normal control 4', [[2030, 2, 12], [2029, 8, 1], [2030, 8, 1], 1, 0.045, 0.02, 1], [103.540613, 101.136503]]], [['regression redemption exponent 1', [[2012, 2, 17], [2011, 9, 30], [2012, 3, 30], 2, 0.03, 0.02, 2], [101.761114, 100.607268]], ['regression redemption exponent 2', [[2021, 6, 29], [2021, 5, 16], [2022, 5, 16], 4, 0.015, 0.05, 1], [88.105852, 87.92503]], ['partial repair probe 1', [[2008, 1, 26], [2007, 8, 13], [2008, 2, 13], 30, 0.075, 0.005, 2], [201.490921, 198.107769]], ['partial repair probe 2', [[2028, 5, 30], [2028, 5, 21], [2028, 11, 21], 17, 0.0, 0.11, 2], [40.350185, 40.350185]], ['normal control 1', [[2007, 5, 29], [2006, 12, 15], [2007, 6, 15], 21, 0.03, 0.005, 2], [125.826261, 124.466371]], ['normal control 2', [[2034, 6, 20], [2034, 2, 20], [2034, 8, 20], 12, 0.06, 0.005, 2], [132.689419, 130.700469]], ['normal control 3', [[2034, 11, 7], [2034, 9, 30], [2034, 12, 30], 9, 0.0, 0.02, 4], [95.809804, 95.809804]], ['normal control 4', [[2016, 5, 23], [2016, 1, 31], [2016, 7, 31], 3, 0.015, 0.005, 2], [101.649993, 101.184334]]], [['regression redemption exponent 1', [[2008, 1, 31], [2008, 1, 31], [2009, 1, 31], 26, 0.075, 0.08, 1], [94.595011, 94.595011]], ['regression redemption exponent 2', [[2027, 12, 22], [2027, 10, 13], [2028, 4, 13], 25, 0.075, 0.08, 2], [97.547002, 96.112576]], ['partial repair probe 1', [[2038, 11, 12], [2038, 11, 1], [2039, 5, 1], 25, 0.03, 0.035, 2], [95.072991, 94.98183]], ['partial repair probe 2', [[2039, 4, 24], [2039, 1, 16], [2039, 7, 16], 1, 0.0, 0.035, 2], [99.207611, 99.207611]], ['normal control 1', [[2036, 5, 31], [2036, 5, 31], [2036, 11, 30], 7, 0.075, 0.08, 2], [98.499486, 98.499486]], ['normal control 2', [[2018, 4, 7], [2018, 2, 9], [2018, 8, 9], 23, 0.06, 0.02, 2], [141.353886, 140.409134]], ['normal control 3', [[2006, 1, 1], [2005, 3, 28], [2006, 3, 28], 17, 0.015, 0.11, 1], [30.635335, 29.48876]], ['normal control 4', [[2009, 8, 3], [2009, 3, 31], [2009, 9, 30], 12, 0.015, 0.05, 2], [83.44453, 82.932235]]], [['regression redemption exponent 1', [[2011, 9, 24], [2011, 7, 9], [2012, 7, 9], 15, 0.075, 0.05, 1], [127.24862, 125.670751]], ['regression redemption exponent 2', [[2012, 3, 15], [2011, 10, 28], [2012, 4, 28], 22, 0.045, 0.02, 2], [125.52057, 123.811554]], ['partial repair probe 1', [[2025, 7, 24], [2025, 4, 30], [2025, 7, 30], 13, 0.015, 0.005, 4], [103.342254, 102.99198]], ['partial repair probe 2', [[2025, 5, 9], [2025, 3, 4], [2025, 6, 4], 21, 0.015, 0.035, 4], [91.013286, 90.744264]], ['normal control 1', [[2035, 7, 7], [2034, 7, 31], [2035, 7, 31], 4, 0.0, 0.005, 1], [98.482573, 98.482573]], ['normal control 2', [[2037, 5, 10], [2037, 2, 9], [2038, 2, 9], 21, 0.075, 0.11, 1], [73.607196, 71.757881]], ['normal control 3', [[2025, 6, 18], [2025, 5, 5], [2026, 5, 5], 6, 0.0, 0.08, 1], [63.604323, 63.604323]], ['normal control 4', [[2023, 5, 30], [2023, 4, 20], [2023, 10, 20], 1, 0.06, 0.05, 2], [101.031633, 100.375896]]], [['regression redemption exponent 1', [[2036, 6, 14], [2036, 3, 18], [2036, 9, 18], 16, 0.0, 0.11, 2], [43.55935, 43.55935]], ['regression redemption exponent 2', [[2014, 1, 31], [2013, 12, 26], [2014, 3, 26], 26, 0.045, 0.05, 4], [97.724231, 97.274231]], ['partial repair probe 1', [[2036, 12, 13], [2036, 11, 14], [2037, 2, 14], 24, 0.03, 0.11, 4], [65.758337, 65.521924]], ['partial repair probe 2', [[2032, 12, 8], [2032, 11, 7], [2033, 5, 7], 21, 0.045, 0.035, 2], [109.047307, 108.661948]], ['normal control 1', [[2037, 9, 4], [2037, 7, 31], [2037, 10, 31], 18, 0.06, 0.02, 4], [117.395307, 116.824655]], ['normal control 2', [[2038, 3, 5], [2037, 10, 18], [2038, 4, 18], 23, 0.045, 0.11, 2], [60.565646, 58.859602]], ['normal control 3', [[2032, 2, 4], [2031, 10, 31], [2032, 4, 30], 8, 0.0, 0.08, 2], [74.596406, 74.596406]], ['normal control 4', [[2038, 10, 12], [2038, 7, 18], [2038, 10, 18], 6, 0.045, 0.035, 4], [102.284714, 101.233084]]]]
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 fixtureActualExpectedOutcome
regression redemption exponent 1[166.508373, 163.122071][167.264723, 163.878421]Failed
regression redemption exponent 2[64.422912, 64.209213][64.658678, 64.444979]Failed
partial repair probe 1[143.391574, 138.22993][144.746333, 139.584689]Failed
partial repair probe 2[97.635161, 97.493495][97.77232, 97.630654]Failed
normal control 1[178.158628, 177.725936][178.185834, 177.753142]Failed
normal control 2[78.835236, 78.541757][79.348472, 79.054994]Failed
normal control 3[95.605117, 95.605117][95.60774, 95.60774]Failed
normal control 4[102.497902, 100.093793][103.540613, 101.136503]Failed

SHA-256 / e5de3814d612224ebb45bd5af15c73dc69a7a9a047aab51540b8a0ef66fb0cd1

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json
import datetime
N = 1
observations = []
def solve(settle, prev, nxt, n, rate, y, freq):
    S = datetime.date(*settle)
    P = datetime.date(*prev)
    Q = datetime.date(*nxt)
    w = (Q - S).days / (Q - P).days
    c = 100 * rate / freq
    v = 1 / (1 + y / freq)
    dirty = sum(c * v ** (k + w) for k in range(n)) + 100 * v ** (n - 1 + w)
    accrued = c * (1 - w)
    return [round(dirty, 6), round(dirty - accrued, 6)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression redemption exponent 1', [[2031, 9, 22], [2031, 2, 28], [2032, 2, 28], 20, 0.06, 0.02, 1], [167.264723, 163.878421]], ['regression redemption exponent 2', [[2038, 7, 15], [2038, 6, 19], [2039, 6, 19], 11, 0.03, 0.08, 1], [64.658678, 64.444979]], ['partial repair probe 1', [[2007, 8, 23], [2006, 10, 13], [2007, 10, 13], 12, 0.06, 0.02, 1], [144.746333, 139.584689]], ['partial repair probe 2', [[2031, 1, 29], [2031, 1, 12], [2031, 4, 12], 21, 0.03, 0.035, 4], [97.77232, 97.630654]], ['normal control 1', [[2008, 11, 7], [2008, 10, 17], [2009, 4, 17], 23, 0.075, 0.005, 2], [178.185834, 177.753142]], ['normal control 2', [[2018, 12, 7], [2018, 11, 1], [2019, 2, 1], 21, 0.03, 0.08, 4], [79.348472, 79.054994]], ['normal control 3', [[2039, 9, 15], [2039, 9, 13], [2040, 3, 13], 18, 0.0, 0.005, 2], [95.60774, 95.60774]], ['normal control 4', [[2030, 2, 12], [2029, 8, 1], [2030, 8, 1], 1, 0.045, 0.02, 1], [103.540613, 101.136503]]], [['regression redemption exponent 1', [[2012, 2, 17], [2011, 9, 30], [2012, 3, 30], 2, 0.03, 0.02, 2], [101.761114, 100.607268]], ['regression redemption exponent 2', [[2021, 6, 29], [2021, 5, 16], [2022, 5, 16], 4, 0.015, 0.05, 1], [88.105852, 87.92503]], ['partial repair probe 1', [[2008, 1, 26], [2007, 8, 13], [2008, 2, 13], 30, 0.075, 0.005, 2], [201.490921, 198.107769]], ['partial repair probe 2', [[2028, 5, 30], [2028, 5, 21], [2028, 11, 21], 17, 0.0, 0.11, 2], [40.350185, 40.350185]], ['normal control 1', [[2007, 5, 29], [2006, 12, 15], [2007, 6, 15], 21, 0.03, 0.005, 2], [125.826261, 124.466371]], ['normal control 2', [[2034, 6, 20], [2034, 2, 20], [2034, 8, 20], 12, 0.06, 0.005, 2], [132.689419, 130.700469]], ['normal control 3', [[2034, 11, 7], [2034, 9, 30], [2034, 12, 30], 9, 0.0, 0.02, 4], [95.809804, 95.809804]], ['normal control 4', [[2016, 5, 23], [2016, 1, 31], [2016, 7, 31], 3, 0.015, 0.005, 2], [101.649993, 101.184334]]], [['regression redemption exponent 1', [[2008, 1, 31], [2008, 1, 31], [2009, 1, 31], 26, 0.075, 0.08, 1], [94.595011, 94.595011]], ['regression redemption exponent 2', [[2027, 12, 22], [2027, 10, 13], [2028, 4, 13], 25, 0.075, 0.08, 2], [97.547002, 96.112576]], ['partial repair probe 1', [[2038, 11, 12], [2038, 11, 1], [2039, 5, 1], 25, 0.03, 0.035, 2], [95.072991, 94.98183]], ['partial repair probe 2', [[2039, 4, 24], [2039, 1, 16], [2039, 7, 16], 1, 0.0, 0.035, 2], [99.207611, 99.207611]], ['normal control 1', [[2036, 5, 31], [2036, 5, 31], [2036, 11, 30], 7, 0.075, 0.08, 2], [98.499486, 98.499486]], ['normal control 2', [[2018, 4, 7], [2018, 2, 9], [2018, 8, 9], 23, 0.06, 0.02, 2], [141.353886, 140.409134]], ['normal control 3', [[2006, 1, 1], [2005, 3, 28], [2006, 3, 28], 17, 0.015, 0.11, 1], [30.635335, 29.48876]], ['normal control 4', [[2009, 8, 3], [2009, 3, 31], [2009, 9, 30], 12, 0.015, 0.05, 2], [83.44453, 82.932235]]], [['regression redemption exponent 1', [[2011, 9, 24], [2011, 7, 9], [2012, 7, 9], 15, 0.075, 0.05, 1], [127.24862, 125.670751]], ['regression redemption exponent 2', [[2012, 3, 15], [2011, 10, 28], [2012, 4, 28], 22, 0.045, 0.02, 2], [125.52057, 123.811554]], ['partial repair probe 1', [[2025, 7, 24], [2025, 4, 30], [2025, 7, 30], 13, 0.015, 0.005, 4], [103.342254, 102.99198]], ['partial repair probe 2', [[2025, 5, 9], [2025, 3, 4], [2025, 6, 4], 21, 0.015, 0.035, 4], [91.013286, 90.744264]], ['normal control 1', [[2035, 7, 7], [2034, 7, 31], [2035, 7, 31], 4, 0.0, 0.005, 1], [98.482573, 98.482573]], ['normal control 2', [[2037, 5, 10], [2037, 2, 9], [2038, 2, 9], 21, 0.075, 0.11, 1], [73.607196, 71.757881]], ['normal control 3', [[2025, 6, 18], [2025, 5, 5], [2026, 5, 5], 6, 0.0, 0.08, 1], [63.604323, 63.604323]], ['normal control 4', [[2023, 5, 30], [2023, 4, 20], [2023, 10, 20], 1, 0.06, 0.05, 2], [101.031633, 100.375896]]], [['regression redemption exponent 1', [[2036, 6, 14], [2036, 3, 18], [2036, 9, 18], 16, 0.0, 0.11, 2], [43.55935, 43.55935]], ['regression redemption exponent 2', [[2014, 1, 31], [2013, 12, 26], [2014, 3, 26], 26, 0.045, 0.05, 4], [97.724231, 97.274231]], ['partial repair probe 1', [[2036, 12, 13], [2036, 11, 14], [2037, 2, 14], 24, 0.03, 0.11, 4], [65.758337, 65.521924]], ['partial repair probe 2', [[2032, 12, 8], [2032, 11, 7], [2033, 5, 7], 21, 0.045, 0.035, 2], [109.047307, 108.661948]], ['normal control 1', [[2037, 9, 4], [2037, 7, 31], [2037, 10, 31], 18, 0.06, 0.02, 4], [117.395307, 116.824655]], ['normal control 2', [[2038, 3, 5], [2037, 10, 18], [2038, 4, 18], 23, 0.045, 0.11, 2], [60.565646, 58.859602]], ['normal control 3', [[2032, 2, 4], [2031, 10, 31], [2032, 4, 30], 8, 0.0, 0.08, 2], [74.596406, 74.596406]], ['normal control 4', [[2038, 10, 12], [2038, 7, 18], [2038, 10, 18], 6, 0.045, 0.035, 4], [102.284714, 101.233084]]]]
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 fixtureActualExpectedOutcome
regression redemption exponent 1[167.264723, 163.878421][167.264723, 163.878421]Passed
regression redemption exponent 2[64.658678, 64.444979][64.658678, 64.444979]Passed
partial repair probe 1[144.746333, 139.584689][144.746333, 139.584689]Passed
partial repair probe 2[97.77232, 97.630654][97.77232, 97.630654]Passed
normal control 1[178.185834, 177.753142][178.185834, 177.753142]Passed
normal control 2[79.348472, 79.054994][79.348472, 79.054994]Passed
normal control 3[95.60774, 95.60774][95.60774, 95.60774]Passed
normal control 4[103.540613, 101.136503][103.540613, 101.136503]Passed

SHA-256 / 704fb310ecf71236ac9abd25df26ba676ac4271ea869bd20266b4d4df98f2aa8

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:51.823626+00:00.

Case digest / 9fddf96ab489657f862bf23c2ad20b9805acc25d464a7c32440179c39a104d71