找回密码
 注册
Simdroid-非首页
查看: 123|回复: 13

[后处理] 求平面焊接命令流解释

[复制链接]
发表于 2011-9-6 16:59:27 | 显示全部楼层 |阅读模式 来自 陕西西安
*do,j,1,4
  ddele,nelem(neorder(i),j),temp       !删除自由度约束        
*enddo
t=t+dt-2*delt
time,t
nsubst,nsub1
solve
*enddo  
不明白减2*delt是啥意思?
 楼主| 发表于 2011-9-7 09:44:21 | 显示全部楼层 来自 陕西西安
Simdroid开发平台
跪求大牛指导!
回复 不支持

使用道具 举报

发表于 2011-9-7 09:54:16 | 显示全部楼层 来自 北京
这一句是计算t这个参数的数值的。又没有上下文,怎么知道delt是什么意思。
回复 不支持

使用道具 举报

 楼主| 发表于 2011-9-7 10:06:28 | 显示全部楼层 来自 陕西西安
woomii 发表于 2011-9-7 09:54
这一句是计算t这个参数的数值的。又没有上下文,怎么知道delt是什么意思。 ...

哦 给邮箱 把程序发给你 帮我看看
回复 不支持

使用道具 举报

发表于 2011-9-7 10:10:15 | 显示全部楼层 来自 北京
就贴在这里大家一起研究下不好么?
回复 不支持

使用道具 举报

 楼主| 发表于 2011-9-7 11:10:14 | 显示全部楼层 来自 陕西西安
/prep7
/unit,si

et,1,13,4
et,2,13,4

mptemp,1,20,500,800,1200,1500                           
mpdata,ex,1,,2.09e11,1.72e11,1.33e11,0.84e11,0.45e11     
mpdata,ex,2,,2.16e11,1.78e11,1.42e11,1.04e11,0.68e11     
mpdata,ex,3,,2.12e11,1.75e11,1.39e11,1.07e11,0.83e11     

tb,bkin,1,5               
tbtemp,20,1
tbdata,1,315e6,0.209e11
tbtemp,500,2
tbdata,1,212e6,0.172e11
tbtemp,800,3
tbdata,1,153e6,0.133e11
tbtemp,1200,4
tbdata,1,93e6,0.084e11
tbtemp,1500,5
tbdata,1,33e6,0.045e11

tb,bkin,2,5               
tbtemp,20,1
tbdata,1,314e6,0.216e11
tbtemp,500,2
tbdata,1,203e6,0.178e11
tbtemp,800,3
tbdata,1,153e6,0.142e11
tbtemp,1200,4
tbdata,1,63e6,0.104e11
tbtemp,1500,5
tbdata,1,13e6,0.068e11

tb,bkin,3,5               
tbtemp,20,1
tbdata,1,330e6,0.212e11
tbtemp,500,2
tbdata,1,213e6,0.175e11
tbtemp,800,3
tbdata,1,153e6,0.139e11
tbtemp,1200,4
tbdata,1,73e6,0.107e11
tbtemp,1500,5
tbdata,1,13e6,0.083e11

mp,dens,1,7850
mp,dens,2,7770
mp,dens,3,7860

mp,alpx,1,1.23e-5
mp,alpx,2,1.38e-5
mp,alpx,3,1.48e-5

mp,nuxy,1,0.30
mp,nuxy,2,0.29
mp,nuxy,3,0.29

mp,kxx,1,33
mp,kxx,2,32
mp,kxx,3,34

mp,c,1,561
mp,c,2,683
mp,c,3,983

mp,murx,1,1            
mp,murx,2,1
mp,murx,3,1

mp,reft,1,20
mp,reft,2,1500
mp,reft,3,20

!*******************以下建立分析模型和网格*******************

*afun,deg

csys,0

width=1
height=0.3
ar=0.14*tan(30)
ex=0.01*tan(60)
df=ar+ex
cf=df/cos(60)

k,1,
k,2,width/2-0.01-ar,0,0
k,3,width/2+0.01+ar,0,0
k,4,width,0,0
k,5,width/2-0.01,height/2-0.01,0
k,6,width/2+0.01,height/2-0.01,0
k,7,width/2-0.01,height/2+0.01,0
k,8,width/2+0.01,height/2+0.01,0
k,9,0,height,0
k,10,width/2-0.01-ar,height,0
k,11,width/2+0.01+ar,height,0
k,12,width,height,0

