step-examples/12-8-mixed/M186.stp
Sources
- 16-iso-spec ISO 10303-238 §5.8 coolant_operation material-compatibility safety rule
- OSHA/NFPA shop-safety guidance
- bug-reporter language: "AP238 water on magnesium", "STEP-NC unsafe coolant", "coolant type wrong for material".
Description
A `COOLANT_OPERATION` declares coolant type WATER on a workpiece whose material is declared as MAGNESIUM. Water on burning magnesium accelerates the fire (hydrogen liberation); shop safety codes prohibit this combination. Bug-reporter language: "AP238 coolant unsafe for material", "STEP-NC water on Mg", "coolant material incompatibility".
Reproducer recipe
a `WORKPIECE` with `MATERIAL('AZ31_magnesium', ..)`; a `COOLANT_OPERATION` with mode `.WATER.` targeting that workpiece.
Expected kernel behavior
cross-check coolant type against workpiece material; reject incompatible safety-critical combinations.
Notes
Synonyms: "AP238 unsafe coolant choice", "STEP-NC water on magnesium", "coolant-material safety violation", "incompatible coolant type".
Expected validation
occt=empty/empty gmsh=empty ifc=schema_n/a
Byte assertions
contains(b'AP238_STEP_NC_MIM')contains(b'COOLANT_OPERATION')contains(b'magnesium')
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/* M186: AP238 coolant type WATER incompatible with MAGNESIUM workpiece material */ 3/* DEFECT: COOLANT_OPERATION declares mode .WATER. on AZ31 magnesium workpiece */ 4/* Water on burning magnesium liberates hydrogen gas â explosion/fire risk */ 5/* OSHA/NFPA shop-safety guidance prohibits water coolant on magnesium */ 6/* Per ISO 10303-238 §5.8 coolant_operation material-compatibility safety rule */ 7/* Byte assertion: contains(b'AP238_STEP_NC_MIM') */ 8/* Byte assertion: contains(b'COOLANT_OPERATION') */ 9/* Byte assertion: contains(b'magnesium') */ 10HEADER; 11FILE_DESCRIPTION(('M186: AP238 COOLANT_OPERATION WATER mode on AZ31 magnesium workpiece'),'2;1'); 12FILE_NAME('M186.stp','2026-06-21T00:00:00',(''),(''),'cad-research-suite','',''); 13/* Byte assertion: contains(b'AP238_STEP_NC_MIM') */ 14FILE_SCHEMA(('AP238_STEP_NC_MIM { 1 0 10303 238 3 1 1 1 }')); 15ENDSEC; 16DATA; 17/* Standard unit context (mm) */ 18#10=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 19#11=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 20#12=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 21#13=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(0.001),#10, 22 'distance_accuracy_value','maximum model space distance between geometric entities'); 23#14=(GEOMETRIC_REPRESENTATION_CONTEXT(3) 24 GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#13)) 25 GLOBAL_UNIT_ASSIGNED_CONTEXT((#10,#11,#12)) 26 REPRESENTATION_CONTEXT('ctx','3D')); 27/* mm length unit reference for MEASURE_WITH_UNIT */ 28#15=SI_UNIT(.MILLI.,.METRE.); 29/* GEOMETRIC_CURVE_SET IS the model entity â OCC yields empty */ 30#20=GEOMETRIC_CURVE_SET('ap238-coolant-water-on-magnesium-workpiece', 31 (#30,#40,#50,#60)); 32/* MATERIAL 'AZ31_magnesium': magnesium alloy â reacts violently with water when ignited */ 33/* Byte assertion: contains(b'magnesium') */ 34#30=MATERIAL('AZ31_magnesium','AZ31B magnesium alloy workpiece material',$); 35/* WORKPIECE 'magnesium_block': made of AZ31 magnesium alloy */ 36#40=WORKPIECE('magnesium_block','AZ31 magnesium alloy block',$,#30,$,$,$); 37/* Byte assertion: contains(b'COOLANT_OPERATION') */ 38/* DEFECT: COOLANT_OPERATION 'water_coolant_op' uses .WATER. mode on Mg workpiece */ 39/* Water on burning magnesium: hydrogen liberation + fire acceleration */ 40#50=COOLANT_OPERATION('water_coolant_op',.WATER.,$,#40,$); 41/* MACHINING_WORKINGSTEP 'coolant_step' */ 42#60=MACHINING_WORKINGSTEP('coolant_step','Water coolant on magnesium step',#50,#40,$); 43/* WORKPLAN: unsafe coolant operation on magnesium workpiece */ 44#70=WORKPLAN('unsafe_coolant_program','Unsafe water coolant on Mg workplan',(),$,(#60)); 45/* Product chain */ 46#100=APPLICATION_CONTEXT('mechanical design'); 47#101=PRODUCT_CONTEXT('',#100,'mechanical'); 48#102=PRODUCT('M186','M186','M186',(#101)); 49#103=PRODUCT_DEFINITION_FORMATION('','',#102); 50#104=PRODUCT_DEFINITION_CONTEXT(#100,'design'); 51#105=PRODUCT_DEFINITION('','',#103,#104); 52#106=PRODUCT_DEFINITION_SHAPE('','',#105); 53#107=SHAPE_REPRESENTATION('',(#20),#14); 54#108=SHAPE_DEFINITION_REPRESENTATION(#106,#107); 55ENDSEC; 56END-ISO-10303-21;