tomli2008 发表于 2008-2-1 11:54:20

flags(i,j)是什么意思,请教高手

def relax_ini
   nstart = step;步数
   nstop = nstart + ninc;步数+1000
end
def relax_hist
   if step < nstop;当前步数小于停止步数时
      step_inc = float(step - nstart);当前-开始
      relax_hist = rstart - ((rstart - rstop)/ float(ninc)) * step_inc;
   else
      relax_hist = rstop
   endif
end
def apply_rf
   loop ii (ib_ap,ie_ap);10,17
      loop jj (jb_ap,je_ap);34,52
         if and(flags(ii,jj), 2) = 2 then
            if and(flags(ii,jj), 4) = 4 then
            xftmp = -xforce(ii,jj)
            yftmp = -yforce(ii,jj)
            command
                apply xforce=xftmp hist relax_hist i=ii j=jj
                apply yforce=yftmp hist relax_hist i=ii j=jj
            end_command
            endif
         endif
      endloop
   endloop
end
def relax_tractions
   relax_ini
   relax_hist
   apply_rf
end

cpb1986 发表于 2009-8-8 10:36:10

个人觉得应该是判断该单元是否为null单元!当为null单元,则其值为0
页: [1]
查看完整版本: flags(i,j)是什么意思,请教高手