step-examples/12-2a-pcurves/Gp024.stp
Sources
- 14-brlcad-rhino.md K016
Sender
Rhino after `Scale 1000` then re-export
Description
STEP files contain no pcurves natively; on Rhino export, pcurves are computed against the host surface. After scaling the 3D model by 1000, pcurve evaluation error scales by 1000 too, producing validation messages like "Distance from end of trim to 3D edge is 0.05 (edge tol = 0.0001)".
Reproducer recipe
Open a small STEP file (mm tolerance 0.0001), scale by ×1000, export STEP with "export parameter space curves" enabled.
Expected kernel behavior
heal; refit pcurves after scale, recompute pcurves at export, or scale `edge_tolerance` consistently.
Notes
**See also**: Gn032. **OCC behavior**: accepts and loads shape(1); OCC's STEP reader recomputes the pcurve from the 3D curve on transfer (per Gp193), so the declared 2D/pcurve defect does not survive into the built shape. Perturbing the declared defect from clean to grossly exaggerated leaves the built shape unchanged in both shape-counts and BRepCheck validity (heal_on and heal_off), so the shape-count oracle cannot distinguish it from a clean input; shape(1) does not witness a kernel bug. Synonyms: "pcurve error scales with non-uniform 3D scale", "scale by 1000 inflates pcurve deviation", "Rhino scale breaks pcurve trim accuracy", "edge tolerance not rescaled with model scale", "distance from end of trim to 3D edge exceeds tolerance after scale".
Expected validation
occt=shape(1)/shape(1) gmsh=reject ifc=schema_n/a
Byte assertions
contains(b'SURFACE_CURVE')contains(b'EDGE_CURVE')count_entity_def(b'PCURVE') >= 1
Tier-3 assertions
shape_null == Falsen_faces_total == 1n_edges_total == 1n_vertices_total == 2face[0].surface_type == "cylinder"face[0].quadric.radius == 1000.0edge[0].curve_type == "circle"edge[0].analytic.radius == 1000.0
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/* Gp024: After x1000 scale: EDGE_CURVE tolerance stays 0.0001 but pcurve LINE magnitude is (pi-0.05) instead of pi; pcurve end is 0.05 from 3D edge end; SameParameter=.T. asserted despite mismatch */ 3HEADER; 4FILE_DESCRIPTION(('Gp024'),'2;1'); 5FILE_NAME('Gp024.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=CYLINDRICAL_SURFACE('',#4,1000.0); 15#6=(GEOMETRIC_REPRESENTATION_CONTEXT(2)PARAMETRIC_REPRESENTATION_CONTEXT()REPRESENTATION_CONTEXT('UV','2D')); 16#7=CARTESIAN_POINT('',(1000.0,0.0,500.0)); 17#8=CARTESIAN_POINT('',(-1000.0,0.0,500.0)); 18#9=VERTEX_POINT('',#7); 19#10=VERTEX_POINT('',#8); 20#11=CARTESIAN_POINT('',(0.0,0.0,500.0)); 21#12=DIRECTION('',(0.0,0.0,1.0)); 22#13=DIRECTION('',(1.0,0.0,0.0)); 23#14=AXIS2_PLACEMENT_3D('',#11,#12,#13); 24#15=CIRCLE('',#14,1000.0); 25#16=CARTESIAN_POINT('',(0.0,500.0)); 26#17=DIRECTION('',(1.0,0.0)); 27#18=VECTOR('',#17,3.09159265359); 28#19=LINE('',#16,#18); 29#20=DEFINITIONAL_REPRESENTATION('pc_scale_err',(#19),#6); 30#21=PCURVE('',#5,#20); 31#22=SURFACE_CURVE('scaled_arc',#15,(#21),.PCURVE_S1.); 32#23=EDGE_CURVE('scaled_edge',#9,#10,#22,.T.); 33#24=ORIENTED_EDGE('',$,$,#23,.T.); 34#25=EDGE_LOOP('',(#24)); 35#26=FACE_OUTER_BOUND('',#25,.T.); 36#27=ADVANCED_FACE('',(#26),#5,.T.); 37#28=OPEN_SHELL('',(#27)); 38#29=SHELL_BASED_SURFACE_MODEL('',(#28)); 39#9050=PRODUCT_CONTEXT('',#9000,'mechanical'); 40#9051=PRODUCT('Gp024','Gp024','',(#9050)); 41#9052=PRODUCT_DEFINITION_FORMATION('','',#9051); 42#9053=PRODUCT_DEFINITION_CONTEXT('part definition',#9000,'design'); 43#9054=PRODUCT_DEFINITION('','','',#9052,#9053); 44#9055=PRODUCT_DEFINITION_SHAPE('','','',#9054); 45#9056=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 46#9057=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 47#9058=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 48#9059=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-7),#9056,'distance_accuracy_value',''); 49#9060=(GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#9059))GLOBAL_UNIT_ASSIGNED_CONTEXT((#9056,#9057,#9058))REPRESENTATION_CONTEXT('','3D')); 50#9061=MANIFOLD_SURFACE_SHAPE_REPRESENTATION('',(#29),#9060); 51#9062=SHAPE_DEFINITION_REPRESENTATION(#9055,#9061); 52ENDSEC; 53END-ISO-10303-21;