Loading...
Searching...
No Matches
mapDistributePolyMesh Class Reference

Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of meshes (using subsetting) to other processors and receive and reconstruct mesh. More...

#include <mapDistributePolyMesh.H>

Inheritance diagram for mapDistributePolyMesh:

Public Member Functions

 mapDistributePolyMesh ()
 Default construct - uses worldComm.
 mapDistributePolyMesh (const label comm)
 Default construct with specified communicator.
 mapDistributePolyMesh (const dictionary &dict, const label comm=UPstream::worldComm)
 Read construct from dictionary.
 mapDistributePolyMesh (const mapDistributePolyMesh &map)
 Copy construct.
 mapDistributePolyMesh (mapDistributePolyMesh &&map)
 Move construct.
 mapDistributePolyMesh (mapDistributePolyMesh &map, bool reuse)
 Copy/move construct.
 mapDistributePolyMesh (const polyMesh &mesh, const label nOldPoints, const label nOldFaces, const label nOldCells, labelList &&oldPatchStarts, labelList &&oldPatchNMeshPoints, labelListList &&subPointMap, labelListList &&subFaceMap, labelListList &&subCellMap, labelListList &&subPatchMap, labelListList &&constructPointMap, labelListList &&constructFaceMap, labelListList &&constructCellMap, labelListList &&constructPatchMap, const bool subFaceHasFlip=false, const bool constructFaceHasFlip=false)
 Construct from components. Note that mesh has to be changed already.
 mapDistributePolyMesh (const label nOldPoints, const label nOldFaces, const label nOldCells, labelList &&oldPatchStarts, labelList &&oldPatchNMeshPoints, mapDistribute &&pointMap, mapDistribute &&faceMap, mapDistribute &&cellMap, mapDistribute &&patchMap)
 Move construct from components.
 mapDistributePolyMesh (Istream &is)
 Construct from Istream.
label nOldPoints () const noexcept
 Number of points in mesh before distribution.
label nOldFaces () const noexcept
 Number of faces in mesh before distribution.
label nOldCells () const noexcept
 Number of cells in mesh before distribution.
const labelListoldPatchSizes () const noexcept
 List of the old patch sizes.
const labelListoldPatchStarts () const noexcept
 List of the old patch start labels.
const labelListoldPatchNMeshPoints () const noexcept
 List of numbers of mesh points per old patch.
const mapDistributepointMap () const noexcept
 Point distribute map.
const mapDistributefaceMap () const noexcept
 Face distribute map.
const mapDistributecellMap () const noexcept
 Cell distribute map.
const mapDistributepatchMap () const noexcept
 Patch distribute map.
void clear ()
 Reset to zero size, only retaining communicator(s).
void transfer (mapDistributePolyMesh &map)
 Transfer the contents of the argument and annul the argument.
template<class T>
void distributePointData (List< T > &values) const
 Distribute list of point data.
template<class T>
void distributeFaceData (List< T > &values) const
 Distribute list of face data.
template<class T>
void distributeCellData (List< T > &values) const
 Distribute list of cell data.
template<class T>
void distributePatchData (List< T > &values) const
 Distribute list of patch data.
void distributePointIndices (labelList &pointIDs) const
 Distribute list of point/face/cell/patch indices.
void distributeFaceIndices (labelList &faceIDs) const
void distributeCellIndices (labelList &cellIDs) const
void distributePatchIndices (labelList &patchIDs) const
void operator= (const mapDistributePolyMesh &map)
 Copy assignment.
void operator= (mapDistributePolyMesh &&map)
 Move assignment.
InfoProxy< mapDistributePolyMeshinfo () const noexcept
 Return info proxy, used to print summary information to a stream.
void readDict (const dictionary &dict)
 Read entries from dictionary format.
void writeCellMapEntries (Ostream &os) const
 Write cellMap in dictionary format.
void writeFaceMapEntries (Ostream &os) const
 Write faceMap in dictionary format.
void writePointMapEntries (Ostream &os) const
 Write pointMap entries in dictionary format.
void writePatchMapEntries (Ostream &os) const
 Write patchMap in dictionary format.
