step-examples/12-3b-wires/Twi072.stp
Sources
- OCCT `ShapeAnalysis_Wire::CheckGap3d` (`ShapeAnalysis_Wire.hxx:340`)
Description
Targeted single-junction 3D gap query. Caller specifies `num`; analyzer reports whether the gap between edge `num-1` and edge `num` exceeds working precision and the actual distance. Used by interactive healing tools to focus on one defect at a time.
Reproducer recipe
As Twi053 but the caller queries junction 4 specifically.
Expected kernel behavior
Heal and accept: normalize an O(1) check returning OK/DONE/FAIL plus the gap value.
Notes
**See also**: Twi073. Per-junction counterpart to Twi068 (whole-wire). Synonyms: "single-junction 3D gap query", "specific gap location query", "ask about one specific junction in wire", "wire gap diagnostic at one index".- **Tier-3 assertion**: n_edges_total >= 3
Expected validation
occt=shape(1)/shape(1) gmsh=reject ifc=schema_n/a
Closure intent
sheet — the open shell is the intended final geometry; a solid-only kernel should cleanly refuse.
Tier-3 assertions
face[0].surface_type == "plane"n_vertices_total >= 6
Cross-references
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes
1ISO-10303-21; 2/* Twi072: ADVANCED_FACE on a PLANE; EDGE_LOOP with THREE EDGE_CURVEs; missing closing edge creates 3D gap at junction 3/wrap-around; edge1 (bottom): v_bl(0,0,0)âv_br(10,0,0) â correct; edge2 (right): v_br(10,0,0)âv_tr(10,10,0) â correct; edge3 (top-partial): v_tr(10,10,0)âv_gap(0.0,10.05,0) â last vertex is at (0,10.05,0), NOT at (0,0,0); wrap-around junction has 3D gap of 10.05 units (v_gap to v_bl); per-junction query for junction 3 (lastâfirst wrap) reports the localized fault distance; CheckGap3d(num=3) returns DONE/FAIL plus the 10.05-unit gap; per-junction query isolates ONE junction â targeted diagnostic; all EDGE_CURVEs ARE wired into EDGE_LOOP â FACE_OUTER_BOUND â ADVANCED_FACE in CLOSED_SHELL; second face in shell provides tier-3 vertex/edge counts */ 3HEADER; 4FILE_DESCRIPTION(('Twi072'),'2;1'); 5FILE_NAME('Twi072.stp','2026-06-17T00:00:00',(''),(''),'cad-research-suite','',''); 6FILE_SCHEMA(('AUTOMOTIVE_DESIGN { 1 0 10303 214 3 1 1 }')); 7ENDSEC; 8DATA; 9#9000=APPLICATION_CONTEXT('mechanical design'); 10#1=CARTESIAN_POINT('',(0.0,0.0,0.0)); 11#2=DIRECTION('',(0.0,0.0,1.0)); 12#3=DIRECTION('',(1.0,0.0,0.0)); 13#4=AXIS2_PLACEMENT_3D('',#1,#2,#3); 14#5=PLANE('',#4); 15#6=CARTESIAN_POINT('',(0.0,0.0,0.0)); 16#7=VERTEX_POINT('',#6); 17#8=CARTESIAN_POINT('',(10.0,0.0,0.0)); 18#9=VERTEX_POINT('',#8); 19#10=CARTESIAN_POINT('',(10.0,10.0,0.0)); 20#11=VERTEX_POINT('',#10); 21#12=CARTESIAN_POINT('',(0.0,10.05,0.0)); 22#13=VERTEX_POINT('',#12); 23#14=CARTESIAN_POINT('',(0.0,0.0,0.0)); 24#15=DIRECTION('',(1.0,0.0,0.0)); 25#16=VECTOR('',#15,10.0); 26#17=LINE('',#14,#16); 27#18=EDGE_CURVE('',#7,#9,#17,.T.); 28#19=ORIENTED_EDGE('',$,$,#18,.T.); 29#20=CARTESIAN_POINT('',(10.0,0.0,0.0)); 30#21=DIRECTION('',(0.0,1.0,0.0)); 31#22=VECTOR('',#21,10.0); 32#23=LINE('',#20,#22); 33#24=EDGE_CURVE('',#9,#11,#23,.T.); 34#25=ORIENTED_EDGE('',$,$,#24,.T.); 35#26=CARTESIAN_POINT('',(10.0,10.0,0.0)); 36#27=DIRECTION('',(-1.0,0.0,0.0)); 37#28=VECTOR('',#27,10.0); 38#29=LINE('',#26,#28); 39#30=EDGE_CURVE('',#11,#13,#29,.T.); 40#31=ORIENTED_EDGE('',$,$,#30,.T.); 41#32=EDGE_LOOP('',(#19,#25,#31)); 42#33=FACE_OUTER_BOUND('',#32,.T.); 43#34=ADVANCED_FACE('',(#33),#5,.T.); 44#35=CARTESIAN_POINT('',(0.0,0.0,-1.0)); 45#36=DIRECTION('',(0.0,0.0,1.0)); 46#37=DIRECTION('',(1.0,0.0,0.0)); 47#38=AXIS2_PLACEMENT_3D('',#35,#36,#37); 48#39=PLANE('',#38); 49#40=CARTESIAN_POINT('',(0.0,0.0,-1.0)); 50#41=VERTEX_POINT('',#40); 51#42=CARTESIAN_POINT('',(10.0,0.0,-1.0)); 52#43=VERTEX_POINT('',#42); 53#44=CARTESIAN_POINT('',(10.0,10.0,-1.0)); 54#45=VERTEX_POINT('',#44); 55#46=CARTESIAN_POINT('',(0.0,10.0,-1.0)); 56#47=VERTEX_POINT('',#46); 57#48=CARTESIAN_POINT('',(0.0,0.0,-1.0)); 58#49=DIRECTION('',(1.0,0.0,0.0)); 59#50=VECTOR('',#49,10.0); 60#51=LINE('',#48,#50); 61#52=EDGE_CURVE('',#41,#43,#51,.T.); 62#53=CARTESIAN_POINT('',(10.0,0.0,-1.0)); 63#54=DIRECTION('',(0.0,1.0,0.0)); 64#55=VECTOR('',#54,10.0); 65#56=LINE('',#53,#55); 66#57=EDGE_CURVE('',#43,#45,#56,.T.); 67#58=CARTESIAN_POINT('',(10.0,10.0,-1.0)); 68#59=DIRECTION('',(-1.0,0.0,0.0)); 69#60=VECTOR('',#59,10.0); 70#61=LINE('',#58,#60); 71#62=EDGE_CURVE('',#45,#47,#61,.T.); 72#63=CARTESIAN_POINT('',(0.0,10.0,-1.0)); 73#64=DIRECTION('',(0.0,-1.0,0.0)); 74#65=VECTOR('',#64,10.0); 75#66=LINE('',#63,#65); 76#67=EDGE_CURVE('',#47,#41,#66,.T.); 77#68=ORIENTED_EDGE('',$,$,#52,.T.); 78#69=ORIENTED_EDGE('',$,$,#57,.T.); 79#70=ORIENTED_EDGE('',$,$,#62,.T.); 80#71=ORIENTED_EDGE('',$,$,#67,.T.); 81#72=EDGE_LOOP('',(#68,#69,#70,#71)); 82#73=FACE_OUTER_BOUND('',#72,.T.); 83#74=ADVANCED_FACE('',(#73),#39,.T.); 84#75=CLOSED_SHELL('',(#34,#74)); 85#76=SHELL_BASED_SURFACE_MODEL('',(#75)); 86#9050=PRODUCT_CONTEXT('',#9000,'mechanical'); 87#9051=PRODUCT('Twi072','Twi072','',(#9050)); 88#9052=PRODUCT_DEFINITION_FORMATION('','',#9051); 89#9053=PRODUCT_DEFINITION_CONTEXT('part definition',#9000,'design'); 90#9054=PRODUCT_DEFINITION('','','',#9052,#9053); 91#9055=PRODUCT_DEFINITION_SHAPE('','','',#9054); 92#9056=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 93#9057=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 94#9058=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 95#9059=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-7),#9056,'distance_accuracy_value',''); 96#9060=(GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#9059))GLOBAL_UNIT_ASSIGNED_CONTEXT((#9056,#9057,#9058))REPRESENTATION_CONTEXT('','3D')); 97#9061=MANIFOLD_SURFACE_SHAPE_REPRESENTATION('',(#76),#9060); 98#9062=SHAPE_DEFINITION_REPRESENTATION(#9055,#9061); 99ENDSEC; 100END-ISO-10303-21;