General Mechanical

General Mechanical

Can I run a script before each solving?

    • Fuxx
      Subscriber

      Hi dear Ansys learners and experts,

      I wonder if it is possible to run a script (Python API) before each solve? Probably my approaches are very poor and there are better ways to solve the problem but it is as follows:

      Using Workbench parameters and a script in SpaceClaim, I create geometries from several parts. Parts are added and removed, so the mesh/material/contact conditions have to be adjusted each time.This can be done comfortably via python scripts, but it is still manual. If I want to use the power of the parameter set, the manual option is no longer available.

      I look forward to your feedback.

      Ferdi

    • Aniket
      Ansys Employee
      Can you please explain your query in some more details, Running script before each DP would basically change the DP, and hence each DP would have to be solved again, manually. If your geometry is parametric in SpaceClaim and all you need is to add or remove parts, probably you can use a command snippet based element birth death commands to kill the elements of the parts that you want to remove.
      -Aniket
      How to access Ansys help links
      Guidelines for Posting on Ansys Learning Forum
Viewing 1 reply thread
  • You must be logged in to reply to this topic.