!File:EXAMPLE.LGW
H=0.06
B=0.06
L=1
/PREP7
ET,1, BEAM3
R,1,B*H,B*H*H*H/12,H
MP,EX,1,2E11
MP,NUXY,1,0.3
K,1,0,0,0
K,2,L,0,0
LSTR,1,2
LESIZE,1,,,50
LMESH,1
FINISH
/SOLU
DK,1,UX
DK,1,UY
DK,2,UX
DK,2,UY
SFBEAM,ALL,1,PRES,5000
SOLVE
SAVE
FINISH
/POST1
ETABLE,E_VOL,VOLU
SSUM
*GET,V_TOT,SSUM,,ITEM,E_VOL
NSORT,U,Y
*GET,UY_MIN,SORT,,MIN
UY_MAX=ABS(UY_MIN)
FINISH
2. 优化控制文件
!File:EXAMPLE_OPT.TXT
/FILNAME, EXAMPLE
/OPT
OPCLR
FINISH
/CLEAR
/INPUT, EXAMPLE,LGW
/OPT
OPANL, EXAMPLE,LGW
OPVAR,B,DV,0.05,0.1,0.001
OPVAR,H,DV,0.05,0.1,0.001
OPVAR,UY_MAX,SV,0,2E-4,1E-5
OPVAR,V_TOT,OBJ,,,1E-5
OPSAVE, EXAMPLE,OPT
OPTYPE, FIRST
OPFRST,30
OPEXEC
OPLIST,ALL
FINISH
3. 求解方法
先分别以文件名EXAMPLE.LGW、EXAMPLE_OPT.TXT将优化分析文件和优化控制文件存储在ANSYS的工作文件夹里,再在ANSYS的输入窗口输入/ INPUT, EXAMPLE_OPT,TXT,回车,开始求解。
[ 本帖最后由 jxxansys 于 2009-8-30 13:14 编辑 ] |