{"abstract":"A mesh with both fins and flipped faces is reported as merely inconsistent.","category":"Mesh topology invariants","checks":7,"contract":"Input: polygon faces. Empty input returns \"empty\". Consecutive repeated indices form no edge (skip that pair only). Undirected edges used once are boundary, twice interior, more non-manifold; an interior edge whose two uses have the same direction is inconsistent. Verdict precedence: non-manifold, then \"non-orientable-or-inconsistent\", then \"open-oriented\" (boundary present), else \"closed-oriented\". Return [boundary, interior, nonmanifold, inconsistent, verdict].","contract_signature":"x","evaluation_group":"w2-mesh_topology_invariants-edge-classification","failed_approach":"Choosing whichever count is larger ignores the fixed precedence.","family":"w2-mesh_topology_invariants-edge-classification-verdict-precedence","id":"FA-88376","implementations":{"attempt":{"sha256":"12e298a7d55493070c2460997cfeed5b66747d2449357c454c39a514cdb514a9","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(x):\n    faces=x\n    if not faces: return 'empty'\n    uses={}\n    for f in faces:\n        n=len(f)\n        for i in range(n):\n            a,b=f[i],f[(i+1)%n]\n            if a==b: continue\n            uses.setdefault((min(a,b),max(a,b)),[]).append((a,b))\n    bd=it=nm=inc=0\n    for k in sorted(uses):\n        u=uses[k]\n        if len(u)==1: bd+=1\n        elif len(u)==2:\n            it+=1\n            if u[0]==u[1]: inc+=1\n        else: nm+=1\n    if nm>inc: v='non-manifold'\n    elif inc: v='non-orientable-or-inconsistent'\n    elif bd: v='open-oriented'\n    else: v='closed-oriented'\n    return [bd,it,nm,inc,v]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['tetrahedron', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']], ['cube', [[[0, 3, 2, 1], [4, 5, 6, 7], [0, 1, 5, 4], [1, 2, 6, 5], [2, 3, 7, 6], [3, 0, 4, 7]]], [0, 12, 0, 0, 'closed-oriented']], ['disk', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1]]], [5, 5, 0, 0, 'open-oriented']], ['mobius', [[[0, 3, 4, 1], [1, 4, 5, 2], [2, 5, 0, 3]]], [6, 3, 0, 1, 'non-orientable-or-inconsistent']], ['book', [[[0, 1, 2], [1, 0, 3], [0, 1, 4]]], [6, 0, 1, 0, 'non-manifold']], ['flipped pair', [[[0, 1, 2], [0, 1, 3]]], [4, 1, 0, 1, 'non-orientable-or-inconsistent']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']]], [['mobius', [[[0, 3, 4, 1], [1, 4, 5, 2], [2, 5, 0, 3]]], [6, 3, 0, 1, 'non-orientable-or-inconsistent']], ['book', [[[0, 1, 2], [1, 0, 3], [0, 1, 4]]], [6, 0, 1, 0, 'non-manifold']], ['flipped pair', [[[0, 1, 2], [0, 1, 3]]], [4, 1, 0, 1, 'non-orientable-or-inconsistent']], ['bowtie', [[[0, 1, 2], [0, 3, 4]]], [6, 0, 0, 0, 'open-oriented']], ['empty', [[]], 'empty'], ['repeated corner', [[[0, 1, 1, 2], [2, 1, 3]]], [4, 1, 0, 0, 'open-oriented']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']]], [['bowtie', [[[0, 1, 2], [0, 3, 4]]], [6, 0, 0, 0, 'open-oriented']], ['empty', [[]], 'empty'], ['repeated corner', [[[0, 1, 1, 2], [2, 1, 3]]], [4, 1, 0, 0, 'open-oriented']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']], ['four sheets', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [1, 0, 5]]], [8, 0, 1, 0, 'non-manifold']], ['torus', [[[0, 3, 4], [0, 4, 1], [1, 4, 5], [1, 5, 2], [2, 5, 3], [2, 3, 0], [3, 6, 7], [3, 7, 4], [4, 7, 8], [4, 8, 5], [5, 8, 6], [5, 6, 3], [6, 0, 1], [6, 1, 7], [7, 1, 2], [7, 2, 8], [8, 2, 0], [8, 0, 6]]], [0, 27, 0, 0, 'closed-oriented']], ['projective plane', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1], [1, 2, 4], [2, 3, 5], [3, 4, 1], [4, 5, 2], [5, 1, 3]]], [0, 15, 0, 10, 'non-orientable-or-inconsistent']]], [['tetrahedron', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']], ['cube', [[[0, 3, 2, 1], [4, 5, 6, 7], [0, 1, 5, 4], [1, 2, 6, 5], [2, 3, 7, 6], [3, 0, 4, 7]]], [0, 12, 0, 0, 'closed-oriented']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']], ['four sheets', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [1, 0, 5]]], [8, 0, 1, 0, 'non-manifold']], ['torus', [[[0, 3, 4], [0, 4, 1], [1, 4, 5], [1, 5, 2], [2, 5, 3], [2, 3, 0], [3, 6, 7], [3, 7, 4], [4, 7, 8], [4, 8, 5], [5, 8, 6], [5, 6, 3], [6, 0, 1], [6, 1, 7], [7, 1, 2], [7, 2, 8], [8, 2, 0], [8, 0, 6]]], [0, 27, 0, 0, 'closed-oriented']], ['projective plane', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1], [1, 2, 4], [2, 3, 5], [3, 4, 1], [4, 5, 2], [5, 1, 3]]], [0, 15, 0, 10, 'non-orientable-or-inconsistent']], ['repeated corner closed', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']]], [['tetrahedron', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']], ['cube', [[[0, 3, 2, 1], [4, 5, 6, 7], [0, 1, 5, 4], [1, 2, 6, 5], [2, 3, 7, 6], [3, 0, 4, 7]]], [0, 12, 0, 0, 'closed-oriented']], ['disk', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1]]], [5, 5, 0, 0, 'open-oriented']], ['mobius', [[[0, 3, 4, 1], [1, 4, 5, 2], [2, 5, 0, 3]]], [6, 3, 0, 1, 'non-orientable-or-inconsistent']], ['book', [[[0, 1, 2], [1, 0, 3], [0, 1, 4]]], [6, 0, 1, 0, 'non-manifold']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']], ['repeated corner closed', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']]]]\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":"ae62dd29062b75ba713122746401e05f5a7da7ce50f41c9b47d711e7f0161934","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(x):\n    faces=x\n    if not faces: return 'empty'\n    uses={}\n    for f in faces:\n        n=len(f)\n        for i in range(n):\n            a,b=f[i],f[(i+1)%n]\n            if a==b: continue\n            uses.setdefault((min(a,b),max(a,b)),[]).append((a,b))\n    bd=it=nm=inc=0\n    for k in sorted(uses):\n        u=uses[k]\n        if len(u)==1: bd+=1\n        elif len(u)==2:\n            it+=1\n            if u[0]==u[1]: inc+=1\n        else: nm+=1\n    if inc: v='non-orientable-or-inconsistent'\n    elif nm: v='non-manifold'\n    elif bd: v='open-oriented'\n    else: v='closed-oriented'\n    return [bd,it,nm,inc,v]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[['tetrahedron', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']], ['cube', [[[0, 3, 2, 1], [4, 5, 6, 7], [0, 1, 5, 4], [1, 2, 6, 5], [2, 3, 7, 6], [3, 0, 4, 7]]], [0, 12, 0, 0, 'closed-oriented']], ['disk', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1]]], [5, 5, 0, 0, 'open-oriented']], ['mobius', [[[0, 3, 4, 1], [1, 4, 5, 2], [2, 5, 0, 3]]], [6, 3, 0, 1, 'non-orientable-or-inconsistent']], ['book', [[[0, 1, 2], [1, 0, 3], [0, 1, 4]]], [6, 0, 1, 0, 'non-manifold']], ['flipped pair', [[[0, 1, 2], [0, 1, 3]]], [4, 1, 0, 1, 'non-orientable-or-inconsistent']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']]], [['mobius', [[[0, 3, 4, 1], [1, 4, 5, 2], [2, 5, 0, 3]]], [6, 3, 0, 1, 'non-orientable-or-inconsistent']], ['book', [[[0, 1, 2], [1, 0, 3], [0, 1, 4]]], [6, 0, 1, 0, 'non-manifold']], ['flipped pair', [[[0, 1, 2], [0, 1, 3]]], [4, 1, 0, 1, 'non-orientable-or-inconsistent']], ['bowtie', [[[0, 1, 2], [0, 3, 4]]], [6, 0, 0, 0, 'open-oriented']], ['empty', [[]], 'empty'], ['repeated corner', [[[0, 1, 1, 2], [2, 1, 3]]], [4, 1, 0, 0, 'open-oriented']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']]], [['bowtie', [[[0, 1, 2], [0, 3, 4]]], [6, 0, 0, 0, 'open-oriented']], ['empty', [[]], 'empty'], ['repeated corner', [[[0, 1, 1, 2], [2, 1, 3]]], [4, 1, 0, 0, 'open-oriented']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']], ['four sheets', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [1, 0, 5]]], [8, 0, 1, 0, 'non-manifold']], ['torus', [[[0, 3, 4], [0, 4, 1], [1, 4, 5], [1, 5, 2], [2, 5, 3], [2, 3, 0], [3, 6, 7], [3, 7, 4], [4, 7, 8], [4, 8, 5], [5, 8, 6], [5, 6, 3], [6, 0, 1], [6, 1, 7], [7, 1, 2], [7, 2, 8], [8, 2, 0], [8, 0, 6]]], [0, 27, 0, 0, 'closed-oriented']], ['projective plane', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1], [1, 2, 4], [2, 3, 5], [3, 4, 1], [4, 5, 2], [5, 1, 3]]], [0, 15, 0, 10, 'non-orientable-or-inconsistent']]], [['tetrahedron', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']], ['cube', [[[0, 3, 2, 1], [4, 5, 6, 7], [0, 1, 5, 4], [1, 2, 6, 5], [2, 3, 7, 6], [3, 0, 4, 7]]], [0, 12, 0, 0, 'closed-oriented']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']], ['four sheets', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [1, 0, 5]]], [8, 0, 1, 0, 'non-manifold']], ['torus', [[[0, 3, 4], [0, 4, 1], [1, 4, 5], [1, 5, 2], [2, 5, 3], [2, 3, 0], [3, 6, 7], [3, 7, 4], [4, 7, 8], [4, 8, 5], [5, 8, 6], [5, 6, 3], [6, 0, 1], [6, 1, 7], [7, 1, 2], [7, 2, 8], [8, 2, 0], [8, 0, 6]]], [0, 27, 0, 0, 'closed-oriented']], ['projective plane', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1], [1, 2, 4], [2, 3, 5], [3, 4, 1], [4, 5, 2], [5, 1, 3]]], [0, 15, 0, 10, 'non-orientable-or-inconsistent']], ['repeated corner closed', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']]], [['tetrahedron', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']], ['cube', [[[0, 3, 2, 1], [4, 5, 6, 7], [0, 1, 5, 4], [1, 2, 6, 5], [2, 3, 7, 6], [3, 0, 4, 7]]], [0, 12, 0, 0, 'closed-oriented']], ['disk', [[[0, 1, 2], [0, 2, 3], [0, 3, 4], [0, 4, 5], [0, 5, 1]]], [5, 5, 0, 0, 'open-oriented']], ['mobius', [[[0, 3, 4, 1], [1, 4, 5, 2], [2, 5, 0, 3]]], [6, 3, 0, 1, 'non-orientable-or-inconsistent']], ['book', [[[0, 1, 2], [1, 0, 3], [0, 1, 4]]], [6, 0, 1, 0, 'non-manifold']], ['book and flipped pair', [[[0, 1, 2], [1, 0, 3], [0, 1, 4], [5, 6, 7], [5, 6, 8]]], [10, 1, 1, 1, 'non-manifold']], ['repeated corner closed', [[[0, 2, 1], [0, 1, 3], [1, 2, 3], [0, 3, 3, 2]]], [0, 6, 0, 0, 'closed-oriented']]]]\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":"Pure combinatorial teaching model over integer face lists with a stipulated contract; no geometry kernel or file format is implied. 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-mesh_topology_invariants-edge-classification-verdict-precedence","generated_at":"2026-09-29T14:51:07.528056+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Mesh processing pipelines (remeshing, export, simulation, printing) trust these topological counts and adjacency answers; a wrong invariant silently accepts broken meshes or rejects valid ones.","root_cause":"The verdict chain tests inconsistency before non-manifoldness.","sha256":"36e90f2be3a2113c82ec96c7cd9da90af0b53caeaf8cd5ed5017cb7da4e64514","title":"Inconsistent orientation outranks non-manifold edges · 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":40.007,"exit_code":1,"observations":[{"actual":[0,6,0,0,"closed-oriented"],"check":"tetrahedron","expected":[0,6,0,0,"closed-oriented"],"passed":true},{"actual":[0,12,0,0,"closed-oriented"],"check":"cube","expected":[0,12,0,0,"closed-oriented"],"passed":true},{"actual":[5,5,0,0,"open-oriented"],"check":"disk","expected":[5,5,0,0,"open-oriented"],"passed":true},{"actual":[6,3,0,1,"non-orientable-or-inconsistent"],"check":"mobius","expected":[6,3,0,1,"non-orientable-or-inconsistent"],"passed":true},{"actual":[6,0,1,0,"non-manifold"],"check":"book","expected":[6,0,1,0,"non-manifold"],"passed":true},{"actual":[4,1,0,1,"non-orientable-or-inconsistent"],"check":"flipped pair","expected":[4,1,0,1,"non-orientable-or-inconsistent"],"passed":true},{"actual":[10,1,1,1,"non-orientable-or-inconsistent"],"check":"book and flipped pair","expected":[10,1,1,1,"non-manifold"],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"tetrahedron\", \"actual\": [0, 6, 0, 0, \"closed-oriented\"], \"expected\": [0, 6, 0, 0, \"closed-oriented\"], \"passed\": true}, {\"check\": \"cube\", \"actual\": [0, 12, 0, 0, \"closed-oriented\"], \"expected\": [0, 12, 0, 0, \"closed-oriented\"], \"passed\": true}, {\"check\": \"disk\", \"actual\": [5, 5, 0, 0, \"open-oriented\"], \"expected\": [5, 5, 0, 0, \"open-oriented\"], \"passed\": true}, {\"check\": \"mobius\", \"actual\": [6, 3, 0, 1, \"non-orientable-or-inconsistent\"], \"expected\": [6, 3, 0, 1, \"non-orientable-or-inconsistent\"], \"passed\": true}, {\"check\": \"book\", \"actual\": [6, 0, 1, 0, \"non-manifold\"], \"expected\": [6, 0, 1, 0, \"non-manifold\"], \"passed\": true}, {\"check\": \"flipped pair\", \"actual\": [4, 1, 0, 1, \"non-orientable-or-inconsistent\"], \"expected\": [4, 1, 0, 1, \"non-orientable-or-inconsistent\"], \"passed\": true}, {\"check\": \"book and flipped pair\", \"actual\": [10, 1, 1, 1, \"non-orientable-or-inconsistent\"], \"expected\": [10, 1, 1, 1, \"non-manifold\"], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":39.021,"exit_code":1,"observations":[{"actual":[0,6,0,0,"closed-oriented"],"check":"tetrahedron","expected":[0,6,0,0,"closed-oriented"],"passed":true},{"actual":[0,12,0,0,"closed-oriented"],"check":"cube","expected":[0,12,0,0,"closed-oriented"],"passed":true},{"actual":[5,5,0,0,"open-oriented"],"check":"disk","expected":[5,5,0,0,"open-oriented"],"passed":true},{"actual":[6,3,0,1,"non-orientable-or-inconsistent"],"check":"mobius","expected":[6,3,0,1,"non-orientable-or-inconsistent"],"passed":true},{"actual":[6,0,1,0,"non-manifold"],"check":"book","expected":[6,0,1,0,"non-manifold"],"passed":true},{"actual":[4,1,0,1,"non-orientable-or-inconsistent"],"check":"flipped pair","expected":[4,1,0,1,"non-orientable-or-inconsistent"],"passed":true},{"actual":[10,1,1,1,"non-orientable-or-inconsistent"],"check":"book and flipped pair","expected":[10,1,1,1,"non-manifold"],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"tetrahedron\", \"actual\": [0, 6, 0, 0, \"closed-oriented\"], \"expected\": [0, 6, 0, 0, \"closed-oriented\"], \"passed\": true}, {\"check\": \"cube\", \"actual\": [0, 12, 0, 0, \"closed-oriented\"], \"expected\": [0, 12, 0, 0, \"closed-oriented\"], \"passed\": true}, {\"check\": \"disk\", \"actual\": [5, 5, 0, 0, \"open-oriented\"], \"expected\": [5, 5, 0, 0, \"open-oriented\"], \"passed\": true}, {\"check\": \"mobius\", \"actual\": [6, 3, 0, 1, \"non-orientable-or-inconsistent\"], \"expected\": [6, 3, 0, 1, \"non-orientable-or-inconsistent\"], \"passed\": true}, {\"check\": \"book\", \"actual\": [6, 0, 1, 0, \"non-manifold\"], \"expected\": [6, 0, 1, 0, \"non-manifold\"], \"passed\": true}, {\"check\": \"flipped pair\", \"actual\": [4, 1, 0, 1, \"non-orientable-or-inconsistent\"], \"expected\": [4, 1, 0, 1, \"non-orientable-or-inconsistent\"], \"passed\": true}, {\"check\": \"book and flipped pair\", \"actual\": [10, 1, 1, 1, \"non-orientable-or-inconsistent\"], \"expected\": [10, 1, 1, 1, \"non-manifold\"], \"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."}}