n,1,width/2+0.01+ar,height,0                 
n,2,width,height,0                           
n,3,width/2+0.01+ar,0,0                     

larc,10,11,7,cf                              
larc,2,3,5,cf
a,1,2,5,7,10,9                              
a,10,7,5,2,3,6,8,11                        
a,3,4,12,11,8,6                             

/triad,off
/plots,info,0
/devices,vector,1

esize,0.02                                 
type,2                                      
mat,2                                      
amesh,2                                      

esize,0.03                                   
type,1                                      
mat,1                                         
amesh,1

mat,3
amesh,3

nummrg,all,,,,low                           
numcmp,all                                   
eplot

!/image,save,vmesh,jpeg
/devices,vector,1
finish

!*************************施加约束***************************

/solu

antype,4                                   
trnopt,full                                   

nsel,all

*get,minx,node,,mnloc,x                     
nsel,s,loc,x,minx                           
d,all,ux,0                                 

*get,miny,node,,mnloc,y                     
nsel,r,loc,y,miny                           
d,all,uy,0                                 

nsel,all

*get,minx,node,,mnloc,x                       
nsel,s,loc,x,minx
d,all,temp,20                                

nsel,all

*get,maxx,node,,mxloc,x                     
nsel,s,loc,x,maxx
d,all,temp,20                                

alls

!**********************************************************

nna=2

esel,all

*get,emax,elem,,num,max                     
asel,s,area,,nna                              
esla                                          


*get,nse,elem,,count                        

*dim,ne,,nse                                 
*dim,n1,,nse
*dim,n2,,nse
*dim,nex,,nse
*dim,ney,,nse
*dim,neorder,,nse

ii=0

*do,i,1,emax                                 
*if,esel(i),eq,1,then                       
  ii=ii+1                                    
  ne(ii)=i                                    
*endif
*enddo

*do,i,1,nse                                 
*get,ney(i),elem,ne(i),cent,y              
*get,nex(i),elem,ne(i),cent,x               
*enddo

d=0

*do,i,1,nse                                 
*if,ney(i),ge,height/2,then                        
  d=d+1                                    
  n2(d)=ne(i)
*endif
*enddo

c=0

*do,i,1,nse
*if,ney(i),lt,height/2,then                 
  c=c+1                                      
  n1(c)=ne(i)
*endif
*enddo

esel,none                                    

*do,i,1,d
*if,n2(i),ne,0,then                        
  esel,a,elem,,n2(i)
*endif
*enddo

eplot                                       


!*****************对焊缝区上部分的单元按质心Y坐标进行排序*******************


mine=0

*dim,ne2,,d                                 
*dim,nex2,,d
*dim,ney2,,d

*do,i1,1,d                                    

esel,u,elem,,mine                           
*get,nse2,elem,,count                     

ii=0

*do,i,1,emax
  *if,esel(i),eq,1,then
    ii=ii+1                                   
    ne2(ii)=i                                
  *endif
*enddo

*do,i,1,nse2
  *get,ney2(i),elem,ne2(i),cent,y            
  *get,nex2(i),elem,ne2(i),cent,x            
*enddo

miny=1e20                                 
minx=1e20

*do,i,1,nse2
  *if,ney2(i),lt,miny,then                  
   miny=ney2(i)
   minx=nex2(i)
   mine=ne2(i)                              
  *else
  *if,ney2(i),eq,miny,then
  *if,nex2(i),lt,minx,then
   miny=ney2(i)
   minx=nex2(i)
   mine=ne2(i)
  *endif
  *endif
  *endif
*enddo

neorder(i1)=mine                           

*enddo


!******对焊缝区下部分的单元按质心Y坐标进行排序,与其上部分的过程相类似************

maxe=0

esel,none

*do,j,1,c
*if,n1(j),ne,0,then !非零的全选
  esel,a,elem,,n1(j)
*endif
*enddo

eplot

*dim,ne1,,c
*dim,nex1,,c
*dim,ney1,,c

*do,j1,1,c

esel,u,elem,,maxe
*get,nse3,elem,,count

jj=0

*do,j,1,emax
  *if,esel(j),eq,1,then
    jj=jj+1
    ne1(jj)=j
  *endif
*enddo

*do,j,1,nse3
   *get,ney1(j),elem,ne1(j),cent,y
   *get,nex1(j),elem,ne1(j),cent,x
*enddo

maxy=-1e10
maxx=-1e10

