```python
from sympy import *

half = S(1)/2

B, q, l, xi = var("B, q, l, xi")

N1 = -xi**3 + 2*xi**2 - xi
N2 = 2*xi**3 - 3*xi**2 + 1
N3 = -xi**3 + xi**2
N4 = -2*xi**3 + 3*xi**2
N5 = xi**4/24 - xi**3/12 + xi**2/24

A = Matrix([l*N1, N2, l*N3, N4, l**4/B*N5])

A4 = Matrix([l*N1, N2, l*N3, N4])
dA4 = diff(A4, xi) / l

pprint("\nDistributed Load:")
q1 = 2*q*xi
q2 = 2*q*(1 - xi)
pprint("q₁, q₂:")
pprint(q1)
pprint(q2)
fq  = integrate(q1*A4*l, (xi, 0, half))
fq += integrate(q2*A4*l, (xi, half, 1))
pprint("leads to fq / ql:")
pprint(fq/(q*l))

pprint("\nConcentrated Moment:")
pprint("M at xi=1/2")
Mxi = var("M")
fM  = - Mxi * dA4.subs(xi, half)
pprint("leads to fM / M:")
pprint(fM/M)

pprint("\nConcentrated Force:")
pprint("F at xi=1/2")
Fxi = var("F")
fF  = Fxi * A4.subs(xi, half)
pprint("leads to fF / F:")
pprint(fF/F)

# Distributed Load:
# q₁, q₂:
# 2⋅q⋅ξ
# 2⋅q⋅(-ξ + 1)
# leads to fq / ql:
# ⎡-5⋅l ⎤
# ⎢─────⎥
# ⎢  96 ⎥
# ⎢     ⎥
# ⎢ 1/4 ⎥
# ⎢     ⎥
# ⎢ 5⋅l ⎥
# ⎢ ─── ⎥
# ⎢  96 ⎥
# ⎢     ⎥
# ⎣ 1/4 ⎦
#
# Concentrated Moment:
# M at xi=1/2
# leads to fM / M:
# ⎡-1/4⎤
# ⎢    ⎥
# ⎢ 3  ⎥
# ⎢─── ⎥
# ⎢2⋅l ⎥
# ⎢    ⎥
# ⎢-1/4⎥
# ⎢    ⎥
# ⎢-3  ⎥
# ⎢─── ⎥
# ⎣2⋅l ⎦
#
# Concentrated Force:
# F at xi=1/2
# leads to fF / F:
# ⎡-l ⎤
# ⎢───⎥
# ⎢ 8 ⎥
# ⎢   ⎥
# ⎢1/2⎥
# ⎢   ⎥
# ⎢ l ⎥
# ⎢ ─ ⎥
# ⎢ 8 ⎥
# ⎢   ⎥
# ⎣1/2⎦

```

86d582f74478c417a89f84aeb8d8928bfa3245f6
ipynb
Jupyter Notebook
ipynb/TM_A/TM_2/arbitrary-load.ipynb
kassbohm/tm-snippets
5e0621ba2470116e54643b740d1b68b9f28bff12
MIT
ipynb/TM_A/TM_2/arbitrary-load.ipynb
kassbohm/tm-snippets
5e0621ba2470116e54643b740d1b68b9f28bff12
MIT
ipynb/TM_A/TM_2/arbitrary-load.ipynb
kassbohm/tm-snippets
5e0621ba2470116e54643b740d1b68b9f28bff12
MIT
Qwen/Qwen-72B
1. YES
2. YES