OpenFOAM logo
Open Source CFD Toolkit

globalPoints.H File Reference


Detailed Description

View globalPoints.H
License
This file is part of OpenFOAM.

OpenFOAM is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.

OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
for more details.

You should have received a copy of the GNU General Public License
along with OpenFOAM; if not, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Description
Calculates points shared by more than two processor patches or cyclic
patches. Is used in parallelInfo. (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:
- domain to be one single domain (i.e. all faces can be reached through
face-cell walk).
- patch face ordering to be ok
- f[0] ordering on patch faces to be ok.

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:
    - get meshPoints of all my points on processor patches and initialize
      equivalence lists to this.
    loop
    - send to all neighbours in relative form:
        - patchFace
        - index in face
    - receive and convert into meshPoints. Add to to my equivalence lists.
    - mark meshPoints for which information changed.
    - send data for these meshPoints again
    endloop until nothing changes

At this point one will have complete point-point connectivity for all
points on processor patches. Now

    - remove point equivalences of size 2. These are just normal points
    shared between two neighbouring procPatches.
    - collect on each processor points for which it is the master
    - request number of sharedPointLabels from the Pstream::master.

This information gets redistributed to all processors in a similar way
as that in which the equivalence lists were collected:

    - initialize the indices of shared points I am the master for
    loop
    - send my known sharedPoints + meshPoints to all neighbours
    - receive from all neighbour. Find which meshPoint on my processor
      the sharedpoint is connected to
    - mark indices for which information has changed
    endloop until nothing changes.


Source files

Definition in file globalPoints.H.

Go to the source code of this file.

Namespaces

namespace  Foam

Classes

class  globalPoints

For further information go to www.openfoam.org