*do,j,1,nse3
  *if,ney1(j),gt,maxy,then
     maxy=ney1(j)
     maxx=nex1(j)
     maxe=ne1(j)
  *else
  *if,ney1(j),eq,maxy,then
  *if,nex1(j),lt,maxx,then
     maxy=ney1(j)
     maxx=nex1(j)
     maxe=ne1(j)
  *endif
  *endif
  *endif
*enddo

neorder(j1+d)=maxe                                                   
*enddo

/eof

!******************************************************************

max_tem=1500                                   
delt=1e-3                                    
dt=5                                          
t=0                                             

esel,all
eplot

/auto,1                                       
/replot

*do,i,1,nse                                   
ekill,neorder(i)                           
esel,s,live                        
eplot
*enddo


alls                                          

outres,all,all                                       

ic,all,temp,20                                
kbc,1                                         

timint,0,struct                                
timint,0,mag                                 
timint,1,therm                                 

tintp,0.005,,,1,0.5,0.2                        

nsub1=2
nsub2=40

*do,i,1,nse                                    
ealive,neorder(i)                          
esel,s,live                                    
eplot
esel,all                                   

t=t+delt
time,t                                       
nsubst,1                                       

*do,j,1,4
   d,nelem(neorder(i),j),temp,max_tem           
*enddo



solve



t=t+delt
time,t
solve                                           ! 求解

*do,j,1,4
  ddele,nelem(neorder(i),j),temp               
*enddo

t=t+dt-2*delt
time,t
nsubst,nsub1
solve

*enddo                                          



t=t+50000                                      
time,t                                         
nsubst,nsub2                                    

solve                                          

finish
回复 不支持

使用道具 举报

 楼主| 发表于 2011-9-7 11:11:15 | 显示全部楼层 来自 陕西西安
t=t+dt-2*delt
不明白减2*delt是何意?
回复 不支持

使用道具 举报

 楼主| 发表于 2011-9-7 11:11:51 | 显示全部楼层 来自 陕西西安
woomii 发表于 2011-9-7 10:10
就贴在这里大家一起研究下不好么?

你看看
回复 不支持

使用道具 举报

发表于 2011-9-7 15:36:28 | 显示全部楼层 来自 北京
这个作者肯定是想在1e-3, 2e-3, 5这几个时间点计算。没有-2*delt就会在5+2e-3这个时间点计算,没什么意义。
回复 不支持

使用道具 举报

发表于 2011-9-7 15:37:48 | 显示全部楼层 来自 北京
其实没有-2*delt也没什么,不影响结果,不过整数比较讨喜,做报告的时候也比较好看。
回复 不支持

使用道具 举报

 楼主| 发表于 2011-9-9 09:14:05 | 显示全部楼层 来自 陕西西安
woomii 发表于 2011-9-7 15:37
其实没有-2*delt也没什么,不影响结果,不过整数比较讨喜,做报告的时候也比较好看。 ...

t=t+delt
time,t                                       
nsubst,1                                       
*do,j,1,4
   d,nelem(neorder(i),j),temp,max_tem           
*enddo
solve  !此步求解,求得是什么?
t=t+delt
time,t
solve   !此步求解,求得是什么?   
*do,j,1,4
  ddele,nelem(neorder(i),j),temp               
*enddo
t=t+dt-2*delt
time,t
nsubst,nsub1
solve         !此步求解,求得是什么?
跪求仁兄指点                           
回复 不支持

使用道具 举报

发表于 2011-9-9 15:27:33 | 显示全部楼层 来自 北京
仔细看了下code,排序那部分还真是纠结啊。
建议楼主运行一下就知道求解的是什么了。一个delt时间加载,一个delt时间持续,一个dt时间卸载,模拟焊接中的温度变化。
回复 不支持

使用道具 举报

 楼主| 发表于 2011-9-9 15:29:19 | 显示全部楼层 来自 陕西西安
woomii 发表于 2011-9-9 15:27
仔细看了下code,排序那部分还真是纠结啊。
建议楼主运行一下就知道求解的是什么了。一个delt时间加载,一 ...

非常感谢!
回复 不支持

使用道具 举报

发表于 2012-2-27 19:08:34 | 显示全部楼层 来自 天津
kkankan kan bu cuo a
回复 不支持

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

Simapps系列直播

Archiver|小黑屋|联系我们|仿真互动网 ( 京ICP备15048925号-7 )

GMT+8, 2024-9-22 21:21 , Processed in 0.034432 second(s), 11 queries , Gzip On, MemCache On.

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表