Skip to content

feat(ifc): a beam whose type is a rectangular tube is drawn as that tube, corners as arcs, and gets the six base quantities its profile gives (#1698) - #2034

Merged
DrunkOnJava merged 7 commits into
mainfrom
feat/1698-tube-beams
Nov 15, 2026
Merged

DrunkOnJava merged 7 commits into
mainfrom
feat/1698-tube-beams

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Nov 15, 2026 •

Copy link
Copy Markdown
Owner

Summary

A structural framing element whose type is a rectangular tube is drawn as that tube, its corners as arcs, and gets the six base quantities the profile gives. On Revit 2024 only, which is the one release the BIM4LCA office's 8 tube beams (Putkipalkki - suorakaide:PA-1) are measured on. Part of #1698.

Motivation

#1698: rvt-rs drew the office's 8 hollow tube beams as a solid box, 0.3411 m3 where Revit's tube is 0.0221 m3, and left their six base quantities out (the saved mesh gives them only to 1.1e-4 to 4.4e-4, outside the census's 1e-5, because the tube's rounded corners are chords in it; #1759). The comment on #1698 showed the profile does give them. What was open was where the profile is in the file.

Found (Measure 43663617767, probe_1698_beam_type_lengths): the tube type holds its profile as named lengths, bf 200 mm, d 300 mm, tf and tw 4 mm, ri 8 mm and ra 4 mm, on both office files. ri is the OUTSIDE corner radius and ra the inside one, the reverse of what the letters suggest. The columns' hollow sections use b, Ht, t and kr, so hollow_section finds nothing here.

Revit's form (Measure 43665396874, tools/re/beam_tubes_in_ifc.py): each of the 8 is an IfcExtrudedAreaSolid over an IfcArbitraryProfileDefWithVoids, one signature for all 8: an outer IfcIndexedPolyCurve of 12 points (four arcs, four lines), one void of 12 points, depth 5,685 mm equal to the Length quantity on each, the extrusion running along the beam's local X from -L/2, the profile's X across the beam and Y vertical.

Changes

  • src/research/partition_type_parameters.rs: TUBE_BEAM_PARAMETER_NAMES and tube_beam_section, which reads the six captions as a hollow section only when tf equals tw and the inside radius is the outside radius less the wall.
  • src/research/partition_schema_mvp/fields.rs, framing.rs: TUBE_BEAM_REVIT_VERSIONS (2024) and attach_column_sections giving structural framing the same four hollow-section fields a column gets, from the same read.
  • src/ifc/export_content.rs: beam_tube_solid (the beam's I-section solid with the tube's profile), the body chosen where the beam's body along its line is as wide and as deep as the tube's outside, SectionShape RectangleHollow and SectionWallThickness beside the record's other properties, and add_tube_beam_quantities: CrossSectionArea the profile's area, OuterSurfaceArea the outside outline times the length, GrossSurfaceArea that plus the two ends, NetSurfaceArea both outlines times the length plus the two ends, GrossVolume and NetVolume the area times the length, the arcs counted as arcs.
  • src/ifc/element_provenance.rs: the tube's source has its own reader, type_tube_section (six captions), listed as a profile reader and for a beam with that SectionShape, as an I section's is. tests/value_sources_offsets.rs holds it to its six captions and pins it on the office as built; its first form, sharing type_hollow_section, failed that check on the office.
  • tools/re/beam_tubes_in_ifc.py: the scorer above. changelog.d/changed/1698-tube-beams.md, reports/element-framing/RE-470-tube-beam-sections.md, and the docs above.

The BodySource stays partition_beam_axis, so the storey binding, the same-project gates' beam minimums and the saved-mesh pass are as they were.

Testing

Measure 43667655898, unfiltered against the merge base 63d06f42, with samples, nordic, r2025 and holdout; and 43667663717, the two office files with beam_tubes_in_ifc, beam_quantities_vs_ifc, qtos_vs_ifc, psets_vs_ifc and column_bodies_vs_ifc, keep_ifc, both on head 36664995 (the heads since add RE-470, docs and a merge of main). Rows registered before either was read, and what they read:

  1. Not met as registered; the body is Revit's within the writer's digits. The 8 tube beams of each office file are an IfcExtrudedAreaSolid over IfcArbitraryProfileDefWithVoids, where they were IfcRectangleProfileDef. Outer and void have Revit's 12 points, the same alternation of four lines and four arcs, the outer counter-clockwise and the void clockwise, and areas 59,925.0 and 56,045.2 mm2 against Revit's 59,925.0 and 56,045.3. But the row asked for the same indices and points equal to 1e-6 mm: rvt-rs starts its outer ring one vertex and its void ring two vertices before Revit's, and writes its points to six decimals of a metre, so after aligning the start they differ by at most 0.000146 mm (outer) and 0.000427 mm (void). The row was tighter than the writer's resolution of 1e-3 mm; these are the bounds measured. Two beams 6,000.000 mm apart in Revit's export are 6,000.000 mm apart in rvt-rs's, turned by the office's site rotation (40.33 degrees), at Revit's height.
  2. Met. The six quantities are written on the 8 and equal Revit's on both files, 48 values per file, none different, none missing; Length stays 8 of 8 equal.
  3. Met. different is 1 on both sides on both files (the one that was already there); values Revit does not write 0. In qtos_vs_ifc the equal count goes 37,509 to 37,557 (as built) and 37,882 to 37,930 (permit).
  4. Met. 118 of 120 exports are byte for byte the merge base's, the two that are not being the office files; all 102 diagnostics.json are. The Autodesk samples and the held-out models are among the 118.
  5. Met. same-project gates pass on 36664995 (15 samples held to their earlier saves); the diagnostics are identical, so no body_sources count moves.

Cost: one export of the as-built office took 21.3 s on the head and 23.7 s on the base (single runs, no difference above the noise).

Not measured: any release but 2024, any tube of another shape (the reader gives none), a tube beam turned so that its body is not as wide and deep as the tube's outside (it keeps its box). RE-470 holds all of it.

  • tools/check-local.sh: no local builds; rustfmt --check passes; CI runs the rest.

Audit-honesty checklist

  • No figure beyond the runs named; the changelog fragment, RE-470, docs/export-diagnostics.md, docs/evidence.md, docs/contribution-map.md and docs/one-project-rules.md are updated from them. The measured commit and the probe's are archived under refs/archive/2026-11-15/cited/.
  • No emojis, private paths or jargon.

Legal and contribution hygiene

  • Apache-2.0; no Autodesk source; no fixtures.

Breaking changes

None.

Part of #1698.

…profile has voids, curve by curve, beside what rvt-rs writes for it (#1698)

The BIM4LCA office's 8 hollow tube beams are an IfcExtrudedAreaSolid over an
IfcArbitraryProfileDefWithVoids in Revit's export. To write Revit's own form the
writer needs each curve's points and segment indices in Revit's order, the
extrusion's placement and direction, and how its depth relates to Length: the
scorer prints them, and counts how many beams share one signature.
…ube, corners as arcs, and gets the six base quantities its profile gives (#1698)

The BIM4LCA office's 8 hollow tube beams were a solid box (0.3411 m3 where
Revit's tube is 0.0221 m3). Their type holds the profile as the captions bf, d,
tf, tw, ri and ra (Measure run 43663617767: 200 by 300 mm, 4 mm wall, 8 mm
outside and 4 mm inside corner radius), and Revit's export draws each as an
extrusion over IfcArbitraryProfileDefWithVoids (run 43665396874). The type's
tube is read beside the columns' hollow sections, gated to Revit 2024, and the
beam is drawn as it where its body along its line is as wide and as deep as the
tube's outside. CrossSectionArea, OuterSurfaceArea, GrossSurfaceArea,
NetSurfaceArea, GrossVolume and NetVolume follow from the profile with its arcs
as arcs, which the saved mesh's chords cannot give to the census's 1e-5.
…be_section, from the six captions it is made of, and the value-sources check holds it to them (#1698)

The corpus value-sources check holds type_hollow_section to the four captions of
a column's hollow section (b, Ht, t, kr); a tube beam's type is made of six (bf,
d, tf, tw, ri, ra), so it failed on the office. The tube gets its own reader
name, listed beside the hollow and I sections as a profile reader, and the check
reads both sets of captions from the parameter elements the ids name. The office
as built is pinned to have a tube section source.
…all 8 of both office files, the ring's start vertex and digits, and nothing else moving (#1698) (RE-470)

Measure 43667663717 (scorers) and 43667655898 (unfiltered): the six base
quantities equal on 8 of 8 in both files, 118 of 120 exports and all 102
diagnostics unchanged, same-project gates pass. The registered row for the
profile's points (1e-6 mm, same indices) is not met and the report says so.
@DrunkOnJava
DrunkOnJava marked this pull request as ready for review November 15, 2026 03:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant