step-examples/12-2b-nurbs/Gn013.stp
Sources
- 03-occt-tests.md (R005 surface_to_bspline)
- 05-occt-shapefix.md (F053 `ShapeCustom_ConvertTo*`)
Description
Some downstream tools require uniform NURBS for every face; others require analytic primitives. The healer must convert plane/cylinder/cone/sphere/torus to/from BSpline on demand.
Reproducer recipe
STEP with mixed `PLANE`, `CYLINDRICAL_SURFACE`, `B_SPLINE_SURFACE_WITH_KNOTS` faces; convert all to NURBS via `ShapeCustom_ConvertToBSpline` or recover analytic via canonical recognition.
Expected kernel behavior
heal; exact algebraic conversion both ways (degree-d Bezier ⇄ NURBS with mult = degree+1; cylinder/cone/sphere ⇄ rational degree-2 NURBS).
Notes
**OCC behavior**: OCC loads the file and produces no shape (empty). Re-audit (2026-07-18, empty-claim re-audit) shows the empty is not caused by the declared defect (elementary<->BSpline conversion requirement): the model is one hand-authored ADVANCED_FACE (B-spline surface with per-edge SURFACE_CURVE/PCURVE) in an OPEN_SHELL that OCC's STEP transfer never builds into a TopoDS face. Base, a CLEAN copy with the injected C-1-break defect edge closed, and a fully well-formed copy (declared defect repaired, scaffold pcurve domains corrected) are all empty (f=0); a genuinely-building B-spline face fixture (Gn024) loads f=1. The silent-empty is toy single-face topology, not a defect-driven silent data-loss, so this is not a proven kernel bug. Synonyms: "convert elementary surface to B-spline", "convert NURBS to analytic primitive", "downstream needs uniform NURBS for every face", "exact algebraic conversion between cylinder and BSpline", "kernel must convert plane/cylinder to NURBS on demand".
Expected validation
occt=empty/empty gmsh=empty ifc=schema_n/a
Byte assertions
contains(b'B_SPLINE_SURFACE')
Tier-3 assertions
shape_null == True
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/* Gn013: Mixed PLANE + B_SPLINE_SURFACE_WITH_KNOTS(1,1) 2x2 net in same shell; consumer requiring uniform NURBS cannot use PLANE face without conversion; consumer requiring analytic cannot use B-spline face without recognition; B-spline face bottom edge B_SPLINE_CURVE_WITH_KNOTS degree-2 C-1 break at t=0.5 (CP[2]=(1.5,0,0) vs CP[3]=(3.0,0,0), 1.5-unit gap) drives shape_null=True */ 3HEADER; 4FILE_DESCRIPTION(('Gn013'),'2;1'); 5FILE_NAME('Gn013.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,3.0,0.0)); 16#7=CARTESIAN_POINT('',(0.0,6.0,0.0)); 17#8=CARTESIAN_POINT('',(3.0,3.0,0.0)); 18#9=CARTESIAN_POINT('',(3.0,6.0,0.0)); 19#10=B_SPLINE_SURFACE_WITH_KNOTS('nurbs_plane',1,1,((#6,#7),(#8,#9)),.UNSPECIFIED.,.F.,.F.,.F.,(2,2),(2,2),(0.0,1.0),(0.0,1.0),.UNSPECIFIED.); 20#11=(GEOMETRIC_REPRESENTATION_CONTEXT(2)PARAMETRIC_REPRESENTATION_CONTEXT()REPRESENTATION_CONTEXT('UV','2D')); 21#12=CARTESIAN_POINT('',(0.0,0.0,0.0)); 22#13=VERTEX_POINT('',#12); 23#14=CARTESIAN_POINT('',(3.0,0.0,0.0)); 24#15=VERTEX_POINT('',#14); 25#16=CARTESIAN_POINT('',(3.0,3.0,0.0)); 26#17=VERTEX_POINT('',#16); 27#18=CARTESIAN_POINT('',(0.0,3.0,0.0)); 28#19=VERTEX_POINT('',#18); 29#20=CARTESIAN_POINT('',(0.0,0.0,0.0)); 30#21=DIRECTION('',(1.0,0.0,0.0)); 31#22=VECTOR('',#21,3.0); 32#23=LINE('',#20,#22); 33#24=CARTESIAN_POINT('',(0.0,0.0)); 34#25=DIRECTION('',(1.0,0.0)); 35#26=VECTOR('',#25,3.0); 36#27=LINE('',#24,#26); 37#28=DEFINITIONAL_REPRESENTATION('pcdef',(#27),#11); 38#29=PCURVE('pc',#5,#28); 39#30=SURFACE_CURVE('sc',#23,(#29),.PCURVE_S1.); 40#31=EDGE_CURVE('ec',#13,#15,#30,.T.); 41#32=CARTESIAN_POINT('',(3.0,0.0,0.0)); 42#33=DIRECTION('',(0.0,1.0,0.0)); 43#34=VECTOR('',#33,3.0); 44#35=LINE('',#32,#34); 45#36=CARTESIAN_POINT('',(3.0,0.0)); 46#37=DIRECTION('',(0.0,1.0)); 47#38=VECTOR('',#37,3.0); 48#39=LINE('',#36,#38); 49#40=DEFINITIONAL_REPRESENTATION('pcdef',(#39),#11); 50#41=PCURVE('pc',#5,#40); 51#42=SURFACE_CURVE('sc',#35,(#41),.PCURVE_S1.); 52#43=EDGE_CURVE('ec',#15,#17,#42,.T.); 53#44=CARTESIAN_POINT('',(3.0,3.0,0.0)); 54#45=DIRECTION('',(-1.0,0.0,0.0)); 55#46=VECTOR('',#45,3.0); 56#47=LINE('',#44,#46); 57#48=CARTESIAN_POINT('',(3.0,3.0)); 58#49=DIRECTION('',(-1.0,0.0)); 59#50=VECTOR('',#49,3.0); 60#51=LINE('',#48,#50); 61#52=DEFINITIONAL_REPRESENTATION('pcdef',(#51),#11); 62#53=PCURVE('pc',#5,#52); 63#54=SURFACE_CURVE('sc',#47,(#53),.PCURVE_S1.); 64#55=EDGE_CURVE('ec',#17,#19,#54,.T.); 65#56=CARTESIAN_POINT('',(0.0,3.0,0.0)); 66#57=DIRECTION('',(0.0,-1.0,0.0)); 67#58=VECTOR('',#57,3.0); 68#59=LINE('',#56,#58); 69#60=CARTESIAN_POINT('',(0.0,3.0)); 70#61=DIRECTION('',(0.0,-1.0)); 71#62=VECTOR('',#61,3.0); 72#63=LINE('',#60,#62); 73#64=DEFINITIONAL_REPRESENTATION('pcdef',(#63),#11); 74#65=PCURVE('pc',#5,#64); 75#66=SURFACE_CURVE('sc',#59,(#65),.PCURVE_S1.); 76#67=EDGE_CURVE('ec',#19,#13,#66,.T.); 77#68=ORIENTED_EDGE('',$,$,#31,.T.); 78#69=ORIENTED_EDGE('',$,$,#43,.T.); 79#70=ORIENTED_EDGE('',$,$,#55,.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),#5,.T.); 84#75=CARTESIAN_POINT('',(0.0,3.0,0.0)); 85#76=VERTEX_POINT('',#75); 86#77=CARTESIAN_POINT('',(3.0,3.0,0.0)); 87#78=VERTEX_POINT('',#77); 88#79=CARTESIAN_POINT('',(3.0,6.0,0.0)); 89#80=VERTEX_POINT('',#79); 90#81=CARTESIAN_POINT('',(0.0,6.0,0.0)); 91#82=VERTEX_POINT('',#81); 92#83=CARTESIAN_POINT('',(3.0,3.0,0.0)); 93#84=DIRECTION('',(0.0,1.0,0.0)); 94#85=VECTOR('',#84,3.0); 95#86=LINE('',#83,#85); 96#87=CARTESIAN_POINT('',(1.0,0.0)); 97#88=DIRECTION('',(0.0,1.0)); 98#89=VECTOR('',#88,3.0); 99#90=LINE('',#87,#89); 100#91=DEFINITIONAL_REPRESENTATION('pcdef',(#90),#11); 101#92=PCURVE('pc',#10,#91); 102#93=SURFACE_CURVE('sc',#86,(#92),.PCURVE_S1.); 103#94=EDGE_CURVE('ec',#78,#80,#93,.T.); 104#95=CARTESIAN_POINT('',(3.0,6.0,0.0)); 105#96=DIRECTION('',(-1.0,0.0,0.0)); 106#97=VECTOR('',#96,3.0); 107#98=LINE('',#95,#97); 108#99=CARTESIAN_POINT('',(1.0,1.0)); 109#100=DIRECTION('',(-1.0,0.0)); 110#101=VECTOR('',#100,3.0); 111#102=LINE('',#99,#101); 112#103=DEFINITIONAL_REPRESENTATION('pcdef',(#102),#11); 113#104=PCURVE('pc',#10,#103); 114#105=SURFACE_CURVE('sc',#98,(#104),.PCURVE_S1.); 115#106=EDGE_CURVE('ec',#80,#82,#105,.T.); 116#107=CARTESIAN_POINT('',(0.0,6.0,0.0)); 117#108=DIRECTION('',(0.0,-1.0,0.0)); 118#109=VECTOR('',#108,3.0); 119#110=LINE('',#107,#109); 120#111=CARTESIAN_POINT('',(0.0,1.0)); 121#112=DIRECTION('',(0.0,-1.0)); 122#113=VECTOR('',#112,3.0); 123#114=LINE('',#111,#113); 124#115=DEFINITIONAL_REPRESENTATION('pcdef',(#114),#11); 125#116=PCURVE('pc',#10,#115); 126#117=SURFACE_CURVE('sc',#110,(#116),.PCURVE_S1.); 127#118=EDGE_CURVE('ec',#82,#76,#117,.T.); 128#119=CARTESIAN_POINT('',(0.0,3.0,0.0)); 129#120=CARTESIAN_POINT('',(0.75,3.0,0.0)); 130#121=CARTESIAN_POINT('',(1.5,3.0,0.0)); 131#122=CARTESIAN_POINT('',(3.0,3.0,0.0)); 132#123=CARTESIAN_POINT('',(3.5,3.0,0.0)); 133#124=CARTESIAN_POINT('',(3.0,3.0,0.0)); 134#125=B_SPLINE_CURVE_WITH_KNOTS('mixed_form_c1_break',2,(#119,#120,#121,#122,#123,#124),.UNSPECIFIED.,.F.,.F.,(3,3,3),(0.0,0.5,1.0),.UNSPECIFIED.); 135#126=CARTESIAN_POINT('',(0.0,0.0)); 136#127=CARTESIAN_POINT('',(0.25,0.0)); 137#128=CARTESIAN_POINT('',(0.5,0.0)); 138#129=CARTESIAN_POINT('',(0.5,0.0)); 139#130=CARTESIAN_POINT('',(0.75,0.0)); 140#131=CARTESIAN_POINT('',(1.0,0.0)); 141#132=B_SPLINE_CURVE_WITH_KNOTS('mixed_form_c1_break_pc',2,(#126,#127,#128,#129,#130,#131),.UNSPECIFIED.,.F.,.F.,(3,3,3),(0.0,0.5,1.0),.UNSPECIFIED.); 142#133=DEFINITIONAL_REPRESENTATION('mixed_form_pc_def',(#132),#11); 143#134=PCURVE('mixed_form_pc_ent',#10,#133); 144#135=SURFACE_CURVE('mixed_form_sc',#125,(#134),.PCURVE_S1.); 145#136=EDGE_CURVE('mixed_form_edge',#76,#78,#135,.T.); 146#137=ORIENTED_EDGE('',$,$,#136,.T.); 147#138=ORIENTED_EDGE('',$,$,#94,.T.); 148#139=ORIENTED_EDGE('',$,$,#106,.T.); 149#140=ORIENTED_EDGE('',$,$,#118,.T.); 150#141=EDGE_LOOP('',(#137,#138,#139,#140)); 151#142=FACE_OUTER_BOUND('',#141,.T.); 152#143=ADVANCED_FACE('',(#142),#10,.T.); 153#144=OPEN_SHELL('',(#74,#143)); 154#145=SHELL_BASED_SURFACE_MODEL('',(#144)); 155#9050=PRODUCT_CONTEXT('',#9000,'mechanical'); 156#9051=PRODUCT('Gn013','Gn013','',(#9050)); 157#9052=PRODUCT_DEFINITION_FORMATION('','',#9051); 158#9053=PRODUCT_DEFINITION_CONTEXT('part definition',#9000,'design'); 159#9054=PRODUCT_DEFINITION('','','',#9052,#9053); 160#9055=PRODUCT_DEFINITION_SHAPE('','','',#9054); 161#9056=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 162#9057=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 163#9058=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 164#9059=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-7),#9056,'distance_accuracy_value',''); 165#9060=(GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#9059))GLOBAL_UNIT_ASSIGNED_CONTEXT((#9056,#9057,#9058))REPRESENTATION_CONTEXT('','3D')); 166#9061=MANIFOLD_SURFACE_SHAPE_REPRESENTATION('',(#145),#9060); 167#9062=SHAPE_DEFINITION_REPRESENTATION(#9055,#9061); 168ENDSEC; 169END-ISO-10303-21;