9#include <kernel/geometry/intern/congruency_mapping.hpp>
10#include <kernel/geometry/intern/face_index_mapping.hpp>
32 static_assert(cell_dim_ < Shape_::dimension,
"invalid cell dimension");
33 static_assert(face_dim_ < cell_dim_,
"invalid cell/face dimension");
34 static_assert(face_dim_ >= 0,
"invalid face dimension");
37 typedef typename Shape::FaceTraits<Shape_, cell_dim_>::ShapeType CellType;
39 template<
typename Outer_>
47 explicit CompIndexMap(
56 Index operator[](
int i)
const
58 typedef FaceIndexMapping<Shape_, cell_dim_, 0> LimType;
59 return _outer[LimType::map(_idx,i)];
64 static constexpr int num_cells = Shape::FaceTraits<Shape_, cell_dim_>::count;
67 int _cell_orient[num_cells];
74 explicit SubIndexMapping(
75 const ShapeVerts_& shape_verts,
76 const ShapeCells_& shape_cells,
77 const CellVerts_& cell_verts)
79 typedef CongruencySampler<CellType> SamplerType;
82 for(
int cell(0); cell < num_cells; ++cell)
84 CompIndexMap<ShapeVerts_> comp_index_map(shape_verts, cell);
85 _cell_orient[cell] = SamplerType::compare(comp_index_map, cell_verts[shape_cells[cell]]);
89 Index map(
int cell,
int face)
const
91 return Index(CongruencyMapping<CellType, face_dim_>::map(_cell_orient[cell], face));
std::uint64_t Index
Index data type.