21#include "libmesh/elem.h"
22#include "libmesh/enum_to_string.h"
23#include "libmesh/fe.h"
24#include "libmesh/fe_interface.h"
25#include "libmesh/fe_lagrange_gll_shape_1D.h"
26#include "libmesh/fe_macro.h"
48 libmesh_assert_greater (o, 0);
50 const unsigned int n =
static_cast<unsigned int>(o) + 1;
53 "The LAGRANGE_GLL basis of order " << o <<
" needs " << n
54 <<
" Gauss-Lobatto points. The table has at most "
72 libmesh_error_msg_if(o >
FIRST,
73 "The LAGRANGE_GLL basis of order " << o <<
" puts " << o - 1
74 <<
" degrees of freedom on each edge. "
76 "Use QUAD8 or QUAD9.");
77 libmesh_fallthrough();
86 libmesh_error_msg_if(o >
FIRST,
87 "The LAGRANGE_GLL basis of order " << o
88 <<
" puts degrees of freedom on the edges and faces of a hexahedron. "
89 "HEX8 has no edge or face nodes. Use HEX27.");
90 libmesh_fallthrough();
92 libmesh_error_msg_if(o >
FIRST,
93 "The LAGRANGE_GLL basis of order " << o <<
" puts " << (o - 1)*(o - 1)
94 <<
" degrees of freedom on each face. HEX20 has no face nodes. "
96 libmesh_fallthrough();
104 libmesh_error_msg(
"The LAGRANGE_GLL basis is a tensor product. It does not support "
126 const unsigned int n)
128 libmesh_assert_greater (o, 0);
130 const unsigned int per_edge =
static_cast<unsigned int>(o) - 1;
140 return (n < 2) ? 1 : 0;
144 libmesh_assert_less (n, 4);
145 libmesh_fallthrough();
157 libmesh_assert_less (n, 8);
158 libmesh_fallthrough();
166 return per_edge * per_edge;
173 libmesh_error_msg(
"The LAGRANGE_GLL basis is a tensor product. It does not support "
184 libmesh_assert_greater (o, 0);
186 const unsigned int per_edge =
static_cast<unsigned int>(o) - 1;
205 return per_edge * per_edge;
210 return per_edge * per_edge * per_edge;
213 libmesh_error_msg(
"The LAGRANGE_GLL basis is a tensor product. It does not support "
227 const std::vector<Number> & elem_soln,
228 std::vector<Number> & nodal_soln,
229 const bool add_p_level)
237 const unsigned int n_sf =
240 std::vector<Point> refspace_nodes;
242 libmesh_assert_equal_to (refspace_nodes.size(),
n_nodes);
243 libmesh_assert_equal_to (elem_soln.size(), n_sf);
245 std::fill(nodal_soln.begin(), nodal_soln.end(), 0);
249 nodal_soln[n] += elem_soln[i] *
307#ifdef LIBMESH_ENABLE_AMR
311 const unsigned int variable_number,
313{ compute_proj_constraints(constraints, dof_map, variable_number, elem); }
318 const unsigned int variable_number,
320{ compute_proj_constraints(constraints, dof_map, variable_number, elem); }
The constraint matrix storage format.
This class handles the numbering of degrees of freedom on a mesh.
This is the base class from which all geometric element types are derived.
virtual unsigned int n_nodes() const =0
virtual ElemType type() const =0
static void get_refspace_nodes(const ElemType t, std::vector< Point > &nodes)
static Real shape(const unsigned int dim, const FEType &fe_t, const ElemType t, const unsigned int i, const Point &p)
static unsigned int n_shape_functions(const unsigned int dim, const FEType &fe_t, const ElemType t)
class FEType hides (possibly multiple) FEFamily and approximation orders, thereby enabling specialize...
virtual bool is_hierarchic() const override
static unsigned int n_dofs_per_elem(const ElemType t, const Order o)
virtual FEContinuity get_continuity() const override
static void compute_constraints(DofConstraints &constraints, DofMap &dof_map, const unsigned int variable_number, const Elem *elem)
Computes the constraint matrix contributions (for non-conforming adapted meshes) corresponding to var...
static unsigned int n_dofs(const ElemType t, const Order o)
static unsigned int n_dofs_at_node(const ElemType t, const Order o, const unsigned int n)
virtual bool shapes_need_reinit() const override
std::string enum_to_string(const T e)
The libMesh namespace provides an interface to certain functionality in the library.
LIBMESH_FE_NODAL_SOLN(BERNSTEIN, bernstein_nodal_soln)
ElemType
Defines an enum for geometric element types.
unsigned int lagrange_gll_n_dofs(const ElemType t, const Order o)
unsigned int lagrange_gll_n_dofs_per_elem(const ElemType t, const Order o)
unsigned int lagrange_gll_n_dofs_at_node(const ElemType t, const Order o, const unsigned int n)
constexpr unsigned int fe_lagrange_gll_max_points_1D
The number of points in the largest Gauss-Lobatto rule that QGaussLobatto tabulates,...
void lagrange_gll_nodal_soln(const Elem *elem, const Order order, const std::vector< Number > &elem_soln, std::vector< Number > &nodal_soln, const bool add_p_level)
Evaluates a solution at the nodes of elem.
IntRange< T > make_range(T beg, T end)
The 2-parameter make_range() helper function returns an IntRange<T> when both input parameters are of...
LIBMESH_FE_SIDE_NODAL_SOLN(HIERARCHIC_VEC)
const dof_id_type n_nodes