Calculates points shared by more than two processor patches or cyclic patches. More...
#include <OpenFOAM/globalPoints.H>
Calculates points shared by more than two processor patches or cyclic patches.
Is used in globalMeshData. (this info is needed for point-edge communication where you do all but these shared points with patch to patch communication but need to do a reduce on these shared points)
Works purely topological and using local communication only. Needs:
Works by constructing equivalence lists for all the points on processor patches. These list are procPointList and give processor and meshPoint label on that processor. E.g.
((7 93)(4 731)(3 114))
means point 93 on proc7 is connected to point 731 on proc4 and 114 on proc3. It then gets the lowest numbered processor (the 'master') to request a sharedPoint label from processor0 and it redistributes this label back to the other processors in the equivalence list.
Algorithm:
At this point one will have complete point-point connectivity for all points on processor patches. Now
This information gets redistributed to all processors in a similar way as that in which the equivalence lists were collected:
Definition at line 117 of file globalPoints.H.
Public Member Functions | |
ClassName ("globalPoints") | |
Declare name of the class and its debug switch.
| |
globalPoints (const polyMesh &mesh) | |
Construct from mesh.
| |
label | nPatchPoints () const |
const Map< label > & | meshToProcPoint () const |
const labelList & | sharedPointAddr () const |
shared points used by this processor (= global point number)
| |
const labelList & | sharedPointLabels () const |
my meshpoints corresponding to the shared points
| |
label | nGlobalPoints () const |
globalPoints | ( | const polyMesh & | mesh ) |
Construct from mesh.
Definition at line 892 of file globalPoints.C.
References Foam::abort(), Foam::endl(), Foam::FatalError, FatalErrorIn, forAll, Pstream::gatherList(), Pstream::myProcNo(), Pstream::nProcs(), Foam::Pout, Foam::reduce(), Pstream::scatterList(), List< T >::setSize(), List< T >::size(), and HashTable< T, Key, Hash >::size().
ClassName | ( | "globalPoints" | ) |
Declare name of the class and its debug switch.
label nPatchPoints | ( | ) | const [inline]
|
Definition at line 230 of file globalPoints.H.
const Map<label>& meshToProcPoint | ( | ) | const [inline]
|
Definition at line 235 of file globalPoints.H.
const labelList& sharedPointAddr | ( | ) | const [inline]
|
shared points used by this processor (= global point number)
Definition at line 241 of file globalPoints.H.
Referenced by globalMeshData::updateMesh().
const labelList& sharedPointLabels | ( | ) | const [inline]
|
my meshpoints corresponding to the shared points
Definition at line 247 of file globalPoints.H.
Referenced by globalMeshData::updateMesh().
label nGlobalPoints | ( | ) | const [inline]
|
Definition at line 252 of file globalPoints.H.
Referenced by globalMeshData::updateMesh().