Looking to automate export velocity FRF via input file running in a cluster Ansys harmonic analysis

Hello Experts,
I need to export velocity FRF of predefined named selections in a harmonic analysis. I'm creating a input file from GUI and solving it using an inhouse HPC cluster. RST file size is very large that I cant download it to generate a FRF. So need a method by which it will create a CSV/txt file for required frequency response plot then I can download only that file.
Answers
-
Hi,
You can add some code to the end of the input file. Something like:
FRF_point = 55247 !! look at what node you use !!
P_point = 7541
P_point2 = 7545
file_namex = 'Dx_ow'
file_namey = 'Dy_ow'
file_namez = 'Dz_ow'/post26
NSOL,2,FRF_point,u,x,,x_disp !save displacement to var2,var3,var4
NSOL,3,FRF_point,u,y,,y_disp
NSOL,4,FRF_point,u,z,,z_disp*DIM,freq_1,ARRAY,My_Fstep ! Dimension for frequency results
*DIM,x_disp_r,ARRAY,My_Fstep ! Dimension for x displacement
*DIM,x_disp_i,ARRAY,My_Fstep
*DIM,y_disp_r,ARRAY,My_Fstep
*DIM,y_disp_i,ARRAY,My_Fstep
*DIM,z_disp_r,ARRAY,My_Fstep
*DIM,z_disp_i,ARRAY,My_FstepVGET,freq_1,1,,0 ! Store freq data of variable 1 into freq_p1
VGET,x_disp_r,2,,0 ! Store freq data of variable 2 into x_disp_r
VGET,x_disp_i,2,,1 ! Store freq data of variable 2 into x_disp_i
VGET,y_disp_r,3,,0
VGET,y_disp_i,3,,1
VGET,z_disp_r,4,,0
VGET,z_disp_i,4,,1/com, The pres_r = %pres_r%
/com, The pres_i = %pres_i%
/com, The pres2_r = %pres2_r%
/com, The y_disp_r = %y_disp_r%
/com, The z_disp_i = %z_disp_i%*CFOPEN, file_namex, csv
*VWRITE,freq_1(1),x_disp_r(1),x_disp_i(1) ! Write array in given format
(6x,F12.6,',',6x,E12.6,',',6x,E12.6)
*CFCLOSE ! Close file*CFOPEN, file_namey, csv
*VWRITE,freq_1(1),y_disp_r(1),y_disp_i(1)
(6x,F12.6,',',6x,E12.6,',',6x,E12.6)
*CFCLOSE*CFOPEN, file_namez, csv
*VWRITE,freq_1(1),z_disp_r(1),z_disp_i(1)
(6x,F12.6,',',6x,E12.6,',',6x,E12.6)
*CFCLOSEThen you need to do something with the displacement to get the velocity because it does not save that.
Kind regards,Michael
0 -
Ah you should define My_Fstep as the number of freq points.
0 -
Ok thanks, I'm able to generate this FRF.
One question, if you further help me please, lets say this one I can postprocess offline to get the disp amplitudes and then calculate the velocity and acceleration.
How can I do the this same 'disp amplitudes and then calculate the velocity and acceleration' in script it self?0