Hello,
I’ve got a quick question regarding getting information about the mesh connectivity in FEniCS 2019.1.
My problem is as follows: There are the following methods for a mesh available: mesh.coordinates
and mesh.cells
, which give the list of coordinates of the mesh vertices (mesh.coordinates
) as well as the composition of the cells (triangles, tetrahedrons, etc.) with mesh.cells
. See, e.g.,
from fenics import *
mesh = UnitSquareMesh(2, 2)
print(f"{mesh.coordinates() = }")
print(f"{mesh.cells() = }")
My question is: Is there any analogous functionality which gives a representation of the facets (e.g. line segments, triangles, etc.) of the mesh? And I need two things from this function: It should be fast (so no loops in python) and also possible to compute in parallel.
Thansk in advance for your help!