# How Bridges Work 2, Exercise 1: a timber joist, flat or on edge # A simply supported timber beam spans 4 m and carries a uniform load # of 6 kN/m (its own weight included). Its section is 75 mm x 225 mm. # Find the maximum moment and shear, then the maximum bending stress # with the beam on edge (225 mm deep) and laid flat (75 mm deep). def udl_beam(w, span): """Max moment (kN m) and max shear (kN) for a uniform load w (kN/m).""" return w * span**2 / 8, w * span / 2 def rect_i(b, h): """Second moment of area of a rectangle, in mm^4.""" return b * h**3 / 12 def bend_stress(m_knm, i_mm4, y_mm): """Bending stress in MPa from a moment in kN m.""" return m_knm * 1e6 * y_mm / i_mm4 m, v = udl_beam(6, 4) print(m, v) for name, b, h in [("on edge", 75, 225), ("flat", 225, 75)]: i = rect_i(b, h) print(name, round(i), round(bend_stress(m, i, h / 2), 1)) # Output when run: # 12.0 12.0 # on edge 71191406 19.0 # flat 7910156 56.9 # # Same timber, same load. Laid flat, I is 9 times smaller (the depth is 3 # times smaller and it is cubed, with the width 3 times bigger, so 27/3 = 9), # while the distance y to the outer face is only 3 times smaller. Stress is # M * y / I, so it comes out 9/3 = 3 times higher (56.9 against 19.0 MPa). # Always lay a joist on edge.