step-examples/12-3b-wires/Twi281.stp
Sources
- openNURBS validity ontology (`ON_BrepLoop` loop-type `ptonsrf` / singular loop
- `ON_Brep::IsValidTopology` loop-type checks). B4 wave-12 repair-code mining (LGPL-clean — pattern only, no upstream bytes copied). openNURBS constrains a point-loop (a loop that collapses to a single vertex) to occur only where the underlying surface has a genuine singularity (cone apex / sphere pole)
- a point-loop as a face's boundary on a surface with no singular point is a loop-type-vs-geometry inconsistency.
Sender
BRep translator / writer that emits a face whose outer boundary is a `VERTEX_LOOP` on a non-singular surface — e.g. a healing/decomposition pass that collapsed a wire to a single vertex, or a mis-typed singular loop copied onto a planar carrier.
Description
An `ADVANCED_FACE` on a flat `PLANE` whose SOLE `FACE_OUTER_BOUND` wraps a `VERTEX_LOOP('point_loop_on_flat_plane',#v)` — a loop collapsing to a single `VERTEX_POINT` at (0,0,0). A point-loop declares "this face's boundary is a single point / the face collapses to a singular vertex", which openNURBS permits only at a genuine surface singularity; a `PLANE` has no singular point anywhere, so the loop-degeneracy flag contradicts the flat geometry. The face is transferred through an `OPEN_SHELL` / `SHELL_BASED_SURFACE_MODEL` so the malformed loop is on the live traversal path (no orphaned entities).
Reproducer recipe
`PLANE` at origin (+Z normal); `VERTEX_POINT` at (0,0,0); `VERTEX_LOOP('point_loop_on_flat_plane',#v)`; `FACE_OUTER_BOUND('',#vloop,.T.)` as the ADVANCED_FACE's only bound; `ADVANCED_FACE` on the plane; `OPEN_SHELL` + `SHELL_BASED_SURFACE_MODEL`.
Expected kernel behavior
Reject or heal loudly — a `ptonsrf`/singular loop is only well-formed at a surface singularity; on a non-singular surface the face has no bounded area and should be dropped with a diagnostic, or the point-loop coerced to a proper wire. Silently building a zero-area face masks the inconsistency.
Notes
openNURBS validity ontology (`ON_BrepLoop` type `ptonsrf` / singular). B4 wave-12 repair-code mining. Confidence: MEDIUM — accept-live-oracle. Distinct from **Twi041 / Pf025** (`VERTEX_LOOP` as an INNER `FACE_BOUND` alongside a real outer bound — here it is the SOLE / OUTER bound) and from the Tfe writer-drop sphere-cap `VERTEX_LOOP` cluster (a `SPHERICAL_SURFACE` HAS pole singularities; a `PLANE` has none). Live oracle: OCCT builds a face on the plane bounded only by the degenerate vertex loop — `shape(1)` but with n_edges_total==0 / n_vertices_total==0 (a clean planar quad face carries 4 edges) and an empty mesh; gmsh yields `shape(1)` where a clean planar quad meshes to `shape(9)` — the distinguishable signal. Synonyms: "point-loop outer bound on flat plane", "VERTEX_LOOP as sole face boundary non-singular surface", "singular loop type on plane", "face collapses to point on plane", "ptonsrf loop off singularity".
Expected validation
occt=shape(1)/shape(1) gmsh=shape(1) ifc=schema_n/a
Byte assertions
contains(b'VERTEX_LOOP(')contains(b'point_loop_on_flat_plane')contains(b'PLANE(')
Tier-3 assertions
shape_null == Falsen_faces_total == 1n_edges_total == 0n_vertices_total == 0face[0].surface_type == "plane"
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/* Twi281: VERTEX_LOOP 'point_loop_on_flat_plane' wrapping a single VERTEX_POINT at (0,0,0) used as the SOLE FACE_OUTER_BOUND of an ADVANCED_FACE on a flat PLANE; a point-loop (openNURBS ON_BrepLoop ptonsrf / singular loop type) is only valid at a genuine surface singularity (cone apex / sphere pole) â a PLANE has none; loop-degeneracy flag contradicts the flat surface geometry; face IS transferred via SHELL_BASED_SURFACE_MODEL â no orphaned entities */ 3HEADER; 4FILE_DESCRIPTION(('Twi281'),'2;1'); 5FILE_NAME('Twi281.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,0.0,0.0)); 16#7=VERTEX_POINT('',#6); 17#8=VERTEX_LOOP('point_loop_on_flat_plane',#7); 18#9=FACE_OUTER_BOUND('',#8,.T.); 19#10=ADVANCED_FACE('',(#9),#5,.T.); 20#11=OPEN_SHELL('',(#10)); 21#12=SHELL_BASED_SURFACE_MODEL('',(#11)); 22#9050=PRODUCT_CONTEXT('',#9000,'mechanical'); 23#9051=PRODUCT('Twi281','Twi281','',(#9050)); 24#9052=PRODUCT_DEFINITION_FORMATION('','',#9051); 25#9053=PRODUCT_DEFINITION_CONTEXT('part definition',#9000,'design'); 26#9054=PRODUCT_DEFINITION('','','',#9052,#9053); 27#9055=PRODUCT_DEFINITION_SHAPE('','','',#9054); 28#9056=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 29#9057=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 30#9058=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 31#9059=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-7),#9056,'distance_accuracy_value',''); 32#9060=(GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#9059))GLOBAL_UNIT_ASSIGNED_CONTEXT((#9056,#9057,#9058))REPRESENTATION_CONTEXT('','3D')); 33#9061=MANIFOLD_SURFACE_SHAPE_REPRESENTATION('',(#12),#9060); 34#9062=SHAPE_DEFINITION_REPRESENTATION(#9055,#9061); 35ENDSEC; 36END-ISO-10303-21;