/COM,ANSYS MEDIA REL. 182 (07/10/2017) REF. VERIF. MANUAL: REL. 182 /VERIFY,vme3 /TITLE,VME3,Response of Spring-Mass-Damper System ! Modeling And Analysis of Dynamic Systems, ! Close and Frederick, page 314 PI=3.1415927 ZETA=0.21545376 ! zeta=damping ratio. M=1.0 ! m=mass. K=(4*PI)**2.0 ! k=spring stiffness. WN=SQRT(K/M) ! wn=system undamped natural frequency. C=M*(2*ZETA*WN) ! c=damping constant. /PREP7 ! Enter preprocessor. N,1,0,0,0 ! Node 1 will be the fixed end. N,2,1,0,0 ! The applied force will be at node 2. ET,1,166 ! Define element type 1 as MASS166. ET,2,165 ! Define element type 2 as COMBIN165. R,1,M ! Real constant for MASS166 is the value of the mass. R,2 MP,EX,1,30E6 ! Define modulus of elasticity. MP,DENS,1,.000733 ! Define density. MP,NUXY,1,0.29 ! Define poisson's ratio. MP,EX,2,30E6 MP,DENS,2,.000733 MP,NUXY,2,0.29 TB,discrete,2,,,0 tbdata,1,K TYPE,1 REAL,1 E,2 ! Create the MASS166 element at node 2. TYPE,2 REAL,2 MAT,2 E,1,2 ! Create the COMBIN165 element with end nodes 1 and 2. NSEL,S,NODE,,2 CM,MASS,NODE ! Create a nodal component at node 2 named "mass" ALLSEL D,1,UX,0 ! Constrain all deflections at node 1. D,1,UY,0 D,1,UZ,0 D,2,UY,0 ! Constrain uy and uz deflections at node 2. D,2,UZ,0 EDDAMP,ALL,0,C/M ! Define alpha damping. FINI /SOLU EDRST,1000 EDHTIME,1000 EDHIST,MASS ! Specify the mass component for time history output. EDCTS,,0.001 ! Set a time step scaling factor to 0.001. *DIM,T,ARRAY,2 ! Dimension array for time values. *DIM,FSTEP,ARRAY,2 ! Dimension array for step force input. *DIM,FRAMP,ARRAY,2 ! Dimension array for ramp force input. T(1)=0,1 FSTEP(1)=K,K ! The step input magnitude equals k so x=1 at steady-state. FRAMP(1)=0,K ! The ramp input is the integral of the step input. EDLOAD,ADD,FX,,MASS,T,FSTEP !Specify the load for the step input solution. TIME,1 !Specify the solution time. /COM &COMPARE,NOCOMPARE SOLVE /COM &COMPARE,NORMAL FINI /POST26 !Enter the time history post-processor. NSOL,2,2,U,X,DISPLACE !Define variable 2 - node 2 ux deflection EXTREM,2 !Print the max deflection and peak time *GET,RES1,VARI,2,EXTREM,VMAX,, *GET,TMAX1,VARI,2,EXTREM,TMAX,, /solu !Return to the solution processor. EDLOAD,ADD,FX,,MASS,T,FRAMP !Redefine the load for a ramp input. /COM &COMPARE,NOCOMPARE SOLVE /COM &COMPARE,NORMAL FINI /POST26 NSOL,2,2,V,X,VELOCITY !Define variable 2 - node 2 velocity. PLVAR,2 EXTREM,2 !Print the max velocity and peak time *GET,RES2,VARI,2,EXTREM,VMAX,, *GET,TMAX2,VARI,2,EXTREM,TMAX,, save *DIM,LABEL,CHAR,4 *DIM,RES,,4,3 LABEL(1) = 'MAX Ux','PK TIME','MAX Vx','PK TIME' *VFILL,RES(1,1),DATA,1.5,0.256,1.5,0.256 *VFILL,RES(1,2),DATA,RES1,TMAX1,RES2,TMAX2 *DO,I,1,4 *VFILL,RES(I,3),DATA,(RES(I,2)/RES(I,1)) *ENDDO /OUT,vme3,vrt /COM, /COM,-------------------- VME3 DYNA RESULTS COMPARISION -------------------- /COM, /COM, | TARGET | ANSYS | RATIO | /COM, *VWRITE,LABEL(1),RES(1,1),RES(1,2),RES(1,3) (1X,A8,' ',F5.3,' ',F5.3,' ',F5.3) /COM, /COM,----------------------------------------------------------------------- /OUT *LIST,vme3,vrt /GOPR FINISH