! St2LH_AFC_1 - program for ANSYS ! Structural analysis(St) ! 2D problem(2) ! Linear analysis(L) ! Harmonic analysis(H) ! Amplitude-frequency characteristic (AFC) ! ! Test problem: computation of steady-state oscillations (harmonic analysis) ! for the system of linear elasticity equations ! (plane stress) ! Graph of amplitude-frequency response around two resonance frequencies ! ! Geometry of the domain - double T-region ! Domain consists of two different materials ! ! Program uses Ansys database St2LM_1.db created previously for modal analysis /filname,st2lh_afc_1 RESUME,St2LM_1,db ! Resume database St2LM_1.db F_R='Harm1' ! file name for text output FORC=1e3 ! value of the force FBEG=50 ! start value of frequency range FEND=900 ! end value of frequency range NFREQ=250 ! number of frequencies in the range F1=98.218 $ F2=735.42 ! values of the first two natural frequencies /OUTPUT,F_R,rez ! define file name and extension for text output *VWRITE ! write to file (1X,' HARMONIC ANALYS ') ! use FORTRAN FORMAT conventions, 1x stands for one blank *VWRITE,FBEG,FEND (1X,' FBEG=', E12.5,' FEND=', E12.5) !specify real exponential fortran format for FBEG and value: Ew.d !W = width of field, d = number of digits after the decimal point !specify real fortran format for nfreq value: Fw.d !W = number of positions to be used, d = number of digits after the decimal point *VWRITE,NFREQ (1X,' NFRåQ= ',F6.0) /OUTPUT ! finish text output /COM, Damping properties PI2=(3.141593*2) IPI2=1./PI2 FDB=F1 FDE=F2 FRDS=FDB+FDE Q=1000 ! quality factor ADAMP=PI2*FDB*FDE/(FRDS*Q) ! parameter for damping coefficient BDAMP=IPI2/(FRDS*Q) ! parameter for damping coefficient /OUTPUT,F_R,rez,,append ! continue output to file ! use real fortran format with exponent notation Ew.d *VWRITE,FDB,FDE ! write values of FDB and FDE (1X,' FDB=', E12.5,' FDE=', E12.5) *VWRITE,Q ! write value of Q in the same format (1X,' Q=', F12.2) *VWRITE,ADAMP,BDAMP ! write values of adamp and bdamp in the same format (1X,' ADAMP=', E12.5,' BDAMP=',E12.5) /OUTPUT /SOLU ANTYPE,HARMIC ! Harmonic analysis (steady-state oscillations) HARFRQ,FBEG,FEND ! Start and end values of frequency range NSUBST,NFREQ ! number of frequencies in the frequency range: NFREQ. KBC,1 ! specify step-changed loading ALPHAD,ADAMP ! Defines the mass matrix multiplier for damping BETAD,BDAMP ! Defines the stiffness matrix multiplier for damping NSEL,S,LOC,X,L !Select new set of nodes with x=l NSEL,R,LOC,Y,B !Reselect the nodes from the current set with y=b *GET,N_RES2,NODE,,NUM,MIN ! specify parameter N_RES2 with the value of the minimal node number located in(L,B) NSEL,S,LOC,X,-L !Select new set of nodes with x=-l NSEL,R,LOC,Y,B !Reselect the nodes from the current set with y=b *GET,N_RES1,NODE,,NUM,MIN ! specify parameter N_RES1 with the value of the minimal node number located in(-L,B) NSEL,ALL ! select all nodes F,N_RES2,FX,FORC ! set force fx value in node n_res2 F,N_RES2,FY,FORC ! set force fy value in node n_res2 F,N_RES1,FX,-FORC ! set force fx value in node n_res1 F,N_RES1,FY,-FORC ! ! set force fy value in node n_res1 OUTRES,BASIC,ALL ! write basic solution results for every substep SOLVE SAVE FINISH /POST26 ! Enter time-history postprocessor ! Plot graph of amplitude-frequency response ! Variable for x-axes is frequency (default variable 1) /XRANG,FBEG,FEND ! Range for x-axes /AXLAB,X,Frequency (Hz) ! Label for x-axes in graph display /AXLAB,Y,Displacement (M) ! Lable for y-axes in graph display ! Define variable for y-axes (variable 2) NSOL,2,N_RES2,UY ! displacement uy in node n_res2 PLVAR,2 ! plot variable 2 on a graph