![]() |
Vulpes
0.1.0
Versatile and parallel compUtational Library for high-order discontinuous Polytopal Element Simulations
|
Manages geometrical information about the cell and its mapping to the reference element. More...
#include <cell_manager.hpp>
Classes | |
| struct | NeighInfo |
| Information about the neighbouring cell for a certain face. More... | |
Public Types | |
| using | index_t = typename MeshType::index_t |
| using | FeType = FeSpaceType |
| using | CellType = geometry::Cell<dim, double, index_t> |
| using | MappingType = std::decay_t<decltype(FeType::getMapping(CellType{}))> |
Public Member Functions | |
| CellManager (const MeshType &mesh, const FeSpaceType &fe_space) | |
| Construct a new Cell Manager object. | |
| const auto & | getFeSpace () const |
| Get the finite element space associated to this cell manager. | |
| const auto & | getMesh () const |
| Get the underlying mesh. | |
| const CellType & | getCell (index_t cell_id) |
| Get and build lazily the cells of the mesh. | |
| const auto & | getMapping (index_t cell_id) const |
| Get the geometrical mapping of the reference element to physical element. | |
| const auto & | getCells () const |
| Access the underlying memory buffer for cells (some might be empty). | |
| NeighInfo | findCellNeigh (index_t cell_id, index_t loc_face_id) |
| Find the cell id of the neighbour of a cell given the face id in local cell enumeration. | |
| Eigen::Array< double, MeshType::self_dim, 1 > | getPeriodicShift (index_t neigh_cell_id, index_t current_cell_id) const |
| Get the periodic shift needed for neighbor cell coordinate transformation. | |
Static Public Attributes | |
| static constexpr std::size_t | dim = MeshType::self_dim |
Protected Attributes | |
| const MeshType & | m_mesh |
| const FeType & | m_fe_space |
| std::vector< std::unique_ptr< CellType > > | m_cells |
| std::vector< bool > | m_cell_is_normalized |
| std::vector< std::unique_ptr< MappingType > > | m_mappings |
| datastructure::CrsMap< NeighInfo, index_t > | m_cell_to_facet_neigh |
| For each facet of each cell store the info about its neighbour The map is built lazily, the skeleton is stolen from the cell to facet map of the mesh, so that we do not have to pass in uncompressed format. | |
Manages geometrical information about the cell and its mapping to the reference element.
This class constructs lazily all the cells of a mesh (in a mesh all cells are represented implicitly). This requires a lot of extra memory, but having contiguous information (e.g., for vertices) significantly improves the speed of the code. The cells are initialized by building all the extra information required by the finite element space, namely the cellInitOptions() static method that all finite elements type must implement. The cells are then mapped to the reference element and the mapping is stored. This class also offers the possibility to query the neighbour of the cell in local cell enumeration, which is more costly to do in global mesh enumeration.
| using vulpes::assemble::CellManager< MeshType, FeSpaceType >::CellType = geometry::Cell<dim, double, index_t> |
| using vulpes::assemble::CellManager< MeshType, FeSpaceType >::FeType = FeSpaceType |
| using vulpes::assemble::CellManager< MeshType, FeSpaceType >::index_t = typename MeshType::index_t |
| using vulpes::assemble::CellManager< MeshType, FeSpaceType >::MappingType = std::decay_t<decltype(FeType::getMapping(CellType{}))> |
|
inline |
Construct a new Cell Manager object.
| mesh | The mesh to manage |
| fe_space | The finite element space associated to this cell manager |
|
inline |
Find the cell id of the neighbour of a cell given the face id in local cell enumeration.
| cell_id | Cell id of the considered cell, in mesh (local MPI) enumeration |
| loc_face_id | Face id in local cell enumeration (of the cell pointed by cell_id) |
|
inline |
Get and build lazily the cells of the mesh.
| cell_id | Cell id of the considered cell in mesh (local MPI) enumeration |
|
inline |
Access the underlying memory buffer for cells (some might be empty).
|
inline |
Get the finite element space associated to this cell manager.
|
inline |
Get the geometrical mapping of the reference element to physical element.
| cell_id | Cell id of the considered cell in mesh (local MPI) enumeration |
|
inline |
Get the underlying mesh.
|
inline |
Get the periodic shift needed for neighbor cell coordinate transformation.
| neigh_cell_id | Neighbor cell ID |
| current_cell_id | Current cell ID |
Extracts period values from mesh metadata and delegates geometric calculation to geometry::computePeriodicShift. Returns zero if cells are not initialized.
|
inlinestaticconstexpr |
|
protected |
|
protected |
For each facet of each cell store the info about its neighbour The map is built lazily, the skeleton is stolen from the cell to facet map of the mesh, so that we do not have to pass in uncompressed format.
|
protected |
|
protected |
|
protected |
|
protected |