11 #include "cell_types.h"
13 #include <dolfinx/common/MPI.h>
14 #include <dolfinx/common/UniqueIdGenerator.h>
20 class CoordinateElement;
37 = std::function<const dolfinx::graph::AdjacencyList<std::int32_t>(
38 MPI_Comm comm,
int nparts,
int tdim,
59 template <
typename Topology,
typename Geometry>
79 Mesh& operator=(
const Mesh& mesh) =
delete;
110 std::size_t
id()
const {
return _unique_id; }
155 const xt::xtensor<double, 2>& x,
GhostMode ghost_mode);
160 const xt::xtensor<double, 2>& x,
GhostMode ghost_mode,
A duplicate MPI communicator and manage lifetime of the communicator.
Definition: MPI.h:32
static std::size_t id()
Generate a unique ID.
Definition: UniqueIdGenerator.cpp:22
This class manages coordinate mappings for isoparametric cells.
Definition: CoordinateElement.h:29
This class provides a static adjacency list data structure. It is commonly used to store directed gra...
Definition: AdjacencyList.h:47
Geometry stores the geometry imposed on a mesh.
Definition: Geometry.h:37
A Mesh consists of a set of connected and numbered mesh topological entities, and geometry data.
Definition: Mesh.h:53
Topology & topology_mutable() const
Get mesh topology if one really needs the mutable version.
Definition: Mesh.cpp:177
Mesh(Mesh &&mesh)=default
Move constructor.
~Mesh()=default
Destructor.
Mesh(MPI_Comm comm, Topology &&topology, Geometry &&geometry)
Create a mesh.
Definition: Mesh.h:60
Mesh & operator=(Mesh &&mesh)=default
Assignment move operator.
std::string name
Name.
Definition: Mesh.h:117
MPI_Comm mpi_comm() const
Mesh MPI communicator.
Definition: Mesh.cpp:183
Geometry & geometry()
Get mesh geometry.
Definition: Mesh.cpp:179
std::size_t id() const
Get unique identifier for the mesh.
Definition: Mesh.h:110
Mesh(const Mesh &mesh)=default
Copy constructor.
Topology & topology()
Get mesh topology.
Definition: Mesh.cpp:173
Topology stores the topology of a mesh, consisting of mesh entities and connectivity (incidence relat...
Definition: Topology.h:56
Finite element method functionality.
Definition: assemble_matrix_impl.h:23
Graph data structures and algorithms.
Definition: AdjacencyList.h:19
Mesh data structures and algorithms on meshes.
Definition: DirichletBC.h:20
Mesh create_mesh(MPI_Comm comm, const graph::AdjacencyList< std::int64_t > &cells, const fem::CoordinateElement &element, const xt::xtensor< double, 2 > &x, GhostMode ghost_mode)
Create a mesh using the default partitioner. This function takes mesh input data that is distributed ...
Definition: Mesh.cpp:55
std::function< const dolfinx::graph::AdjacencyList< std::int32_t >(MPI_Comm comm, int nparts, int tdim, const dolfinx::graph::AdjacencyList< std::int64_t > &cells, dolfinx::mesh::GhostMode ghost_mode)> CellPartitionFunction
Definition: Mesh.h:40
GhostMode
Enum for different partitioning ghost modes.
Definition: Mesh.h:44