20 #include "libmesh/cell_tet.h" 21 #include "libmesh/cell_tet4.h" 22 #include "libmesh/face_tri3.h" 23 #include "libmesh/enum_elem_quality.h" 76 libmesh_assert_less (s, this->
n_sides());
87 libmesh_assert_less (s, this->
n_sides());
97 unsigned int side_node)
const 99 libmesh_assert_less (side, this->
n_sides());
108 unsigned int edge_node)
const 110 libmesh_assert_less (edge, this->
n_edges());
119 libmesh_assert_less (i, this->
n_sides());
121 std::unique_ptr<Elem> face = std::make_unique<Tri3>();
123 for (
auto n : face->node_index_range())
132 const unsigned int i)
134 this->simple_side_ptr<Tet,Tet4>(side, i,
TRI3);
149 #ifdef LIBMESH_ENABLE_AMR 153 const unsigned int s,
154 const unsigned int checked_nodes[][3])
const 157 libmesh_assert_less (s, this->
n_sides());
161 for (
unsigned int i = 0; i != 3; ++i)
176 const unsigned int node_facing_side[4] = {3, 2, 0, 1};
177 const unsigned int n = node_facing_side[s];
182 Real embedding_sum = 0.;
183 for (
unsigned i=0; i<3; ++i)
184 embedding_sum += std::abs(this->
embedding_matrix(c, checked_nodes[n][i], n));
186 return ( std::abs(embedding_sum) < 1.e-3 );
193 const unsigned int [][3])
const 195 libmesh_not_implemented();
199 #endif //LIBMESH_ENABLE_AMR 213 std::array<Real, 3> D = {diag_02_13, diag_03_12, diag_01_23};
223 const unsigned int s)
const 225 libmesh_assert_less (e, this->
n_edges());
226 libmesh_assert_less (s, this->
n_sides());
235 libmesh_assert_less (e, this->
n_edges());
250 std::vector<unsigned int>
253 libmesh_assert_less(n, this->
n_nodes());
279 std::pair<Real, Real> bounds;
309 bounds.second = 1.414;
313 libMesh::out <<
"Warning: Invalid quality measure chosen." << std::endl;
324 const Real eps)
const 326 const Real & xi = p(0);
327 const Real & eta = p(1);
328 const Real & zeta = p(2);
332 return ((xi >= 0.-eps) &&
335 ((xi + eta + zeta) <= 1.+eps));
virtual bool is_edge_on_side(const unsigned int e, const unsigned int s) const override final
virtual Real quality(const ElemQuality q) const override
static const unsigned int edge_sides_map[6][2]
This maps each edge to the sides that contain said edge.
virtual bool is_face(const unsigned int i) const =0
virtual unsigned int local_side_node(unsigned int side, unsigned int side_node) const override
virtual dof_id_type key() const
static const unsigned int side_nodes_map[num_sides][nodes_per_side]
This maps the node of the side to element node numbers.
virtual unsigned int n_sides() const override final
static const int num_sides
Geometric constants for all Tets.
Diagonal
This enumeration keeps track of which diagonal is selected during refinement.
static const int num_edges
virtual unsigned int n_children() const override final
Diagonal _diagonal_selection
The currently-selected diagonal used during refinement.
The libMesh namespace provides an interface to certain functionality in the library.
virtual std::pair< Real, Real > qual_bounds(const ElemQuality q) const override
virtual bool is_flipped() const override final
Real distance(const Point &p)
static const unsigned int adjacent_edges_map[4][3]
This maps the node to the (in this case) 3 edge ids adjacent to the node.
virtual unsigned int local_edge_node(unsigned int edge, unsigned int edge_node) const override
virtual Real embedding_matrix(const unsigned int child_num, const unsigned int child_node_num, const unsigned int parent_node_num) const =0
static const Real _master_points[14][3]
Master element node locations.
virtual unsigned int n_vertices() const override final
virtual bool on_reference_element(const Point &p, const Real eps=TOLERANCE) const override final
T triple_product(const TypeVector< T > &a, const TypeVector< T > &b, const TypeVector< T > &c)
static const int nodes_per_side
virtual dof_id_type low_order_key(const unsigned int s) const override
virtual unsigned int n_nodes() const =0
virtual std::unique_ptr< Elem > side_ptr(const unsigned int i) override final
virtual unsigned int n_edges() const override final
ElemQuality
Defines an enum for element quality metrics.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
virtual bool is_vertex(const unsigned int i) const =0
virtual Real quality(const ElemQuality q) const
void select_diagonal(const Diagonal diag) const
Allows the user to select the diagonal for the refinement.
virtual std::vector< unsigned int > sides_on_edge(const unsigned int e) const override final
void choose_diagonal() const
Derived classes use this function to select an initial diagonal during refinement.
static const int num_children
static const unsigned int edge_nodes_map[num_edges][nodes_per_edge]
This maps the node of the edge to element node numbers.
static dof_id_type compute_key(dof_id_type n0)
bool is_child_on_side_helper(const unsigned int c, const unsigned int s, const unsigned int checked_nodes[][3]) const
Called by descendant classes with appropriate data to determine if child c is on side s...
A Point defines a location in LIBMESH_DIM dimensional Real space.
dof_id_type node_id(const unsigned int i) const
const Point & point(const unsigned int i) const
static const int nodes_per_edge
virtual bool is_edge(const unsigned int i) const =0
virtual std::vector< unsigned int > edges_adjacent_to_node(const unsigned int n) const override