Various tools to aid synchronizing lists across coupled patches. WIP. More...
Static Public Member Functions | |
template<class T , class CombineOp , class TransformOp > | |
static void | syncPointMap (const polyMesh &mesh, Map< T > &pointValues, const CombineOp &cop, const TransformOp &top) |
Synchronize values on selected points. More... | |
template<class T , class CombineOp , class TransformOp > | |
static void | syncEdgeMap (const polyMesh &mesh, EdgeMap< T > &edgeValues, const CombineOp &cop, const TransformOp &top) |
Synchronize values on selected edges. More... | |
template<class T , class CombineOp , class TransformOp > | |
static void | syncPointList (const polyMesh &mesh, List< T > &pointValues, const CombineOp &cop, const T &nullValue, const TransformOp &top) |
Synchronize values on all mesh points. More... | |
template<class T , class CombineOp , class TransformOp > | |
static void | syncPointList (const polyMesh &mesh, const labelUList &meshPoints, List< T > &pointValues, const CombineOp &cop, const T &nullValue, const TransformOp &top) |
Synchronize values on selected mesh points. More... | |
template<class T , class CombineOp , class TransformOp > | |
static void | syncEdgeList (const polyMesh &mesh, List< T > &edgeValues, const CombineOp &cop, const T &nullValue, const TransformOp &top) |
Synchronize values on all mesh edges. More... | |
template<class T , class CombineOp , class TransformOp > | |
static void | syncEdgeList (const polyMesh &mesh, const labelList &meshEdges, List< T > &edgeValues, const CombineOp &cop, const T &nullValue, const TransformOp &top) |
Synchronize values on selected mesh edges. More... | |
template<class T , class CombineOp , class TransformOp > | |
static void | syncBoundaryFaceList (const polyMesh &mesh, UList< T > &faceValues, const CombineOp &cop, const TransformOp &top, const bool parRun=Pstream::parRun()) |
Synchronize values on boundary faces only. More... | |
template<class T , class CombineOp > | |
static void | syncPointList (const polyMesh &mesh, List< T > &pointValues, const CombineOp &cop, const T &nullValue) |
Synchronize values on all mesh points. More... | |
template<class CombineOp > | |
static void | syncPointPositions (const polyMesh &mesh, List< point > &positions, const CombineOp &cop, const point &nullValue) |
Synchronize locations on all mesh points. More... | |
template<class T , class CombineOp > | |
static void | syncPointList (const polyMesh &mesh, const labelList &meshPoints, List< T > &pointValues, const CombineOp &cop, const T &nullValue) |
Synchronize values on selected mesh points. More... | |
template<class CombineOp > | |
static void | syncPointPositions (const polyMesh &mesh, const labelList &meshPoints, List< point > &positions, const CombineOp &cop, const point &nullValue) |
Synchronize locations on selected mesh points. More... | |
template<class T , class CombineOp > | |
static void | syncEdgeList (const polyMesh &mesh, List< T > &edgeValues, const CombineOp &cop, const T &nullValue) |
Synchronize values on all mesh edges. More... | |
template<class CombineOp > | |
static void | syncEdgePositions (const polyMesh &mesh, List< point > &positions, const CombineOp &cop, const point &nullValue) |
Synchronize locations on all mesh edges. More... | |
template<class T , class CombineOp > | |
static void | syncEdgeList (const polyMesh &mesh, const labelList &meshEdges, List< T > &edgeValues, const CombineOp &cop, const T &nullValue) |
Synchronize values on selected mesh edges. More... | |
template<class CombineOp > | |
static void | syncEdgePositions (const polyMesh &mesh, const labelList &meshEdges, List< point > &positions, const CombineOp &cop, const point &nullValue) |
Synchronize locations on selected mesh edges. More... | |
template<class T , class CombineOp > | |
static void | syncBoundaryFaceList (const polyMesh &mesh, UList< T > &faceValues, const CombineOp &cop) |
Synchronize values on boundary faces only. More... | |
template<class CombineOp > | |
static void | syncBoundaryFacePositions (const polyMesh &mesh, UList< point > &positions, const CombineOp &cop) |
Synchronize locations on boundary faces only. More... | |
template<class T , class CombineOp > | |
static void | syncFaceList (const polyMesh &mesh, UList< T > &faceValues, const CombineOp &cop) |
Synchronize values on all mesh faces. More... | |
template<class CombineOp > | |
static void | syncFacePositions (const polyMesh &mesh, UList< point > &positions, const CombineOp &cop) |
Synchronize locations on all mesh faces. More... | |
template<class T > | |
static void | swapBoundaryFaceList (const polyMesh &mesh, UList< T > &faceValues) |
Swap coupled boundary face values. Uses eqOp. More... | |
static void | swapBoundaryFacePositions (const polyMesh &mesh, UList< point > &positions) |
Swap coupled positions. Uses eqOp. More... | |
template<class T > | |
static void | swapFaceList (const polyMesh &mesh, UList< T > &faceValues) |
Swap coupled face values. Uses eqOp. More... | |
template<class T > | |
static void | swapBoundaryCellList (const polyMesh &mesh, const UList< T > &cellData, List< T > &neighbourCellData) |
Swap to obtain neighbour cell values for all boundary faces. More... | |
static void | swapBoundaryCellPositions (const polyMesh &mesh, const UList< point > &cellData, List< point > &neighbourCellData) |
Swap to obtain neighbour cell positions for all boundary faces. More... | |
template<class T , class CombineOp > | |
static void | syncPointMap (const polyMesh &mesh, Map< T > &pointValues, const CombineOp &cop) |
Synchronize values on selected points. More... | |
template<class CombineOp > | |
static void | syncPointPositions (const polyMesh &mesh, Map< point > &positions, const CombineOp &cop) |
Synchronize locations on selected points. More... | |
template<class T , class CombineOp > | |
static void | syncEdgeMap (const polyMesh &mesh, EdgeMap< T > &edgeValues, const CombineOp &cop) |
Synchronize values on selected edges. Edges are represented. More... | |
template<class CombineOp > | |
static void | syncEdgePositions (const polyMesh &mesh, EdgeMap< point > &edgePositions, const CombineOp &cop) |
Synchronize locations on selected edges. More... | |
template<unsigned Width, class CombineOp > | |
static void | syncFaceList (const polyMesh &mesh, const bool isBoundaryOnly, PackedList< Width > &faceValues, const CombineOp &cop, const bool parRun=Pstream::parRun()) |
Synchronize face values from PackedList/bitSet. More... | |
template<unsigned Width, class CombineOp > | |
static void | syncFaceList (const polyMesh &mesh, PackedList< Width > &faceValues, const CombineOp &cop, const bool parRun=Pstream::parRun()) |
Synchronize mesh face values from PackedList/bitSet. More... | |
template<unsigned Width, class CombineOp > | |
static void | syncBoundaryFaceList (const polyMesh &mesh, PackedList< Width > &faceValues, const CombineOp &cop, const bool parRun=Pstream::parRun()) |
Synchronize boundary face values from PackedList/bitSet. More... | |
template<unsigned Width> | |
static void | swapFaceList (const polyMesh &mesh, PackedList< Width > &faceValues) |
Swap coupled face values. Uses eqOp. More... | |
template<unsigned Width> | |
static void | swapBoundaryFaceList (const polyMesh &mesh, PackedList< Width > &faceValues) |
Swap coupled boundary face values. Uses eqOp. More... | |
template<unsigned Width, class CombineOp > | |
static void | syncPointList (const polyMesh &mesh, PackedList< Width > &pointValues, const CombineOp &cop, const unsigned int nullValue) |
template<unsigned Width, class CombineOp > | |
static void | syncEdgeList (const polyMesh &mesh, PackedList< Width > &edgeValues, const CombineOp &cop, const unsigned int nullValue) |
static bitSet | getMasterPoints (const polyMesh &mesh) |
static bitSet | getMasterEdges (const polyMesh &mesh) |
static bitSet | getMasterFaces (const polyMesh &mesh) |
static bitSet | getInternalOrMasterFaces (const polyMesh &mesh) |
static bitSet | getInternalOrCoupledFaces (const polyMesh &mesh) |
Get per face whether it is internal or coupled. More... | |
Various tools to aid synchronizing lists across coupled patches. WIP.
Definition at line 66 of file syncTools.H.
|
static |
Synchronize values on selected points.
Definition at line 86 of file syncToolsTemplates.C.
References polyMesh::boundaryMesh(), Foam::ListListOps::combine(), cyclicPolyPatch::coupledPoints(), Foam::constant::electromagnetic::e, PstreamBuffers::finishedSends(), UPstream::firstSlave(), forAll, forAllConstIters(), polyMesh::globalData(), UPstream::lastSlave(), UPstream::master(), UPstream::masterNo(), mesh, PrimitivePatch< FaceList, PointField >::meshPoints(), cyclicPolyPatch::neighbPatch(), processorPolyPatch::neighbPoints(), processorPolyPatch::neighbProcNo(), globalMeshData::nGlobalPoints(), UPstream::nonBlocking, cyclicPolyPatch::owner(), UPstream::parRun(), patches, UPstream::scheduled, globalMeshData::sharedPointAddr(), and globalMeshData::sharedPointLabels().
Referenced by reconstructedDistanceFunction::markCellsNearSurf(), syncTools::syncPointMap(), and syncTools::syncPointPositions().
|
static |
Synchronize values on selected edges.
Definition at line 379 of file syncToolsTemplates.C.
References polyMesh::boundaryMesh(), HashTable< T, edge, Hash< edge > >::cfind(), Foam::ListListOps::combine(), cyclicPolyPatch::coupledEdges(), Foam::constant::electromagnetic::e, PrimitivePatch< FaceList, PointField >::edges(), f(), polyMesh::faces(), PstreamBuffers::finishedSends(), UPstream::firstSlave(), forAll, forAllConstIters(), polyMesh::globalData(), UPstream::lastSlave(), UPstream::master(), UPstream::masterNo(), mesh, PrimitivePatch< FaceList, PointField >::meshPoints(), cyclicPolyPatch::neighbPatch(), processorPolyPatch::neighbPoints(), processorPolyPatch::neighbProcNo(), primitiveMesh::nFaces(), primitiveMesh::nInternalFaces(), UPstream::nonBlocking, cyclicPolyPatch::owner(), UPstream::parRun(), patches, UPstream::scheduled, globalMeshData::sharedPointAddr(), and globalMeshData::sharedPointLabels().
Referenced by patchPatchDist::correct(), syncTools::syncEdgeMap(), and syncTools::syncEdgePositions().
|
static |
Synchronize values on all mesh points.
Definition at line 747 of file syncToolsTemplates.C.
References Foam::abort(), Foam::FatalError, FatalErrorInFunction, polyMesh::globalData(), mesh, primitiveMesh::nPoints(), and globalMeshData::syncPointData().
Referenced by singleProcessorFaceSets::add(), sensitivitySurface::addGeometricSens(), snappyLayerDriver::addLayers(), singleProcessorFaceSets::apply(), sensitivitySurfacePoints::assembleSensitivities(), motionSmootherAlgo::avg(), snappySnapDriver::avgCellCentres(), snappySnapDriver::calcNearestSurface(), snappySnapDriver::calcSnapDistance(), pointZone::checkParallelSync(), hexRef8::checkRefinementLevels(), edgeCollapser::consistentCollapse(), hexRef8::consistentSlowRefinement(), sensitivitySurfacePoints::constructGlobalPointNormalsAndAreas(), motionSmootherAlgo::correctBoundaryConditions(), removePoints::countPointUsage(), meshRefinement::dupNonManifoldBoundaryPoints(), meshRefinement::getMasterPoints(), patchTransformedInterpolation::interpolate(), motionSmootherAlgo::scaleMesh(), dynamicRefineFvMesh::selectUnrefinePoints(), motionSmootherAlgo::setDisplacement(), combineFaces::setRefinement(), removeFaces::setRefinement(), addPatchCellLayer::setRefinement(), fieldSmoother::smoothNormals(), pointBitSet::sync(), pointSet::sync(), syncTools::syncPointList(), syncTools::syncPointPositions(), meshRefinement::testSyncPointList(), and meshRefinement::weightedSum().
|
static |
Synchronize values on selected mesh points.
Definition at line 769 of file syncToolsTemplates.C.
References Foam::abort(), globalMeshData::coupledPatch(), Foam::FatalError, FatalErrorInFunction, forAll, polyMesh::globalData(), globalMeshData::globalPointSlaves(), globalMeshData::globalPointSlavesMap(), globalMeshData::globalPointTransformedSlaves(), globalMeshData::globalTransforms(), mesh, PrimitivePatch< FaceList, PointField >::meshPointMap(), PrimitivePatch< FaceList, PointField >::nPoints(), UList< T >::size(), and globalMeshData::syncData().
|
static |
Synchronize values on all mesh edges.
Definition at line 826 of file syncToolsTemplates.C.
References Foam::abort(), globalMeshData::coupledPatchMeshEdges(), Foam::FatalError, FatalErrorInFunction, forAll, polyMesh::globalData(), globalMeshData::globalEdgeSlaves(), globalMeshData::globalEdgeSlavesMap(), globalMeshData::globalEdgeTransformedSlaves(), globalMeshData::globalTransforms(), mesh, primitiveMesh::nEdges(), and globalMeshData::syncData().
Referenced by edgeCollapser::consistentCollapse(), meshRefinement::getMasterEdges(), addPatchCellLayer::globalEdgeFaces(), removeFaces::setRefinement(), meshCutter::setRefinement(), addPatchCellLayer::setRefinement(), hexRef8::setRefinement(), syncTools::syncEdgeList(), and syncTools::syncEdgePositions().
|
static |
Synchronize values on selected mesh edges.
Definition at line 870 of file syncToolsTemplates.C.
References Foam::abort(), globalMeshData::coupledPatch(), globalMeshData::coupledPatchMeshEdgeMap(), Foam::FatalError, FatalErrorInFunction, forAll, polyMesh::globalData(), globalMeshData::globalEdgeSlaves(), globalMeshData::globalEdgeSlavesMap(), globalMeshData::globalEdgeTransformedSlaves(), globalMeshData::globalTransforms(), mesh, PrimitivePatch< FaceList, PointField >::nEdges(), and globalMeshData::syncData().
|
static |
Synchronize values on boundary faces only.
Definition at line 927 of file syncToolsTemplates.C.
References Foam::abort(), polyMesh::boundaryMesh(), Foam::FatalError, FatalErrorInFunction, PstreamBuffers::finishedSends(), mesh, primitiveMesh::nBoundaryFaces(), cyclicPolyPatch::neighbPatch(), processorPolyPatch::neighbProcNo(), primitiveMesh::nInternalFaces(), Foam::nl, UPstream::nonBlocking, cyclicPolyPatch::owner(), patches, UList< T >::size(), polyPatch::start(), and Foam::T().
Referenced by cellToFaceStencil::calcFaceStencil(), removePoints::getUnrefimentSet(), syncTools::swapBoundaryFaceList(), syncTools::swapBoundaryFacePositions(), syncTools::swapFaceList(), syncTools::syncBoundaryFaceList(), syncTools::syncBoundaryFacePositions(), syncTools::syncFaceList(), and syncTools::syncFacePositions().
|
inlinestatic |
Synchronize values on all mesh points.
Definition at line 179 of file syncTools.H.
References mesh, and syncTools::syncPointList().
|
inlinestatic |
Synchronize locations on all mesh points.
Definition at line 199 of file syncTools.H.
References mesh, and syncTools::syncPointList().
|
inlinestatic |
Synchronize values on selected mesh points.
Definition at line 219 of file syncTools.H.
References mesh, and syncTools::syncPointList().
|
inlinestatic |
Synchronize locations on selected mesh points.
Definition at line 241 of file syncTools.H.
References mesh, and syncTools::syncPointList().
|
inlinestatic |
Synchronize values on all mesh edges.
Definition at line 266 of file syncTools.H.
References mesh, and syncTools::syncEdgeList().
|
inlinestatic |
Synchronize locations on all mesh edges.
Definition at line 286 of file syncTools.H.
References mesh, and syncTools::syncEdgeList().
Referenced by hexRef8::setRefinement().
|
inlinestatic |
Synchronize values on selected mesh edges.
Definition at line 306 of file syncTools.H.
References mesh, and syncTools::syncEdgeList().
|
inlinestatic |
Synchronize locations on selected mesh edges.
Definition at line 328 of file syncTools.H.
References mesh, and syncTools::syncEdgeList().
|
inlinestatic |
Synchronize values on boundary faces only.
Definition at line 354 of file syncTools.H.
References mesh, and syncTools::syncBoundaryFaceList().
|
inlinestatic |
Synchronize locations on boundary faces only.
Definition at line 372 of file syncTools.H.
References mesh, and syncTools::syncBoundaryFaceList().
Referenced by meshRefinement::checkData(), and hexRef8::setRefinement().
|
inlinestatic |
Synchronize values on all mesh faces.
Definition at line 390 of file syncTools.H.
References mesh, and syncTools::syncBoundaryFaceList().
Referenced by preserveBaffles::add(), singleProcessorFaceSets::add(), refinementHistory::add(), meshRefinement::balance(), meshRefinement::createBaffles(), dynamicRefineFvMesh::dynamicRefineFvMesh(), dynamicRefineFvMesh::extendMarkedCells(), dynamicOversetFvMesh::normalisation(), hexRef8::setRefinement(), meshRefinement::splitMesh(), faceBoolSet::sync(), faceBitSet::sync(), faceSet::sync(), and meshRefinement::updateIntersections().
|
inlinestatic |
Synchronize locations on all mesh faces.
Definition at line 415 of file syncTools.H.
References mesh, and syncTools::syncBoundaryFaceList().
Swap coupled boundary face values. Uses eqOp.
Definition at line 439 of file syncTools.H.
References mesh, and syncTools::syncBoundaryFaceList().
Referenced by decompositionMethod::calcCellCells(), meshRefinement::checkCoupledFaceZones(), meshRefinement::checkData(), hexRef8::checkMesh(), faceZone::checkParallelSync(), hexRef8::checkRefinementLevels(), polyMeshGeometry::checkVolRatio(), hexRef8::consistentSlowRefinement(), hexRef8::consistentUnrefinement(), fluxSummary::initialiseCellZoneAndDirection(), regionSplit::reduceRegions(), SloanRenumber::renumber(), rotorDiskSource::setFaceArea(), tetDecomposer::setRefinement(), hexRef8::setRefinement(), syncTools::swapBoundaryCellList(), and faceZoneSet::sync().
|
inlinestatic |
Swap coupled positions. Uses eqOp.
Definition at line 455 of file syncTools.H.
References mesh, and syncTools::syncBoundaryFaceList().
Referenced by polyMeshGeometry::checkFaceDotProduct(), polyMeshGeometry::checkFaceTets(), polyMeshGeometry::checkFaceTwist(), and polyMeshGeometry::checkFaceWeights().
Swap coupled face values. Uses eqOp.
Definition at line 472 of file syncTools.H.
References mesh, and syncTools::syncBoundaryFaceList().
Referenced by dynamicRefineFvMesh::dynamicRefineFvMesh(), and removeFaces::setRefinement().
|
static |
Swap to obtain neighbour cell values for all boundary faces.
Definition at line 1175 of file syncToolsTemplates.C.
References Foam::abort(), polyMesh::boundaryMesh(), Foam::FatalError, FatalErrorInFunction, mesh, primitiveMesh::nBoundaryFaces(), primitiveMesh::nCells(), primitiveMesh::nInternalFaces(), patches, List< T >::resize(), UList< T >::size(), and syncTools::swapBoundaryFaceList().
Referenced by decompositionMethod::decompose(), cellCellStencil::globalCellCells(), dynamicOversetFvMesh::normalisation(), and meshRefinement::zonify().
|
static |
Swap to obtain neighbour cell positions for all boundary faces.
Definition at line 34 of file syncTools.C.
References Foam::abort(), Foam::FatalError, FatalErrorInFunction, mesh, patches, List< T >::resize(), and UList< T >::size().
Referenced by polyMeshGeometry::checkFaceSkewness().
|
inlinestatic |
Synchronize values on selected points.
Definition at line 515 of file syncTools.H.
References mesh, and syncTools::syncPointMap().
|
inlinestatic |
Synchronize locations on selected points.
Definition at line 533 of file syncTools.H.
References mesh, and syncTools::syncPointMap().
|
inlinestatic |
Synchronize values on selected edges. Edges are represented.
by the two vertices that make it up so global edges never get constructed.
Definition at line 553 of file syncTools.H.
References mesh, and syncTools::syncEdgeMap().
|
inlinestatic |
Synchronize locations on selected edges.
Definition at line 571 of file syncTools.H.
References mesh, and syncTools::syncEdgeMap().
|
static |
Synchronize face values from PackedList/bitSet.
mesh | The mesh |
isBoundaryOnly | True if faceValues are for the boundary only and not the entire mesh. This determines the face offset when accessing values. |
faceValues | The face values to synchronize |
cop | The combine operation |
parRun | True if this is a parallel simulation |
Definition at line 1045 of file syncToolsTemplates.C.
References Foam::abort(), polyMesh::boundaryMesh(), Foam::FatalError, FatalErrorInFunction, PstreamBuffers::finishedSends(), mesh, primitiveMesh::nBoundaryFaces(), cyclicPolyPatch::neighbPatch(), processorPolyPatch::neighbProcNo(), primitiveMesh::nFaces(), primitiveMesh::nInternalFaces(), Foam::nl, UPstream::nonBlocking, cyclicPolyPatch::owner(), patches, range, PackedList< Width >::set(), PackedList< Width >::size(), and polyPatch::start().
|
static |
Synchronize mesh face values from PackedList/bitSet.
Definition at line 1211 of file syncToolsTemplates.C.
References mesh.
|
static |
Synchronize boundary face values from PackedList/bitSet.
Definition at line 1224 of file syncToolsTemplates.C.
References mesh.
|
static |
Swap coupled face values. Uses eqOp.
Definition at line 1237 of file syncToolsTemplates.C.
References mesh.
|
static |
Swap coupled boundary face values. Uses eqOp.
Definition at line 1248 of file syncToolsTemplates.C.
References mesh.
|
static |
Definition at line 1259 of file syncToolsTemplates.C.
References Foam::abort(), mapDistributeBase::constructSize(), globalMeshData::coupledPatch(), Foam::FatalError, FatalErrorInFunction, forAll, polyMesh::globalData(), globalMeshData::globalPointSlaves(), globalMeshData::globalPointSlavesMap(), globalMeshData::globalPointTransformedSlaves(), mesh, PrimitivePatch< FaceList, PointField >::meshPoints(), primitiveMesh::nPoints(), PackedList< Width >::size(), and globalMeshData::syncData().
|
static |
Definition at line 1302 of file syncToolsTemplates.C.
References Foam::abort(), mapDistributeBase::constructSize(), globalMeshData::coupledPatchMeshEdges(), Foam::FatalError, FatalErrorInFunction, forAll, polyMesh::globalData(), globalMeshData::globalEdgeSlaves(), globalMeshData::globalEdgeSlavesMap(), globalMeshData::globalEdgeTransformedSlaves(), mesh, primitiveMesh::nEdges(), PackedList< Width >::size(), and globalMeshData::syncData().
|
static |
Get per point whether it is uncoupled or a master of a coupled set of points
Definition at line 68 of file syncTools.C.
References forAll, mesh, and List< T >::set().
Referenced by meshRefinement::printMeshInfo().
|
static |
Get per edge whether it is uncoupled or a master of a coupled set of edges
Definition at line 97 of file syncTools.C.
References forAll, polyMesh::globalData(), mesh, primitiveMesh::nEdges(), and List< T >::set().
Referenced by motionSmootherAlgo::updateMesh().
|
static |
Get per face whether it is uncoupled or a master of a coupled set of faces
Definition at line 126 of file syncTools.C.
References polyMesh::boundaryMesh(), mesh, primitiveMesh::nFaces(), and patches.
Referenced by meshRefinement::countHits(), meshRefinement::printMeshInfo(), faceZoneSet::sync(), meshRefinement::updateIntersections(), and meshRefinement::zonify().
|
static |
Get per face whether it is internal or a master of a coupled set of faces
Definition at line 148 of file syncTools.C.
References polyMesh::boundaryMesh(), mesh, primitiveMesh::nFaces(), and patches.
|
static |
Get per face whether it is internal or coupled.
Definition at line 176 of file syncTools.C.
References polyMesh::boundaryMesh(), mesh, primitiveMesh::nFaces(), and patches.
Referenced by snappyLayerDriver::doLayers().