{"abstract":"Clean prices are wrong except at the midpoint.","category":"Bond day-count conventions","checks":8,"contract":"Inputs issue, maturity and settlement dates, coupon and yield (decimals). The instrument pays 100*(1 + coupon*T/360) at maturity where T = days(issue, maturity). Dirty = redemption/(1 + y*R/360) with R = days(settle, maturity); accrued = 100*coupon*A/360 with A = days(issue, settle). Return [dirty, dirty-accrued] rounded to 6.","contract_signature":"issue, maturity, settle, coupon, y","evaluation_group":"w2-bond_day_count_conventions-cd-interest-at-maturity","failed_approach":"Adding a day to the elapsed count includes the settlement date.","family":"w2-bond_day_count_conventions-cd-interest-at-maturity-accrued-days","id":"FA-61251","implementations":{"attempt":{"sha256":"dcab41a30321db8dca92a9e9c9833599c764992d67ff3e33a3820f10bf17028b","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport datetime\nN = 1\nobservations = []\ndef solve(issue, maturity, settle, coupon, y):\n    I = datetime.date(*issue)\n    M = datetime.date(*maturity)\n    S = datetime.date(*settle)\n    T = (M - I).days\n    R = (M - S).days\n    A = (S - I).days + 1\n    redemption = 100 * (1 + coupon * T / 360)\n    dirty = redemption / (1 + y * R / 360)\n    accrued = 100 * coupon * A / 360\n    return [round(dirty, 6), round(dirty - accrued, 6)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression accrued days 1', [[2021, 12, 31], [2023, 4, 27], [2022, 2, 12], 0.065, 0.06], [101.291608, 100.51522]], ['regression accrued days 2', [[2028, 5, 30], [2028, 12, 26], [2028, 11, 21], 0.0375, 0.01], [102.088248, 100.265331]], ['partial repair probe 1', [[2036, 5, 23], [2038, 2, 25], [2037, 6, 1], 0.02, 0.01], [102.804048, 100.72627]], ['partial repair probe 2', [[2030, 9, 27], [2032, 7, 9], [2032, 6, 26], 0.0375, 0.01], [106.742704, 100.096871]], ['normal control 1', [[2022, 9, 30], [2023, 10, 5], [2022, 11, 27], 0.0, 0.045], [96.246391, 96.246391]], ['normal control 2', [[2014, 12, 28], [2016, 7, 26], [2016, 3, 31], 0.0, 0.06], [98.087298, 98.087298]], ['normal control 3', [[2039, 7, 31], [2040, 1, 25], [2039, 10, 22], 0.0, 0.06], [98.441345, 98.441345]], ['normal control 4', [[2023, 3, 31], [2023, 7, 22], [2023, 6, 2], 0.0, 0.045], [99.378882, 99.378882]]], [['regression accrued days 1', [[2030, 3, 31], [2032, 1, 23], [2030, 11, 12], 0.02, 0.01], [102.439828, 101.184272]], ['regression accrued days 2', [[2020, 12, 9], [2021, 8, 7], [2020, 12, 17], 0.0375, 0.045], [99.609296, 99.525963]], ['partial repair probe 1', [[2011, 6, 30], [2011, 8, 3], [2011, 7, 17], 0.02, 0.06], [99.905822, 99.811378]], ['partial repair probe 2', [[2021, 9, 15], [2021, 12, 22], [2021, 11, 3], 0.065, 0.03], [101.355576, 100.470854]], ['normal control 1', [[2025, 8, 12], [2027, 5, 8], [2025, 10, 1], 0.0, 0.01], [98.403674, 98.403674]], ['normal control 2', [[2034, 2, 28], [2034, 9, 17], [2034, 7, 14], 0.0, 0.03], [99.461252, 99.461252]], ['normal control 3', [[2029, 11, 19], [2031, 6, 23], [2031, 5, 13], 0.0, 0.03], [99.659497, 99.659497]], ['normal control 4', [[2030, 9, 16], [2032, 8, 16], [2032, 3, 2], 0.0, 0.03], [98.627435, 98.627435]]], [['regression accrued days 1', [[2012, 5, 14], [2013, 1, 15], [2012, 8, 31], 0.065, 0.01], [104.045715, 102.077659]], ['regression accrued days 2', [[2013, 10, 29], [2014, 1, 15], [2013, 11, 22], 0.0375, 0.06], [99.91328, 99.66328]], ['partial repair probe 1', [[2033, 7, 3], [2035, 4, 26], [2034, 4, 3], 0.0375, 0.045], [101.9512, 99.097033]], ['partial repair probe 2', [[2020, 10, 14], [2021, 7, 14], [2020, 11, 3], 0.0375, 0.01], [102.126031, 101.917698]], ['normal control 1', [[2023, 7, 13], [2025, 4, 14], [2023, 11, 4], 0.0, 0.045], [93.819632, 93.819632]], ['normal control 2', [[2010, 12, 4], [2012, 1, 14], [2011, 11, 20], 0.0, 0.09], [98.64365, 98.64365]], ['normal control 3', [[2011, 1, 31], [2012, 8, 15], [2011, 5, 28], 0.0, 0.01], [98.778982, 98.778982]], ['normal control 4', [[2012, 1, 13], [2012, 11, 21], [2012, 11, 12], 0.0, 0.06], [99.850225, 99.850225]]], [['regression accrued days 1', [[2032, 4, 1], [2034, 1, 25], [2033, 8, 16], 0.0375, 0.045], [104.794576, 99.56541]], ['regression accrued days 2', [[2012, 9, 28], [2013, 3, 23], [2012, 12, 17], 0.02, 0.01], [100.70922, 100.264775]], ['partial repair probe 1', [[2031, 11, 30], [2032, 2, 4], [2032, 1, 2], 0.065, 0.01], [101.098993, 100.503159]], ['normal control 1', [[2036, 4, 3], [2036, 11, 25], [2036, 11, 21], 0.0, 0.03], [99.966678, 99.966678]], ['normal control 2', [[2025, 9, 30], [2026, 12, 8], [2026, 4, 20], 0.0, 0.03], [98.103336, 98.103336]], ['normal control 3', [[2029, 5, 16], [2030, 2, 19], [2030, 1, 13], 0.0, 0.09], [99.083478, 99.083478]], ['normal control 4', [[2022, 1, 10], [2023, 2, 23], [2022, 4, 3], 0.0, 0.06], [94.846665, 94.846665]], ['normal control 5', [[2022, 4, 11], [2023, 9, 11], [2022, 12, 4], 0.0, 0.045], [96.60669, 96.60669]]], [['regression accrued days 1', [[2023, 6, 10], [2023, 11, 27], [2023, 10, 10], 0.065, 0.06], [102.251433, 100.048655]], ['regression accrued days 2', [[2021, 4, 4], [2022, 6, 11], [2022, 1, 14], 0.02, 0.045], [100.545464, 98.962131]], ['partial repair probe 1', [[2015, 11, 24], [2016, 2, 16], [2016, 1, 5], 0.02, 0.09], [99.422728, 99.189395]], ['normal control 1', [[2016, 12, 31], [2017, 4, 21], [2017, 2, 18], 0.0, 0.045], [99.23096, 99.23096]], ['normal control 2', [[2029, 10, 18], [2030, 8, 8], [2029, 11, 5], 0.0, 0.03], [97.751711, 97.751711]], ['normal control 3', [[2038, 1, 30], [2038, 5, 9], [2038, 4, 5], 0.0, 0.01], [99.905645, 99.905645]], ['normal control 4', [[2013, 4, 23], [2014, 6, 5], [2014, 4, 30], 0.0, 0.045], [99.552016, 99.552016]], ['normal control 5', [[2026, 8, 27], [2028, 2, 14], [2027, 7, 18], 0.0, 0.03], [98.27205, 98.27205]]]]\nfor label, args, expected in fixtures[N-1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"a563c0f4da7ca57ded021bd0c984e3747f226492a6b4be63a52073f2cd58bbf9","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport datetime\nN = 1\nobservations = []\ndef solve(issue, maturity, settle, coupon, y):\n    I = datetime.date(*issue)\n    M = datetime.date(*maturity)\n    S = datetime.date(*settle)\n    T = (M - I).days\n    R = (M - S).days\n    A = (M - S).days\n    redemption = 100 * (1 + coupon * T / 360)\n    dirty = redemption / (1 + y * R / 360)\n    accrued = 100 * coupon * A / 360\n    return [round(dirty, 6), round(dirty - accrued, 6)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression accrued days 1', [[2021, 12, 31], [2023, 4, 27], [2022, 2, 12], 0.065, 0.06], [101.291608, 100.51522]], ['regression accrued days 2', [[2028, 5, 30], [2028, 12, 26], [2028, 11, 21], 0.0375, 0.01], [102.088248, 100.265331]], ['partial repair probe 1', [[2036, 5, 23], [2038, 2, 25], [2037, 6, 1], 0.02, 0.01], [102.804048, 100.72627]], ['partial repair probe 2', [[2030, 9, 27], [2032, 7, 9], [2032, 6, 26], 0.0375, 0.01], [106.742704, 100.096871]], ['normal control 1', [[2022, 9, 30], [2023, 10, 5], [2022, 11, 27], 0.0, 0.045], [96.246391, 96.246391]], ['normal control 2', [[2014, 12, 28], [2016, 7, 26], [2016, 3, 31], 0.0, 0.06], [98.087298, 98.087298]], ['normal control 3', [[2039, 7, 31], [2040, 1, 25], [2039, 10, 22], 0.0, 0.06], [98.441345, 98.441345]], ['normal control 4', [[2023, 3, 31], [2023, 7, 22], [2023, 6, 2], 0.0, 0.045], [99.378882, 99.378882]]], [['regression accrued days 1', [[2030, 3, 31], [2032, 1, 23], [2030, 11, 12], 0.02, 0.01], [102.439828, 101.184272]], ['regression accrued days 2', [[2020, 12, 9], [2021, 8, 7], [2020, 12, 17], 0.0375, 0.045], [99.609296, 99.525963]], ['partial repair probe 1', [[2011, 6, 30], [2011, 8, 3], [2011, 7, 17], 0.02, 0.06], [99.905822, 99.811378]], ['partial repair probe 2', [[2021, 9, 15], [2021, 12, 22], [2021, 11, 3], 0.065, 0.03], [101.355576, 100.470854]], ['normal control 1', [[2025, 8, 12], [2027, 5, 8], [2025, 10, 1], 0.0, 0.01], [98.403674, 98.403674]], ['normal control 2', [[2034, 2, 28], [2034, 9, 17], [2034, 7, 14], 0.0, 0.03], [99.461252, 99.461252]], ['normal control 3', [[2029, 11, 19], [2031, 6, 23], [2031, 5, 13], 0.0, 0.03], [99.659497, 99.659497]], ['normal control 4', [[2030, 9, 16], [2032, 8, 16], [2032, 3, 2], 0.0, 0.03], [98.627435, 98.627435]]], [['regression accrued days 1', [[2012, 5, 14], [2013, 1, 15], [2012, 8, 31], 0.065, 0.01], [104.045715, 102.077659]], ['regression accrued days 2', [[2013, 10, 29], [2014, 1, 15], [2013, 11, 22], 0.0375, 0.06], [99.91328, 99.66328]], ['partial repair probe 1', [[2033, 7, 3], [2035, 4, 26], [2034, 4, 3], 0.0375, 0.045], [101.9512, 99.097033]], ['partial repair probe 2', [[2020, 10, 14], [2021, 7, 14], [2020, 11, 3], 0.0375, 0.01], [102.126031, 101.917698]], ['normal control 1', [[2023, 7, 13], [2025, 4, 14], [2023, 11, 4], 0.0, 0.045], [93.819632, 93.819632]], ['normal control 2', [[2010, 12, 4], [2012, 1, 14], [2011, 11, 20], 0.0, 0.09], [98.64365, 98.64365]], ['normal control 3', [[2011, 1, 31], [2012, 8, 15], [2011, 5, 28], 0.0, 0.01], [98.778982, 98.778982]], ['normal control 4', [[2012, 1, 13], [2012, 11, 21], [2012, 11, 12], 0.0, 0.06], [99.850225, 99.850225]]], [['regression accrued days 1', [[2032, 4, 1], [2034, 1, 25], [2033, 8, 16], 0.0375, 0.045], [104.794576, 99.56541]], ['regression accrued days 2', [[2012, 9, 28], [2013, 3, 23], [2012, 12, 17], 0.02, 0.01], [100.70922, 100.264775]], ['partial repair probe 1', [[2031, 11, 30], [2032, 2, 4], [2032, 1, 2], 0.065, 0.01], [101.098993, 100.503159]], ['normal control 1', [[2036, 4, 3], [2036, 11, 25], [2036, 11, 21], 0.0, 0.03], [99.966678, 99.966678]], ['normal control 2', [[2025, 9, 30], [2026, 12, 8], [2026, 4, 20], 0.0, 0.03], [98.103336, 98.103336]], ['normal control 3', [[2029, 5, 16], [2030, 2, 19], [2030, 1, 13], 0.0, 0.09], [99.083478, 99.083478]], ['normal control 4', [[2022, 1, 10], [2023, 2, 23], [2022, 4, 3], 0.0, 0.06], [94.846665, 94.846665]], ['normal control 5', [[2022, 4, 11], [2023, 9, 11], [2022, 12, 4], 0.0, 0.045], [96.60669, 96.60669]]], [['regression accrued days 1', [[2023, 6, 10], [2023, 11, 27], [2023, 10, 10], 0.065, 0.06], [102.251433, 100.048655]], ['regression accrued days 2', [[2021, 4, 4], [2022, 6, 11], [2022, 1, 14], 0.02, 0.045], [100.545464, 98.962131]], ['partial repair probe 1', [[2015, 11, 24], [2016, 2, 16], [2016, 1, 5], 0.02, 0.09], [99.422728, 99.189395]], ['normal control 1', [[2016, 12, 31], [2017, 4, 21], [2017, 2, 18], 0.0, 0.045], [99.23096, 99.23096]], ['normal control 2', [[2029, 10, 18], [2030, 8, 8], [2029, 11, 5], 0.0, 0.03], [97.751711, 97.751711]], ['normal control 3', [[2038, 1, 30], [2038, 5, 9], [2038, 4, 5], 0.0, 0.01], [99.905645, 99.905645]], ['normal control 4', [[2013, 4, 23], [2014, 6, 5], [2014, 4, 30], 0.0, 0.045], [99.552016, 99.552016]], ['normal control 5', [[2026, 8, 27], [2028, 2, 14], [2027, 7, 18], 0.0, 0.03], [98.27205, 98.27205]]]]\nfor label, args, expected in fixtures[N-1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"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.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"w2-bond_day_count_conventions-cd-interest-at-maturity-accrued-days","generated_at":"2026-09-29T14:46:53.524804+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Bond accrual and pricing systems depend on exact day-count arithmetic; a single-day error changes settlement cash.","root_cause":"Accrued days use days from settlement to maturity.","sha256":"0fa59c0a9e9ac268f37843830b054badb3dc1480ab0499ddfd69cda99d6c712e","title":"Money-market certificate priced from yield: accrued interest counts days remaining instead of days elapsed · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":46.411,"exit_code":1,"observations":[{"actual":[101.291608,100.497164],"check":"regression accrued days 1","expected":[101.291608,100.51522],"passed":false},{"actual":[102.088248,100.254914],"check":"regression accrued days 2","expected":[102.088248,100.265331],"passed":false},{"actual":[102.804048,100.720714],"check":"partial repair probe 1","expected":[102.804048,100.72627],"passed":false},{"actual":[106.742704,100.086454],"check":"partial repair probe 2","expected":[106.742704,100.096871],"passed":false},{"actual":[96.246391,96.246391],"check":"normal control 1","expected":[96.246391,96.246391],"passed":true},{"actual":[98.087298,98.087298],"check":"normal control 2","expected":[98.087298,98.087298],"passed":true},{"actual":[98.441345,98.441345],"check":"normal control 3","expected":[98.441345,98.441345],"passed":true},{"actual":[99.378882,99.378882],"check":"normal control 4","expected":[99.378882,99.378882],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression accrued days 1\", \"actual\": [101.291608, 100.497164], \"expected\": [101.291608, 100.51522], \"passed\": false}, {\"check\": \"regression accrued days 2\", \"actual\": [102.088248, 100.254914], \"expected\": [102.088248, 100.265331], \"passed\": false}, {\"check\": \"partial repair probe 1\", \"actual\": [102.804048, 100.720714], \"expected\": [102.804048, 100.72627], \"passed\": false}, {\"check\": \"partial repair probe 2\", \"actual\": [106.742704, 100.086454], \"expected\": [106.742704, 100.096871], \"passed\": false}, {\"check\": \"normal control 1\", \"actual\": [96.246391, 96.246391], \"expected\": [96.246391, 96.246391], \"passed\": true}, {\"check\": \"normal control 2\", \"actual\": [98.087298, 98.087298], \"expected\": [98.087298, 98.087298], \"passed\": true}, {\"check\": \"normal control 3\", \"actual\": [98.441345, 98.441345], \"expected\": [98.441345, 98.441345], \"passed\": true}, {\"check\": \"normal control 4\", \"actual\": [99.378882, 99.378882], \"expected\": [99.378882, 99.378882], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":43.06,"exit_code":1,"observations":[{"actual":[101.291608,93.36522],"check":"regression accrued days 1","expected":[101.291608,100.51522],"passed":false},{"actual":[102.088248,101.723664],"check":"regression accrued days 2","expected":[102.088248,100.265331],"passed":false},{"actual":[102.804048,101.309603],"check":"partial repair probe 1","expected":[102.804048,100.72627],"passed":false},{"actual":[106.742704,106.607287],"check":"partial repair probe 2","expected":[106.742704,100.096871],"passed":false},{"actual":[96.246391,96.246391],"check":"normal control 1","expected":[96.246391,96.246391],"passed":true},{"actual":[98.087298,98.087298],"check":"normal control 2","expected":[98.087298,98.087298],"passed":true},{"actual":[98.441345,98.441345],"check":"normal control 3","expected":[98.441345,98.441345],"passed":true},{"actual":[99.378882,99.378882],"check":"normal control 4","expected":[99.378882,99.378882],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression accrued days 1\", \"actual\": [101.291608, 93.36522], \"expected\": [101.291608, 100.51522], \"passed\": false}, {\"check\": \"regression accrued days 2\", \"actual\": [102.088248, 101.723664], \"expected\": [102.088248, 100.265331], \"passed\": false}, {\"check\": \"partial repair probe 1\", \"actual\": [102.804048, 101.309603], \"expected\": [102.804048, 100.72627], \"passed\": false}, {\"check\": \"partial repair probe 2\", \"actual\": [106.742704, 106.607287], \"expected\": [106.742704, 100.096871], \"passed\": false}, {\"check\": \"normal control 1\", \"actual\": [96.246391, 96.246391], \"expected\": [96.246391, 96.246391], \"passed\": true}, {\"check\": \"normal control 2\", \"actual\": [98.087298, 98.087298], \"expected\": [98.087298, 98.087298], \"passed\": true}, {\"check\": \"normal control 3\", \"actual\": [98.441345, 98.441345], \"expected\": [98.441345, 98.441345], \"passed\": true}, {\"check\": \"normal control 4\", \"actual\": [99.378882, 99.378882], \"expected\": [99.378882, 99.378882], \"passed\": true}], \"passed\": false}\n"}},"member_only":{"stages":["fixed"],"fields":["implementations.fixed","verification.fixed","harness","repair"],"note":"The verified repair, its recorded checks, the repair description, and the scoring harness are available to members."}}