void writeEntries (Ostream &os) const
 Write all map entries in dictionary format.
void updateMesh (const mapPolyMesh &)
 No correction for topo change.

Friends

Istreamoperator>> (Istream &, mapDistributePolyMesh &)
 Read plain content (not dictionary) from Istream.
Ostreamoperator<< (Ostream &, const mapDistributePolyMesh &)
 Write plain content (not dictionary) to Ostream.

Detailed Description

Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of meshes (using subsetting) to other processors and receive and reconstruct mesh.

We store mapping from the bits-to-send to the complete starting mesh (subXXXMap) and from the received bits to their location in the new mesh (constructXXXMap).

Source files

Definition at line 65 of file mapDistributePolyMesh.H.

Constructor & Destructor Documentation

◆ mapDistributePolyMesh() [1/9]

◆ mapDistributePolyMesh() [2/9]

mapDistributePolyMesh ( const label comm)
explicit

Default construct with specified communicator.

Definition at line 63 of file mapDistributePolyMesh.C.

◆ mapDistributePolyMesh() [3/9]

mapDistributePolyMesh ( const dictionary & dict,
const label comm = UPstream::worldComm )
explicit

Read construct from dictionary.

Definition at line 26 of file mapDistributePolyMeshIO.C.

References dict, mapDistributePolyMesh(), and readDict().

Here is the call graph for this function:

◆ mapDistributePolyMesh() [4/9]

mapDistributePolyMesh ( const mapDistributePolyMesh & map)

Copy construct.

Definition at line 78 of file mapDistributePolyMesh.C.

References mapDistributePolyMesh().

Here is the call graph for this function:

◆ mapDistributePolyMesh() [5/9]

mapDistributePolyMesh ( mapDistributePolyMesh && map)

Move construct.

Definition at line 89 of file mapDistributePolyMesh.C.

References mapDistributePolyMesh(), and transfer().

Here is the call graph for this function:

◆ mapDistributePolyMesh() [6/9]

mapDistributePolyMesh ( mapDistributePolyMesh & map,
bool reuse )

Copy/move construct.

Definition at line 100 of file mapDistributePolyMesh.C.

References mapDistributePolyMesh(), and transfer().

Here is the call graph for this function:

◆ mapDistributePolyMesh() [7/9]

mapDistributePolyMesh ( const polyMesh & mesh,
const label nOldPoints,
const label nOldFaces,
const label nOldCells,
labelList && oldPatchStarts,
labelList && oldPatchNMeshPoints,
labelListList && subPointMap,
labelListList && subFaceMap,
labelListList && subCellMap,
labelListList && subPatchMap,
labelListList && constructPointMap,
labelListList && constructFaceMap,
labelListList && constructCellMap,
labelListList && constructPatchMap,
const bool subFaceHasFlip = false,
const bool constructFaceHasFlip = false )

Construct from components. Note that mesh has to be changed already.

since uses mesh.nPoints etc as the new size.

Definition at line 119 of file mapDistributePolyMesh.C.

References mesh, nOldCells(), nOldFaces(), nOldPoints(), nPoints, oldPatchNMeshPoints(), and oldPatchStarts().

Here is the call graph for this function:

◆ mapDistributePolyMesh() [8/9]

mapDistributePolyMesh ( const label nOldPoints,
const label nOldFaces,
const label nOldCells,
labelList && oldPatchStarts,
labelList && oldPatchNMeshPoints,
mapDistribute && pointMap,
mapDistribute && faceMap,
mapDistribute && cellMap,
mapDistribute && patchMap )

Move construct from components.

Definition at line 183 of file mapDistributePolyMesh.C.

References cellMap(), faceMap(), nOldCells(), nOldFaces(), nOldPoints(), oldPatchNMeshPoints(), oldPatchStarts(), patchMap(), and pointMap().

Here is the call graph for this function:

◆ mapDistributePolyMesh() [9/9]

mapDistributePolyMesh ( Istream & is)
explicit

Construct from Istream.

Definition at line 38 of file mapDistributePolyMeshIO.C.

Member Function Documentation

◆ nOldPoints()

label nOldPoints ( ) const
inlinenoexcept

Number of points in mesh before distribution.

