How to extract Ids of all the nodes on a face (surface) using Python scripting

Erik Kostson
Erik Kostson Member, Employee Posts: 87
First Answer Name Dropper First Anniversary Ansys Employee
edited January 30 in Structures

How to extract Ids of all the nodes on a face (surface) using Python scripting

Comments

  • Erik Kostson
    Erik Kostson Member, Employee Posts: 87
    First Answer Name Dropper First Anniversary Ansys Employee
    edited January 30

    Below is a sample script to do that (it takes the first named selection):

    model=ExtAPI.DataModel.Project.Model
    ns=model.NamedSelections.Children
    f=ns[0].Location.Ids
    meshData = ExtAPI.DataModel.Project.Model.Analyses[0].MeshData
    faceMesh = meshData.MeshRegionById(f[0])
    nodes=faceMesh.NodeIds
    
This discussion has been closed.