1#include <libmesh/mesh.h>
2#include <libmesh/mesh_generation.h>
3#include <libmesh/boundary_info.h>
4#include <libmesh/elem.h>
5#include <libmesh/face_quad4_shell.h>
6#include <libmesh/equation_systems.h>
7#include <libmesh/zero_function.h>
8#include <libmesh/dirichlet_boundaries.h>
9#include <libmesh/dof_map.h>
10#include <libmesh/parallel.h>
11#include <libmesh/mesh_refinement.h>
36# ifdef LIBMESH_ENABLE_AMR
37# ifdef LIBMESH_ENABLE_EXCEPTIONS
47# ifdef LIBMESH_ENABLE_DIRICHLET
87 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(4), bi.
n_boundary_ids());
94 bool has_bcid = bc_ids.count(i);
96 CPPUNIT_ASSERT(has_bcid);
104 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(8), bc_triples.size());
108 std::unique_ptr<MeshBase> mesh_clone =
mesh.
clone();
109 CPPUNIT_ASSERT(mesh_clone->get_boundary_info() ==
115 CPPUNIT_ASSERT(mesh_clone->get_boundary_info() !=
120 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(3), bi.
n_boundary_ids());
124 CPPUNIT_ASSERT(!bc_ids.count(0));
127 bool has_bcid = bc_ids.count(i);
129 CPPUNIT_ASSERT(has_bcid);
139 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(6), bc_triples.size());
142 CPPUNIT_ASSERT(std::find_if(bc_triples.begin(), bc_triples.end(),
143 [](
const auto & t) { return std::get<2>(t) == 0; }) == bc_triples.end());
148 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(3), bi.
n_boundary_ids());
158 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(0), bi.
n_boundary_ids());
159 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(0), bc_triples.size());
184 const std::map<boundary_id_type, std::string> expected_names =
185 {{4,
"bottom"}, {5,
"right"}, {6,
"left"}};
189 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(3), bi.
n_boundary_ids());
197 bool has_bcid = bc_ids.count(i);
199 CPPUNIT_ASSERT(!has_bcid);
203 bool has_bcid = bc_ids.count(i);
205 bool bad_name =
false;
210 bad_name = (current_name != libmesh_map_find(expected_names, i));
215 CPPUNIT_ASSERT(has_bcid);
219 CPPUNIT_ASSERT(!bad_name);
229 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(8), bc_triples.size());
238 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(0), bi.
n_boundary_ids());
239 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(0), bc_triples.size());
285 const std::map<boundary_id_type, std::string> expected_basic_names =
286 {{1,
"bottom"}, {2,
"right"}, {3,
"top"}, {4,
"left"}};
288 std::map<boundary_id_type, std::string> expected_side_names =
289 expected_basic_names;
290 expected_side_names.insert({{6,
"back"}, {7,
"front"}});
292 std::map<boundary_id_type, std::string> expected_node_names =
293 expected_basic_names;
294 expected_node_names.insert({{6,
"front"}, {7,
"back"}});
296 const std::map<boundary_id_type, std::string> expected_edge_names =
297 {{3,
"firstedge"}, {4,
"secondedge"}};
301 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(6), bi.
n_boundary_ids());
313 bool has_bcid = bc_ids.count(noid) ||
314 side_bc_ids.count(noid) ||
315 edge_bc_ids.count(noid) ||
316 node_bc_ids.count(noid);
318 CPPUNIT_ASSERT(!has_bcid);
323 bool has_bcid = bc_ids.count(
id),
324 has_side_id = side_bc_ids.count(
id),
325 has_edge_id = edge_bc_ids.count(
id),
326 has_node_id = node_bc_ids.count(
id);
328 bool bad_name =
false;
332 bad_name = bad_name || (side_name != libmesh_map_find(expected_side_names,
id));
338 bad_name = bad_name || (edge_name != libmesh_map_find(expected_edge_names,
id));
344 bad_name = bad_name || (node_name != libmesh_map_find(expected_node_names,
id));
349 CPPUNIT_ASSERT(has_bcid);
352 CPPUNIT_ASSERT(has_side_id);
355 if (
id == 3 ||
id == 4)
356 CPPUNIT_ASSERT(has_edge_id);
358 CPPUNIT_ASSERT(!has_edge_id);
361 CPPUNIT_ASSERT(has_node_id);
365 CPPUNIT_ASSERT(!bad_name);
375 const unsigned int n_elem = 5;
376 const std::string mesh_filename =
"cube_mesh.xda";
381 n_elem, n_elem, n_elem,
390 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(0), bi.
n_edge_conds());
399 for (
const auto & elem :
mesh.element_ptr_range())
401 unsigned short side_max_x = 0, side_min_y = 0;
402 bool found_side_max_x =
false, found_side_min_y =
false;
404 for (
unsigned short side=0; side<elem->n_sides(); side++)
409 found_side_max_x =
true;
415 found_side_min_y =
true;
422 if (found_side_max_x && found_side_min_y)
423 for (
unsigned short e=0; e<elem->n_edges(); e++)
424 if (elem->is_edge_on_side(e, side_max_x) &&
425 elem->is_edge_on_side(e, side_min_y))
426 bi.
add_edge(elem, e, EDGE_BOUNDARY_ID);
431 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(n_elem), bi.
n_edge_conds());
435 std::unique_ptr<MeshBase> mesh_clone =
mesh.
clone();
436 CPPUNIT_ASSERT(mesh_clone->get_boundary_info() ==
451 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(n_elem), bi.
n_edge_conds());
475 CPPUNIT_ASSERT_EQUAL(bi2.get_sideset_name(0), std::string(
"zero"));
476 CPPUNIT_ASSERT_EQUAL(bi2.get_sideset_name(1), std::string(
"one"));
477 CPPUNIT_ASSERT_EQUAL(bi2.get_sideset_name(2), std::string(
"two"));
478 CPPUNIT_ASSERT_EQUAL(bi2.get_sideset_name(3), std::string(
"three"));
479 CPPUNIT_ASSERT_EQUAL(bi2.get_nodeset_name(0), std::string(
"ZERO"));
480 CPPUNIT_ASSERT_EQUAL(bi2.get_nodeset_name(1), std::string(
"ONE"));
492#ifdef LIBMESH_ENABLE_DIRICHLET
544 std::unique_ptr<MeshBase> mesh_clone =
mesh.
clone();
545 CPPUNIT_ASSERT(mesh_clone->get_boundary_info() ==
556 std::vector<unsigned int> variables;
557 variables.push_back(0);
558 std::set<boundary_id_type> shellface_ids;
559 shellface_ids.insert(20);
569 elem_bottom =
nullptr;
579 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(4),
static_cast<std::size_t
>(system.
n_constrained_dofs()));
586 std::vector<dof_id_type> dof_indices;
588 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(4), dof_indices.size());
590 for(
unsigned int i=0; i<dof_indices.size(); i++)
599#if LIBMESH_ENABLE_AMR
600# if LIBMESH_ENABLE_EXCEPTIONS
621 for (
auto & elem :
mesh->active_element_ptr_range())
630 bool threw_desired_exception =
false;
632 for (
auto & elem :
mesh->active_element_ptr_range())
634 const Point c = elem->vertex_average();
635 if (c(0) < 0.5 && c(1) > 0.5)
640 std::regex msg_regex(
"Trying to add boundary ID 3 which already exists on the ancestors");
641 CPPUNIT_ASSERT(std::regex_search(e.what(), msg_regex));
642 threw_desired_exception =
true;
648 CPPUNIT_ASSERT(threw_desired_exception);
650 threw_desired_exception =
false;
652 for (
auto & elem :
mesh->active_element_ptr_range())
654 const Point c = elem->vertex_average();
655 if (c(0) < 0.5 && c(1) > 0.5)
660 std::regex msg_regex(
"Trying to add boundary ID 3 which already exists on the ancestors");
661 CPPUNIT_ASSERT(std::regex_search(e.what(), msg_regex));
662 threw_desired_exception =
true;
669 CPPUNIT_ASSERT(threw_desired_exception);
673 threw_desired_exception =
false;
674 bi.allow_children_on_boundary_side(
true);
676 for (
auto & elem :
mesh->active_element_ptr_range())
678 const Point c = elem->vertex_average();
679 if (c(0) < 0.5 && c(1) > 0.5)
680 bi.remove_side(elem, 3, 3);
684 std::regex msg_regex(
"We cannot delete boundary ID 3 using a child because it is inherited from an ancestor");
685 CPPUNIT_ASSERT(std::regex_search(e.what(), msg_regex));
686 threw_desired_exception =
true;
693 CPPUNIT_ASSERT(threw_desired_exception);
726 std::vector<boundary_id_type> container;
729 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(2), container.size());
733 std::vector<std::vector<boundary_id_type>> all_bids_container;
735 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(elem->n_sides()), all_bids_container.size());
736 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(2), all_bids_container[3].size());
737 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(3), all_bids_container[3][0]);
738 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(5), all_bids_container[3][1]);
740 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(1), all_bids_container[0].size());
741 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(0), all_bids_container[0][0]);
742 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(1), all_bids_container[1].size());
743 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(1), all_bids_container[1][0]);
744 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(1), all_bids_container[1].size());
745 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(2), all_bids_container[2][0]);
768 for (
auto & elem :
mesh->active_element_ptr_range())
770 const Point c = elem->vertex_average();
773 elem->subdomain_id() = 1;
777 elem->subdomain_id() = 2;
786 for (
auto & elem :
mesh->active_element_ptr_range())
788 const Point c = elem->vertex_average();
789 if (c(0) < 1 && c(0) > 0.5)
795 unsigned int count = 0;
796 for (
auto & elem :
mesh->active_element_ptr_range())
802 CPPUNIT_ASSERT_EQUAL(
static_cast<unsigned int>(2), count);
809 for (
auto & elem :
mesh->active_element_ptr_range())
811 const Point c = elem->vertex_average();
822 for (
auto & elem :
mesh->active_element_ptr_range())
824 const Point c = elem->vertex_average();
841 for (
auto & elem :
mesh->active_element_ptr_range())
843 const Point c = elem->vertex_average();
846 if (c(0) > 0.5 && c(0) < 1 && c(1) < 0.5)
856 for (
auto & elem :
mesh->active_element_ptr_range())
858 const Point c = elem->vertex_average();
887 for (
auto & elem :
mesh->active_element_ptr_range())
895 for (
auto & elem :
mesh->active_element_ptr_range())
897 const Point c = elem->vertex_average();
898 if (c(0) < 0.5 && c(1) > 0.5)
905 for (
auto & elem :
mesh->active_element_ptr_range())
907 const Point c = elem->vertex_average();
908 if (c(0) < 0.5 && c(1) > 0.5)
910 std::vector<boundary_id_type> container;
913 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(2), container.size());
917 std::vector<std::vector<boundary_id_type>> all_bids_container;
919 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(elem->n_sides()), all_bids_container.size());
920 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(2), all_bids_container[3].size());
921 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(5), all_bids_container[3][0]);
922 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(3), all_bids_container[3][1]);
923 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(1), all_bids_container[2].size());
924 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(2), all_bids_container[2][0]);
926 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(0), all_bids_container[0].size());
927 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(0), all_bids_container[1].size());
935 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(elem->n_sides()), all_bids_container.size());
936 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(1), all_bids_container[3].size());
937 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(3), all_bids_container[3][0]);
938 CPPUNIT_ASSERT_EQUAL(
static_cast<std::size_t
>(1), all_bids_container[2].size());
939 CPPUNIT_ASSERT_EQUAL(
static_cast<boundary_id_type>(2), all_bids_container[2][0]);
967 for (
auto & elem :
mesh->active_element_ptr_range())
974 for (
auto & elem :
mesh->active_element_ptr_range())
976 const Point c = elem->vertex_average();
977 if (c(0) < 0.5 && c(1) < 0.5)
989 for (
auto & elem :
mesh->active_element_ptr_range())
991 const Point c = elem->vertex_average();
992 if (c(0) < 0.5 && c(0) > 0.25 && c(1) < 0.25)
1001 for (
auto & elem :
mesh->active_element_ptr_range())
1003 const Point c = elem->vertex_average();
1004 if (c(0) < 0.5 && c(0) > 0.25 && c(1) < 0.25)
1008 CPPUNIT_ASSERT_EQUAL(
static_cast<unsigned int>(1), side_5);
1009 CPPUNIT_ASSERT_EQUAL(
static_cast<unsigned int>(1), side_6);
1016 for (
auto & elem :
mesh->active_element_ptr_range())
1018 const Point c = elem->vertex_average();
1019 if (c(0) < 0.5 && c(0) > 0.25 && c(1) > 0.25 && c(1) < 0.5)
1022 CPPUNIT_ASSERT_EQUAL(
static_cast<unsigned long>(2), sides.size());
1023 CPPUNIT_ASSERT_EQUAL(
static_cast<unsigned int>(1), sides[0]);
1024 CPPUNIT_ASSERT_EQUAL(
static_cast<unsigned int>(2), sides[1]);
1055 for (
const auto & elem :
mesh.element_ptr_range())
1057 for (
auto n : elem->node_index_range())
1059 const Node * node = elem->node_ptr(n);
1060 for (
auto s : {0,2})
1061 if (elem->is_node_on_side(n, s) && !elem->neighbor_ptr(s))
1063 for (
auto s : {1,3})
1094 for (
const auto & elem :
mesh.element_ptr_range())
1096 for (
auto s : {0,2})
1098 if (!elem->neighbor_ptr(s))
1106 for (
auto s : {1,3})
1130 const unsigned int internal_side = 1;
1135 Elem * left_bottom_elem =
nullptr;
1136 for (
auto & elem :
mesh.active_element_ptr_range())
1141 const Point c = elem->vertex_average();
1142 if (c(0) < 0.5 && c(1) < 0.5 && elem->neighbor_ptr(internal_side) !=
nullptr)
1144 left_bottom_elem = elem;
1150 if (left_bottom_elem)
1152 bi.
add_side(left_bottom_elem, internal_side, BID);
1155 CPPUNIT_ASSERT_EQUAL(internal_side, found_side);
CPPUNIT_TEST(testInternalBoundary)
CPPUNIT_TEST(testBoundaryOnChildrenBoundaryIDs)
CPPUNIT_TEST(testShellFaceConstraints)
CPPUNIT_TEST(testEdgeBoundaryConditions)
CPPUNIT_TEST(testBoundaryIDs)
void testSelectiveRenumber()
CPPUNIT_TEST(testBoundaryOnChildrenElementsRefineCoarsen)
void testShellFaceConstraints()
void testBoundaryOnChildrenErrors()
void testBuildSideListFromNodeList()
CPPUNIT_TEST(testBoundaryOnChildrenErrors)
CPPUNIT_TEST(testBoundaryOnChildrenBoundarySides)
CPPUNIT_TEST(testBuildSideListFromNodeList)
CPPUNIT_TEST(testSelectiveRenumber)
CPPUNIT_TEST(testNameCopying)
void testBoundaryOnChildrenElementsRefineCoarsen()
void testEdgeBoundaryConditions()
CPPUNIT_TEST(testBuildNodeListFromSideList)
CPPUNIT_TEST(testRenumber)
void testBuildNodeListFromSideList()
void testBoundaryOnChildrenBoundarySides()
LIBMESH_CPPUNIT_TEST_SUITE(BoundaryInfoTest)
This test ensures various aspects of the BoundaryInfo class work as expected.
void testBoundaryOnChildrenBoundaryIDs()
void testInternalBoundary()
void max(const T &r, T &o, Request &req) const
The BoundaryInfo class contains information relevant to boundary conditions including storing faces,...
std::size_t n_boundary_ids() const
void add_shellface(const dof_id_type elem, const unsigned short int shellface, const boundary_id_type id)
Add shell face shellface of element number elem with boundary id id to the boundary information data ...
std::string & sideset_name(boundary_id_type id)
void side_boundary_ids(const Elem *const elem, std::vector< std::vector< boundary_id_type > > &vec_to_fill) const
void renumber_edge_id(boundary_id_type old_id, boundary_id_type new_id)
Changes all edges with boundary id old_id to instead be labeled by boundary id new_id.
void synchronize_global_id_set()
Synchronizes the boundary_ids set on each processor to determine global_boundary_ids.
void allow_children_on_boundary_side(const bool children_on_boundary)
Whether or not to allow directly setting boundary sides on child elements.
void add_edge(const dof_id_type elem, const unsigned short int edge, const boundary_id_type id)
Add edge edge of element number elem with boundary id id to the boundary information data structure.
void build_side_list_from_node_list(const std::set< boundary_id_type > &nodeset_list={})
Adds sides to a sideset if every node on that side are in the same sideset.
unsigned int side_with_boundary_id(const Elem *const elem, const boundary_id_type boundary_id) const
std::vector< BCTuple > build_side_list(BCTupleSortBy sort_by=BCTupleSortBy::ELEM_ID) const
std::size_t n_edge_conds() const
void remove_node_id(boundary_id_type id, bool global=false)
Removes all nodes with boundary id id from the BoundaryInfo object, removes it from the set of node b...
std::vector< unsigned int > sides_with_boundary_id(const Elem *const elem, const boundary_id_type boundary_id) const
std::vector< NodeBCTuple > build_node_list(NodeBCTupleSortBy sort_by=NodeBCTupleSortBy::NODE_ID) const
bool has_boundary_id(const Node *const node, const boundary_id_type id) const
const std::set< boundary_id_type > & get_edge_boundary_ids() const
void boundary_ids(const Node *node, std::vector< boundary_id_type > &vec_to_fill) const
Fills a user-provided std::vector with the boundary ids associated with Node node.
std::string & nodeset_name(boundary_id_type id)
void remove_id(boundary_id_type id, bool global=false)
Removes all entities (nodes, sides, edges, shellfaces) with boundary id id from their respective cont...
std::size_t n_shellface_conds() const
void remove_side_id(boundary_id_type id, bool global=false)
Removes all sides with boundary id id from the BoundaryInfo object, removes it from the set of side b...
const std::string & get_nodeset_name(boundary_id_type id) const
const std::set< boundary_id_type > & get_boundary_ids() const
const std::set< boundary_id_type > & get_node_boundary_ids() const
void build_node_list_from_side_list(const std::set< boundary_id_type > &sideset_list={})
Adds nodes with boundary ids based on the side's boundary ids they are connected to.
const std::string & get_sideset_name(boundary_id_type id) const
std::string & edgeset_name(boundary_id_type id)
const std::set< boundary_id_type > & get_side_boundary_ids() const
bool is_children_on_boundary_side() const
void renumber_id(boundary_id_type old_id, boundary_id_type new_id)
Changes all entities (nodes, sides, edges, shellfaces) with boundary id old_id to instead be labeled ...
void add_side(const dof_id_type elem, const unsigned short int side, const boundary_id_type id)
Add side side of element number elem with boundary id id to the boundary information data structure.
void renumber_node_id(boundary_id_type old_id, boundary_id_type new_id)
Changes all nodes with boundary id old_id to instead be labeled by boundary id new_id.
void remove_side(const Elem *elem, const unsigned short int side)
Removes all boundary conditions associated with side side of element elem, if any exist.
void renumber_side_id(boundary_id_type old_id, boundary_id_type new_id)
Changes all sides with boundary id old_id to instead be labeled by boundary id new_id.
This class allows one to associate Dirichlet boundary values with a given set of mesh boundary ids an...
void dof_indices(const Elem *const elem, std::vector< dof_id_type > &di) const
void add_dirichlet_boundary(const DirichletBoundary &dirichlet_boundary)
Adds a copy of the specified Dirichlet boundary to the system.
bool is_constrained_dof(const dof_id_type dof) const
processor_id_type processor_id() const
This is the base class from which all geometric element types are derived.
virtual Node *& set_node(const unsigned int i)
const Point & point(const unsigned int i) const
static std::unique_ptr< Elem > build(const ElemType type, Elem *p=nullptr)
This is the EquationSystems class.
virtual void init()
Initialize all the systems.
virtual System & add_system(std::string_view system_type, std::string_view name)
Add the system of type system_type named name to the systems array.
virtual bool is_serial() const
const BoundaryInfo & get_boundary_info() const
The information about boundary ids on the mesh.
virtual const Node * node_ptr(const dof_id_type i) const =0
void allow_renumbering(bool allow)
If false is passed in then this mesh will no longer be renumbered when being prepared for use.
void prepare_for_use(const bool skip_renumber_nodes_and_elements, const bool skip_find_neighbors)
Prepare a newly created (or read) mesh for use.
virtual void write(const std::string &name) const =0
virtual std::unique_ptr< MeshBase > clone() const =0
Virtual "copy constructor".
virtual void read(const std::string &name, void *mesh_data=nullptr, bool skip_renumber_nodes_and_elements=false, bool skip_find_neighbors=false, bool skip_detect_interior_parents=false)=0
Interfaces for reading/writing a mesh to/from a file.
virtual Node * add_point(const Point &p, const dof_id_type id=DofObject::invalid_id, const processor_id_type proc_id=DofObject::invalid_processor_id)=0
Add a new Node at Point p to the end of the vertex array, with processor_id procid.
virtual dof_id_type max_elem_id() const =0
virtual const Elem * query_elem_ptr(const dof_id_type i) const =0
virtual Elem * add_elem(Elem *e)=0
Add elem e to the end of the element array.
dof_id_type n_active_local_elem() const
Implements (adaptive) mesh refinement algorithms for a MeshBase.
bool coarsen_elements()
Only coarsens the user-requested elements.
bool refine_elements()
Only refines the user-requested elements.
The Mesh class is a thin wrapper, around the ReplicatedMesh class by default.
A Node is like a Point, but with more information.
A class to stub for features that should be in libMesh, but haven't been written yet,...
processor_id_type processor_id() const
const Parallel::Communicator & comm() const
A Point defines a location in LIBMESH_DIM dimensional Real space.
Manages consistently variables, degrees of freedom, and coefficient vectors.
unsigned int add_variable(std::string_view var, const FEType &type, const std::set< subdomain_id_type > *const active_subdomains=nullptr)
Adds the variable var to the list of variables for this system.
dof_id_type n_constrained_dofs() const
const DofMap & get_dof_map() const
ConstFunction that simply returns 0.
Communicator * TestCommWorld
The libMesh namespace provides an interface to certain functionality in the library.
CPPUNIT_TEST_SUITE_REGISTRATION(BoundaryInfoTest)