Me982 — merge_reversible_connected_components stitching_compatibility_check: border edge endpoint coincident at (1,0,0); stitch_borders welds components (Branch 3)

§12.14 mesh defects (sub-class: multi-component / stitch-compatibility)

topology

Sources

Description

Two open triangle patches with no shared edge structure. Patch A: triangle (a0,a1,a2) with a1 at (1,0,0). Patch B: triangle (b0,b1,b2) with b0 also at (1,0,0). Vertices a1 (index 1) and b0 (index 3) are distinct entries at the same coordinate — the half-edge structure has no connection, so components are disconnected. The stitching_compatibility_check branch fires when it detects that border halfedge endpoints of Patch A and Patch B are geometrically coincident (distance=0 < tolerance); stitch_borders merges a1/b0. Euler: V=6, E=6, F=2, chi=2.

Reproducer recipe

a0=(0,0,0), a1=(1,0,0), a2=(0.5,1,0); b0=(1,0,0)[=a1], b1=(2,0,0), b2=(1.5,1,0); t0=(a0,a1,a2), t1=(b0,b1,b2); assert_triangle_not_reachable_from(1,0); assert_vertex_pair_distance_lt(1,3,1e-9); assert_vertex_pair_no_shared_triangle(1,3); euler V=6,E=6,F=2,chi=2.

Expected kernel behavior

Branch 3 fires; compatible_for_stitch passes for the (a1,b0) border halfedge pair; stitch_borders merges vertices 1 and 3 and joins the two triangles into a single connected surface.

Expected validation

Live oracle output

No live oracle data — run _run_corpus to populate.

Fixture content

Show fixture bytes
1{
2  "vertices": [
3    [
4      0.0,
5      0.0,
6      0.0
7    ],
8    [
9      1.0,
10      0.0,
11      0.0
12    ],
13    [
14      0.5,
15      1.0,
16      0.0
17    ],
18    [
19      1.0,
20      0.0,
21      0.0
22    ],
23    [
24      2.0,
25      0.0,
26      0.0
27    ],
28    [
29      1.5,
30      1.0,
31      0.0
32    ]
33  ],
34  "triangles": [
35    [
36      0,
37      1,
38      2
39    ],
40    [
41      3,
42      4,
43      5
44    ]
45  ],
46  "metadata": {
47    "id": "Me982",
48    "schema_version": 0,
49    "defect_class": "near_coincident_vertex",
50    "title": "merge_reversible_connected_components stitching_compatibility_check: border edge a1\u2013a2 and b0 endpoint coincident; stitch_borders welds components (Branch 3)",
51    "assertions": [
52      {
53        "kind": "triangle_not_reachable_from",
54        "target": 1,
55        "source": 0
56      },
57      {
58        "kind": "vertex_pair_distance_lt",
59        "pair": [
60          1,
61          3
62        ],
63        "lt": 1e-09
64      },
65      {
66        "kind": "vertex_pair_no_shared_triangle",
67        "pair": [
68          1,
69          3
70        ]
71      },
72      {
73        "kind": "euler_characteristic",
74        "v": 6,
75        "e": 6,
76        "f": 2,
77        "chi": 2
78      }
79    ]
80  }
81}