GAMGAgglomeration Class Reference

Geometric agglomerated algebraic multigrid agglomeration class. More...

Inheritance diagram for GAMGAgglomeration:
[legend]
Collaboration diagram for GAMGAgglomeration:
[legend]

Public Member Functions

 TypeName ("GAMGAgglomeration")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, GAMGAgglomeration, lduMesh,(const lduMesh &mesh, const dictionary &controlDict),(mesh, controlDict))
 Runtime selection table for pure geometric agglomerators. More...
 
 declareRunTimeSelectionTable (autoPtr, GAMGAgglomeration, lduMatrix,(const lduMatrix &matrix, const dictionary &controlDict),(matrix, controlDict))
 
 declareRunTimeSelectionTable (autoPtr, GAMGAgglomeration, geometry,(const lduMesh &mesh, const scalarField &cellVolumes, const vectorField &faceAreas, const dictionary &controlDict),(mesh, cellVolumes, faceAreas, controlDict))
 
 GAMGAgglomeration (const lduMesh &mesh, const dictionary &controlDict)
 Construct given mesh and controls. More...
 
 ~GAMGAgglomeration ()
 Destructor. More...
 
label size () const
 
const lduMeshmeshLevel (const label leveli) const
 Return LDU mesh of given level. More...
 
bool hasMeshLevel (const label leveli) const
 Do we have mesh for given level? More...
 
const lduInterfacePtrsListinterfaceLevel (const label leveli) const
 Return LDU interface addressing of given level. More...
 
const labelFieldrestrictAddressing (const label leveli) const
 Return cell restrict addressing of given level. More...
 
const labelListfaceRestrictAddressing (const label leveli) const
 Return face restrict addressing of given level. More...
 
const labelListListpatchFaceRestrictAddressing (const label leveli) const
 
const boolListfaceFlipMap (const label leveli) const
 Return face flip map of given level. More...
 
label nCells (const label leveli) const
 Return number of coarse cells (before processor agglomeration) More...
 
label nFaces (const label leveli) const
 Return number of coarse faces (before processor agglomeration) More...
 
const labelListnPatchFaces (const label leveli) const
 
template<class Type >
void restrictField (Field< Type > &cf, const Field< Type > &ff, const label fineLevelIndex, const bool procAgglom) const
 Restrict (integrate by summation) cell field. More...
 
template<class Type >
void restrictFaceField (Field< Type > &cf, const Field< Type > &ff, const label fineLevelIndex) const
 Restrict (integrate by summation) face field. More...
 
template<class Type >
void restrictField (Field< Type > &cf, const Field< Type > &ff, const labelList &fineToCoarse) const
 Restrict (integrate by summation) cell field. More...
 
template<class Type >
void prolongField (Field< Type > &ff, const Field< Type > &cf, const label coarseLevelIndex, const bool procAgglom) const
 Prolong (interpolate by injection) cell field. More...
 
bool processorAgglomerate () const
 Whether to agglomerate across processors. More...
 
const labelListprocAgglomMap (const label fineLeveli) const
 
const labelListagglomProcIDs (const label fineLeveli) const
 
bool hasProcMesh (const label fineLeveli) const
 Check that level has combined mesh. More...
 
label procCommunicator (const label fineLeveli) const
 Communicator for current level or -1. More...
 
const labelListcellOffsets (const label fineLeveli) const
 Mapping from processor to procMesh cells. More...
 
const labelListListfaceMap (const label fineLeveli) const
 Mapping from processor to procMesh face. More...
 
const labelListListboundaryMap (const label fineLeveli) const
 Mapping from processor to procMesh boundary. More...
 
const labelListListListboundaryFaceMap (const label fineLeveli) const
 Mapping from processor to procMesh boundary face. More...
 
- Public Member Functions inherited from MeshObject< lduMesh, GeometricMeshObject, GAMGAgglomeration >
 MeshObject (const lduMesh &mesh)
 Construct on Mesh type. More...
 
virtual ~MeshObject ()=default
 Destructor. More...
 
const lduMeshmesh () const
 
virtual bool writeData (Ostream &os) const
 

Static Public Member Functions

static const GAMGAgglomerationNew (const lduMesh &mesh, const dictionary &controlDict)
 Return the selected geometric agglomerator. More...
 
