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...

Inheritance diagram for mapDistributePolyMesh:

Public Member Functions

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

Friends

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

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]

Default construct - uses worldComm.

Definition at line 57 of file mapDistributePolyMesh.C.

◆ 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 27 of file mapDistributePolyMeshIO.C.

References dict.

◆ mapDistributePolyMesh() [4/9]

Copy construct.

Definition at line 79 of file mapDistributePolyMesh.C.

◆ mapDistributePolyMesh() [5/9]

Move construct.

Definition at line 90 of file mapDistributePolyMesh.C.

◆ mapDistributePolyMesh() [6/9]

mapDistributePolyMesh ( mapDistributePolyMesh map,
bool  reuse 
)

Copy/move construct.

Definition at line 101 of file mapDistributePolyMesh.C.

◆ 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 120 of file mapDistributePolyMesh.C.

◆ 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 184 of file mapDistributePolyMesh.C.

◆ 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.

Referenced by pointSet::distribute(), faMeshDistributor::distribute(), faMeshTools::writeProcAddressing(), 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.

Referenced by faceSet::distribute(), faMeshDistributor::distribute(), faMeshTools::writeProcAddressing(), 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.

Referenced by cellSet::distribute(), faMeshTools::writeProcAddressing(), 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.

Referenced by faMeshTools::writeProcAddressing(), and 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.

◆ oldPatchNMeshPoints()

const labelList& oldPatchNMeshPoints ( ) const
inlinenoexcept

List of numbers of mesh points per old patch.

Definition at line 269 of file mapDistributePolyMesh.H.

◆ pointMap()

const mapDistribute& pointMap ( ) const
inlinenoexcept

Point distribute map.

Definition at line 277 of file mapDistributePolyMesh.H.

Referenced by hexRef8Data::distribute(), faMeshDistributor::distribute(), faMeshTools::writeProcAddressing(), 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.

Referenced by faMeshDistributor::distribute(), faMeshTools::writeProcAddressing(), 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.

Referenced by hexRef8Data::distribute(), refinementHistory::distribute(), faMeshTools::writeProcAddressing(), 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.

Referenced by faMeshTools::writeProcAddressing(), 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.

Referenced by IOmapDistributePolyMesh::IOmapDistributePolyMesh().

Here is the caller graph for this function:

◆ distributePointData()

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

Distribute list of point data.

Definition at line 326 of file mapDistributePolyMesh.H.

References mapDistribute::distribute(), and Foam::HashTableOps::values().

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

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

◆ distributeFaceData()

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

Distribute list of face data.

Definition at line 335 of file mapDistributePolyMesh.H.

References mapDistribute::distribute(), and Foam::HashTableOps::values().

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

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

◆ distributeCellData()

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

Distribute list of cell data.

Definition at line 344 of file mapDistributePolyMesh.H.

References mapDistribute::distribute(), and Foam::HashTableOps::values().

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

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

◆ distributePatchData()

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

Distribute list of patch data.

Definition at line 353 of file mapDistributePolyMesh.H.

References mapDistribute::distribute(), and Foam::HashTableOps::values().

Here is the call 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::findIndices().

Here is the call graph for this function:

◆ distributeFaceIndices()

void distributeFaceIndices ( labelList faceIDs) const

Definition at line 293 of file mapDistributePolyMesh.C.

References Foam::findIndices().

Here is the call graph for this function:

◆ distributeCellIndices()

void distributeCellIndices ( labelList cellIDs) const

Definition at line 309 of file mapDistributePolyMesh.C.

References Foam::findIndices().

Here is the call graph for this function:

◆ distributePatchIndices()

void distributePatchIndices ( labelList patchIDs) const

Definition at line 325 of file mapDistributePolyMesh.C.

References Foam::findIndices().

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.

Referenced by IOmapDistributePolyMesh::IOmapDistributePolyMesh().

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.

◆ 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.

◆ readDict()

void readDict ( const dictionary dict)

Read entries from dictionary format.

Definition at line 46 of file mapDistributePolyMeshIO.C.

References dict, dictionary::readEntry(), and dictionary::subDict().

Here is the call graph for this function:

◆ writeCellMapEntries()

void writeCellMapEntries ( Ostream os) const

Write cellMap in dictionary format.

Definition at line 84 of file mapDistributePolyMeshIO.C.

References Ostream::beginBlock(), Ostream::endBlock(), os(), and Ostream::writeEntry().

Here is the call graph for this function:

◆ writeFaceMapEntries()

void writeFaceMapEntries ( Ostream os) const

Write faceMap in dictionary format.

Definition at line 93 of file mapDistributePolyMeshIO.C.

References Ostream::beginBlock(), Ostream::endBlock(), os(), and Ostream::writeEntry().

Here is the call 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 Ostream::beginBlock(), Ostream::endBlock(), os(), and Ostream::writeEntry().

Here is the call graph for this function:

◆ writePatchMapEntries()

void writePatchMapEntries ( Ostream os) const

Write patchMap in dictionary format.

Definition at line 111 of file mapDistributePolyMeshIO.C.

References Ostream::beginBlock(), Ostream::endBlock(), os(), and Ostream::writeEntry().

Here is the call 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, and os().

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.

Friends And Related Function Documentation

◆ operator>>

Istream& operator>> ( Istream ,
mapDistributePolyMesh  
)
friend

Read plain content (not dictionary) from Istream.

◆ operator<<

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

Write plain content (not dictionary) to Ostream.


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