[Python] How do I extract each unique (internal and external) face connectivity from an...

Discussão em 'Python' iniciado por Stack, Março 29, 2025.

  1. Stack

    Stack Membro Participativo

    Hi I'm building a converter to go from an arbitrary finite element mesh to an edge based finite volume mesh format.

    To do so I need the barycentres (ie the midpoint) of all cells, faces and edges from the finite element mesh and the connectivities of all elements,faces and edges (to find the number of faces and elements connected to a node).

    Currently I'm able to extract the barycentres of cells using paraview.simple.CellCenters (and all element connectivities) and I'm able to extract the coordinates of internal edges (and subsequently the centre point) by using paraview.simple.ExtractEdges.

    I'm trying to do a similar thing to find the connectivities of unique-internal faces however the paraview.simple.ExtractSurface filter only extracts external faces.

    Is there a preexisting filter to achieve this or a good method for extracting the node all ids of all points comprising element faces?

    TLDR: how do I get node IDs of internal and external element surfaces in paraview.

    Continue reading...

Compartilhe esta Página