How do i extract force reaction table from rst file using DPF Post?
Hello Ansys developers:
recently i am trying to extract force reaction from rst file without opening Ansys Mechanical. As the below pic shows, i want to get the forces on the whole process time steps.
Thus, i implemented such code to get my target values.
But i get the following error msg:
I suppose that i have defined a wrong argument or just used a wrong method, unfortunately, i am not familiar with this module and could solve this issue. Could you give some advise or hint to get my target values? Thanks in advance!
BR,
Kevin
Answers
-
Hi @DENG_Kevin ,
The names of named selections are converted to capital letters when they are passed to the solver. So a named selection called "my_ns" would become "MY_NS" for DPF postprocessing. You can check the available named selections through
print(simulation.named_selections)
Also in Mechanical your named selection seems to be called "pull_edges" but in your DPF script you are calling "force_node_set". Have you made sure that this scoping is not empty?
0 -
Hi @Pernelle Marone-Hitz,
Thanks for your solution. Yes, you're right that i should give the 'pull_edge' to the reaction force method. I tried it but i still didn't gain the values in Force reaction table ( time vs. x-force) but the nodal force on 'pull_edge'. Is there any solution that i could directly get my target values from rst file?
Best regard,
Kevin
0 -
Hi @DENG_Kevin , you've made some nice progress! From the results you obtained you can filter the X values and sum them together to get the total reaction force. You'll also have define the time scoping to get all the time steps in your analysis, to get the value for each time step. By default you're getting the values for the last time step only.
1 -
Hi @Pernelle Marone-Hitz
I have extracted reaction force successfully by the codes in the discuss mentioned.
There is still one thing bother me that how can I get the reaction force table under the specific coordinates?Just like the function described in the picture.
0 -
Hi @wanghao, there will be two ways here:
- with your current method, you can use some matrix transformation to convert the value to any other CS
- you can also use Mechanical automation scripting to retrieve the values that are shown in Mechanical
0