PFC利用UDTensor繪制應(yīng)力十字架
當(dāng)發(fā)生大變形的時候我們往往需要知道內(nèi)部的應(yīng)力狀態(tài),這時候張量的可視化就是一個比較好的方法。
這里利用PFC中的UDTensor來顯示直剪試驗(yàn)中的應(yīng)力狀態(tài)。
直剪試驗(yàn)產(chǎn)生的位移場為:
上部的盒子右移,產(chǎn)生位移場。
我們首先需要用測量圓來記錄試樣中的數(shù)據(jù):
[meas_radius=yy*0.2]
[meas_x_chongdie=meas_radius*0.5]
[meas_y_chongdie=meas_radius*0.5]
def create_measure
x_pos=-wlx*0.5+meas_radius*1.2
y_pos=-wly*0.5+meas_radius
loop while x_pos+meas_radius<wlx*0.5
y_pos=-wly*0.5+meas_radius
loop while y_pos+meas_radius<wly*0.5
command
measure create position [x_pos] [y_pos] radius [meas_radius]
endcommand
y_pos+=2*meas_radius-meas_y_chongdie
endloop
x_pos+=2*meas_radius-meas_x_chongdie
endloop
end
@create_measure
測量圓分布如圖:
這里沒有完全分布滿,讀者可以自己再調(diào)一下參數(shù)得到一個比較滿的測量圓分布。
得到UDTensor的代碼:
def get_stress array stress(133)
count=1
loop foreach mp measure.list
tessor_stress=user.tensor.create(measure.pos.x(mp),measure.pos.y(mp))
user.tensor.value(tessor_stress)=measure.stress(mp)
stress(count)=tessor_stress
count+=1
endloop
end
@get_stress
主要是兩個要素,一個是UDTensor的位置,一個是大小。
可視化效果如圖:
工程師必備
- 項(xiàng)目客服
- 培訓(xùn)客服
- 平臺客服
TOP




















