step-examples/12-2c-surfaces/Gs042.stp
Sources
- 16-iso-spec ISO 10303-42 §CURVE_BOUNDED_SURFACE
Description
A CURVE_BOUNDED_SURFACE is a (basis surface, set of boundary curves) where boundary curves are pcurves on the basis. The spec requires the boundary to be a non-self-intersecting loop in parameter space. Producers occasionally emit a boundary whose two segments cross at an interior point (figure-eight / bowtie), yielding two regions where the trim "inside" is ambiguous.
Reproducer recipe
CURVE_BOUNDED_SURFACE whose basis is a plane and whose boundary is a four-segment COMPOSITE_CURVE forming a self-intersecting bowtie (corners (0,0),(1,1),(1,0),(0,1) connected in that order).
Expected kernel behavior
detect the self-intersection and either reject as malformed or split the boundary into simple loops with explicit inside/outside designation.
Notes
**See also**: Twi-family wire self-intersection entries, Twi286 (same "reader silently resolves the self-intersection on import" finding for the wire-loop analogue). Synonyms: "CURVE_BOUNDED_SURFACE bowtie boundary", "self-intersecting boundary on curve-bounded surface", "boundary curves cross in parameter space", "trim inside ambiguous due to figure-eight boundary", "non-simple loop in CURVE_BOUNDED_SURFACE".
Expected validation
occt=shape(1)/shape(1) gmsh=empty ifc=schema_n/a
Byte assertions
contains(b'CURVE_BOUNDED_SURFACE(')contains(b'BOUNDARY_CURVE(')count_entity_def(b'POLYLINE') == 4
Tier-3 assertions
load == "ok"
Cross-references
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes (with defect highlighting)
1ISO-10303-21; 2/* Gs042: CURVE_BOUNDED_SURFACE IS ADVANCED_FACE.face_geometry; BOUNDARY_CURVE COMPOSITE_CURVE with 4 POLYLINE segments forming self-intersecting bowtie boundary (corners (0,0),(1,1),(1,0),(0,1)) IS wired into face topology; shape(1) (live OCC heals) */ 3HEADER; 4FILE_DESCRIPTION(('Gs042'),'2;1'); 5FILE_NAME('Gs042.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('gs042_ax',#1,#2,#3); 14#5=PLANE('gs042_plane',#4); 15#6=CARTESIAN_POINT('',(0.0,0.0,0.0)); 16#7=CARTESIAN_POINT('',(0.0,1.0,0.0)); 17#8=CARTESIAN_POINT('',(1.0,0.0,0.0)); 18#9=CARTESIAN_POINT('',(1.0,1.0,0.0)); 19#10=POLYLINE('gs042_poly1',(#6,#8)); 20#11=POLYLINE('gs042_poly2',(#8,#7)); 21#12=POLYLINE('gs042_poly3',(#7,#9)); 22#13=POLYLINE('gs042_poly4',(#9,#6)); 23#14=COMPOSITE_CURVE_SEGMENT(.CONTINUOUS.,.T.,#10); 24#15=COMPOSITE_CURVE_SEGMENT(.CONTINUOUS.,.T.,#11); 25#16=COMPOSITE_CURVE_SEGMENT(.CONTINUOUS.,.T.,#12); 26#17=COMPOSITE_CURVE_SEGMENT(.CONTINUOUS.,.T.,#13); 27#18=BOUNDARY_CURVE('gs042_bc',(#14,#15,#16,#17),.T.); 28#19=CURVE_BOUNDED_SURFACE('gs042_cbs',#5,(#18),.F.); 29#20=(GEOMETRIC_REPRESENTATION_CONTEXT(2)PARAMETRIC_REPRESENTATION_CONTEXT()REPRESENTATION_CONTEXT('UV','2D')); 30#21=CARTESIAN_POINT('',(0.0,0.0,0.0)); 31#22=CARTESIAN_POINT('',(1.0,0.0,0.0)); 32#23=CARTESIAN_POINT('',(1.0,1.0,0.0)); 33#24=CARTESIAN_POINT('',(0.0,1.0,0.0)); 34#25=VERTEX_POINT('',#21); 35#26=VERTEX_POINT('',#22); 36#27=VERTEX_POINT('',#23); 37#28=VERTEX_POINT('',#24); 38#29=CARTESIAN_POINT('',(0.0,0.0,0.0)); 39#30=DIRECTION('',(1.0,0.0,0.0)); 40#31=VECTOR('',#30,1.0); 41#32=LINE('',#29,#31); 42#33=CARTESIAN_POINT('',(0.0,0.0)); 43#34=DIRECTION('',(1.0,0.0)); 44#35=VECTOR('',#34,1.0); 45#36=LINE('',#33,#35); 46#37=DEFINITIONAL_REPRESENTATION('pcdef',(#36),#20); 47#38=PCURVE('pc',#19,#37); 48#39=SURFACE_CURVE('sc',#32,(#38),.PCURVE_S1.); 49#40=EDGE_CURVE('ec',#25,#26,#39,.T.); 50#41=CARTESIAN_POINT('',(1.0,0.0,0.0)); 51#42=DIRECTION('',(0.0,1.0,0.0)); 52#43=VECTOR('',#42,1.0); 53#44=LINE('',#41,#43); 54#45=CARTESIAN_POINT('',(1.0,0.0)); 55#46=DIRECTION('',(0.0,1.0)); 56#47=VECTOR('',#46,1.0); 57#48=LINE('',#45,#47); 58#49=DEFINITIONAL_REPRESENTATION('pcdef',(#48),#20); 59#50=PCURVE('pc',#19,#49); 60#51=SURFACE_CURVE('sc',#44,(#50),.PCURVE_S1.); 61#52=EDGE_CURVE('ec',#26,#27,#51,.T.); 62#53=CARTESIAN_POINT('',(1.0,1.0,0.0)); 63#54=DIRECTION('',(-1.0,0.0,0.0)); 64#55=VECTOR('',#54,1.0); 65#56=LINE('',#53,#55); 66#57=CARTESIAN_POINT('',(1.0,1.0)); 67#58=DIRECTION('',(-1.0,0.0)); 68#59=VECTOR('',#58,1.0); 69#60=LINE('',#57,#59); 70#61=DEFINITIONAL_REPRESENTATION('pcdef',(#60),#20); 71#62=PCURVE('pc',#19,#61); 72#63=SURFACE_CURVE('sc',#56,(#62),.PCURVE_S1.); 73#64=EDGE_CURVE('ec',#27,#28,#63,.T.); 74#65=CARTESIAN_POINT('',(0.0,1.0,0.0)); 75#66=DIRECTION('',(0.0,-1.0,0.0)); 76#67=VECTOR('',#66,1.0); 77#68=LINE('',#65,#67); 78#69=CARTESIAN_POINT('',(0.0,1.0)); 79#70=DIRECTION('',(0.0,-1.0)); 80#71=VECTOR('',#70,1.0); 81#72=LINE('',#69,#71); 82#73=DEFINITIONAL_REPRESENTATION('pcdef',(#72),#20); 83#74=PCURVE('pc',#19,#73); 84#75=SURFACE_CURVE('sc',#68,(#74),.PCURVE_S1.); 85#76=EDGE_CURVE('ec',#28,#25,#75,.T.); 86#77=ORIENTED_EDGE('',$,$,#40,.T.); 87#78=ORIENTED_EDGE('',$,$,#52,.T.); 88#79=ORIENTED_EDGE('',$,$,#64,.T.); 89#80=ORIENTED_EDGE('',$,$,#76,.T.); 90#81=EDGE_LOOP('',(#77,#78,#79,#80)); 91#82=FACE_OUTER_BOUND('',#81,.T.); 92#83=ADVANCED_FACE('',(#82),#19,.T.); 93#84=OPEN_SHELL('',(#83)); 94#85=SHELL_BASED_SURFACE_MODEL('',(#84)); 95#9050=PRODUCT_CONTEXT('',#9000,'mechanical'); 96#9051=PRODUCT('Gs042','Gs042','',(#9050)); 97#9052=PRODUCT_DEFINITION_FORMATION('','',#9051); 98#9053=PRODUCT_DEFINITION_CONTEXT('part definition',#9000,'design'); 99#9054=PRODUCT_DEFINITION('','','',#9052,#9053); 100#9055=PRODUCT_DEFINITION_SHAPE('','','',#9054); 101#9056=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 102#9057=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 103#9058=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 104#9059=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-7),#9056,'distance_accuracy_value',''); 105#9060=(GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#9059))GLOBAL_UNIT_ASSIGNED_CONTEXT((#9056,#9057,#9058))REPRESENTATION_CONTEXT('','3D')); 106#9061=MANIFOLD_SURFACE_SHAPE_REPRESENTATION('',(#85),#9060); 107#9062=SHAPE_DEFINITION_REPRESENTATION(#9055,#9061); 108ENDSEC; 109END-ISO-10303-21;