32 void Foam::mapDistributePolyMesh::calcPatchSizes()
34 oldPatchSizes_.
setSize(oldPatchStarts_.size());
36 if (oldPatchStarts_.size())
46 const label lastPatchID = oldPatchStarts_.size() - 1;
48 oldPatchSizes_[lastPatchID] = nOldFaces_ - oldPatchStarts_[lastPatchID];
50 if (
min(oldPatchSizes_) < 0)
53 <<
"Calculated negative old patch size:" << oldPatchSizes_ <<
nl 69 oldPatchNMeshPoints_(0),
82 const label nOldPoints,
83 const label nOldFaces,
84 const label nOldCells,
100 const bool subFaceHasFlip,
101 const bool constructFaceHasFlip
104 nOldPoints_(nOldPoints),
105 nOldFaces_(nOldFaces),
106 nOldCells_(nOldCells),
108 oldPatchStarts_(oldPatchStarts),
109 oldPatchNMeshPoints_(oldPatchNMeshPoints),
110 pointMap_(mesh.
nPoints(), subPointMap, constructPointMap),
119 cellMap_(mesh.
nCells(), subCellMap, constructCellMap),
129 const label nOldPoints,
130 const label nOldFaces,
131 const label nOldCells,
142 nOldPoints_(nOldPoints),
143 nOldFaces_(nOldFaces),
144 nOldCells_(nOldCells),
146 oldPatchStarts_(oldPatchStarts),
147 oldPatchNMeshPoints_(oldPatchNMeshPoints),
162 nOldPoints_(map().nOldPoints_),
163 nOldFaces_(map().nOldFaces_),
164 nOldCells_(map().nOldCells_),
165 oldPatchSizes_(map().oldPatchSizes_.
xfer()),
166 oldPatchStarts_(map().oldPatchStarts_.xfer()),
167 oldPatchNMeshPoints_(map().oldPatchNMeshPoints_.xfer()),
168 pointMap_(map().pointMap_.xfer()),
169 faceMap_(map().faceMap_.xfer()),
170 cellMap_(map().cellMap_.xfer()),
171 patchMap_(map().patchMap_.xfer())
185 nOldPoints_ = rhs.nOldPoints_;
186 nOldFaces_ = rhs.nOldFaces_;
187 nOldCells_ = rhs.nOldCells_;
188 oldPatchSizes_.
transfer(rhs.oldPatchSizes_);
189 oldPatchStarts_.transfer(rhs.oldPatchStarts_);
190 oldPatchNMeshPoints_.
transfer(rhs.oldPatchNMeshPoints_);
209 createWithValues<boolList>
231 createWithValues<boolList>
253 createWithValues<boolList>
275 createWithValues<boolList>
296 nOldPoints_ = rhs.nOldPoints_;
297 nOldFaces_ = rhs.nOldFaces_;
298 nOldCells_ = rhs.nOldCells_;
299 oldPatchSizes_ = rhs.oldPatchSizes_;
300 oldPatchStarts_ = rhs.oldPatchStarts_;
301 oldPatchNMeshPoints_ = rhs.oldPatchNMeshPoints_;
302 pointMap_ = rhs.pointMap_;
303 faceMap_ = rhs.faceMap_;
304 cellMap_ = rhs.cellMap_;
305 patchMap_ = rhs.patchMap_;
313 is.
fatalCheck(
"operator>>(Istream&, mapDistributePolyMesh&)");
315 is >> map.nOldPoints_
318 >> map.oldPatchSizes_
319 >> map.oldPatchStarts_
320 >> map.oldPatchNMeshPoints_
334 os << map.nOldPoints_
void operator=(const mapDistributePolyMesh &)
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
A simple container for copying or transferring objects of type <T>.
void distributeCellIndices(labelList &cellIDs) const
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
label nOldFaces() const
Number of faces in mesh before distribution.
void distributePointData(List< T > &lst) const
Distribute list of point data.
void distributePatchIndices(labelList &patchIDs) const
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
Xfer< List< T > > xfer()
Transfer contents to the Xfer container.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of me...
labelList findIndices(const ListType &, typename ListType::const_reference, const label start=0)
Find all occurences of given element. Linear search.
void transfer(mapDistribute &)
Transfer the contents of the argument and annul the argument.
mapDistributePolyMesh()
Construct null.
void distributeCellData(List< T > &lst) const
Distribute list of cell data.
Xfer< mapDistributePolyMesh > xfer()
Transfer contents to the Xfer container.
void distributeFaceData(List< T > &lst) const
Distribute list of face data.
Xfer< T > xferMove(T &)
Construct by transferring the contents of the arg.
Istream & operator>>(Istream &, directionInfo &)
const labelList & oldPatchStarts() const
List of the old patch start labels.
errorManip< error > abort(error &err)
void fatalCheck(const char *operation) const
Check IOstream status for given operation.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
label size() const
Return the number of elements in the UPtrList.
void distributeFaceIndices(labelList &faceIDs) const
void setSize(const label)
Reset size of List.
label nOldPoints() const
Number of points in mesh before distribution.
label nOldCells() const
Number of cells in mesh before distribution.
void distributePointIndices(labelList &pointIDs) const
Distribute list of point/face/cell/patch indices.
Ostream & operator<<(Ostream &, const ensightPart &)
void transfer(mapDistributePolyMesh &)
Transfer the contents of the argument and annul the argument.
void distributePatchData(List< T > &lst) const
Distribute list of patch data.
Mesh consisting of general polyhedral cells.
void transfer(List< T > &)
Transfer the contents of the argument List into this list.