static const GAMGAgglomerationNew (const lduMatrix &matrix, const dictionary &controlDict)
 Return the selected matrix agglomerator. More...
 
static const GAMGAgglomerationNew (const lduMesh &mesh, const scalarField &cellVolumes, const vectorField &faceAreas, const dictionary &controlDict)
 Return the selected geometric agglomerator. More...
 
static void calculateRegionMaster (const label comm, const labelList &procAgglomMap, labelList &masterProcs, List< label > &agglomProcIDs)
 Given fine to coarse processor map determine: More...
 
static bool checkRestriction (labelList &newRestrict, label &nNewCoarse, const lduAddressing &fineAddressing, const labelUList &restriction, const label nCoarse)
 Given restriction determines if coarse cells are connected. More...
 
- Static Public Member Functions inherited from MeshObject< lduMesh, GeometricMeshObject, GAMGAgglomeration >
static const GAMGAgglomerationNew (const lduMesh &mesh, Args &&... args)
 Get existing or create a new MeshObject. More...
 
static bool Delete (const lduMesh &mesh)
 Static destructor. More...
 

Protected Member Functions

void agglomerateLduAddressing (const label fineLevelIndex)
 Assemble coarse mesh addressing. More...
 
void combineLevels (const label curLevel)
 Combine a level with the previous one. More...
 
void compactLevels (const label nCreatedLevels)
 Shrink the number of levels to that specified. More...
 
bool continueAgglomerating (const label nCells, const label nCoarseCells) const
 Check the need for further agglomeration. More...
 
void clearLevel (const label leveli)
 
void procAgglomerateLduAddressing (const label comm, const labelList &procAgglomMap, const labelList &procIDs, const label allMeshComm, const label levelIndex)
 Collect and combine processor meshes into allMesh: More...
 
void procAgglomerateRestrictAddressing (const label comm, const labelList &procIDs, const label levelIndex)
 Collect and combine basic restriction addressing: More...
 
 GAMGAgglomeration (const GAMGAgglomeration &)=delete
 No copy construct. More...
 
void operator= (const GAMGAgglomeration &)=delete
 No copy assignment. More...
 

Protected Attributes

const label maxLevels_
 Max number of levels. More...
 
label nCellsInCoarsestLevel_
 Number of cells in coarsest level. More...
 
const lduInterfacePtrsList meshInterfaces_
 Cached mesh interfaces. More...
 
autoPtr< GAMGProcAgglomerationprocAgglomeratorPtr_
 
labelList nCells_
 The number of cells in each level. More...
 
PtrList< labelFieldrestrictAddressing_
 Cell restriction addressing array. More...
 
labelList nFaces_
 The number of (coarse) faces in each level. More...
 
PtrList< labelListfaceRestrictAddressing_
 Face restriction addressing array. More...
 
PtrList< boolListfaceFlipMap_
 Face flip: for faces mapped to internal faces stores whether. More...
 
PtrList< labelListnPatchFaces_
 The number of (coarse) patch faces in each level. More...
 
PtrList< labelListListpatchFaceRestrictAddressing_
 Patch-local face restriction addressing array. More...
 
PtrList< lduPrimitiveMeshmeshLevels_
 Hierarchy of mesh addressing. More...
 
PtrList< labelListprocAgglomMap_
 Per level, per processor the processor it agglomerates into. More...
 
PtrList< labelListagglomProcIDs_
 Per level the set of processors to agglomerate. Element 0 is. More...
 
labelList procCommunicator_
 Communicator for given level. More...
 
PtrList< labelListprocCellOffsets_
 Mapping from processor to procMeshLevel cells. More...
 
PtrList< labelListListprocFaceMap_
 Mapping from processor to procMeshLevel face. More...
 
PtrList< labelListListprocBoundaryMap_
 Mapping from processor to procMeshLevel boundary. More...
 
PtrList< labelListListListprocBoundaryFaceMap_
 Mapping from processor to procMeshLevel boundary face. More...
 
- Protected Attributes inherited from MeshObject< lduMesh, GeometricMeshObject, GAMGAgglomeration >
const lduMeshmesh_
 

Friends

class GAMGProcAgglomeration
 Declare friendship with GAMGProcAgglomeration. More...
 

Detailed Description

Geometric agglomerated algebraic multigrid agglomeration class.

Source files

Definition at line 64 of file GAMGAgglomeration.H.

Constructor & Destructor Documentation

