オリジナル
Youtube 仮想仕事の原理の教育に関する研究会 様
例題2:等分布荷重を受ける片持ち梁 (6:30〜9:00)
https://youtu.be/NMP0Q78Wl9Q?t=390
<目次(18:50)
https://youtu.be/NMP0Q78Wl9Q?t=1130
<フル【② 構造力学の「構造」例題】(0:00〜19:21)
https://youtu.be/NMP0Q78Wl9Q
sympyで
・ver0.2 差し替え未
・ver0.1
# ver0.1
# 例題2:等分布荷重を受ける片持ち梁 <【② 構造力学の「構造」例題】を参考にsympyで実行した。
from sympy import *
var('x,C1,C2,C3,C4,w,L,EI')
def myMujigennka(v,com):
return ( str(com)+"*("
+str((v/com).expand()) \
.replace("x**2/L**2","(x/L)**2") \
.replace("x**3/L**3","(x/L)**3") \
.replace("x**4/L**4","(x/L)**4")
+")").replace(" ","")
def myKakeruPw(v,Pw):
return Pw+"*"+str(v).replace("*"+Pw,"")
EIv4=w #;print(EIv4)
EIv3=integrate(EIv4,x)+w*L *C1 #;print(EIv3)
EIv2=integrate(EIv3,x)+w*L**2*C2 #;print(EIv2)
EIv1=integrate(EIv2,x)+w*L**3*C3 #;print(EIv1)
EIv =integrate(EIv1,x)+w*L**4*C4 #;print(EIv )
sol =solve([Eq(1/EI*EIv .subs({x:0}),0), # 幾何的境界条件
Eq(1/EI*EIv1.subs({x:0}),0),
Eq( -EIv3.subs({x:L}),0), # 力学的境界条件
Eq( -EIv2.subs({x:L}),0)
],[C1,C2,C3,C4]) # ;print(sol)
v =(1/EI*(EIv.subs({C1:sol[C1],C2:sol[C2],C3:sol[C3],C4:sol[C4]}))).factor()
print("#",myKakeruPw(myMujigennka(v,w*L**4/(24*EI)),"w"))
print("#",myKakeruPw( v .subs({x:L}) ,"w"))
print("#",myKakeruPw(diff(v,x).subs({x:L}) ,"w"))
# w*L**4/(24*EI)*(6*(x/L)**2-4*(x/L)**3+(x/L)**4)
# w*L**4/(8*EI)
# w*L**3/(6*EI)
#
rep={w:1,L:1,EI:1}
plot (diff(v,x,3).subs(rep),(x,0,1)) # (-)
plot (diff(v,x,2).subs(rep),(x,0,1)) # (-)上に凸
plotで作図
・値は、適当に1.0です。yscaleは、ylim=(,)で対応です。
sympyで(Beamで)
勉強中
https://docs.sympy.org/latest/modules/physics/continuum_mechanics/beam.html
https://docs.sympy.org/latest/modules/physics/continuum_mechanics/beam_problems.html
https://qiita.com/tags/beam
いつもの? sympyの実行環境と 参考のおすすめです。
いつもと違うおすすめです。
参考文献
>一部に等分布荷重を受ける単純支持はり
>JSME p89
>片持ちばり 2)
>構造力学公式集 表5.1 片持ちばりの公式 p128