{"abstract":"The exact negative radix encoding result violates the stated contract at nonnegative negative radix remainder.","category":"Numerics","checks":8,"contract":"Input [integer, magnitude base>=2]; return most-significant-first digits 0..base-1 representing integer in radix -base. Bounds: |integer|<=100 and base<=8.","contract_signature":"x","evaluation_group":"s3-numerics-negative-radix-encoding","failed_approach":"The partial repair abs(n)%b still violates the nonnegative negative radix remainder invariant.","family":"s3-numerics-negative-radix-encoding-nonnegative-negative-radix-remainder","id":"FA-15046","implementations":{"attempt":{"sha256":"1745c4cc4947e77415921402cbee09b41486e553ea722ad064ad58646eeda1bc","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    n,b=x\n    if n==0:return [0]\n    out=[]\n    for _ in range(60):\n     if n==0:break\n     r=abs(n)%b\n     out.append(r)\n     n=(n-r)//(-b)\n    return out[::-1] if bool(out) else []\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([-100, 3], [1, 2, 1, 1, 1, 2]), ([100, 8], [2, 4, 4]), ([-100, 4], [2, 2, 1, 0]), ([-100, 5], [1, 1, 0, 0]), ([-100, 6], [1, 4, 5, 2]), ([-100, 7], [1, 5, 1, 5]), ([-100, 8], [1, 7, 5, 4])], [([-100, 3], [1, 2, 1, 1, 1, 2]), ([-100, 7], [1, 5, 1, 5]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-98, 5], [1, 1, 0, 2]), ([-98, 6], [1, 4, 5, 4]), ([-98, 7], [1, 5, 0, 0]), ([-98, 8], [1, 7, 5, 6])], [([-100, 4], [2, 2, 1, 0]), ([-99, 4], [2, 2, 1, 1]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-96, 8], [1, 7, 4, 0]), ([-95, 2], [1, 1, 1, 0, 0, 0, 0, 1]), ([-95, 3], [1, 2, 1, 2, 2, 1]), ([-95, 4], [2, 2, 0, 1])], [([-100, 5], [1, 1, 0, 0]), ([-99, 7], [1, 5, 1, 6]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-93, 4], [2, 2, 0, 3]), ([-93, 5], [1, 2, 4, 2]), ([-93, 6], [1, 4, 4, 3]), ([-93, 7], [1, 5, 0, 5])], [([-100, 6], [1, 4, 5, 2]), ([-98, 5], [1, 1, 0, 2]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-91, 7], [1, 6, 6, 0]), ([-91, 8], [1, 7, 4, 5]), ([-90, 2], [1, 1, 1, 1, 1, 0, 1, 0]), ([-90, 3], [1, 2, 1, 2, 0, 0])]]\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":"04498cca62fde6032ea83570d77a656111693ea59771531eac14ca9b78705655","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    n,b=x\n    if n==0:return [0]\n    out=[]\n    for _ in range(60):\n     if n==0:break\n     r=n%(-b)\n     out.append(r)\n     n=(n-r)//(-b)\n    return out[::-1] if bool(out) else []\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([-100, 3], [1, 2, 1, 1, 1, 2]), ([100, 8], [2, 4, 4]), ([-100, 4], [2, 2, 1, 0]), ([-100, 5], [1, 1, 0, 0]), ([-100, 6], [1, 4, 5, 2]), ([-100, 7], [1, 5, 1, 5]), ([-100, 8], [1, 7, 5, 4])], [([-100, 3], [1, 2, 1, 1, 1, 2]), ([-100, 7], [1, 5, 1, 5]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-98, 5], [1, 1, 0, 2]), ([-98, 6], [1, 4, 5, 4]), ([-98, 7], [1, 5, 0, 0]), ([-98, 8], [1, 7, 5, 6])], [([-100, 4], [2, 2, 1, 0]), ([-99, 4], [2, 2, 1, 1]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-96, 8], [1, 7, 4, 0]), ([-95, 2], [1, 1, 1, 0, 0, 0, 0, 1]), ([-95, 3], [1, 2, 1, 2, 2, 1]), ([-95, 4], [2, 2, 0, 1])], [([-100, 5], [1, 1, 0, 0]), ([-99, 7], [1, 5, 1, 6]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-93, 4], [2, 2, 0, 3]), ([-93, 5], [1, 2, 4, 2]), ([-93, 6], [1, 4, 4, 3]), ([-93, 7], [1, 5, 0, 5])], [([-100, 6], [1, 4, 5, 2]), ([-98, 5], [1, 1, 0, 2]), ([-100, 2], [1, 1, 1, 0, 1, 1, 0, 0]), ([100, 8], [2, 4, 4]), ([-91, 7], [1, 6, 6, 0]), ([-91, 8], [1, 7, 4, 5]), ([-90, 2], [1, 1, 1, 1, 1, 0, 1, 0]), ([-90, 3], [1, 2, 1, 2, 0, 0])]]\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-negative-radix-encoding-nonnegative-negative-radix-remainder","generated_at":"2026-09-29T14:39:22.734191+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 nonnegative negative radix remainder step uses n%(-b) instead of n%b.","sha256":"9fe16e491e120405dd62488648c7f628f64cdf2dbe71bb795cf22fe483ca600b","title":"Negative radix encoding: nonnegative negative radix remainder · 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":44.75,"exit_code":1,"observations":[{"actual":[1,1,1,0,1,1,0,0],"check":"explicit oracle 0","expected":[1,1,1,0,1,1,0,0],"passed":true},{"actual":[1,1,2,0,1],"check":"explicit oracle 1","expected":[1,2,1,1,1,2],"passed":false},{"actual":[2,4,4],"check":"explicit oracle 2","expected":[2,4,4],"passed":true},{"actual":[2,2,1,0],"check":"explicit oracle 3","expected":[2,2,1,0],"passed":true},{"actual":[1,4,0,0],"check":"explicit oracle 4","expected":[1,1,0,0],"passed":false},{"actual":[2,5,4],"check":"explicit oracle 5","expected":[1,4,5,2],"passed":false},{"actual":[2,0,2],"check":"explicit oracle 6","expected":[1,5,1,5],"passed":false},{"actual":[1,5,4],"check":"explicit oracle 7","expected":[1,7,5,4],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"explicit oracle 0\", \"actual\": [1, 1, 1, 0, 1, 1, 0, 0], \"expected\": [1, 1, 1, 0, 1, 1, 0, 0], \"passed\": true}, {\"check\": \"explicit oracle 1\", \"actual\": [1, 1, 2, 0, 1], \"expected\": [1, 2, 1, 1, 1, 2], \"passed\": false}, {\"check\": \"explicit oracle 2\", \"actual\": [2, 4, 4], \"expected\": [2, 4, 4], \"passed\": true}, {\"check\": \"explicit oracle 3\", \"actual\": [2, 2, 1, 0], \"expected\": [2, 2, 1, 0], \"passed\": true}, {\"check\": \"explicit oracle 4\", \"actual\": [1, 4, 0, 0], \"expected\": [1, 1, 0, 0], \"passed\": false}, {\"check\": \"explicit oracle 5\", \"actual\": [2, 5, 4], \"expected\": [1, 4, 5, 2], \"passed\": false}, {\"check\": \"explicit oracle 6\", \"actual\": [2, 0, 2], \"expected\": [1, 5, 1, 5], \"passed\": false}, {\"check\": \"explicit oracle 7\", \"actual\": [1, 5, 4], \"expected\": [1, 7, 5, 4], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":41.55,"exit_code":1,"observations":[{"actual":[-1,-1,0,-1,0,0,-1,0,0],"check":"explicit oracle 0","expected":[1,1,1,0,1,1,0,0],"passed":false},{"actual":[-1,0,-2,0,-1],"check":"explicit oracle 1","expected":[1,2,1,1,1,2],"passed":false},{"actual":[-1,-7,-5,-4],"check":"explicit oracle 2","expected":[2,4,4],"passed":false},{"actual":[-1,-3,-3,-3,0],"check":"explicit oracle 3","expected":[2,2,1,0],"passed":false},{"actual":[-4,0,0],"check":"explicit oracle 4","expected":[1,1,0,0],"passed":false},{"actual":[-3,-2,-4],"check":"explicit oracle 5","expected":[1,4,5,2],"passed":false},{"actual":[-2,0,-2],"check":"explicit oracle 6","expected":[1,5,1,5],"passed":false},{"actual":[-2,-4,-4],"check":"explicit oracle 7","expected":[1,7,5,4],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"explicit oracle 0\", \"actual\": [-1, -1, 0, -1, 0, 0, -1, 0, 0], \"expected\": [1, 1, 1, 0, 1, 1, 0, 0], \"passed\": false}, {\"check\": \"explicit oracle 1\", \"actual\": [-1, 0, -2, 0, -1], \"expected\": [1, 2, 1, 1, 1, 2], \"passed\": false}, {\"check\": \"explicit oracle 2\", \"actual\": [-1, -7, -5, -4], \"expected\": [2, 4, 4], \"passed\": false}, {\"check\": \"explicit oracle 3\", \"actual\": [-1, -3, -3, -3, 0], \"expected\": [2, 2, 1, 0], \"passed\": false}, {\"check\": \"explicit oracle 4\", \"actual\": [-4, 0, 0], \"expected\": [1, 1, 0, 0], \"passed\": false}, {\"check\": \"explicit oracle 5\", \"actual\": [-3, -2, -4], \"expected\": [1, 4, 5, 2], \"passed\": false}, {\"check\": \"explicit oracle 6\", \"actual\": [-2, 0, -2], \"expected\": [1, 5, 1, 5], \"passed\": false}, {\"check\": \"explicit oracle 7\", \"actual\": [-2, -4, -4], \"expected\": [1, 7, 5, 4], \"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."}}