step-examples/12-3b-wires/Twi169.stp
Sources
- synthesized — no external source cited
Description
ShapeFix_Wire.FixDegenerated insert-between-degenerate
Reproducer recipe
Expected kernel behavior
The wire is a zero-length edge at (0,0,0), then a real 10-unit edge, then a zero-length edge at (10,0,0): each degenerate edge has the same vertex at both ends, both its 3D `LINE` and its pcurve carry a zero-magnitude `VECTOR`, and the underlying surface is a `PLANE` with no singular point. Remove both — a degenerate edge is legitimate only where the surface collapses to a point and where its parametric length is non-zero — and do so in a single scan over the whole edge list, so removing the first entry does not stop the walk and removing the last does not leave the ring pointing at a deleted edge. What remains is one open edge that cannot bound a face; report that rather than emitting a face.
Expected validation
occt=empty/empty gmsh=empty ifc=schema_n/a
Tier-3 assertions
shape_null == True
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes
1ISO-10303-21; 2/* Twi169: GEOMETRIC_CURVE_SET containing EDGE_LOOP with 3 edges on PLANE; PLANE: normal +Z, origin (0,0,0); wire sequence: [degen_edge_start(vAâvA), e_normal(vAâvB), degen_edge_end(vBâvB)]; degen_edge_start: zero-length LINE at vA=(0,0,0) IS degenerate edge; degen_edge_end: zero-length LINE at vB=(10,0,0) IS degenerate edge; e_normal: LINE from vA to vB separating the two degenerates; FixDegenerated encounters degen-normal-degen adjacency; insertion logic fails to handle degenerate-degenerate boundary IS mechanism; GEOMETRIC_CURVE_SET IS model entity â OCC yields empty; all EDGE_CURVEs ARE wired into EDGE_LOOP; never orphaned */ 3HEADER; 4FILE_DESCRIPTION(('Twi169'),'2;1'); 5FILE_NAME('Twi169.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('',(0.0,0.0,0.0)); 20#11=DIRECTION('',(1.0,0.0,0.0)); 21#12=VECTOR('',#11,0.0); 22#13=LINE('',#10,#12); 23#14=CARTESIAN_POINT('',(0.0,0.0)); 24#15=DIRECTION('',(1.0,0.0)); 25#16=VECTOR('',#15,0.0); 26#17=LINE('',#14,#16); 27#18=DEFINITIONAL_REPRESENTATION('',(#17),#*); 28#19=PCURVE('',#5,#18); 29#20=SURFACE_CURVE('',#13,(#19),.PCURVE_S1.); 30#21=EDGE_CURVE('degen_edge_start',#7,#7,#20,.T.); 31#22=ORIENTED_EDGE('',*,*,#21,.T.); 32#23=CARTESIAN_POINT('',(0.0,0.0,0.0)); 33#24=DIRECTION('',(1.0,0.0,0.0)); 34#25=VECTOR('',#24,10.0); 35#26=LINE('',#23,#25); 36#27=CARTESIAN_POINT('',(0.0,0.0)); 37#28=DIRECTION('',(1.0,0.0)); 38#29=VECTOR('',#28,10.0); 39#30=LINE('',#27,#29); 40#31=DEFINITIONAL_REPRESENTATION('',(#30),#*); 41#32=PCURVE('',#5,#31); 42#33=SURFACE_CURVE('',#26,(#32),.PCURVE_S1.); 43#34=EDGE_CURVE('',#7,#9,#33,.T.); 44#35=ORIENTED_EDGE('',*,*,#34,.T.); 45#36=CARTESIAN_POINT('',(10.0,0.0,0.0)); 46#37=DIRECTION('',(1.0,0.0,0.0)); 47#38=VECTOR('',#37,0.0); 48#39=LINE('',#36,#38); 49#40=CARTESIAN_POINT('',(10.0,0.0)); 50#41=DIRECTION('',(1.0,0.0)); 51#42=VECTOR('',#41,0.0); 52#43=LINE('',#40,#42); 53#44=DEFINITIONAL_REPRESENTATION('',(#43),#*); 54#45=PCURVE('',#5,#44); 55#46=SURFACE_CURVE('',#39,(#45),.PCURVE_S1.); 56#47=EDGE_CURVE('degen_edge_end',#9,#9,#46,.T.); 57#48=ORIENTED_EDGE('',*,*,#47,.T.); 58#49=EDGE_LOOP('',(#22,#35,#48)); 59#50=GEOMETRIC_CURVE_SET('',(#49)); 60#9050=PRODUCT_CONTEXT('',#9000,'mechanical'); 61#9051=PRODUCT('Twi169','Twi169','',(#9050)); 62#9052=PRODUCT_DEFINITION_FORMATION('','',#9051); 63#9053=PRODUCT_DEFINITION_CONTEXT('part definition',#9000,'design'); 64#9054=PRODUCT_DEFINITION('','','',#9052,#9053); 65#9055=PRODUCT_DEFINITION_SHAPE('','','',#9054); 66#9056=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 67#9057=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 68#9058=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 69#9059=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-7),#9056,'distance_accuracy_value',''); 70#9060=(GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#9059))GLOBAL_UNIT_ASSIGNED_CONTEXT((#9056,#9057,#9058))REPRESENTATION_CONTEXT('','3D')); 71#9061=MANIFOLD_SURFACE_SHAPE_REPRESENTATION('',(#50),#9060); 72#9062=SHAPE_DEFINITION_REPRESENTATION(#9055,#9061); 73ENDSEC; 74END-ISO-10303-21;