84 #ifndef Foam_globalMeshData_H 85 #define Foam_globalMeshData_H 100 template<
class T>
class CompactListList;
101 template<
class T>
class EdgeMap;
102 class globalIndexAndTransform;
188 globalPointTransformedBoundaryFacesPtr_;
197 globalPointTransformedBoundaryCellsPtr_;
210 mutable label nGlobalPoints_;
230 mutable label nGlobalEdges_;
246 static void countSharedEdges
254 void calcSharedPoints()
const;
257 void calcSharedEdges()
const;
260 void calcGlobalPointSlaves()
const;
268 void calcGlobalPointEdges
280 const label localPoint
284 void calcGlobalEdgeSlaves()
const;
287 void calcGlobalEdgeOrientation()
const;
296 void calcGlobalPointBoundaryFaces()
const;
299 void calcGlobalPointBoundaryCells()
const;
309 void calcGlobalCoPointSlaves()
const;
359 return !processorPatches_.
empty();
366 return globalMeshPointAddr_;
373 return globalMeshFaceAddr_;
379 return globalMeshCellAddr_;
408 return processorTopology_;
422 return processorPatches_;
430 return processorPatchIndices_;
437 return processorPatchNeighbours_;
517 template<
class Type,
class CombineOp,
class TransformOp>
525 const CombineOp& cop,
526 const TransformOp& top
530 template<
class Type,
class CombineOp>
550 template<
class Type,
class CombineOp,
class TransformOp>
554 const CombineOp& cop,
555 const TransformOp& top
654 const label nLocalCoarse,
671 const label nLocalCoarse,
711 const bitSet& selectedCells,
const labelList & sharedPointLabels() const
Return indices of local points that are globally shared.
const Map< label > & coupledPatchMeshEdgeMap() const
Return map from mesh edges to coupledPatch edges.
const labelListList & globalPointSlaves() const
const mapDistribute & globalCoPointSlavesMap() const
const labelListList & globalPointTransformedSlaves() const
pointField geometricSharedPoints() const
Like sharedPoints but keeps cyclic points separate. (does geometric merging; uses matchTol_*bb as mer...
const globalIndex & globalBoundaryCellNumbering() const
Numbering of boundary cells is according to boundaryCells()
const labelList & sharedPointGlobalLabels() const
Return shared point global labels. Tries to read 'pointProcAddressing' and returns list or -1 if none...
const labelListList & globalPointTransformedBoundaryFaces() const
const mapDistribute & globalEdgeSlavesMap() const
static const Foam::scalar matchTol_
Geometric tolerance (fraction of bounding box)
Various mesh related information for a parallel run. Upon construction, constructs all info using par...
const labelList & processorPatches() const noexcept
Return list of processor patch labels.
bool empty() const noexcept
True if List is empty (ie, size() is zero)
void clearOut()
Remove all demand driven data.
bool parallel() const noexcept
Does the mesh contain processor patches? (also valid when not running parallel)
const mapDistribute & globalPointSlavesMap() const
const bitSet & globalEdgeOrientation() const
Is my edge same orientation as master edge.
const labelListList & globalPointBoundaryCells() const
const globalIndex & globalMeshPointAddr() const noexcept
Global numbering for mesh points. Not compensated for duplicate points!
autoPtr< globalIndex > mergePoints(labelList &pointToGlobal, labelList &uniquePoints) const
Helper for merging (collocated!) mesh point data.
const labelListList & globalEdgeSlaves() const
const globalIndex & globalMeshCellAddr() const noexcept
Global numbering for mesh cells.
const labelList & coupledPatchMeshEdges() const
Return map from coupledPatch edges to mesh edges.
const labelListList & globalPointBoundaryFaces() const
const lduSchedule & patchSchedule() const noexcept
Order in which the patches should be initialised/evaluated corresponding to the schedule.
label nTotalPoints() const noexcept
Total global number of mesh points. Not compensated for duplicate points!
static void syncData(List< Type > &elems, const labelListList &slaves, const labelListList &transformedSlaves, const mapDistribute &slavesMap, const globalIndexAndTransform &, const CombineOp &cop, const TransformOp &top)
Helper: synchronise data with transforms.
const labelList & boundaryCells() const
From boundary cell to mesh cell.
label nGlobalEdges() const
Return number of globally shared edges.
A list of faces which address into the list of points.
Calculates a unique integer (label so might not have enough room - 2G max) for processor + local inde...
const globalIndex & globalEdgeNumbering() const
label nGlobalPoints() const
Return number of globally shared points.
label totalSize() const noexcept
The total addressed size, which corresponds to the end offset and also the sum of all localSizes...
const labelList & sharedEdgeAddr() const
Return addressing into the complete globally shared edge list.
const globalIndexAndTransform & globalTransforms() const
Global transforms numbering.
const globalIndex & globalMeshFaceAddr() const noexcept
Global numbering for mesh faces. Not compensated for duplicate faces!
const labelList & processorPatchIndices() const noexcept
Return list of indices into processorPatches_ for each patch.
const globalIndex & globalPointNumbering() const
Numbering of coupled points is according to coupledPatch.
void operator=(const globalMeshData &)=delete
No copy assignment.
A packed storage of objects of type <T> using an offset table for access.
ClassName("globalMeshData")
Runtime type information.
Map from edge (expressed as its endpoints) to value. Hashing (and ==) on an edge is symmetric...
Determines/represents processor-processor connection. After instantiation contains the processor-proc...
~globalMeshData()
Destructor.
label nTotalCells() const noexcept
Total global number of mesh cells.
void movePoints(const pointField &newPoints)
Update for moving points.
const labelList & processorPatchNeighbours() const noexcept
Return processorPatchIndices of the neighbours processor patches. -1 if not running parallel...
const indirectPrimitivePatch & coupledPatch() const
Return patch of all coupled faces.
const labelListList & globalPointTransformedBoundaryCells() const
Class containing processor-to-processor mapping information.
A bitSet stores bits (elements with only two states) in packed internal format and supports a variety...
const processorTopology & topology() const noexcept
The processor to processor topology.
const lduSchedule & patchSchedule() const noexcept
Order in which the patches should be initialised/evaluated corresponding to the schedule.
void updateMesh()
Change global mesh data given a topological change. Does a.
label nTotalFaces() const noexcept
Total global number of mesh faces. Not compensated for duplicate faces!
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
Mesh consisting of general polyhedral cells.
static void calcCellCells(const polyMesh &mesh, const labelUList &agglom, const label nLocalCoarse, const bool parallel, CompactListList< label > &cellCells)
Determine (local or global) cellCells from mesh agglomeration.
List< label > labelList
A List of labels.
const mapDistribute & globalPointBoundaryFacesMap() const
const labelList & sharedPointAddr() const
Return addressing into the complete globally shared points list.
pointField sharedPoints() const
Collect coordinates of shared points on all processors. (does parallel communication!) ...
const mapDistribute & globalPointBoundaryCellsMap() const
const labelList & sharedEdgeLabels() const
Return indices of local edges that are globally shared.
const labelListList & globalCoPointSlaves() const
const polyMesh & mesh() const noexcept
Return the mesh reference.
const labelListList & globalEdgeTransformedSlaves() const
globalMeshData(const globalMeshData &)=delete
No copy construct.
void syncPointData(List< Type > &pointData, const CombineOp &cop, const TransformOp &top) const
Helper to synchronise coupled patch point data.
const globalIndex & globalBoundaryFaceNumbering() const
Numbering of boundary faces is face-mesh.nInternalFaces()