Info about nodes in a specific direction X, Y, or Z of a structured mesh. More...
#include <arcane/cartesianmesh/NodeDirectionMng.h>
Classes | |
| struct | ItemDirectionInfo |
| class | Impl |
Public Member Functions | |
| NodeDirectionMng () | |
| Creates an empty instance. | |
| DirNode | node (Node n) const |
| Direction node corresponding to node n. | |
| DirNode | node (NodeLocalId n) const |
| Direction node corresponding to node n. | |
| DirNode | dirNode (NodeLocalId n) const |
| Direction node corresponding to node n. | |
| __host__ __device__ DirNodeLocalId | dirNodeId (NodeLocalId n) const |
| Direction node ID corresponding to node n. | |
| NodeGroup | allNodes () const |
| Group of all nodes in the direction. | |
| NodeGroup | overlapNodes () const |
| Group of all overlap nodes in the direction. | |
| NodeGroup | inPatchNodes () const |
| Group of all patch nodes in the direction. | |
| NodeGroup | innerNodes () const |
| Group of all inner nodes in the direction. | |
| NodeGroup | outerNodes () const |
| Group of all outer nodes in the direction. | |
| DirNode | operator[] (Node n) |
| Direction node corresponding to node n. | |
| DirNode | operator[] (NodeLocalId n) const |
| Direction node corresponding to node n. | |
| DirNode | operator[] (NodeEnumerator inode) const |
| Direction node corresponding to the node iterator inode. | |
| eMeshDirection | direction () const |
| Direction value. | |
Protected Member Functions | |
| void | _internalComputeInfos (const CellDirectionMng &cell_dm, const NodeGroup &all_nodes, const VariableCellReal3 &cells_center) |
| Calculates the information about nodes associated with cells of the direction cell_dm. all_nodes is the group of all nodes of the cells managed by cell_dm. Assumes init() has been called. | |
| void | _internalComputeInfos (const CellDirectionMng &cell_dm, const NodeGroup &all_nodes) |
| void | _internalInit (ICartesianMesh *cm, eMeshDirection dir, Integer patch_index) |
| void | _internalDestroy () |
| void | _internalResizeInfos (Int32 new_size) |
| Resizes the container holding the ItemDirectionInfo. | |
Private Types | |
| using | IndexType = DirNode::IndexType |
| using | DirNodeCellIndex = DirNode::DirNodeCellIndex |
Private Member Functions | |
| DirNode | _node (Int32 local_id) const |
| Direction node corresponding to local node number local_id. | |
| __host__ __device__ DirNodeLocalId | _dirNodeId (NodeLocalId local_id) const |
| Direction node ID corresponding to local node number local_id. | |
| void | _computeNodeCellInfos (const CellDirectionMng &cell_dm, const VariableCellReal3 &cells_center) |
| Brief calculation of node/cell connectivities by direction. | |
| void | _computeNodeCellInfos () const |
| void | _filterNodes () |
| Filters the front/back nodes to keep only the nodes of our patch. | |
Private Attributes | |
| friend | CartesianMeshImpl |
| friend | CartesianMeshPatch |
| SmallSpan< ItemDirectionInfo > | m_infos_view |
| NodeInfoListView | m_nodes |
| eMeshDirection | m_direction |
| IndexedNodeCellConnectivityView | m_node_cell_view |
| Impl * | m_p |
Info about nodes in a specific direction X, Y, or Z of a structured mesh.
Definition at line 255 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 261 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 260 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
| Arcane::NodeDirectionMng::NodeDirectionMng | ( | ) |
Creates an empty instance.
The instance is not valid until _internalInit() has been called.
Definition at line 67 of file NodeDirectionMng.cc.
References Arcane::MD_DirInvalid.
Referenced by _computeNodeCellInfos().
|
private |
Definition at line 412 of file NodeDirectionMng.cc.
|
private |
Brief calculation of node/cell connectivities by direction.
Definition at line 325 of file NodeDirectionMng.cc.
References Arcane::CellDirectionMng::allCells(), allNodes(), ARCANE_FATAL, ENUMERATE_CELL, ENUMERATE_NODE, Arcane::ArrayView< T >::fill(), Arcane::Item::localId(), Arcane::MD_DirX, Arcane::MD_DirY, Arcane::MD_DirZ, node(), NodeDirectionMng(), Arcane::Real3POD::x, Arcane::Real3POD::y, and Arcane::Real3POD::z.
Referenced by _internalComputeInfos().
|
inlineprivate |
Direction node ID corresponding to local node number local_id.
Definition at line 461 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References Arcane::NodeDirectionMng::ItemDirectionInfo::m_next_lid, and Arcane::NodeDirectionMng::ItemDirectionInfo::m_previous_lid.
Referenced by dirNodeId().
|
private |
Filters the front/back nodes to keep only the nodes of our patch.
Definition at line 294 of file NodeDirectionMng.cc.
References allNodes(), and ENUMERATE_NODE.
Referenced by _internalComputeInfos().
|
protected |
Definition at line 190 of file NodeDirectionMng.cc.
|
protected |
Calculates the information about nodes associated with cells of the direction cell_dm. all_nodes is the group of all nodes of the cells managed by cell_dm. Assumes init() has been called.
Definition at line 115 of file NodeDirectionMng.cc.
References _computeNodeCellInfos(), _filterNodes(), Arcane::Array< T >::add(), Arcane::CellDirectionMng::allCells(), Arcane::CellDirectionMng::cellNode(), Arcane::IItemFamily::createGroup(), ENUMERATE_CELL, ENUMERATE_ITEM, Arcane::ItemGroup::itemFamily(), Arcane::DirCellNode::nextLeftId(), Arcane::DirCellNode::nextRightId(), Arcane::DirCellNode::previousLeftId(), Arcane::DirCellNode::previousRightId(), Arcane::DirCellNode::topNextLeftId(), Arcane::DirCellNode::topNextRightId(), Arcane::DirCellNode::topPreviousLeftId(), and Arcane::DirCellNode::topPreviousRightId().
|
protected |
Destroys the resources associated with the instance.
Definition at line 95 of file NodeDirectionMng.cc.
|
protected |
Initializes the instance.
Definition at line 80 of file NodeDirectionMng.cc.
References ARCANE_FATAL, Arcane::ICartesianMesh::mesh(), and Arcane::IMeshBase::nodeFamily().
|
protected |
Resizes the container holding the ItemDirectionInfo.
This invalidates current instances of NodeDirectionMng.
Definition at line 105 of file NodeDirectionMng.cc.
Direction node corresponding to local node number local_id.
Definition at line 454 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References Arcane::NodeDirectionMng::ItemDirectionInfo::m_next_lid, and Arcane::NodeDirectionMng::ItemDirectionInfo::m_previous_lid.
Referenced by dirNode(), node(), node(), operator[](), operator[](), and operator[]().
| NodeGroup Arcane::NodeDirectionMng::allNodes | ( | ) | const |
Group of all nodes in the direction.
Definition at line 547 of file NodeDirectionMng.cc.
Referenced by _computeNodeCellInfos(), and _filterNodes().
|
inline |
Direction value.
Definition at line 405 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
inline |
Direction node corresponding to node n.
Definition at line 321 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References _node().
|
inline |
Direction node ID corresponding to node n.
Definition at line 327 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References _dirNodeId().
| NodeGroup Arcane::NodeDirectionMng::innerNodes | ( | ) | const |
Group of all inner nodes in the direction.
A node is considered inner if its previous or next node is not null.
Definition at line 574 of file NodeDirectionMng.cc.
| NodeGroup Arcane::NodeDirectionMng::inPatchNodes | ( | ) | const |
Group of all patch nodes in the direction.
Patch nodes are nodes that do not have all their cells as overlap cells. TODO reformulate (innerNodes() + outerNodes() or simply !overlapNodes())
Definition at line 565 of file NodeDirectionMng.cc.
Direction node corresponding to node n.
Definition at line 309 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References _node(), and Arcane::Item::localId().
Referenced by _computeNodeCellInfos().
|
inline |
Direction node corresponding to node n.
Definition at line 315 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References _node().
Direction node corresponding to node n.
Definition at line 387 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References _node(), and Arcane::Item::localId().
|
inline |
Direction node corresponding to the node iterator inode.
Definition at line 399 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References _node(), and Arcane::ItemEnumeratorBase::itemLocalId().
|
inline |
Direction node corresponding to node n.
Definition at line 393 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
References _node().
| NodeGroup Arcane::NodeDirectionMng::outerNodes | ( | ) | const |
Group of all outer nodes in the direction.
A node is considered outer if its previous or next node is overlap or is null (if it is at the domain boundary or if there are no overlap cell layers).
Definition at line 583 of file NodeDirectionMng.cc.
| NodeGroup Arcane::NodeDirectionMng::overlapNodes | ( | ) | const |
Group of all overlap nodes in the direction.
An overlap node is a node that only has overlap cells around it.
0 1 2 3 4 ┌───┬──┬──┬──┬──┐ │ │ │ │ │ │ │ ├──┼──┼──┼──┤ │ │ │ │ │ │ └───┴──┴──┴──┴──┘
0 : level -1 1 and 2 : Overlap cells (overlapCells) 3 : Outer cells (outerCells) 4 : Inner cells (innerCells)
The overlap cell layer designates the layer of cells of the same level around the patch. These cells may belong to one or more patches.
Definition at line 556 of file NodeDirectionMng.cc.
|
private |
Definition at line 257 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 258 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 447 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 445 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 448 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 446 of file src/arcane/cartesianmesh/NodeDirectionMng.h.
|
private |
Definition at line 449 of file src/arcane/cartesianmesh/NodeDirectionMng.h.