57 {
59
63
64
69
70
72
73
74
76
78
80 (point_neighbor_coupling);
81
82 const unsigned int n_elem_per_side = 5;
83 const std::unique_ptr<Elem> test_elem =
Elem::build(elem_type);
84 const unsigned int ymax = test_elem->dim() > 1;
85 const unsigned int zmax = test_elem->dim() > 2;
86 const unsigned int ny = ymax * n_elem_per_side;
87 const unsigned int nz = zmax * n_elem_per_side;
88
90 n_elem_per_side,
91 ny,
92 nz,
93 0., 1.,
94 0., ymax,
95 0., zmax,
96 elem_type);
97
98 es.init();
100
101 for (
const auto & elem :
mesh.active_local_element_ptr_range())
102 for (unsigned
int s1=0; s1 != elem->n_neighbors(); ++s1)
103 {
105 if (!n1)
106 continue;
107
109
110
111
113 continue;
114
115 for (unsigned int s2=0; s2 != elem->n_neighbors(); ++s2)
116 {
118 if (!n2 ||
120 continue;
121
123
124 for (unsigned int s3=0; s3 != elem->n_neighbors(); ++s3)
125 {
127 if (!n3 ||
129 continue;
130
132
134
135 LIBMESH_ASSERT_NUMBERS_EQUAL(sys.
point_value(0,p,n3),
138 }
139 }
140 }
141 }
void ErrorVector unsigned int
void remove_coupling_functor(GhostingFunctor &coupling_functor)
Removes a functor which was previously added to the set of coupling functors, from both this DofMap a...
void remove_algebraic_ghosting_functor(GhostingFunctor &evaluable_functor)
Removes a functor which was previously added to the set of algebraic ghosting functors,...
DefaultCoupling & default_coupling()
Default coupling functor.
DefaultCoupling & default_algebraic_ghosting()
Default algebraic ghosting functor.
void add_algebraic_ghosting_functor(GhostingFunctor &evaluable_functor, bool to_mesh=true)
Adds a functor which can specify algebraic ghosting requirements for use with distributed vectors.
bool is_evaluable(const DofObjectSubclass &obj, unsigned int var_num=libMesh::invalid_uint) const
processor_id_type processor_id() const
This is the base class from which all geometric element types are derived.
static std::unique_ptr< Elem > build(const ElemType type, Elem *p=nullptr)
const Elem * neighbor_ptr(unsigned int i) const
Point vertex_average() const
This is the EquationSystems class.
The Mesh class is a thin wrapper, around the ReplicatedMesh class by default.
processor_id_type processor_id() const
This class implements ghosting of point neighbors (elements on the same manifold that share points),...
void set_dof_coupling(const CouplingMatrix *dof_coupling)
void set_n_levels(unsigned int n_levels)
A Point defines a location in LIBMESH_DIM dimensional Real space.
Manages consistently variables, degrees of freedom, and coefficient vectors.
void project_solution(FunctionBase< Number > *f, FunctionBase< Gradient > *g=nullptr, std::optional< ConstElemRange > active_local_range=std::nullopt, std::optional< std::vector< unsigned int > > variable_numbers=std::nullopt) const
Projects arbitrary functions onto the current solution.
Number point_value(unsigned int var, const Point &p, const bool insist_on_success=true, const NumericVector< Number > *sol=nullptr) const
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.
const DofMap & get_dof_map() const
static constexpr Real TOLERANCE
Number cubic_point_neighbor_coupling_test(const Point &p, const Parameters &, const std::string &, const std::string &)