A path with results averaged across a face?

Options

Hello,

I am trying to figure out how to write a script for ANSYS Mechanical which would carry out the following:
1. Scan a face running along an edge of a component.
2. Average certain parameter e.g. nodal force, stress and report value at a path sampling point.
3. Export values to a file and maybe print the result.

See SS for better illustration of the problem:
Example of face:

Procedure:

This would preferably be Python Script or Python result, as long as I can export the results along the path for further calculations.

I could not find similar thread, please point me towards it if I missed it.
Also please move the thread if it is not in the right subforum.

I would appreciate your help.

Answers

  • Pernelle Marone-Hitz
    Pernelle Marone-Hitz Member, Moderator, Employee Posts: 804
    First Comment First Anniversary Ansys Employee Solution Developer Community of Practice Member
    Options

    Hi @ArnoldH, this looks like something doable thanks to DPF. For identifying the face, I'd recommend using a named selection. For the rest of the script, DPF will enable you to extract results from the simulation and calculate new data. You'll find more info in the Ansys Help. You'll also find many examples in the PyDPF-Core documentation (they would have to be adapted for Mechanical DPF but the majority could be reused).
    Writing the entire script for you would be outside of what we can offer through this forum (or standard technical support), but if you have specific questions we'll be happy to help.