step-examples/12-8-mixed/M179.stp
Sources
- 16-iso-spec ISO 10303-238 §5.8 touch_probing measurement-resolution invariant
- bug-reporter language: "AP238 probe tolerance below stylus", "STEP-NC inspection unattainable resolution", "touch probe can't resolve sub-radius features".
Description
A `TOUCH_PROBING` op declares a measurement tolerance of 0.005 mm while the touch probe's stylus tip ball diameter is 4.0 mm (radius 2.0 mm). The stylus radius compensation cannot resolve features below the tip radius - the declared tolerance is fundamentally unattainable with this probe. Bug-reporter language: "AP238 probe tolerance < stylus radius", "STEP-NC inspection resolution impossible", "touch probe tip too big".
Reproducer recipe
a `TOUCH_PROBE` with stylus diameter 4.0 mm; a `TOUCH_PROBING` op with tolerance 0.005 mm referencing that probe.
Expected kernel behavior
validate measurement tolerance against probe stylus radius; reject as unattainable or warn.
Notes
Synonyms: "AP238 probe tolerance below stylus", "STEP-NC touch probe over-spec'd", "inspection resolution exceeds probe capability", "stylus diameter exceeds tolerance".
Expected validation
occt=empty/empty gmsh=empty ifc=schema_n/a
Byte assertions
contains(b'AP238_STEP_NC_MIM')contains(b'TOUCH_PROBING(')contains(b'TOUCH_PROBE(')
Tier-3 assertions
shape_null == True
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes (with defect highlighting)
1ISO-10303-21; 2/* M179: AP238 touch_probing tolerance smaller than probe stylus radius */ 3/* DEFECT: TOUCH_PROBING tolerance 0.005 mm; TOUCH_PROBE stylus diameter 4.0 mm */ 4/* Stylus radius 2.0 mm is 400x larger than declared tolerance 0.005 mm */ 5/* Stylus radius compensation cannot resolve features below tip radius */ 6/* Declared tolerance is fundamentally unattainable with this probe tip */ 7/* Per ISO 10303-238 §5.8 tolerance must be achievable with probe stylus radius */ 8/* Byte assertion: contains(b'AP238_STEP_NC_MIM') */ 9/* Byte assertion: contains(b'TOUCH_PROBING(') */ 10/* Byte assertion: contains(b'TOUCH_PROBE(') */ 11HEADER; 12FILE_DESCRIPTION(('M179: AP238 touch_probing tolerance 0.005mm < stylus radius 2.0mm'),'2;1'); 13FILE_NAME('M179.stp','2026-06-21T00:00:00',(''),(''),'cad-research-suite','',''); 14/* Byte assertion: contains(b'AP238_STEP_NC_MIM') */ 15FILE_SCHEMA(('AP238_STEP_NC_MIM { 1 0 10303 238 3 1 1 1 }')); 16ENDSEC; 17DATA; 18/* Standard unit context (mm) */ 19#10=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 20#11=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 21#12=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 22#13=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(0.001),#10, 23 'distance_accuracy_value','maximum model space distance between geometric entities'); 24#14=(GEOMETRIC_REPRESENTATION_CONTEXT(3) 25 GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#13)) 26 GLOBAL_UNIT_ASSIGNED_CONTEXT((#10,#11,#12)) 27 REPRESENTATION_CONTEXT('ctx','3D')); 28/* mm length unit reference for MEASURE_WITH_UNIT */ 29#15=SI_UNIT(.MILLI.,.METRE.); 30/* GEOMETRIC_CURVE_SET IS the model entity â OCC yields empty */ 31#20=GEOMETRIC_CURVE_SET('ap238-touch-probing-tolerance-below-stylus-radius', 32 (#40,#52,#60)); 33/* Byte assertion: contains(b'TOUCH_PROBE(') */ 34/* TOUCH_PROBE 'big_stylus_probe': stylus_diameter 4.0 mm (radius 2.0 mm) */ 35#41=MEASURE_WITH_UNIT(POSITIVE_LENGTH_MEASURE(4.0),#15); 36#40=TOUCH_PROBE('big_stylus_probe',$,#41,$,$,$); 37/* DEFECT: tolerance 0.005 mm << stylus radius 2.0 mm â unattainable resolution */ 38#42=MEASURE_WITH_UNIT(POSITIVE_LENGTH_MEASURE(0.005),#15); 39/* Byte assertion: contains(b'TOUCH_PROBING(') */ 40/* DEFECT: TOUCH_PROBING tolerance 0.005 mm with stylus diameter 4.0 mm probe */ 41#52=TOUCH_PROBING('overspec_probe_op',$,#40,#42,$,$); 42/* WORKPIECE 'probe_workpiece' */ 43#60=WORKPIECE('probe_workpiece','Workpiece for touch-probe tolerance test',$,$,$,$,$); 44/* MACHINING_WORKINGSTEP 'overspec_probe_step' links probing op to workpiece */ 45#51=MACHINING_WORKINGSTEP('overspec_probe_step','Overspec probe workingstep',#52,#60,$); 46/* WORKPLAN: single touch-probing step with unattainable tolerance */ 47#50=WORKPLAN('overspec_probe_program','Overspec touch probe workplan',(),$,(#51)); 48/* Product chain */ 49#100=APPLICATION_CONTEXT('mechanical design'); 50#101=PRODUCT_CONTEXT('',#100,'mechanical'); 51#102=PRODUCT('M179','M179','M179',(#101)); 52#103=PRODUCT_DEFINITION_FORMATION('','',#102); 53#104=PRODUCT_DEFINITION_CONTEXT(#100,'design'); 54#105=PRODUCT_DEFINITION('','',#103,#104); 55#106=PRODUCT_DEFINITION_SHAPE('','',#105); 56#107=SHAPE_REPRESENTATION('',(#20),#14); 57#108=SHAPE_DEFINITION_REPRESENTATION(#106,#107); 58ENDSEC; 59END-ISO-10303-21;