◆ GAMGAgglomeration() [1/2]

GAMGAgglomeration ( const GAMGAgglomeration )
protecteddelete

No copy construct.

◆ GAMGAgglomeration() [2/2]

◆ ~GAMGAgglomeration()

Destructor.

Definition at line 448 of file GAMGAgglomeration.C.

Member Function Documentation

◆ agglomerateLduAddressing()

void agglomerateLduAddressing ( const label  fineLevelIndex)
protected

◆ combineLevels()

void combineLevels ( const label  curLevel)
protected

Combine a level with the previous one.

Definition at line 575 of file GAMGAgglomerateLduAddressing.C.

References GAMGInterface::combine(), forAll, UPtrList< T >::set(), and List< T >::set().

Referenced by pairGAMGAgglomeration::agglomerate().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ compactLevels()

void compactLevels ( const label  nCreatedLevels)
protected

Shrink the number of levels to that specified.

Definition at line 51 of file GAMGAgglomeration.C.

References GAMGAgglomeration::agglomProcIDs_, lduAddressing::band(), Foam::endl(), GAMGAgglomeration::faceFlipMap_, GAMGAgglomeration::faceRestrictAddressing_, forAll, GAMGAgglomeration::hasMeshLevel(), Foam::Info, lduMesh::interfaces(), lduMesh::lduAddr(), lduAddressing::lowerAddr(), GAMGAgglomeration::meshLevel(), GAMGAgglomeration::meshLevels_, GAMGAgglomeration::nCells(), GAMGAgglomeration::nCells_, GAMGAgglomeration::nFaces_, Foam::nl, GAMGAgglomeration::nPatchFaces_, GAMGAgglomeration::patchFaceRestrictAddressing_, OSstream::precision(), GAMGAgglomeration::procAgglomeratorPtr_, GAMGAgglomeration::procAgglomMap_, GAMGAgglomeration::procBoundaryFaceMap_, GAMGAgglomeration::procBoundaryMap_, GAMGAgglomeration::procCellOffsets_, GAMGAgglomeration::procCommunicator_, GAMGAgglomeration::processorAgglomerate(), GAMGAgglomeration::procFaceMap_, GAMGAgglomeration::restrictAddressing_, Foam::returnReduce(), Tuple2< T1, T2 >::second(), UPtrList< T >::set(), List< T >::setSize(), Foam::setw(), lduAddressing::size(), GAMGAgglomeration::size(), UPtrList< T >::size(), UList< T >::size(), messageStream::stream(), and Foam::type().

Referenced by pairGAMGAgglomeration::agglomerate(), dummyAgglomeration::dummyAgglomeration(), and MGridGenGAMGAgglomeration::MGridGenGAMGAgglomeration().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ continueAgglomerating()

bool continueAgglomerating ( const label  nCells,
const label  nCoarseCells 
) const
protected

Check the need for further agglomeration.

Definition at line 210 of file GAMGAgglomeration.C.

References PstreamBuffers::nProcs(), and Foam::returnReduce().

Referenced by pairGAMGAgglomeration::agglomerate(), and MGridGenGAMGAgglomeration::MGridGenGAMGAgglomeration().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ clearLevel()

void clearLevel ( const label  leveli)
protected

Definition at line 499 of file GAMGAgglomeration.C.

◆ procAgglomerateLduAddressing()

void procAgglomerateLduAddressing ( const label  comm,
const labelList procAgglomMap,
const labelList procIDs,
const label  allMeshComm,
const label  levelIndex 
)
protected

Collect and combine processor meshes into allMesh:

  • allMeshComm : communicator for combined mesh.
  • procAgglomMap : per processor the new agglomerated processor (rank in allMeshComm!). Global information.
  • procIDs : local information: same for all in agglomerated processor.

Definition at line 426 of file GAMGAgglomerateLduAddressing.C.

References lduPrimitiveMesh::gather(), processorFaPatch::myProcNo(), and List< T >::set().

Here is the call graph for this function:

◆ procAgglomerateRestrictAddressing()

void procAgglomerateRestrictAddressing ( const label  comm,
const labelList procIDs,
const label  levelIndex 
)
protected

Collect and combine basic restriction addressing:

  • nCells_
  • restrictAddressing_

Definition at line 499 of file GAMGAgglomerateLduAddressing.C.

