Ansys Assistant will be unavailable on the Learning Forum starting January 30. An upgraded version is coming soon. We apologize for any inconvenience and appreciate your patience. Stay tuned for updates.
Fluids

Fluids

Topics related to Fluent, CFX, Turbogrid and more.

PyFLUENT – Meshing – Rename surfaces

    • cesarj.95plus
      Subscriber
      Dear support,

      I am practicing fluent meshing with pyfluent and I am trying to rename the geometrical elements imported into my meshing session (only surfaces). I can rename them like this:

      for full_name in session.meshing_utilities.get_all_objects():
      part_name = full_name.replace('origin-', '')
      new_name = full_name.replace('origin--','')
      session.meshing_utilities.rename_face_zone(zone_name=full_name, new_name=new_name)
      session.meshing_utilities.rename_face_zone_label(object_name=full_name, old_label_name=part_name, new_label_name=f'label_{new_name}')

      However when I try to move forward with the meshing it seems that these commands create new faces and therefore the labels are duplicated pointing to the same element. I have deeply explored the method meshing_utilities inside the meshing session class but couldn't find an effective way to achieve this.

      Is there a way to access to all the available geometrical elements and change their names?
       
       
    • Essence
      Ansys Employee

      Hello,

      Questions related to PyFluent and PyAnsys in general are not considered as a standard Forum support. Therefore, I would request you to post the questions related to PyFluent and PyAnsys on Git Hub.

      Thank you.

Viewing 1 reply thread
  • You must be logged in to reply to this topic.
[bingo_chatbox]