15 , m_cofaces_type(cofaces_type)
16 , m_tdc_itrbl(mesh, simplex, cofaces_type != mesh.top_simplex_type())
17 , m_it_end(m_tdc_itrbl.end())
25 : m_container(container)
26 , m_it(container.m_tdc_itrbl, t)
28 if ((*m_it).is_null()) {
37 if (m_container.m_simplex.primitive_type() == m_container.m_cofaces_type) {
43 return step_depth_3();
52 return *m_it != *other;
67 const Mesh& mesh = m_container.m_mesh;
77 return m_container.m_mesh.top_cell_dimension() ==
83 if (depth() == 3 && !is_coface_d0()) {
84 const Mesh& mesh = m_container.m_mesh;
85 const PrimitiveType& cofaces_type = m_container.m_cofaces_type;
87 m_container.m_visited_cofaces.is_visited(mesh.
get_id_simplex(*m_it, cofaces_type));
93 const Mesh& mesh = m_container.m_mesh;
95 const PrimitiveType& cofaces_type = m_container.m_cofaces_type;
96 auto& visited = m_container.m_visited_cofaces;
98 if (!is_coface_d0()) {
102 while (!(*m_it).is_null()) {
103 for (; m_edge_counter < 3; ++m_edge_counter) {
104 if (!visited.is_visited(mesh.
get_id_simplex(*m_it, cofaces_type))) {
Tuple switch_tuples(const Tuple &tuple, const ContainerType &op_sequence) const
int64_t top_cell_dimension() const
simplex::IdSimplex get_id_simplex(const Tuple &tuple, PrimitiveType pt) const
Retrieve the IdSimplex that is represented by the tuple and primitive type.
The Tuple is the basic navigation tool in our mesh data structure.
int64_t depth()
Compute the depth from the mesh and the simplex type.
Iterator & step_depth_3()
Use breadth first search to find all d-simplices, and iterate through all cofaces in a d-simplex.
void init()
Depending on the depth, the iterator must be initialized differently.
bool operator!=(const Iterator &other) const
Iterator(CofacesSingleDimensionIterable &container, const Tuple &t=Tuple())
bool is_coface_d0()
Check if coface type is the mesh's top simplex type.
This iterator internally uses TopDimensionCofacesIterable.
CofacesSingleDimensionIterable(const Mesh &mesh, const Simplex &simplex, const PrimitiveType cofaces_type)
PrimitiveType primitive_type() const
constexpr int8_t get_primitive_type_id(PrimitiveType t)
Get a unique integer id corresponding to each primitive type.