Ansys Learning Forum › Forums › Discuss Simulation › General Mechanical › how to assign energy probe using APDL command ? › Reply To: how to assign energy probe using APDL command ?
There could be other errors, but procedurally the script should be like this:
/POST1
ESEL,S,ENAME,,185
*DIM,potential_energy,ARRAY,55 ! Number of steps
*DO, step, 1, 55, 1
  set,,,,,,,step     ! store results for set step
  *GET,energy,SENE,step,ITEM
  potential_energy(step) = energy
  *CFOPEN,my_file,TXT,C:\Users\MD\Desktop\energy\
 *VWRITE, potential_energy(1:55),â%10.2Fâ
 *CFCLOSE
*ENDDO
I don't recognize the format of the two commands below. Are they based on the *GET command documentation?
*GET, max_index, potential_energy, MAX
*GET, my_energy, ARRAY, potential_energy(max_index)
Â