Info on the faces of a specific direction X, Y, or Z of a structured mesh. More...
#include <arcane/cartesianmesh/FaceDirectionMng.h>
Classes | |
| class | Impl |
Public Member Functions | |
| FaceDirectionMng () | |
| Creates an empty instance. | |
| DirFace | face (Face f) const |
| Direction face corresponding to face f. | |
| DirFace | face (FaceLocalId f) const |
| Direction face corresponding to face f. | |
| __host__ __device__ DirFaceLocalId | dirFaceId (FaceLocalId f) const |
| Direction face corresponding to face f. | |
| FaceGroup | allFaces () const |
| Group of all faces in the direction. | |
| FaceGroup | overlapFaces () const |
| Group of all overlap faces in the direction. | |
| FaceGroup | inPatchFaces () const |
| Group of all faces within the patch in the direction. | |
| FaceGroup | innerFaces () const |
| Group of all internal faces in the direction. | |
| FaceGroup | outerFaces () const |
| Group of all external faces in the direction. | |
| DirFace | operator[] (Face f) const |
| Direction face corresponding to face f. | |
| DirFace | operator[] (FaceLocalId f) const |
| Direction face corresponding to face f. | |
| DirFace | operator[] (FaceEnumerator iface) const |
| Direction face corresponding to the face iterator iface. | |
| eMeshDirection | direction () const |
| Direction value. | |
Private Types | |
| using | ItemDirectionInfo = impl::CartesianItemDirectionInfo |
Private Member Functions | |
| DirFace | _face (Int32 local_id) const |
| Direction face corresponding to local face number local_id. | |
| __host__ __device__ DirFaceLocalId | _dirFaceId (FaceLocalId local_id) const |
| Direction face corresponding to local face number local_id. | |
| void | _internalComputeInfos (const CellDirectionMng &cell_dm, const VariableCellReal3 &cells_center, const VariableFaceReal3 &faces_center) |
| Calculates the information on faces associated with the cells in the direction cell_dm. Assumes that _internalInit() has been called. | |
| void | _internalComputeInfos (const CellDirectionMng &cell_dm) |
| void | _internalInit (ICartesianMesh *cm, eMeshDirection dir, Integer patch_index) |
| void | _internalDestroy () |
| void | _internalResizeInfos (Int32 new_size) |
| Resizes the container holding the ItemDirectionInfo. | |
| void | _computeCellInfos (const CellDirectionMng &cell_dm, const VariableCellReal3 &cells_center, const VariableFaceReal3 &faces_center) |
| Calculates the cells before and after a face, in a given direction. | |
| void | _computeCellInfos () const |
| bool | _hasFace (Cell cell, Int32 face_local_id) const |
Private Attributes | |
| friend | CartesianMeshImpl |
| friend | CartesianMeshPatch |
| SmallSpan< ItemDirectionInfo > | m_infos_view |
| CellInfoListView | m_cells |
| eMeshDirection | m_direction |
| Impl * | m_p |
Info on the faces of a specific direction X, Y, or Z of a structured mesh.
Definition at line 114 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
|
private |
Definition at line 122 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
| Arcane::FaceDirectionMng::FaceDirectionMng | ( | ) |
Creates an empty instance.
The instance is not valid until _internalInit() has been called.
Definition at line 63 of file FaceDirectionMng.cc.
References Arcane::MD_DirInvalid.
|
private |
Definition at line 378 of file FaceDirectionMng.cc.
|
private |
Calculates the cells before and after a face, in a given direction.
To be independent of how the mesh is created, we use the coordinates of the face centers and the cell centers.
Definition at line 292 of file FaceDirectionMng.cc.
References Arcane::CellDirectionMng::allCells(), Arcane::Cell, ENUMERATE_CELL, ENUMERATE_FACE, face(), Arcane::Cell::level(), Arcane::Item::localId(), Arcane::MD_DirX, Arcane::MD_DirY, Arcane::MD_DirZ, Arcane::Item::null(), Arcane::Real3POD::x, Arcane::Real3POD::y, and Arcane::Real3POD::z.
Referenced by _internalComputeInfos(), and _internalComputeInfos().
|
inlineprivate |
Direction face corresponding to local face number local_id.
Definition at line 245 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References Arcane::impl::CartesianItemDirectionInfo::m_next_lid, and Arcane::impl::CartesianItemDirectionInfo::m_previous_lid.
Referenced by dirFaceId().
Direction face corresponding to local face number local_id.
Definition at line 238 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References Arcane::impl::CartesianItemDirectionInfo::m_next_lid, and Arcane::impl::CartesianItemDirectionInfo::m_previous_lid.
Referenced by face(), face(), operator[](), operator[](), and operator[]().
Definition at line 274 of file FaceDirectionMng.cc.
|
private |
Adds the previous face to the list of faces in this direction
Definition at line 173 of file FaceDirectionMng.cc.
References _computeCellInfos(), Arcane::Array< T >::add(), Arcane::CellDirectionMng::allCells(), Arcane::CellDirectionMng::cellFace(), Arcane::AbstractArray< T >::contains(), Arcane::IItemFamily::createGroup(), ENUMERATE_, face(), Arcane::ItemVectorView::fillLocalIds(), Arcane::CellDirectionMng::innerCells(), Arcane::Item::localId(), Arcane::DirCellFace::next(), Arcane::CellDirectionMng::outerCells(), Arcane::DirCellFace::previous(), Arcane::Array< T >::reserve(), Arcane::ItemGroup::setItems(), Arcane::ItemGroup::size(), and Arcane::ItemGroup::view().
|
private |
Calculates the information on faces associated with the cells in the direction cell_dm. Assumes that _internalInit() has been called.
Adds the previous face to the list of faces in this direction
Definition at line 107 of file FaceDirectionMng.cc.
References _computeCellInfos(), Arcane::Array< T >::add(), Arcane::CellDirectionMng::allCells(), Arcane::CellDirectionMng::cellFace(), Arcane::IItemFamily::createGroup(), ENUMERATE_CELL, ENUMERATE_FACE, face(), Arcane::Item::localId(), Arcane::DirCellFace::next(), Arcane::DirCellFace::previous(), Arcane::Array< T >::reserve(), Arcane::ItemGroup::setItems(), and Arcane::ItemGroup::size().
|
private |
Destroys the resources associated with the instance.
Definition at line 87 of file FaceDirectionMng.cc.
|
private |
Initializes the instance.
Definition at line 73 of file FaceDirectionMng.cc.
References ARCANE_FATAL.
|
private |
Resizes the container holding the ItemDirectionInfo.
This invalidates current instances of FaceDirectionMng.
Definition at line 97 of file FaceDirectionMng.cc.
| FaceGroup Arcane::FaceDirectionMng::allFaces | ( | ) | const |
Group of all faces in the direction.
Definition at line 513 of file FaceDirectionMng.cc.
|
inline |
Direction value.
Definition at line 230 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
|
inline |
Direction face corresponding to face f.
Definition at line 147 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References _dirFaceId().
Direction face corresponding to face f.
Definition at line 136 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References _face(), and Arcane::Item::localId().
Referenced by _computeCellInfos(), _internalComputeInfos(), and _internalComputeInfos().
|
inline |
Direction face corresponding to face f.
Definition at line 141 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References _face().
| FaceGroup Arcane::FaceDirectionMng::innerFaces | ( | ) | const |
Group of all internal faces in the direction.
A face is considered internal if its cell in front and behind is not null and is not an overlap cell.
Definition at line 540 of file FaceDirectionMng.cc.
| FaceGroup Arcane::FaceDirectionMng::inPatchFaces | ( | ) | const |
Group of all faces within the patch in the direction.
These are all faces that do not have two overlap cells. (innerFaces() + outerFaces() or simply !overlapFaces())
Definition at line 531 of file FaceDirectionMng.cc.
Direction face corresponding to face f.
Definition at line 212 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References _face(), and Arcane::Item::localId().
|
inline |
Direction face corresponding to the face iterator iface.
Definition at line 224 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References _face(), and Arcane::ItemEnumeratorBase::itemLocalId().
|
inline |
Direction face corresponding to face f.
Definition at line 218 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
References _face().
| FaceGroup Arcane::FaceDirectionMng::outerFaces | ( | ) | const |
Group of all external faces in the direction.
A face is considered external if its cell in front or behind is an overlap cell or is null (if at the domain boundary or if there are no layers of overlap cells).
Definition at line 549 of file FaceDirectionMng.cc.
| FaceGroup Arcane::FaceDirectionMng::overlapFaces | ( | ) | const |
Group of all overlap faces in the direction.
These are all faces that have two overlap cells around them.
0 1 2 3 4 ┌───┬──┬──┬──┬──┐ │ │ │ │ │ │ │ ├──┼──┼──┼──┤ │ │ │ │ │ │ └───┴──┴──┴──┴──┘
0 : level -1 1 and 2 : Overlap cells (overlapCells) 3 : Outer cells (outerCells) 4 : Inner cells (innerCells)
The layer of overlap cells refers to the layer of cells of the same level around the patch. These cells may belong to one or more patches.
Definition at line 522 of file FaceDirectionMng.cc.
|
private |
Definition at line 116 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
|
private |
Definition at line 117 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
|
private |
Definition at line 293 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
|
private |
Definition at line 294 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
|
private |
Definition at line 292 of file src/arcane/cartesianmesh/FaceDirectionMng.h.
|
private |
Definition at line 295 of file src/arcane/cartesianmesh/FaceDirectionMng.h.