PFC_lobby_边坡案例

目录

形成地基

table展示地应力分布

使用交集范围削坡


形成地基


        PFC2D5.0

new

domain extent -100 100

wall generate box -40 40 0 80 

ball distribute porosity 0.2 radius 0.5 0.8 box -39.5 39.5 0.5 44.5
ball attribute density 2e3 damp 0.7
;为了防止颗粒溢出,需要把边界适量调小

cmat default type ball-ball model linear property kn 1e9 ks 1e9 fric 0.5
cmat default type ball-facet model linear property kn 1e9 

cycle 2000 calm 2
;防止颗粒溢出,把calm的周期缩短

set gravity 9.8
solve

save sample

ball delete range y 40 100
;删除上部的球体

cycle 1 
solve 
;每次solve前需要用cycle 1来打破平衡状态
;运行会比较慢,如果预压的话,运行就会快很多

save diji

model cycle <calm i2 >

model calm. Calm the model. For mechanical processes, all linear and rotational velocities are set to 0.


table展示地应力分布


        测量圆table展示天然地基的地应力分布。

restore diji

def create_measure
    measure_rad=4.0
    x_pos=0
    y_incri=(40-measure_rad*2.0)/7.0
    loop n(1,8)        
        y_pos=measure_rad+(n-1)*y_incri
        command
            measure create position @x_pos @y_pos ...
                radius @measure_rad
        endcommand
    endloop
end
@create_measure
;创建多个测量圆,在循环里写一些变量,而不变量写在外面
;在fish里使用command,用@加变量名,可以在command里使用fish
;一次性生成8个测量圆


def get_stress_yy
    tb=table.create("shuxiang_stress")
    loop n(1,8)
        mp=measure.find(n)
        stress_yy=measure.stress.yy(mp)
        pos_y=40-measure.pos.y(mp)
        table(tb,stress_yy)=pos_y
    endloop
end
;table 允许自行定义x值和y值,比hist更加灵活
;mp=measure.find(n)查找指针
;table(tb,stress_yy)=pos_y ,tb表示table指针,而stress_yy表示x坐标,pos_y表示y坐标
;在plot items里打开table查看曲线
;mark里面可以改变曲线标注样式


def get_k0
    tb=table.create("k0")
    loop n(1,8)
        mp=measure.find(n)
        k0=measure.stress.xx(mp)/measure.stress.yy(mp)
        pos_y=40-measure.pos.y(mp)
        table(tb,k0)=pos_y
    endloop
end
@get_k0
;k0等于横向土压力除以竖向土压力

使用交集范围削坡


restore diji

ball attribute displacement multiply 0
;位移清零
ball delete range plane origin 20 20 dip 70 above ...
                  plane origin 20 20 dip 0 above
;这两个平面相交,然后削坡
                  
cycle 1
solve
;cycle 1 和 solve 建议搭配使用,cycle 1来打破平衡状态,solve则进行再次求解。

  • 2
    点赞
  • 8
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值