單向流固耦合——模擬彎曲河床砂石運移

0 引言

    要完成這個工況的模擬,其實需要解決兩個難點,第一個是如何生成河床。這里假設河床截面是圓形的,那其實是需要一個pipe形狀的三維體,但是這個在PFC中是沒有提供的。第二個難點就是河流流場的生成了。

1 生成河床

    這里我們使用的是以直代曲的辦法,可以用一個個圓柱拼接成河床的額樣子。createwall 函數中就是使用循環生成河床的墻體,R_he 為河床截面中心的弧長半徑,jing_he 為河床截面的圓形半徑,he_kua 為河床跨過的圓心角。wallsplit是我們河床墻體的分段,也不是說分的越細結果越好的。

    ball_range 我們定義了河床砂石的生成區域,也是一個圓柱形區域,用的是generate生成后自重沉降的方式。

new domain extent 0 20 -20 20 -4 4

[wallsplit=50][R_he=16][jing_he=2]

[he_kua=math.pi*1.0/3.0]def createwall jiaodu_split=he_kua/float(wallsplit) loop n(1,wallsplit) jiaodu1=-he_kua*0.5+jiaodu_split*(n-1) jiaodu2=-he_kua*0.5+jiaodu_split*(n) x_pos1=math.cos(jiaodu1)*R_he y_pos1=math.sin(jiaodu1)*R_he x_pos2=math.cos(jiaodu2)*R_he y_pos2=math.sin(jiaodu2)*R_he vec=math.unit(vector(x_pos2-x_pos1,y_pos2-y_pos1,0)) height=(R_he+jing_he)*jiaodu_split command wall generate cylinder base @x_pos1 @y_pos1 0 axis @vec height @height radius @jing_he ... cap false false resolution 0.5 endcommand endloopend@createwall wall delete range z 0 20 extent

def ball_range jiaodu1=-he_kua*0.5+jiaodu_split*6 jiaodu2=-he_kua*0.5+jiaodu_split*7 x_pos1=math.cos(jiaodu1)*R_he y_pos1=math.sin(jiaodu1)*R_he x_pos2=math.cos(jiaodu2)*R_he y_pos2=math.sin(jiaodu2)*R_he vec=math.unit(vector(x_pos2-x_pos1,y_pos2-y_pos1,0)) height=(R_he+jing_he)*jiaodu_split*8 command geometry set ballrange geometry generate cylinder base @x_pos1 @y_pos1 0 axis @vec height @height radius [jing_he*0.8] endcommandend@ball_range

cmat default model rrlinear method deformability emod 100e6 kratio 1.5 property fric 0.5

ball generate radius 0.03 0.09 number 2000 tries 20000000 range geometry ballrange count 1ball attribute density 2.7e3 damp 0.7 set gravity 9.8 solvesave sample

生成后如圖:

單向流固耦合——模擬彎曲河床砂石運移的圖1

2 流場生成

    這里使用我們之前的小程序 PFC單向流固耦合——模擬顆粒落入流動的水中 生成流體網格。

參數為:

單向流固耦合——模擬彎曲河床砂石運移的圖2

記得將其放置到項目文件下。

    導入網格后我們需要對流場進行設置,這里我們假設流速是均勻的,實際上的河床截面上的流速是上大下小的應該。因為我們河床圓弧的中心在原點,所以我們直接根據流體網格的位置取切向作為流速方向即可。


restore sampleconfigure cfdball attribute displacement multiply 0cfd read nodes Node.datcfd read elements Elem.datcfd buoyancy on

[sudu=5]def addliusu loop foreach local ele element.cfd.list vec=math.unit(vector(element.cfd.pos.y(ele),(-1)*element.cfd.pos.x(ele),0)) element.cfd.vel(ele)=(-1)*vec*sudu endloop end@addliusuelement cfd attribute density 1000.0element cfd attribute viscosity 1.5

set mech age 0[baocunpinlv=0.1][time_record=mech.age-1][count=0]def savefile if mech.age-time_record >= baocunpinlv then filename=string.build("jieguo%1",count) command save @filename endcommand time_record=mech.age count +=1 endif endset fish callback -1.0 @savefilesolve time 10

生成后的結果如圖,保證模型元素都在流場中即可:

單向流固耦合——模擬彎曲河床砂石運移的圖3

3 結果展示

    這里就不會結果進行分析了,按理說這種弧形的河道會發生砂石顆粒的離析,這種規律是和粒徑有關系的,可以統計粒徑隨著徑向的分布應該是可以得到一些比較好的結果的。

    這里提供兩個動圖給大家:

單向流固耦合——模擬彎曲河床砂石運移的圖4

單向流固耦合——模擬彎曲河床砂石運移的圖5

登錄后免費查看全文
立即登錄
App下載
技術鄰APP
工程師必備
  • 項目客服
  • 培訓客服
  • 平臺客服

TOP

6
2
3