动力分析入门:一个简单的动力分析模型
数据文件:new
conf dyn ;ext 5
grid 1 1 50
gen zone copy 15 0 0;建立两个完全相同的模型
mod elas
prop shear 1e7 bulk 2e7 dens 1000 ;为了得到剪切波速100,所以shear=1e7,dens=1000(因为:Cs=sqrt(shear/dens)
def wave
if dytime > 1.0/freq
wave = 0.0
else
wave = 0.5 * (1.0 - cos(2.0*pi*freq*dytime))
endif
end
def dyn_time
array vec(3)
vec(1) = 18.0
vec(2) = 0.0
vec(3) = 5.0
oo = set_fontsize(1.5) ;设置字体大小
oo = draw_string(vec,'Time') ;添加‘Time’
vec(3) = 0.0
oo = draw_string(vec,string(dytime))
vec(3) = 45.0
oo = set_fontsize(1.0)
oo = draw_string(vec,'stress')
vec(1) = 3.0
oo = draw_string(vec,'vel.')
end;给图形添加标示
;
set freq=4.0 dyn dt=2e-4;设置dt=2e-4,表示每cyc 1 个时步,实际时间为2e-4秒
fix z y range z .5 100
apply xvel 1.0 hist wave yvel 0 zvel 0 range z -.1 .1 ;给模型底部施加剪力波
his gp xvel 0 0 0
his gp xvel 0 0 25
his gp xvel 0 0 50 ;记录模型底、中、顶部的波速
his dytime ;记录实际时间
plo crea qqq
plo add surf red
plo add vel max 0.5 range x -1 2 ;左边的模型显示剪力波
plo add bcon sxz int 1e4 max 1e5 range x 5 18 ; 右边的模型同步显示剪力
plo add fish dyn_time black ;添加fish函数dyn_time设置的标示
plo set per off
plo sho
solve age 2.0 ;算2秒