Definition at line 229 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by pointSet::distribute(), distributePointIndices(), mapDistributePolyMesh(), mapDistributePolyMesh(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ nOldFaces()

label nOldFaces ( ) const
inlinenoexcept

Number of faces in mesh before distribution.

Definition at line 237 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by faceSet::distribute(), distributeFaceIndices(), mapDistributePolyMesh(), mapDistributePolyMesh(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ nOldCells()

label nOldCells ( ) const
inlinenoexcept

Number of cells in mesh before distribution.

Definition at line 245 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by cellSet::distribute(), distributeCellIndices(), mapDistributePolyMesh(), mapDistributePolyMesh(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ oldPatchSizes()

const labelList & oldPatchSizes ( ) const
inlinenoexcept

List of the old patch sizes.

Definition at line 253 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ oldPatchStarts()

const labelList & oldPatchStarts ( ) const
inlinenoexcept

List of the old patch start labels.

Definition at line 261 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by distributePatchIndices(), mapDistributePolyMesh(), and mapDistributePolyMesh().

Here is the caller graph for this function:

◆ oldPatchNMeshPoints()

const labelList & oldPatchNMeshPoints ( ) const
inlinenoexcept

List of numbers of mesh points per old patch.

Definition at line 269 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by mapDistributePolyMesh(), and mapDistributePolyMesh().

Here is the caller graph for this function:

◆ pointMap()

const mapDistribute & pointMap ( ) const
inlinenoexcept

Point distribute map.

Definition at line 277 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by hexRef8Data::distribute(), mapDistributePolyMesh(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ faceMap()

const mapDistribute & faceMap ( ) const
inlinenoexcept

Face distribute map.

Definition at line 285 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by mapDistributePolyMesh(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ cellMap()

const mapDistribute & cellMap ( ) const
inlinenoexcept

Cell distribute map.

Definition at line 293 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by hexRef8Data::distribute(), refinementHistory::distribute(), mapDistributePolyMesh(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ patchMap()

const mapDistribute & patchMap ( ) const
inlinenoexcept

Patch distribute map.

Definition at line 301 of file mapDistributePolyMesh.H.

References Foam::noexcept.

Referenced by mapDistributePolyMesh(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ clear()

void clear ( )

Reset to zero size, only retaining communicator(s).

Definition at line 216 of file mapDistributePolyMesh.C.

◆ transfer()

void transfer ( mapDistributePolyMesh & map)

Transfer the contents of the argument and annul the argument.

Definition at line 252 of file mapDistributePolyMesh.C.

References mapDistributePolyMesh(), and Foam::rhs().

Referenced by IOmapDistributePolyMesh::IOmapDistributePolyMesh(), mapDistributePolyMesh(), mapDistributePolyMesh(), and operator=().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ distributePointData()

template<class T>
void distributePointData ( List< T > & values) const
inline

Distribute list of point data.

Definition at line 326 of file mapDistributePolyMesh.H.

Referenced by hexRef8::distribute(), pointBitSet::distribute(), pointSet::distribute(), distributePointIndices(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ distributeFaceData()

template<class T>
void distributeFaceData ( List< T > & values) const
inline

Distribute list of face data.

Definition at line 335 of file mapDistributePolyMesh.H.

Referenced by faceBitSet::distribute(), faceBoolSet::distribute(), faceSet::distribute(), meshRefinement::distribute(), and distributeFaceIndices().

Here is the caller graph for this function:

◆ distributeCellData()

template<class T>
void distributeCellData ( List< T > & values) const
inline

Distribute list of cell data.

Definition at line 344 of file mapDistributePolyMesh.H.

Referenced by cellSet::distribute(), hexRef8::distribute(), distributeCellIndices(), and fvMeshTools::writeProcAddressing().

Here is the caller graph for this function:

◆ distributePatchData()

template<class T>
void distributePatchData ( List< T > & values) const
inline

Distribute list of patch data.

Definition at line 353 of file mapDistributePolyMesh.H.

Referenced by distributePatchIndices().

Here is the caller graph for this function:

◆ distributePointIndices()

void distributePointIndices ( labelList & pointIDs) const

Distribute list of point/face/cell/patch indices.

(Converts to boolList, distributes boolList and reconstructs)

Definition at line 277 of file mapDistributePolyMesh.C.

References Foam::ListOps::createWithValue(), distributePointData(), Foam::findIndices(), and nOldPoints().

Here is the call graph for this function:

◆ distributeFaceIndices()

void distributeFaceIndices ( labelList & faceIDs) const

Definition at line 293 of file mapDistributePolyMesh.C.

References Foam::ListOps::createWithValue(), distributeFaceData(), Foam::findIndices(), and nOldFaces().

Here is the call graph for this function:

◆ distributeCellIndices()

void distributeCellIndices ( labelList & cellIDs) const

Definition at line 309 of file mapDistributePolyMesh.C.

References Foam::ListOps::createWithValue(), distributeCellData(), Foam::findIndices(), and nOldCells().

Here is the call graph for this function:

◆ distributePatchIndices()

void distributePatchIndices ( labelList & patchIDs) const

Definition at line 325 of file mapDistributePolyMesh.C.

References Foam::ListOps::createWithValue(), distributePatchData(), Foam::findIndices(), and oldPatchStarts().

Here is the call graph for this function:

◆ operator=() [1/2]

void operator= ( const mapDistributePolyMesh & map)

Copy assignment.

Definition at line 349 of file mapDistributePolyMesh.C.

References mapDistributePolyMesh(), and Foam::rhs().

Referenced by IOmapDistributePolyMesh::IOmapDistributePolyMesh().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator=() [2/2]

void operator= ( mapDistributePolyMesh && map)

Move assignment.

Definition at line 370 of file mapDistributePolyMesh.C.

References mapDistributePolyMesh(), Foam::rhs(), and transfer().

Here is the call graph for this function:

◆ info()

InfoProxy< mapDistributePolyMesh > info ( ) const
inlinenoexcept

Return info proxy, used to print summary information to a stream.

Definition at line 391 of file mapDistributePolyMesh.H.

References Foam::noexcept.

◆ readDict()

void readDict ( const dictionary & dict)

Read entries from dictionary format.

Definition at line 46 of file mapDistributePolyMeshIO.C.

References dict, and dictionary::readEntry().

Referenced by mapDistributePolyMesh().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ writeCellMapEntries()

void writeCellMapEntries ( Ostream & os) const

Write cellMap in dictionary format.

Definition at line 84 of file mapDistributePolyMeshIO.C.

References os().

Referenced by writeEntries().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ writeFaceMapEntries()

void writeFaceMapEntries ( Ostream & os) const

Write faceMap in dictionary format.

Definition at line 93 of file mapDistributePolyMeshIO.C.

References os().

Referenced by writeEntries().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ writePointMapEntries()

void writePointMapEntries ( Ostream & os) const

Write pointMap entries in dictionary format.

Definition at line 102 of file mapDistributePolyMeshIO.C.

References os().

Referenced by writeEntries().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ writePatchMapEntries()

void writePatchMapEntries ( Ostream & os) const

Write patchMap in dictionary format.

Definition at line 111 of file mapDistributePolyMeshIO.C.

References os().

Referenced by writeEntries().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ writeEntries()

void writeEntries ( Ostream & os) const

Write all map entries in dictionary format.

Definition at line 122 of file mapDistributePolyMeshIO.C.

References Foam::nl, os(), writeCellMapEntries(), writeFaceMapEntries(), writePatchMapEntries(), and writePointMapEntries().

Here is the call graph for this function:

◆ updateMesh()

void updateMesh ( const mapPolyMesh & )
inline

No correction for topo change.

Definition at line 444 of file mapDistributePolyMesh.H.

References NotImplemented.

◆ operator>>

Istream & operator>> ( Istream & ,
mapDistributePolyMesh &  )
friend

Read plain content (not dictionary) from Istream.

References mapDistributePolyMesh().

◆ operator<<

Ostream & operator<< ( Ostream & ,
const mapDistributePolyMesh &  )
friend

Write plain content (not dictionary) to Ostream.

References mapDistributePolyMesh().


The documentation for this class was generated from the following files: