Refine beam section figure and derive As from bars

- Derive As from the provided longitudinal bars instead of taking it as
  input; drop the redundant As_bars output and update tests.
- Draw a fixed schematic 1 in cover and pin the bottom bars to the
  stirrup's bottom leg so the figure no longer depends on cover or d.
- Fixed stirrup stroke with a rounded 3 pt corner radius.
- Right-align the figure, constrain its caption to the image width, and
  shorten the caption to "Beam cross-section".
- Document input.yaml fields.
This commit is contained in:
smillmorel 2026-09-21 19:16:57 -04:00
commit 759d5e3bae
8 changed files with 638 additions and 680 deletions

View file

@ -1,35 +1,28 @@
// Generated by beam_section.py from input.yaml - do not edit by hand.
#let beam-section() = {
box(width: 302pt, height: 246pt)[
#place(dx: 80pt, dy: 34pt, rect(width: 112pt, height: 168pt, fill: rgb("#f2f2f2"), stroke: 1pt + black))
#place(dx: 103.6pt, dy: 57.62pt, rect(width: 64.75pt, height: 120.8pt, radius: 1.5pt, stroke: 5.25pt + black))
#place(dx: 106.2pt, dy: 162.6pt, circle(radius: 4.375pt, fill: black))
#place(dx: 157pt, dy: 162.6pt, circle(radius: 4.375pt, fill: black))
#place(dx: 106.2pt, dy: 60.25pt, circle(radius: 3.5pt, fill: black))
#place(dx: 158.8pt, dy: 60.25pt, circle(radius: 3.5pt, fill: black))
#place(line(start: (80pt, 218pt), end: (192pt, 218pt), stroke: 0.6pt + black))
#place(line(start: (80pt, 214pt), end: (80pt, 222pt), stroke: 0.6pt + black))
#place(line(start: (192pt, 214pt), end: (192pt, 222pt), stroke: 0.6pt + black))
#place(dx: 80pt, dy: 221pt, box(width: 112pt, align(center)[$b_w = 8 " in"$]))
#place(line(start: (68pt, 34pt), end: (68pt, 202pt), stroke: 0.6pt + black))
#place(line(start: (64pt, 34pt), end: (72pt, 34pt), stroke: 0.6pt + black))
#place(line(start: (64pt, 202pt), end: (72pt, 202pt), stroke: 0.6pt + black))
#place(dx: 2pt, dy: 113pt, text(size: 8pt)[$h = 12 " in"$])
#place(line(start: (50pt, 34pt), end: (50pt, 167pt), stroke: 0.6pt + black))
#place(line(start: (46pt, 34pt), end: (54pt, 34pt), stroke: 0.6pt + black))
#place(line(start: (46pt, 167pt), end: (54pt, 167pt), stroke: 0.6pt + black))
#place(dx: 2pt, dy: 95.5pt, text(size: 8pt)[$d = 9.5 " in"$])
#place(line(start: (162.2pt, 63.75pt), end: (204pt, 52pt), stroke: 0.5pt + rgb("#626b73")))
#place(dx: 160.8pt, dy: 62.25pt, circle(radius: 1.5pt, fill: black))
#place(dx: 208pt, dy: 46pt, text(size: 7.5pt)[2 No. 4 hanger \ bars])
#place(line(start: (168.4pt, 118pt), end: (204pt, 114pt), stroke: 0.5pt + rgb("#626b73")))
#place(dx: 166.9pt, dy: 116.5pt, circle(radius: 1.5pt, fill: black))
#place(dx: 208pt, dy: 108pt, text(size: 7.5pt)[No. 3 stirrup \ at 6 in o.c.])
#place(line(start: (161.4pt, 167pt), end: (204pt, 184pt), stroke: 0.5pt + rgb("#626b73")))
#place(dx: 159.9pt, dy: 165.5pt, circle(radius: 1.5pt, fill: black))
#place(dx: 208pt, dy: 178pt, text(size: 7.5pt)[2 No. 5 bottom \ $A_s = 0.62 " in"^2$])
#place(line(start: (103.6pt, 178.4pt), end: (40pt, 228pt), stroke: 0.5pt + rgb("#626b73")))
#place(dx: 102.1pt, dy: 176.9pt, circle(radius: 1.5pt, fill: black))
#place(dx: 2pt, dy: 232pt, text(size: 7.5pt)[cover = 1.5 in])
box(width: 180pt, height: 180pt)[
#place(dx: 48pt, dy: 28pt, rect(width: 76pt, height: 114pt, fill: rgb("#f2f2f2"), stroke: 1pt + black))
#place(dx: 58.5pt, dy: 38.5pt, rect(width: 55pt, height: 93pt, radius: 3pt, stroke: 2pt + black))
#place(dx: 59.5pt, dy: 124.6pt, circle(radius: 2.969pt, fill: black))
#place(dx: 106.6pt, dy: 124.6pt, circle(radius: 2.969pt, fill: black))
#place(dx: 59.5pt, dy: 39.5pt, circle(radius: 2.375pt, fill: black))
#place(dx: 107.8pt, dy: 39.5pt, circle(radius: 2.375pt, fill: black))
#place(line(start: (48pt, 158pt), end: (124pt, 158pt), stroke: 0.6pt + black))
#place(line(start: (48pt, 155pt), end: (48pt, 161pt), stroke: 0.6pt + black))
#place(line(start: (124pt, 155pt), end: (124pt, 161pt), stroke: 0.6pt + black))
#place(dx: 48pt, dy: 161pt, box(width: 76pt, align(center, text(size: 7pt)[$b_w = 8 " in"$])))
#place(line(start: (42pt, 28pt), end: (42pt, 142pt), stroke: 0.6pt + black))
#place(line(start: (39pt, 28pt), end: (45pt, 28pt), stroke: 0.6pt + black))
#place(line(start: (39pt, 142pt), end: (45pt, 142pt), stroke: 0.6pt + black))
#place(dx: 0.5pt, dy: 82pt, text(size: 7pt)[$h = 12 " in"$])
#place(line(start: (110.1pt, 41.88pt), end: (129pt, 42pt), stroke: 0.5pt + rgb("#626b73")))
#place(dx: 108.6pt, dy: 40.38pt, circle(radius: 1.5pt, fill: black))
#place(dx: 132pt, dy: 37pt, text(size: 7pt)[2 No. 4 hanger \ bars])
#place(line(start: (113.5pt, 85pt), end: (129pt, 82pt), stroke: 0.5pt + rgb("#626b73")))
#place(dx: 112pt, dy: 83.5pt, circle(radius: 1.5pt, fill: black))
#place(dx: 132pt, dy: 77pt, text(size: 7pt)[No. 3 stirrup \ at 6 in o.c.])
#place(line(start: (109.5pt, 127.5pt), end: (129pt, 128pt), stroke: 0.5pt + rgb("#626b73")))
#place(dx: 108pt, dy: 126pt, circle(radius: 1.5pt, fill: black))
#place(dx: 132pt, dy: 123pt, text(size: 7pt)[2 No. 5 bottom \ $A_s = 0.6136 " in"^2$])
]
}