You are on page 1of 8

/CWD,'C:\Users\Murat\Desktop\wrs_calc'

/TITLE,TP16_2bt/b=0_20
/PREP7
! GEOMETRIC VARIABLES
*SET,A,2550
*SET,B,850
*SET,TP,16 ! plate thickness
*SET,HW,250 ! S2 Flat bar
*SET,TW,25
*SET,NUMINTP,5
*SET,ZCORD,(HW+(TP/2))
*SET,yld_stress,313.6
*SET,ELMOD,205800
*SET,APPLSTRESS,350
*set,yld_str,yld_stress/ELMOD
*set,beta,(b/tp)*(yld_stress/ELMOD)**0.5
*set,btotal,3*b

!! Calculate WRS breadths


!! predetermined WRS
btb=0.2 ! Ratio of tensile WRS breadth to the stiffener spacing.
bt=btb*b/2

btsh=1/6 ! Ratio of tensile WRS height on stiffener to web height.


bts=hw*btsh

!! Calculate compressive WRS


sc_p=2*bt*yld_stress/(b-2*bt) ! compressive WRS for plate
sc_s=bts*yld_stress/(hw-bts) ! compressive WRS for stiffener web

! MATERIAL PROPERTIES
ET,1,SHELL181
MP,EX,1,ELMOD
MP,PRXY,1,0.3
TB,BISO,1,1,2,
TBTEMP,0
TBDATA,,yld_stress,0.000001

!!!! PLATE KEYPOINTS !!!!!

k,1,0,0,0
k,2,0,b/2-bt,0
k,3,0,b/2,0
k,4,0,bt+b/2,0
k,5,0,b+b/2,0
k,6,0,b/2+b+b-bt,0
k,7,0,b/2+b+b,0
k,8,0,b/2+b+b+bt,0
k,9,0,3*b,0

k,10,0,b/2,bts+tp/2
k,11,0,5*b/2,bts+tp/2

k,12,0,b/2,zcord
k,13,0,5*b/2,zcord

! For the modeling of tensile WRS along LG


k,14,0,b+b/2-bt,0
k,15,0,b+b/2+bt,0

!! generate additional keypoints


kgen,2,all,,,a/2,0,0,0,1,0

!! Generate areas
!! Plate areas

a,1,2,17,16
a,2,3,18,17
a,3,4,19,18
a,4,14,29,19
a,14,5,20,29
a,5,15,30,20
a,15,6,21,30

a,6,7,22,21
a,7,8,23,22
a,8,9,24,23

! web areas
a,3,18,25,10
a,10,25,27,12

a,7,22,26,11
a,11,26,28,13

!! Generate additional areas

agen,2,all,,,a/2,0,0,0,0,0

!! Merge dublicated keypoints


nummrg,kp,,,,

! SECTION MODELLING
ASEL,NONE
ASEL,S,LOC,Z,0,0 ! SECTIONS
SECTYPE,1,SHELL
SECDATA,TP,1,,NUMINTP
SECOFFSET,MID
AATT,1,,1,,1

ASEL,INVE
SECTYPE,2,SHELL
SECDATA,TW,1,,NUMINTP
SECOFFSET,MID
AATT,1,,1,,2

!!! MESH !!!!


LSEL,S,LOC,X,0,0
LSEL,A,LOC,X,(A/2),(A/2)
LSEL,A,LOC,X,A,A
LSEL,R,LOC,Z,0,0
LESIZE,ALL,(B/10)
lsel,inve
lsel,u,loc,z,tp/2+1,zcord
lsel,a,loc,z,tp/2+bts
lsel,a,loc,z,zcord

lesize,all,a/30

LSEL,NONE

LSEL,S,LOC,X,0,0
LSEL,A,LOC,X,(A/2),(A/2)
LSEL,A,LOC,X,A,A
LSEL,R,LOC,Z,TP/2+1,ZCORD
LESIZE,ALL,zcord/6
LSEL,NONE

ASEL,ALL
MSHKEY,0
AMESH,ALL

!! Select areas and associated elements in which tensile WRS is applied.