References forAll, globalIndex::gather(), globalIndex::gatherValues(), UList< T >::last(), UPstream::msgType(), processorFaPatch::myProcNo(), UPstream::nonBlocking, UPstream::scheduled, UList< T >::size(), and List< T >::transfer().

Here is the call graph for this function:

◆ operator=()

void operator= ( const GAMGAgglomeration )
protecteddelete

No copy assignment.

◆ TypeName()

TypeName ( "GAMGAgglomeration"  )

Runtime type information.

◆ declareRunTimeSelectionTable() [1/3]

declareRunTimeSelectionTable ( autoPtr  ,
GAMGAgglomeration  ,
lduMesh  ,
(const lduMesh &mesh, const dictionary &controlDict ,
(mesh, controlDict  
)

Runtime selection table for pure geometric agglomerators.

◆ declareRunTimeSelectionTable() [2/3]

declareRunTimeSelectionTable ( autoPtr  ,
GAMGAgglomeration  ,
lduMatrix  ,
(const lduMatrix &matrix, const dictionary &controlDict ,
(matrix, controlDict  
)

Runtime selection table for matrix or mixed geometric/matrix agglomerators

◆ declareRunTimeSelectionTable() [3/3]

declareRunTimeSelectionTable ( autoPtr  ,
GAMGAgglomeration  ,
geometry  ,
(const lduMesh &mesh, const scalarField &cellVolumes, const vectorField &faceAreas, const dictionary &controlDict ,
(mesh, cellVolumes, faceAreas, controlDict  
)

Runtime selection table for matrix or mixed geometric/matrix agglomerators

◆ New() [1/3]

const Foam::GAMGAgglomeration & New ( const lduMesh mesh,
const dictionary controlDict 
)
static

Return the selected geometric agglomerator.

Definition at line 292 of file GAMGAgglomeration.C.

References objectRegistry::cfindObject(), controlDict(), Foam::endl(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Time::libs(), mesh, dlLibraryTable::open(), fvMesh::thisDb(), objectRegistry::time(), and ensightPTraits< Type >::typeName.

Here is the call graph for this function:

◆ New() [2/3]

const Foam::GAMGAgglomeration & New ( const lduMatrix matrix,
const dictionary controlDict 
)
static

Return the selected matrix agglomerator.

Definition at line 341 of file GAMGAgglomeration.C.

References objectRegistry::cfindObject(), controlDict(), Time::libs(), mesh, lduMatrix::mesh(), Foam::New(), dlLibraryTable::open(), fvMesh::thisDb(), objectRegistry::time(), and ensightPTraits< Type >::typeName.

Here is the call graph for this function:

◆ New() [3/3]

const Foam::GAMGAgglomeration & New ( const lduMesh mesh,
const scalarField cellVolumes,
const vectorField faceAreas,
const dictionary controlDict 
)
static

Return the selected geometric agglomerator.

Definition at line 387 of file GAMGAgglomeration.C.

References objectRegistry::cfindObject(), controlDict(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, mesh, fvMesh::thisDb(), objectRegistry::time(), and ensightPTraits< Type >::typeName.

Here is the call graph for this function:

◆ size()

label size ( ) const
inline

◆ meshLevel()

const Foam::lduMesh & meshLevel ( const label  leveli) const

Return LDU mesh of given level.

Definition at line 454 of file GAMGAgglomeration.C.

Referenced by pairGAMGAgglomeration::agglomerate(), GAMGAgglomeration::agglomerateLduAddressing(), GAMGAgglomeration::compactLevels(), GAMGSolver::GAMGSolver(), MGridGenGAMGAgglomeration::MGridGenGAMGAgglomeration(), and GAMGProcAgglomeration::printStats().

Here is the caller graph for this function:

◆ hasMeshLevel()

bool hasMeshLevel ( const label  leveli) const

Do we have mesh for given level?

Definition at line 470 of file GAMGAgglomeration.C.

Referenced by GAMGAgglomeration::compactLevels(), GAMGSolver::GAMGSolver(), and GAMGProcAgglomeration::printStats().

Here is the caller graph for this function:

◆ interfaceLevel()

const Foam::lduInterfacePtrsList & interfaceLevel ( const label  leveli) const

Return LDU interface addressing of given level.

Definition at line 483 of file GAMGAgglomeration.C.

Referenced by GAMGAgglomeration::agglomerateLduAddressing(), and GAMGSolver::GAMGSolver().

Here is the caller graph for this function:

◆ restrictAddressing()

const labelField & restrictAddressing ( const label  leveli) const
inline

Return cell restrict addressing of given level.

Definition at line 331 of file GAMGAgglomeration.H.

References GAMGAgglomeration::restrictAddressing_.

Referenced by GAMGAgglomeration::agglomerateLduAddressing(), GAMGProcAgglomeration::printStats(), and dynamicOversetFvMesh::writeAgglomeration().

Here is the caller graph for this function:

◆ faceRestrictAddressing()

const labelList & faceRestrictAddressing ( const label  leveli) const
inline

Return face restrict addressing of given level.

Definition at line 337 of file GAMGAgglomeration.H.

References GAMGAgglomeration::faceRestrictAddressing_.

Referenced by GAMGProcAgglomeration::printStats().

Here is the caller graph for this function:

◆ patchFaceRestrictAddressing()

const labelListList & patchFaceRestrictAddressing ( const label  leveli) const
inline

Definition at line 342 of file GAMGAgglomeration.H.

References GAMGAgglomeration::patchFaceRestrictAddressing_.

Referenced by GAMGProcAgglomeration::printStats().

Here is the caller graph for this function:

◆ faceFlipMap()

const boolList & faceFlipMap ( const label  leveli) const
inline

Return face flip map of given level.

Definition at line 349 of file GAMGAgglomeration.H.

References GAMGAgglomeration::faceFlipMap_.

Referenced by GAMGAgglomeration::agglomerateLduAddressing().

Here is the caller graph for this function:

◆ nCells()

label nCells ( const label  leveli) const
inline

Return number of coarse cells (before processor agglomeration)

Definition at line 355 of file GAMGAgglomeration.H.

References GAMGAgglomeration::nCells_.

Referenced by GAMGAgglomeration::compactLevels(), and GAMGProcAgglomeration::printStats().

Here is the caller graph for this function:

◆ nFaces()

label nFaces ( const label  leveli) const
inline

Return number of coarse faces (before processor agglomeration)

Definition at line 361 of file GAMGAgglomeration.H.

References GAMGAgglomeration::nFaces_.

Referenced by GAMGProcAgglomeration::printStats().

Here is the caller graph for this function:

◆ nPatchFaces()

const labelList & nPatchFaces ( const label  leveli) const
inline

Return number of coarse patch faces (before processor agglomeration)

Definition at line 368 of file GAMGAgglomeration.H.

References GAMGAgglomeration::nPatchFaces_.

Referenced by GAMGAgglomeration::agglomerateLduAddressing().

Here is the caller graph for this function:

◆ restrictField() [1/2]

void restrictField ( Field< Type > &  cf,
const Field< Type > &  ff,
const label  fineLevelIndex,
const bool  procAgglom 
) const

Restrict (integrate by summation) cell field.

Definition at line 52 of file GAMGAgglomerationTemplates.C.

References Foam::abort(), Foam::FatalError, FatalErrorInFunction, globalIndex::gather(), UPstream::msgType(), UPstream::nonBlocking, splitCell::parent(), and UList< T >::size().

Referenced by MGridGenGAMGAgglomeration::MGridGenGAMGAgglomeration().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ restrictFaceField()

void restrictFaceField ( Field< Type > &  cf,
const Field< Type > &  ff,
const label  fineLevelIndex 
) const

Restrict (integrate by summation) face field.

Definition at line 97 of file GAMGAgglomerationTemplates.C.

References Foam::abort(), Foam::FatalError, FatalErrorInFunction, forAll, UList< T >::size(), and Foam::Zero.

Referenced by pairGAMGAgglomeration::agglomerate(), and MGridGenGAMGAgglomeration::MGridGenGAMGAgglomeration().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ restrictField() [2/2]

void restrictField ( Field< Type > &  cf,
const Field< Type > &  ff,
const labelList fineToCoarse 
) const

Restrict (integrate by summation) cell field.

Definition at line 35 of file GAMGAgglomerationTemplates.C.

References forAll, and Foam::Zero.

◆ prolongField()

void prolongField ( Field< Type > &  ff,
const Field< Type > &  cf,
const label  coarseLevelIndex,
const bool  procAgglom 
) const

Prolong (interpolate by injection) cell field.

Definition at line 130 of file GAMGAgglomerationTemplates.C.

References forAll, UPstream::msgType(), UPstream::nonBlocking, splitCell::parent(), and globalIndex::scatter().

Here is the call graph for this function:

◆ calculateRegionMaster()

void calculateRegionMaster ( const label  comm,
const labelList procAgglomMap,
labelList masterProcs,
List< label > &  agglomProcIDs 
)
static

Given fine to coarse processor map determine:

  • for each coarse processor a master (minimum of the fine processors)
  • for each coarse processor the set of fine processors (element 0 is the master processor)

Definition at line 674 of file GAMGAgglomerateLduAddressing.C.

References HashTable< T, Key, Hash >::find(), UList< T >::find(), Foam::findIndices(), forAll, forAllConstIters, HashTable< T, Key, Hash >::insert(), Foam::min(), processorFaPatch::myProcNo(), List< T >::setSize(), HashTable< T, Key, Hash >::size(), and UList< T >::size().

Referenced by eagerGAMGProcAgglomeration::agglomerate(), masterCoarsestGAMGProcAgglomeration::agglomerate(), and procFacesGAMGProcAgglomeration::agglomerate().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ processorAgglomerate()

bool processorAgglomerate ( ) const
inline

Whether to agglomerate across processors.

Definition at line 435 of file GAMGAgglomeration.H.

References bool, and GAMGAgglomeration::procAgglomeratorPtr_.

Referenced by GAMGAgglomeration::compactLevels(), GAMGAgglomeration::GAMGAgglomeration(), and GAMGSolver::GAMGSolver().

Here is the caller graph for this function:

◆ procAgglomMap()

const Foam::labelList & procAgglomMap ( const label  fineLeveli) const

Mapping from processor to agglomerated processor (global, all processors have the same information). Note that level is the fine, not the coarse, level index. This is to be consistent with the way the restriction is stored

Definition at line 519 of file GAMGAgglomeration.C.

Referenced by GAMGSolver::GAMGSolver().

Here is the caller graph for this function:

◆ agglomProcIDs()

const Foam::labelList & agglomProcIDs ( const label  fineLeveli) const

Set of processors to agglomerate. Element 0 is the master processor. (local, same only on those processors that agglomerate)

Definition at line 528 of file GAMGAgglomeration.C.

Referenced by GAMGSolver::GAMGSolver().

Here is the caller graph for this function:

◆ hasProcMesh()

bool hasProcMesh ( const label  fineLeveli) const

Check that level has combined mesh.

Definition at line 537 of file GAMGAgglomeration.C.

Referenced by GAMGSolver::GAMGSolver().

Here is the caller graph for this function:

◆ procCommunicator()

Foam::label procCommunicator ( const label  fineLeveli) const

Communicator for current level or -1.

Definition at line 543 of file GAMGAgglomeration.C.

◆ cellOffsets()

const Foam::labelList & cellOffsets ( const label  fineLeveli) const

Mapping from processor to procMesh cells.

Definition at line 549 of file GAMGAgglomeration.C.

◆ faceMap()

const Foam::labelListList & faceMap ( const label  fineLeveli) const

Mapping from processor to procMesh face.

Definition at line 558 of file GAMGAgglomeration.C.

◆ boundaryMap()

const Foam::labelListList & boundaryMap ( const label  fineLeveli) const

Mapping from processor to procMesh boundary.

Definition at line 567 of file GAMGAgglomeration.C.

◆ boundaryFaceMap()

const Foam::labelListListList & boundaryFaceMap ( const label  fineLeveli) const

Mapping from processor to procMesh boundary face.

Definition at line 576 of file GAMGAgglomeration.C.

◆ checkRestriction()

bool checkRestriction ( labelList newRestrict,
label &  nNewCoarse,
const lduAddressing fineAddressing,
const labelUList restriction,
const label  nCoarse 
)
static

Given restriction determines if coarse cells are connected.

Return ok is so, otherwise creates new restriction that is

Definition at line 585 of file GAMGAgglomeration.C.

References Foam::abort(), List< T >::append(), Foam::FatalError, FatalErrorInFunction, UList< T >::find(), forAll, UList< T >::found(), Foam::identity(), lduAddressing::lowerAddr(), Foam::reduce(), List< T >::setSize(), lduAddressing::size(), UList< T >::size(), and lduAddressing::upperAddr().

Here is the call graph for this function:

Friends And Related Function Documentation

◆ GAMGProcAgglomeration

friend class GAMGProcAgglomeration
friend

Declare friendship with GAMGProcAgglomeration.

Definition at line 206 of file GAMGAgglomeration.H.

Member Data Documentation

◆ maxLevels_

const label maxLevels_
protected

◆ nCellsInCoarsestLevel_

label nCellsInCoarsestLevel_
protected

Number of cells in coarsest level.

Definition at line 76 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::GAMGAgglomeration().

◆ meshInterfaces_

const lduInterfacePtrsList meshInterfaces_
protected

Cached mesh interfaces.

Definition at line 79 of file GAMGAgglomeration.H.

◆ procAgglomeratorPtr_

autoPtr<GAMGProcAgglomeration> procAgglomeratorPtr_
protected

◆ nCells_

◆ restrictAddressing_

◆ nFaces_

labelList nFaces_
protected

The number of (coarse) faces in each level.

max(faceRestrictAddressing)+1.

Definition at line 92 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::agglomerateLduAddressing(), GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::nFaces().

◆ faceRestrictAddressing_

PtrList<labelList> faceRestrictAddressing_
protected

Face restriction addressing array.

Maps from the finer to the coarser level. Positive indices map the finer faces which form part of the boundary of the coarser cells to the corresponding coarser cell face. Negative indices map the finer faces which are internal to the coarser cells to minus the corresponding coarser cell index minus 1.

Definition at line 100 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::agglomerateLduAddressing(), GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::faceRestrictAddressing().

◆ faceFlipMap_

PtrList<boolList> faceFlipMap_
protected

Face flip: for faces mapped to internal faces stores whether.

the face is reversed or not. This is used to avoid having to access the coarse mesh at all when mapping

Definition at line 105 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::agglomerateLduAddressing(), GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::faceFlipMap().

◆ nPatchFaces_

PtrList<labelList> nPatchFaces_
protected

The number of (coarse) patch faces in each level.

max(patchFaceRestrictAddressing_)+1.

Definition at line 109 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::agglomerateLduAddressing(), GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::nPatchFaces().

◆ patchFaceRestrictAddressing_

PtrList<labelListList> patchFaceRestrictAddressing_
protected

Patch-local face restriction addressing array.

Maps from the finer to the coarser level. Always positive. Extracted from GAMGInterfaces after agglomeration.

Definition at line 114 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::agglomerateLduAddressing(), GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::patchFaceRestrictAddressing().

◆ meshLevels_

◆ procAgglomMap_

PtrList<labelList> procAgglomMap_
mutableprotected

Per level, per processor the processor it agglomerates into.

Definition at line 123 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::compactLevels(), GAMGAgglomeration::GAMGAgglomeration(), and GAMGProcAgglomeration::printStats().

◆ agglomProcIDs_

PtrList<labelList> agglomProcIDs_
mutableprotected

Per level the set of processors to agglomerate. Element 0 is.

the 'master' of the cluster.

Definition at line 127 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::compactLevels(), GAMGAgglomeration::GAMGAgglomeration(), and GAMGProcAgglomeration::printStats().

◆ procCommunicator_

labelList procCommunicator_
mutableprotected

◆ procCellOffsets_

PtrList<labelList> procCellOffsets_
mutableprotected

Mapping from processor to procMeshLevel cells.

Definition at line 133 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::compactLevels(), GAMGAgglomeration::GAMGAgglomeration(), and GAMGProcAgglomeration::printStats().

◆ procFaceMap_

PtrList<labelListList> procFaceMap_
mutableprotected

Mapping from processor to procMeshLevel face.

Definition at line 136 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::GAMGAgglomeration().

◆ procBoundaryMap_

PtrList<labelListList> procBoundaryMap_
mutableprotected

Mapping from processor to procMeshLevel boundary.

Definition at line 139 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::GAMGAgglomeration().

◆ procBoundaryFaceMap_

PtrList<labelListListList> procBoundaryFaceMap_
mutableprotected

Mapping from processor to procMeshLevel boundary face.

Definition at line 142 of file GAMGAgglomeration.H.

Referenced by GAMGAgglomeration::compactLevels(), and GAMGAgglomeration::GAMGAgglomeration().


The documentation for this class was generated from the following files: