Example 5#
%pip install sympy==1.12.1
# This is a workaround for the fact that micropip does not support git URLs, to make it work in the online book.
import micropip
await micropip.install('../packages/sympy-1.12.1-py3-none-any.whl')
#takes a while
%matplotlib inline
import sympy as sm
from sympy.physics.continuum_mechanics.beam import Beam
import matplotlib.pyplot as plt
E = sm.Symbol('E')
I = sm.Symbol('I')
b = Beam(10, E, I)
b.apply_support(0, type="pin")
b.apply_support(10, type="pin")
R_0, R_10 = sm.symbols('R_0, R_10')
b.solve_for_ild_reactions(-1, R_0, R_10)
b.ild_reactions
{R_0: 1 - x/10, R_10: x/10}
b.plot_ild_reactions();