ASEL,NONE

asel,s,area,,2
asel,a,area,,3

asel,a,area,,5
asel,a,area,,6

asel,a,area,,8
asel,a,area,,9

asel,a,area,,16
asel,a,area,,17

asel,a,area,,19
asel,a,area,,20

asel,a,area,,22
asel,a,area,,23

esla,s
cm,tensile_elem_plate,elem

asel,none
esel,none

asel,a,area,,11
asel,a,area,,13

asel,a,area,,25
asel,a,area,,27

esla,s

cm,tensile_elem_stiff,elem
!! Elements in which compressive WRS is applied
asel,inve
asel,r,loc,z,0
esla,s

cm,plate_comp_elements,elem

asel,none
asel,s,loc,z,bts+1,zcord
esla,s

cm,stiff_comp_elements,elem

!! get total number of nodes on the base plate


!! and store related informations

! asel,none
! nsel,none
! asel,s,loc,z,0
nsel,s,loc,z,0

*get,nn_plate,node,0,count ! Total number of nodes on plate


*dim,np,array,nn_plate,1 ! This array stores node list for plates
*dim,locx_p,array,nn_plate,1 ! This array stores locx for plate nodes
*dim,locy_p,array,nn_plate,1 ! This array stores locy for plate nodes

*vget,np,node,,nlist ! node list is stored here

*do,i,1,nn_plate,1 ! loop for plate nodes to store node coordinates


nnump=np(i,1)
*vget,locx_p(i,1),node,nnump,loc,x
*vget,locy_p(i,1),node,nnump,loc,y
*enddo

!! get total number of nodes on the stiffeners


!! and store related informations

nsel,inve

*get,nn_stiff,node,0,count
*dim,ns,array,nn_stiff,1 ! This array stores node numbers for stiffeners
*dim,locx_s,array,nn_stiff,1 ! This array stores locx for stiffener nodes
*dim,locz_s,array,nn_stiff,1 ! This array stores locz for stiffener nodes

*vget,ns,node,,nlist

*do,ii,1,nn_stiff,1
nnums=ns(ii,1)
*vget,locx_s(ii,1),node,nnums,loc,x
*vget,locz_s(ii,1),node,nnums,loc,z
*enddo

!! Initial deflections
*set,pi,4*atan(1)
B0=0.001*a
*if,(0.1*beta*beta*tp),lt,6.0,then
*set,A0max,0.1*beta*beta*tp
*else
*set,A0max,6.0
*endif

nsel,all
esel,all
asel,all

!! initial deflections for plate


*do,j,1,nn_plate,1
nnump=np(j,1)
xx=locx_p(j,1)-a/2
yy=locy_p(j,1)-btotal/2
! *if,xx,lt,0,and,yy,gt,b/2,then
! A0maxp=A0max*0.8
! *endif
! *if,xx,lt,0,and,yy,lt,b/2,and,yy,gt,0,then
! A0maxp=A0max
! *endif
w_ov=B0*sin(pi*xx/a)*sin(pi*yy/btotal)
w_thin=A0max*abs((1.1458*sin(pi*xx/a)+0.3079*sin(3*pi*xx/a)
+0.1146*sin(5*pi*xx/a)+0.0327*sin(7*pi*xx/a)-0.0074*sin(11*pi*xx/a))*sin(pi*yy/b))
disp_plate=w_ov+w_thin
d,nnump,uz,disp_plate
*enddo

!! Initial deflections for stiffeners

*do,jj,1,nn_stiff,1
nnums=ns(jj,1)
zz=locz_s(jj,1)
xxs=locx_s(jj,1)-a/2
disp_stiff=B0*(zz/zcord)*sin(pi*xxs/a)
d,nnums,uy,disp_stiff
*enddo

KSEL,S,KP,,20 ! TO PREVENT RIGID BODY MOTION


DK,ALL,UX,0

/SOL
ANTYPE,0
OUTRES,ERASE
OUTRES,ALL,ALL
SOLVE
SAVE

!!!! Prepare for nonlinear analysis


