2350 LOG_SCOPE (
"project_edges",
"GenericProjector");
2354 for (
const auto & e_pair : range)
2356 const Elem & elem = *std::get<0>(e_pair.second);
2360 #ifdef LIBMESH_ENABLE_AMR 2361 if (
f.is_grid_projection() &&
2367 #endif // LIBMESH_ENABLE_AMR 2369 const Node & edge_node = *e_pair.first;
2370 const int dim = elem.dim();
2371 const var_set & edge_vars = std::get<2>(e_pair.second);
2373 const unsigned short edge_num = std::get<1>(e_pair.second);
2374 const unsigned short node_num = elem.n_vertices() + edge_num;
2382 for (
const auto & var : edge_vars)
2385 const FEType & base_fe_type = variable.
type();
2386 const unsigned int var_component =
2389 if (base_fe_type.family ==
SCALAR)
2392 FEType fe_type = base_fe_type;
2395 fe_type.order = fe_type.order + elem.p_level();
2402 if (fe_type.order > 1)
2405 edge_node.processor_id();
2406 FValue fval =
f.eval_at_point
2415 edge_node.dof_number(sys_num, var, i);
2419 const auto insert_val =
2420 raw_value<typename ProjectionAction::InsertInput>(fval, i);
2428 edge_node.dof_number(sys_num, var, 0);
2435 #ifdef LIBMESH_ENABLE_AMR 2443 #endif // LIBMESH_ENABLE_AMR 2446 FEGenericBase<typename FFunctor::RealType> * fe =
nullptr;
2448 FEGenericBase<typename FFunctor::RealType> * edge_fe =
nullptr;
2453 const FEGenericBase<typename FFunctor::RealType> & proj_fe =
2454 #ifdef LIBMESH_ENABLE_AMR 2460 #ifdef LIBMESH_ENABLE_AMR 2463 std::vector<Point> fine_points;
2465 std::unique_ptr<FEGenericBase<typename FFunctor::RealType>> fine_fe
2468 std::unique_ptr<QBase> qrule
2469 (base_fe_type.default_quadrature_rule(1));
2470 fine_fe->attach_quadrature_rule(qrule.get());
2472 const std::vector<Point> & child_xyz =
2475 for (
unsigned int c = 0, nc = elem.n_children();
2481 fine_fe->edge_reinit(elem.child_ptr(c),
context.
edge);
2482 fine_points.insert(fine_points.end(),
2487 std::vector<Point> fine_qp;
2493 #endif // LIBMESH_ENABLE_AMR 2496 const std::vector<dof_id_type> & dof_indices =
2499 std::vector<unsigned int> edge_dofs;
2504 (dof_indices, edge_dofs, var_component,
2505 &edge_node, proj_fe);
Real time
For time-dependent problems, this is the time t at the beginning of the current timestep.
unsigned int variable_scalar_number(std::string_view var, unsigned int component) const
const Variable & variable(unsigned int var) const
Return a constant reference to Variable var.
virtual void pre_fe_reinit(const System &, const Elem *e)
Reinitializes local data vectors/matrices on the current geometric element.
void construct_projection(const std::vector< dof_id_type > &dof_indices_var, const std::vector< unsigned int > &involved_dofs, unsigned int var_component, const Node *node, const FEGenericBase< typename FFunctor::RealType > &fe)
void get_edge_fe(unsigned int var, FEGenericBase< OutputShape > *&fe) const
Accessor for edge (3D only!) finite element object for variable var.
static Point inverse_map(const unsigned int dim, const Elem *elem, const Point &p, const Real tolerance=TOLERANCE, const bool secure=true, const bool extra_checks=true)
static void dofs_on_edge(const Elem *const elem, const unsigned int dim, const FEType &fe_t, unsigned int e, std::vector< unsigned int > &di, const bool add_p_level=true)
Fills the vector di with the local degree of freedom indices associated with edge e of element elem A...
void insert_id(dof_id_type id, const InsertInput &val, processor_id_type pid)
virtual void elem_fe_reinit(const std::vector< Point > *const pts=nullptr)
Reinitializes interior FE objects on the current geometric element.
unsigned char edge
Current edge for edge_* to examine.
uint8_t processor_id_type
unsigned int number() const
static std::unique_ptr< FEGenericBase > build(const unsigned int dim, const FEType &type)
Builds a specific finite element type.
const std::vector< dof_id_type > & get_dof_indices() const
Accessor for element dof indices.
virtual void edge_fe_reinit()
Reinitializes edge FE objects on the current geometric element.
void find_dofs_to_send(const Node &node, const Elem &elem, unsigned short node_num, const var_set &vars)
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...
std::set< unsigned int > var_set
void get_element_fe(unsigned int var, FEGenericBase< OutputShape > *&fe) const
Accessor for interior finite element object for variable var for the largest dimension in the mesh...
const FEType & type() const