{"abstract":"Second-order feedback has the wrong sign, e.g. a stable resonance diverges.","category":"Digital signal filters","checks":7,"contract":"Input [[b0, b1, b2, a1, a2], samples, prime] (a0 = 1). Transposed direct form II: y = b0 x + s1; s1 = b1 x - a1 y + s2; s2 = b2 x - a2 y. If prime and samples exist, initialize s1, s2 to the steady state for a constant input equal to the first sample (y_ss = x0 (b0+b1+b2)/(1+a1+a2), \"dc-pole\" if the denominator is 0). Return exact fraction strings.","contract_signature":"x","evaluation_group":"w2-digital_signal_filters-biquad-transposed-df2","failed_approach":"The attempted repair subtracts a2 times the input instead of the output.","family":"w2-digital_signal_filters-biquad-transposed-df2-second-state-feedback-sign","id":"FA-91386","implementations":{"attempt":{"sha256":"57a47245b970c0814be8a56fb2490813d75e468e787267e78acea3febf6ebf72","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(x):\n    b0, b1, b2, a1, a2 = [Fraction(v) for v in x[0]]\n    xs, prime = x[1], x[2]\n    s1 = s2 = Fraction(0)\n    if prime and xs:\n        den = 1 + a1 + a2\n        if den == 0:\n            return 'dc-pole'\n        x0 = xs[0]\n        yss = x0 * (b0 + b1 + b2) / den\n        s1 = yss - b0 * x0\n        s2 = b2 * x0 - a2 * yss\n    out = []\n    for v in xs:\n        y = b0 * v + s1\n        s1 = b1 * v - a1 * y + s2\n        s2 = b2 * v - a2 * v\n        out.append(str(y))\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression: primed step lowpass', [['1/4', '1/2', '1/4', '-1/2', '1/4'], [2, 2, 2, 2], True], ['8/3', '8/3', '8/3', '8/3']], ['regression: unprimed impulse', [['1', '1/2', '1/3', '1/2', '-1/4'], [1, 0, 0, 0], False], ['1', '0', '7/12', '-7/24']], ['regression: random df2t 0', [['5/4', '1/3', '3/4', '-1/2', '2'], [-1, 2, 4, 4, 1], False], ['-5/4', '37/24', '131/16', '283/32', '-1223/192']], ['control: primed highpass', [['1', '-2', '1', '0', '0'], [3, 3, 1], True], ['0', '0', '-2']], ['control: dc pole', [['1', '0', '0', '-2', '1'], [1, 1], True], 'dc-pole'], ['control: primed empty', [['1', '0', '0', '0', '0'], [], True], []], ['control: random df2t 2', [['3/4', '-1/4', '1/2', '1/8', '-1/2'], [-2, 2], True], ['-16/5', '-1/5']]], [['regression: random df2t 1', [['-1/4', '-1/2', '0', '-1/2', '-3/8'], [-3, 3, 1, 2], False], ['3/4', '9/8', '-29/32', '-33/32']], ['regression: random df2t 6', [['0', '-1/2', '1/8', '3/4', '3/4'], [4, 4, 2, 4], False], ['0', '-2', '0', '1']], ['regression: random df2t 7', [['-1/2', '2', '-1/4', '1/2', '2'], [3, 2, -2, 0], True], ['15/14', '11/7', '37/28', '-465/56']], ['control: random df2t 3', [['1/8', '3/4', '-3/8', '-1/2', '1/8'], [2], False], ['1/4']], ['control: random df2t 4', [['-1/2', '-3/8', '0', '0', '1/3'], [-3], True], ['63/32']], ['control: random df2t 5', [['-3/8', '-1/4', '-1/4', '1/3', '-1/4'], [2], True], ['-21/13']], ['control: random df2t 11', [['1/8', '1/8', '5/4', '-3/8', '1/2'], [0], True], ['0']]], [['regression: random df2t 8', [['-3/8', '2', '1/8', '1/3', '2'], [4, -3, -2, 1, 4], True], ['21/10', '189/40', '-421/40', '-1283/120', '8951/360']], ['regression: random df2t 9', [['-3/8', '0', '-1/2', '2', '5/4'], [3, -3, 3, 2], False], ['-9/8', '27/8', '-255/32', '399/32']], ['regression: random df2t 7', [['-1/2', '2', '-1/4', '1/2', '2'], [3, 2, -2, 0], True], ['15/14', '11/7', '37/28', '-465/56']], ['control: random df2t 12', [['-1/2', '5/4', '-1/4', '5/4', '-1/4'], [0, 0], False], ['0', '0']], ['control: random df2t 13', [['-1/4', '-1/4', '1/2', '5/4', '0'], [2, -3, -1, 3, -3], False], ['-1/2', '7/8', '29/32', '-401/128', '1749/512']], ['control: random df2t 14', [['1/3', '2', '1/2', '1/2', '5/4'], [0, -2], True], ['0', '-2/3']], ['control: random df2t 15', [['-1/4', '2', '-1/2', '1/2', '1/2'], [4], False], ['-1']]], [['regression: random df2t 16', [['5/4', '1/8', '1/8', '-3/8', '1/3'], [-2, 2, 3], True], ['-72/23', '43/23', '1011/184']], ['regression: random df2t 18', [['0', '-3/8', '1/3', '1/3', '2'], [4, 4, 2, 0, -3], True], ['-1/20', '-1/20', '-1/20', '7/10', '8/15']], ['regression: random df2t 9', [['-3/8', '0', '-1/2', '2', '5/4'], [3, -3, 3, 2], False], ['-9/8', '27/8', '-255/32', '399/32']], ['control: random df2t 17', [['2', '-1/2', '3/4', '-1/4', '-3/8'], [-1, 1], True], ['-6', '-2']], ['control: random df2t 19', [['-1/4', '1/3', '1/8', '1/3', '1/8'], [0, 1, -3], True], ['0', '-1/4', '7/6']], ['control: random df2t 20', [['5/4', '0', '5/4', '-1/2', '-1/2'], [-3, 1], True], 'dc-pole'], ['control: random df2t 22', [['1/3', '-3/8', '1/3', '0', '5/4'], [4], True], ['14/27']]], [['regression: random df2t 25', [['-1/4', '1/3', '1/3', '0', '1/8'], [-1, 3, -1, 0], True], ['-10/27', '-37/27', '26/27', '181/216']], ['regression: random df2t 26', [['1/3', '-3/8', '0', '1/3', '5/4'], [-2, 3, -2, 4, 3], True], ['1/31', '158/93', '-5353/2232', '5083/6696', '180377/80352']], ['regression: random df2t 16', [['5/4', '1/8', '1/8', '-3/8', '1/3'], [-2, 2, 3], True], ['-72/23', '43/23', '1011/184']], ['control: random df2t 23', [['3/4', '0', '-1/2', '-1/2', '0'], [3, 0, 3], False], ['9/4', '9/8', '21/16']], ['control: random df2t 24', [['2', '0', '-1/4', '1/8', '2'], [1, 0], False], ['2', '-1/4']], ['control: random df2t 28', [['3/4', '0', '-1/2', '1/2', '-1/2'], [4, 1], False], ['3', '-3/4']], ['control: random df2t 31', [['-1/2', '1/8', '1/2', '-1/2', '-1/4'], [0, -3], False], ['0', '3/2']]]]\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":"3cb1745fa875abf9376021c75ef8e5d2a9f59d3f6984e229991a51c440e3aebc","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(x):\n    b0, b1, b2, a1, a2 = [Fraction(v) for v in x[0]]\n    xs, prime = x[1], x[2]\n    s1 = s2 = Fraction(0)\n    if prime and xs:\n        den = 1 + a1 + a2\n        if den == 0:\n            return 'dc-pole'\n        x0 = xs[0]\n        yss = x0 * (b0 + b1 + b2) / den\n        s1 = yss - b0 * x0\n        s2 = b2 * x0 - a2 * yss\n    out = []\n    for v in xs:\n        y = b0 * v + s1\n        s1 = b1 * v - a1 * y + s2\n        s2 = b2 * v + a2 * y\n        out.append(str(y))\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['regression: primed step lowpass', [['1/4', '1/2', '1/4', '-1/2', '1/4'], [2, 2, 2, 2], True], ['8/3', '8/3', '8/3', '8/3']], ['regression: unprimed impulse', [['1', '1/2', '1/3', '1/2', '-1/4'], [1, 0, 0, 0], False], ['1', '0', '7/12', '-7/24']], ['regression: random df2t 0', [['5/4', '1/3', '3/4', '-1/2', '2'], [-1, 2, 4, 4, 1], False], ['-5/4', '37/24', '131/16', '283/32', '-1223/192']], ['control: primed highpass', [['1', '-2', '1', '0', '0'], [3, 3, 1], True], ['0', '0', '-2']], ['control: dc pole', [['1', '0', '0', '-2', '1'], [1, 1], True], 'dc-pole'], ['control: primed empty', [['1', '0', '0', '0', '0'], [], True], []], ['control: random df2t 2', [['3/4', '-1/4', '1/2', '1/8', '-1/2'], [-2, 2], True], ['-16/5', '-1/5']]], [['regression: random df2t 1', [['-1/4', '-1/2', '0', '-1/2', '-3/8'], [-3, 3, 1, 2], False], ['3/4', '9/8', '-29/32', '-33/32']], ['regression: random df2t 6', [['0', '-1/2', '1/8', '3/4', '3/4'], [4, 4, 2, 4], False], ['0', '-2', '0', '1']], ['regression: random df2t 7', [['-1/2', '2', '-1/4', '1/2', '2'], [3, 2, -2, 0], True], ['15/14', '11/7', '37/28', '-465/56']], ['control: random df2t 3', [['1/8', '3/4', '-3/8', '-1/2', '1/8'], [2], False], ['1/4']], ['control: random df2t 4', [['-1/2', '-3/8', '0', '0', '1/3'], [-3], True], ['63/32']], ['control: random df2t 5', [['-3/8', '-1/4', '-1/4', '1/3', '-1/4'], [2], True], ['-21/13']], ['control: random df2t 11', [['1/8', '1/8', '5/4', '-3/8', '1/2'], [0], True], ['0']]], [['regression: random df2t 8', [['-3/8', '2', '1/8', '1/3', '2'], [4, -3, -2, 1, 4], True], ['21/10', '189/40', '-421/40', '-1283/120', '8951/360']], ['regression: random df2t 9', [['-3/8', '0', '-1/2', '2', '5/4'], [3, -3, 3, 2], False], ['-9/8', '27/8', '-255/32', '399/32']], ['regression: random df2t 7', [['-1/2', '2', '-1/4', '1/2', '2'], [3, 2, -2, 0], True], ['15/14', '11/7', '37/28', '-465/56']], ['control: random df2t 12', [['-1/2', '5/4', '-1/4', '5/4', '-1/4'], [0, 0], False], ['0', '0']], ['control: random df2t 13', [['-1/4', '-1/4', '1/2', '5/4', '0'], [2, -3, -1, 3, -3], False], ['-1/2', '7/8', '29/32', '-401/128', '1749/512']], ['control: random df2t 14', [['1/3', '2', '1/2', '1/2', '5/4'], [0, -2], True], ['0', '-2/3']], ['control: random df2t 15', [['-1/4', '2', '-1/2', '1/2', '1/2'], [4], False], ['-1']]], [['regression: random df2t 16', [['5/4', '1/8', '1/8', '-3/8', '1/3'], [-2, 2, 3], True], ['-72/23', '43/23', '1011/184']], ['regression: random df2t 18', [['0', '-3/8', '1/3', '1/3', '2'], [4, 4, 2, 0, -3], True], ['-1/20', '-1/20', '-1/20', '7/10', '8/15']], ['regression: random df2t 9', [['-3/8', '0', '-1/2', '2', '5/4'], [3, -3, 3, 2], False], ['-9/8', '27/8', '-255/32', '399/32']], ['control: random df2t 17', [['2', '-1/2', '3/4', '-1/4', '-3/8'], [-1, 1], True], ['-6', '-2']], ['control: random df2t 19', [['-1/4', '1/3', '1/8', '1/3', '1/8'], [0, 1, -3], True], ['0', '-1/4', '7/6']], ['control: random df2t 20', [['5/4', '0', '5/4', '-1/2', '-1/2'], [-3, 1], True], 'dc-pole'], ['control: random df2t 22', [['1/3', '-3/8', '1/3', '0', '5/4'], [4], True], ['14/27']]], [['regression: random df2t 25', [['-1/4', '1/3', '1/3', '0', '1/8'], [-1, 3, -1, 0], True], ['-10/27', '-37/27', '26/27', '181/216']], ['regression: random df2t 26', [['1/3', '-3/8', '0', '1/3', '5/4'], [-2, 3, -2, 4, 3], True], ['1/31', '158/93', '-5353/2232', '5083/6696', '180377/80352']], ['regression: random df2t 16', [['5/4', '1/8', '1/8', '-3/8', '1/3'], [-2, 2, 3], True], ['-72/23', '43/23', '1011/184']], ['control: random df2t 23', [['3/4', '0', '-1/2', '-1/2', '0'], [3, 0, 3], False], ['9/4', '9/8', '21/16']], ['control: random df2t 24', [['2', '0', '-1/4', '1/8', '2'], [1, 0], False], ['2', '-1/4']], ['control: random df2t 28', [['3/4', '0', '-1/2', '1/2', '-1/2'], [4, 1], False], ['3', '-3/4']], ['control: random df2t 31', [['-1/2', '1/8', '1/2', '-1/2', '-1/4'], [0, -3], False], ['0', '3/2']]]]\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 bounded teaching model with a stipulated toy contract; exact rational arithmetic or fixed-decimal rounding keeps outputs strict JSON. It is not a production DSP library and claims no standards conformance. 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-digital_signal_filters-biquad-transposed-df2-second-state-feedback-sign","generated_at":"2026-09-29T14:51:35.512687+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Transposed DF-II is the default numerical form in filtering libraries, and steady-state priming avoids start-up transients.","root_cause":"The s2 update uses + a2 y.","sha256":"2ffbc1ac50a825b0fe9ed224ef6d8553181b03f60f52ff6712dff754b31d7d15","title":"Transposed DF-II adds a2 feedback in the second state · 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":41.556,"exit_code":1,"observations":[{"actual":["8/3","8/3","17/6","35/12"],"check":"regression: primed step lowpass","expected":["8/3","8/3","8/3","8/3"],"passed":false},{"actual":["1","0","7/12","-7/24"],"check":"regression: unprimed impulse","expected":["1","0","7/12","-7/24"],"passed":true},{"actual":["-5/4","37/24","123/16","737/96","91/64"],"check":"regression: random df2t 0","expected":["-5/4","37/24","131/16","283/32","-1223/192"],"passed":false},{"actual":["0","0","-2"],"check":"control: primed highpass","expected":["0","0","-2"],"passed":true},{"actual":"dc-pole","check":"control: dc pole","expected":"dc-pole","passed":true},{"actual":[],"check":"control: primed empty","expected":[],"passed":true},{"actual":["-16/5","-1/5"],"check":"control: random df2t 2","expected":["-16/5","-1/5"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression: primed step lowpass\", \"actual\": [\"8/3\", \"8/3\", \"17/6\", \"35/12\"], \"expected\": [\"8/3\", \"8/3\", \"8/3\", \"8/3\"], \"passed\": false}, {\"check\": \"regression: unprimed impulse\", \"actual\": [\"1\", \"0\", \"7/12\", \"-7/24\"], \"expected\": [\"1\", \"0\", \"7/12\", \"-7/24\"], \"passed\": true}, {\"check\": \"regression: random df2t 0\", \"actual\": [\"-5/4\", \"37/24\", \"123/16\", \"737/96\", \"91/64\"], \"expected\": [\"-5/4\", \"37/24\", \"131/16\", \"283/32\", \"-1223/192\"], \"passed\": false}, {\"check\": \"control: primed highpass\", \"actual\": [\"0\", \"0\", \"-2\"], \"expected\": [\"0\", \"0\", \"-2\"], \"passed\": true}, {\"check\": \"control: dc pole\", \"actual\": \"dc-pole\", \"expected\": \"dc-pole\", \"passed\": true}, {\"check\": \"control: primed empty\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"control: random df2t 2\", \"actual\": [\"-16/5\", \"-1/5\"], \"expected\": [\"-16/5\", \"-1/5\"], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":43.51,"exit_code":1,"observations":[{"actual":["8/3","8/3","4","14/3"],"check":"regression: primed step lowpass","expected":["8/3","8/3","8/3","8/3"],"passed":false},{"actual":["1","0","1/12","-1/24"],"check":"regression: unprimed impulse","expected":["1","0","7/12","-7/24"],"passed":false},{"actual":["-5/4","37/24","51/16","1201/96","3497/192"],"check":"regression: random df2t 0","expected":["-5/4","37/24","131/16","283/32","-1223/192"],"passed":false},{"actual":["0","0","-2"],"check":"control: primed highpass","expected":["0","0","-2"],"passed":true},{"actual":"dc-pole","check":"control: dc pole","expected":"dc-pole","passed":true},{"actual":[],"check":"control: primed empty","expected":[],"passed":true},{"actual":["-16/5","-1/5"],"check":"control: random df2t 2","expected":["-16/5","-1/5"],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression: primed step lowpass\", \"actual\": [\"8/3\", \"8/3\", \"4\", \"14/3\"], \"expected\": [\"8/3\", \"8/3\", \"8/3\", \"8/3\"], \"passed\": false}, {\"check\": \"regression: unprimed impulse\", \"actual\": [\"1\", \"0\", \"1/12\", \"-1/24\"], \"expected\": [\"1\", \"0\", \"7/12\", \"-7/24\"], \"passed\": false}, {\"check\": \"regression: random df2t 0\", \"actual\": [\"-5/4\", \"37/24\", \"51/16\", \"1201/96\", \"3497/192\"], \"expected\": [\"-5/4\", \"37/24\", \"131/16\", \"283/32\", \"-1223/192\"], \"passed\": false}, {\"check\": \"control: primed highpass\", \"actual\": [\"0\", \"0\", \"-2\"], \"expected\": [\"0\", \"0\", \"-2\"], \"passed\": true}, {\"check\": \"control: dc pole\", \"actual\": \"dc-pole\", \"expected\": \"dc-pole\", \"passed\": true}, {\"check\": \"control: primed empty\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"control: random df2t 2\", \"actual\": [\"-16/5\", \"-1/5\"], \"expected\": [\"-16/5\", \"-1/5\"], \"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."}}