{"abstract":"The exact integer polynomial pseudodivision result violates the stated contract at pseudo quotient displacement.","category":"Numerics","checks":8,"contract":"Input [A,B] integer ascending canonical nonzero polynomials degA>=degB; returns [scale, quotient, remainder] with scale*A=B*quotient+remainder, scale=lc(B)^(degA-degB+1).","contract_signature":"x","evaluation_group":"s3-numerics-integer-polynomial-pseudodivision","failed_approach":"The partial repair max(0,len(r)-len(B)-1) still violates the pseudo quotient displacement invariant.","family":"s3-numerics-integer-polynomial-pseudodivision-pseudo-quotient-displacement","id":"FA-14791","implementations":{"attempt":{"sha256":"0206d61f0179e885c22a09ee942ff3e2175e4b8e3bea9bb8aee490ef21b0ddad","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nimport itertools\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(x):\n    A,B=x\n    r=A[:];q=[0]*(len(A)-len(B)+1);b=B[-1];steps=len(A)-len(B)+1\n    for _ in range(steps):\n     if len(r)<len(B):\n      q=[b*v for v in q];r=[b*v for v in r];continue\n     k=max(0,len(r)-len(B)-1)\n     c=r[-1]\n     q=[b*v for v in q]\n     q[k]=q[k]+c\n     r=[b*v for v in r]\n     for j in range(len(B)):r[j+k]=r[j+k]-c*B[j]\n     while r and r[-1]==0:r.pop()\n    while q and q[-1]==0:q.pop()\n    return [b**steps,q,r]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, -2], [-2, -1]], [1, [-2, 2], [-6]]), ([[-2, -2, -2], [-2, 1]], [1, [-6, -2], [-14]]), ([[-2, -2, -2], [-2, 2]], [4, [-8, -4], [-24]]), ([[-2, -2, -2], [-1, -2]], [4, [2, 4], [-6]]), ([[-2, -2, -2], [-1, -1]], [1, [0, 2], [-2]]), ([[-2, -2, -2], [-1, 1]], [1, [-4, -2], [-6]])], [([[-2, -2, -2], [-2, -1]], [1, [-2, 2], [-6]]), ([[-2, -2, -2], [-2, 2]], [4, [-8, -4], [-24]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, -2], [2, -1]], [1, [6, 2], [-14]]), ([[-2, -2, -2], [2, 1]], [1, [2, -2], [-6]]), ([[-2, -2, -2], [2, 2]], [4, [0, -4], [-8]]), ([[-2, -2, -1], [-2, -2]], [4, [2, 2], [-4]])], [([[-2, -2, -2], [-2, 1]], [1, [-6, -2], [-14]]), ([[-2, -2, -2], [-1, 1]], [1, [-4, -2], [-6]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, -1], [1, 1]], [1, [-1, -1], [-1]]), ([[-2, -2, -1], [1, 2]], [4, [-3, -2], [-5]]), ([[-2, -2, -1], [2, -2]], [4, [6, 2], [-20]]), ([[-2, -2, -1], [2, -1]], [1, [4, 1], [-10]])], [([[-2, -2, -2], [-2, 2]], [4, [-8, -4], [-24]]), ([[-2, -2, -2], [0, -1]], [1, [2, 2], [-2]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, 1], [0, 2]], [4, [-4, 2], [-8]]), ([[-2, -2, 1], [1, -2]], [4, [3, -2], [-11]]), ([[-2, -2, 1], [1, -1]], [1, [1, -1], [-3]]), ([[-2, -2, 1], [1, 1]], [1, [-3, 1], [1]])], [([[-2, -2, -2], [-1, -2]], [4, [2, 4], [-6]]), ([[-2, -2, -2], [1, -2]], [4, [6, 4], [-14]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, 2], [0, -2]], [4, [4, -4], [-8]]), ([[-2, -2, 2], [0, -1]], [1, [2, -2], [-2]]), ([[-2, -2, 2], [0, 1]], [1, [-2, 2], [-2]]), ([[-2, -2, 2], [0, 2]], [4, [-4, 4], [-8]])]]\nfor i, (args, expected) in enumerate(fixtures[N-1]):\n    check(\"explicit oracle %d\" % i, 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":"de5821814c9f568333a060cf22b3c867b8f50467c5bcecbb5fdac5fa3847a1a9","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nimport itertools\nfrom fractions import Fraction\nN = 1\nobservations = []\ndef solve(x):\n    A,B=x\n    r=A[:];q=[0]*(len(A)-len(B)+1);b=B[-1];steps=len(A)-len(B)+1\n    for _ in range(steps):\n     if len(r)<len(B):\n      q=[b*v for v in q];r=[b*v for v in r];continue\n     k=0\n     c=r[-1]\n     q=[b*v for v in q]\n     q[k]=q[k]+c\n     r=[b*v for v in r]\n     for j in range(len(B)):r[j+k]=r[j+k]-c*B[j]\n     while r and r[-1]==0:r.pop()\n    while q and q[-1]==0:q.pop()\n    return [b**steps,q,r]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, -2], [-2, -1]], [1, [-2, 2], [-6]]), ([[-2, -2, -2], [-2, 1]], [1, [-6, -2], [-14]]), ([[-2, -2, -2], [-2, 2]], [4, [-8, -4], [-24]]), ([[-2, -2, -2], [-1, -2]], [4, [2, 4], [-6]]), ([[-2, -2, -2], [-1, -1]], [1, [0, 2], [-2]]), ([[-2, -2, -2], [-1, 1]], [1, [-4, -2], [-6]])], [([[-2, -2, -2], [-2, -1]], [1, [-2, 2], [-6]]), ([[-2, -2, -2], [-2, 2]], [4, [-8, -4], [-24]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, -2], [2, -1]], [1, [6, 2], [-14]]), ([[-2, -2, -2], [2, 1]], [1, [2, -2], [-6]]), ([[-2, -2, -2], [2, 2]], [4, [0, -4], [-8]]), ([[-2, -2, -1], [-2, -2]], [4, [2, 2], [-4]])], [([[-2, -2, -2], [-2, 1]], [1, [-6, -2], [-14]]), ([[-2, -2, -2], [-1, 1]], [1, [-4, -2], [-6]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, -1], [1, 1]], [1, [-1, -1], [-1]]), ([[-2, -2, -1], [1, 2]], [4, [-3, -2], [-5]]), ([[-2, -2, -1], [2, -2]], [4, [6, 2], [-20]]), ([[-2, -2, -1], [2, -1]], [1, [4, 1], [-10]])], [([[-2, -2, -2], [-2, 2]], [4, [-8, -4], [-24]]), ([[-2, -2, -2], [0, -1]], [1, [2, 2], [-2]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, 1], [0, 2]], [4, [-4, 2], [-8]]), ([[-2, -2, 1], [1, -2]], [4, [3, -2], [-11]]), ([[-2, -2, 1], [1, -1]], [1, [1, -1], [-3]]), ([[-2, -2, 1], [1, 1]], [1, [-3, 1], [1]])], [([[-2, -2, -2], [-1, -2]], [4, [2, 4], [-6]]), ([[-2, -2, -2], [1, -2]], [4, [6, 4], [-14]]), ([[-2, -2, -2], [-2, -2]], [4, [0, 4], [-8]]), ([[2, 2], [2, 2]], [2, [2], []]), ([[-2, -2, 2], [0, -2]], [4, [4, -4], [-8]]), ([[-2, -2, 2], [0, -1]], [1, [2, -2], [-2]]), ([[-2, -2, 2], [0, 1]], [1, [-2, 2], [-2]]), ([[-2, -2, 2], [0, 2]], [4, [-4, 4], [-8]])]]\nfor i, (args, expected) in enumerate(fixtures[N-1]):\n    check(\"explicit oracle %d\" % i, 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. Inputs are restricted to the explicit contract; this is not a production algebra library. 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":"s3-numerics-integer-polynomial-pseudodivision-pseudo-quotient-displacement","generated_at":"2026-09-29T14:39:20.551729+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Exact discrete arithmetic with observable algorithmic state; no floating point approximation is used.","root_cause":"The pseudo quotient displacement step uses 0 instead of len(r)-len(B).","sha256":"c9984b5ad2e33512d28bbcca60cabef491c4a11bb71a79859fd93028ba686ab1","title":"Integer polynomial pseudodivision: pseudo quotient displacement · 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.103,"exit_code":1,"observations":[{"actual":[4,[8],[8,8,-8]],"check":"explicit oracle 0","expected":[4,[0,4],[-8]],"passed":false},{"actual":[2,[2],[]],"check":"explicit oracle 1","expected":[2,[2],[]],"passed":true},{"actual":[1,[4],[6,2,-2]],"check":"explicit oracle 2","expected":[1,[-2,2],[-6]],"passed":false},{"actual":[1,[-4],[-10,2,-2]],"check":"explicit oracle 3","expected":[1,[-6,-2],[-14]],"passed":false},{"actual":[4,[-8],[-24,8,-8]],"check":"explicit oracle 4","expected":[4,[-8,-4],[-24]],"passed":false},{"actual":[4,[8],[0,8,-8]],"check":"explicit oracle 5","expected":[4,[2,4],[-6]],"passed":false},{"actual":[1,[4],[2,2,-2]],"check":"explicit oracle 6","expected":[1,[0,2],[-2]],"passed":false},{"actual":[1,[-4],[-6,2,-2]],"check":"explicit oracle 7","expected":[1,[-4,-2],[-6]],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"explicit oracle 0\", \"actual\": [4, [8], [8, 8, -8]], \"expected\": [4, [0, 4], [-8]], \"passed\": false}, {\"check\": \"explicit oracle 1\", \"actual\": [2, [2], []], \"expected\": [2, [2], []], \"passed\": true}, {\"check\": \"explicit oracle 2\", \"actual\": [1, [4], [6, 2, -2]], \"expected\": [1, [-2, 2], [-6]], \"passed\": false}, {\"check\": \"explicit oracle 3\", \"actual\": [1, [-4], [-10, 2, -2]], \"expected\": [1, [-6, -2], [-14]], \"passed\": false}, {\"check\": \"explicit oracle 4\", \"actual\": [4, [-8], [-24, 8, -8]], \"expected\": [4, [-8, -4], [-24]], \"passed\": false}, {\"check\": \"explicit oracle 5\", \"actual\": [4, [8], [0, 8, -8]], \"expected\": [4, [2, 4], [-6]], \"passed\": false}, {\"check\": \"explicit oracle 6\", \"actual\": [1, [4], [2, 2, -2]], \"expected\": [1, [0, 2], [-2]], \"passed\": false}, {\"check\": \"explicit oracle 7\", \"actual\": [1, [-4], [-6, 2, -2]], \"expected\": [1, [-4, -2], [-6]], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":42.458,"exit_code":1,"observations":[{"actual":[4,[8],[8,8,-8]],"check":"explicit oracle 0","expected":[4,[0,4],[-8]],"passed":false},{"actual":[2,[2],[]],"check":"explicit oracle 1","expected":[2,[2],[]],"passed":true},{"actual":[1,[4],[6,2,-2]],"check":"explicit oracle 2","expected":[1,[-2,2],[-6]],"passed":false},{"actual":[1,[-4],[-10,2,-2]],"check":"explicit oracle 3","expected":[1,[-6,-2],[-14]],"passed":false},{"actual":[4,[-8],[-24,8,-8]],"check":"explicit oracle 4","expected":[4,[-8,-4],[-24]],"passed":false},{"actual":[4,[8],[0,8,-8]],"check":"explicit oracle 5","expected":[4,[2,4],[-6]],"passed":false},{"actual":[1,[4],[2,2,-2]],"check":"explicit oracle 6","expected":[1,[0,2],[-2]],"passed":false},{"actual":[1,[-4],[-6,2,-2]],"check":"explicit oracle 7","expected":[1,[-4,-2],[-6]],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"explicit oracle 0\", \"actual\": [4, [8], [8, 8, -8]], \"expected\": [4, [0, 4], [-8]], \"passed\": false}, {\"check\": \"explicit oracle 1\", \"actual\": [2, [2], []], \"expected\": [2, [2], []], \"passed\": true}, {\"check\": \"explicit oracle 2\", \"actual\": [1, [4], [6, 2, -2]], \"expected\": [1, [-2, 2], [-6]], \"passed\": false}, {\"check\": \"explicit oracle 3\", \"actual\": [1, [-4], [-10, 2, -2]], \"expected\": [1, [-6, -2], [-14]], \"passed\": false}, {\"check\": \"explicit oracle 4\", \"actual\": [4, [-8], [-24, 8, -8]], \"expected\": [4, [-8, -4], [-24]], \"passed\": false}, {\"check\": \"explicit oracle 5\", \"actual\": [4, [8], [0, 8, -8]], \"expected\": [4, [2, 4], [-6]], \"passed\": false}, {\"check\": \"explicit oracle 6\", \"actual\": [1, [4], [2, 2, -2]], \"expected\": [1, [0, 2], [-2]], \"passed\": false}, {\"check\": \"explicit oracle 7\", \"actual\": [1, [-4], [-6, 2, -2]], \"expected\": [1, [-4, -2], [-6]], \"passed\": false}], \"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."}}