16 , m_tdc_itrbl(mesh, simplex, true)
17 , m_it_end(m_tdc_itrbl.end())
21 : m_container(container)
22 , m_mesh(container.m_mesh)
23 , m_it(container.m_tdc_itrbl, t)
33 m_phase = IteratorPhase::OpenStar;
42 return step_depth_3();
47 if (m_phase == IteratorPhase::Faces) {
53 m_phase = IteratorPhase::OpenStar;
68 default: assert(
false);
break;
79 return (m_t != other.
m_t) || (m_pt != other.
m_pt);
106 auto& visited_c = m_container.m_visited_cofaces;
107 auto& visited_l = m_container.m_visited_link;
114 if (m_phase == IteratorPhase::OpenStar) {
117 m_t = navigate_to_link(*m_it);
120 m_phase = IteratorPhase::Link;
123 for (; m_face_counter < 3; ++m_face_counter) {
124 for (; m_pt < 3; ++m_pt) {
125 if (!visited_c[m_pt - 1].is_visited(
139 if (m_phase == IteratorPhase::Link) {
142 m_phase = IteratorPhase::OpenStar;
153 for (; m_face_counter < 3; ++m_face_counter) {
154 for (; m_pt < 2; ++m_pt) {
155 if (!visited_l[m_pt].is_visited(
176 switch (m_face_counter) {
177 case 1: m_pt = 1;
return *
this;
208 if (m_it.is_intermediate() && m_face_counter == 2) {
214 switch (m_face_counter) {
215 case 1: m_pt = 1;
return *
this;
216 case 2: m_pt = 2;
return *
this;
221 case 4: m_pt = 1;
return *
this;
228 switch (m_face_counter) {
229 case 1: m_pt = 2;
return *
this;
238 case 4: m_pt = 1;
return *
this;
246 default: assert(
false);
break;
273 if (m_it.is_intermediate() && m_face_counter == 5) {
277 switch (m_face_counter) {
278 case 1: m_pt = 2;
return *
this;
283 case 3: m_pt = 1;
return *
this;
286 case 6: m_pt = 2;
return *
this;
288 case 8: m_pt = 3;
return *
this;
295 switch (m_face_counter) {
296 case 1: m_pt = 3;
return *
this;
301 case 3: m_pt = 1;
return *
this;
302 case 4: m_pt = 2;
return *
this;
307 case 6: m_pt = 2;
return *
this;
312 case 8: m_pt = 2;
return *
this;
359 for (int8_t j = s; j > -1; --j) {
360 for (int8_t i = 0; i < m - s; ++i) {
371 switch (m_container.m_simplex.primitive_type()) {
376 default: assert(
false);
383 if (m_face_counter == 2) {
396 if (m_face_counter == 3) {
412 switch (m_face_counter) {
413 case 0: m_pt = 0;
break;
414 case 1: m_pt = 1;
break;
419 case 3: m_pt = 1;
break;
424 case 5: m_pt = 1;
break;
425 case 6: m_pt = 2;
break;
430 case 8: m_pt = 1;
break;
431 case 9: m_pt = 2;
break;
436 case 11: m_pt = 2;
break;
441 case 13: m_pt = 2;
break;
442 default:
return false;
Tuple switch_tuples(const Tuple &tuple, const ContainerType &op_sequence) const
int64_t top_cell_dimension() const
virtual Tuple switch_tuple(const Tuple &tuple, PrimitiveType type) const =0
switch the orientation of the Tuple of the given dimension
simplex::IdSimplex get_id_simplex(const Tuple &tuple, PrimitiveType pt) const
Retrieve the IdSimplex that is represented by the tuple and primitive type.
PrimitiveType top_simplex_type() const
bool is_null() const
Checks if a tuple is "null". This merely implies the global index is -1.
Iterator & step_edge_mesh()
Iterator & step_depth_3()
Use breadth first search to find all d-simplices, and iterate through all cofaces in a d-simplex.
Tuple navigate_to_link(Tuple t)
bool operator!=(const Iterator &other) const
int64_t depth()
Compute the depth from the mesh and the simplex type.
Iterator(ClosedStarIterable &container, const Tuple &t=Tuple())
void init()
Depending on the depth, the iterator must be initialized differently.
bool step_faces_triangle()
Iterator & step_tri_mesh()
Iterator & step_tet_mesh()
bool step_faces_tetrahedron()
This iterator internally uses TopDimensionCofacesIterable.
ClosedStarIterable(const Mesh &mesh, const Simplex &simplex)
PrimitiveType primitive_type() const
constexpr wmtk::PrimitiveType PF
constexpr PrimitiveType get_primitive_type_from_id(int8_t id)
Get the primitive type corresponding to its unique integer id.
constexpr PrimitiveType PV
constexpr int8_t get_primitive_type_id(PrimitiveType t)
Get a unique integer id corresponding to each primitive type.
constexpr PrimitiveType PE