34 const bool use_taylor_hood_elements =
false)
52 sort(begin(sorted_nodes), end(sorted_nodes));
55 auto node_is_part_of_mesh =
58 auto it = lower_bound(begin(mesh_nodes), end(mesh_nodes), n);
59 if (it == end(mesh_nodes))
61 ERR(
"A node {:d} ({:g}, {:g}, {:g}) in mesh subset is not "
62 "a part of the mesh.",
63 n->getID(), (*n)[0], (*n)[1], (*n)[2]);
68 if (!std::all_of(begin(
_nodes), end(
_nodes), node_is_part_of_mesh))
70 OGS_FATAL(
"The mesh subset construction failed.");
Definition of the Element class.
void ERR(fmt::format_string< Args... > fmt, Args &&... args)
Definition of the Mesh class.
Definition of the Node class.
A subset of nodes on a single mesh.
std::vector< Node * > const & _nodes
MeshSubset(const Mesh &msh, std::vector< Node * > const &vec_items, const bool use_taylor_hood_elements=false)
bool useTaylorHoodElements() const
std::vector< Element * >::const_iterator elementsEnd() const
Mesh const & getMesh() const
std::size_t getMeshID() const
return this mesh ID
std::vector< Element * >::const_iterator elementsBegin() const
bool const _use_taylor_hood_elements
std::vector< Node * > const & getNodes() const
std::vector< Node * > const & getNodes() const
Get the nodes-vector for the mesh.
std::vector< Element * > const & getElements() const
Get the element-vector for the mesh.
std::size_t getID() const
Get id of the mesh.