/PREP7
*SET,NONSUBST,1
UPGEOM,1,1,NONSUBST,file,rst ! update geometry for initial deflections

!! Remove all load and BCs from the previous analysis


NSEL,ALL
DDELE,ALL,UZ
DDELE,ALL,UY
DDELE,ALL,UX

!! Apply WRS as initial stress

esel,none
cmsel,s,plate_comp_elements,elem ! Compressive WRS for plate
inistate,set,dtyp,stre
inistate,define,,,,,-sc_p

esel,none
cmsel,none
cmsel,s,stiff_comp_elements,elem ! Compressive WRS for stiffener web
inistate,set,dtyp,stre
inistate,define,,,,,-sc_s

nsel,none
lsel,s,loc,x,0
lsel,a,loc,x,a
nsll,s

esel,none
cmsel,none
cmsel,s,tensile_elem_stiff,elem
inistate,set,dtyp,stre
inistate,define,,,,,yld_stress

esel,none
cmsel,none
cmsel,s,tensile_elem_plate,elem
inistate,set,dtyp,stre
inistate,define,,,,,0,yld_stress

esel,all
nsel,all
asel,all

KSEL,S,KP,,20
DKDELE,ALL,UX
DK,ALL,UY,0

LSEL,NONE
LSEL,S,LOC,X,(A/2),(A/2) ! constrain uz along T.F.
DL,ALL,,UZ,0
LSEL,NONE

LSEL,S,LOC,Y,0,0 ! Symmetric BCs along long. edges


DL,ALL,,ROTX,0
dl,all,,rotz,0
NSLL,S,1
CP,1,UY,ALL
LSEL,NONE
NSEL,NONE

LSEL,S,LOC,Y,(3*B),(3*B) ! Symmetric BCs along long. edges


DL,ALL,,ROTX,0
dl,all,,rotz,0
NSLL,S,1
CP,2,UY,ALL
LSEL,NONE
NSEL,NONE

LSEL,S,LOC,X,0,0 ! Constrain roty (for symmetric BCs) at the loaded edge


DL,ALL,,ROTY,0
DL,ALL,,ROTZ,0
LSEL,NONE

LSEL,S,LOC,X,A,A ! constrain ux at the supporting edge (also symmetric


BCs)
DL,ALL,,ROTY,0
DL,ALL,,ROTZ,0
DL,ALL,,UX,0
LSEL,NONE

LSEL,S,LOC,Y,(3*B/2),(3*B/2) ! Constrain uz along L.G.


DL,ALL,,UZ,0
LSEL,NONE

LSEL,S,LOC,Y,(B/2),(B/2) ! uniform uy along T.F. stiffener connections


LSEL,R,LOC,X,(A/2),(A/2)
NSLL,S,1
CP,3,UY,ALL
NSEL,NONE
LSEL,NONE

LSEL,S,LOC,Y,(5*B/2),(5*B/2) ! uniform uy along T.F. stiffener connections


LSEL,R,LOC,X,(A/2),(A/2)
NSLL,S,1
CP,4,UY,ALL
NSEL,NONE
LSEL,NONE

LSEL,S,LOC,X,0,0
NSLL,S,1
CP,5,UX,ALL

!! Apply forced displcement.


LSEL,S,LOC,X,0,0
DL,ALL,,UX,8

LSEL,ALL
ASEL,ALL
NSEL,ALL
esel,all

/SOL !! arc-length olmadan nonlinear cozum


ANTYPE,0
PSTRES,ON
NLGEOM,1
NSUBST,1000,10000,1
AUTOTS,0 !!! 0: Auto time step kapali 1: Autotimestep acik
CUTCONTROL,CRPLIMITexp,0.2,0
CUTCONTROL,CRPLIMITimp,0.2,1
CUTCONTROL,PLSLIMIT,0.5
LNSRCH,1
NEQIT,25
PSTRES,1
! STABILIZE,CONSTANT,ENERGY,0.0015,NO
SOLVE

save
/POST26
RFORCE,2,1,F,X, FX_2
STORE,MERGE
LINES,2000
PRVAR,2,

You might also like