Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
decompositionMethod Class Referenceabstract

Abstract base class for decomposition. More...

Inheritance diagram for decompositionMethod:
Inheritance graph
[legend]
Collaboration diagram for decompositionMethod:
Collaboration graph
[legend]

Public Member Functions

 TypeName ("decompositionMethod")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, decompositionMethod, dictionary,( const dictionary &decompositionDict ),(decompositionDict))
 
 decompositionMethod (const dictionary &decompositionDict)
 Construct given the decomposition dictionary. More...
 
virtual ~decompositionMethod ()
 Destructor. More...
 
label nDomains () const
 
virtual bool parallelAware () const =0
 Is method parallel aware (i.e. does it synchronize domains across. More...
 
virtual labelList decompose (const pointField &points, const scalarField &pointWeights)
 Return for every coordinate the wanted processor number. More...
 
virtual labelList decompose (const pointField &)
 Like decompose but with uniform weights on the points. More...
 
virtual labelList decompose (const polyMesh &mesh, const pointField &points, const scalarField &pointWeights)=0
 Return for every coordinate the wanted processor number. Use the. More...
 
virtual labelList decompose (const polyMesh &, const pointField &)
 Like decompose but with uniform weights on the points. More...
 
virtual labelList decompose (const polyMesh &mesh, const labelList &cellToRegion, const pointField &regionPoints, const scalarField &regionWeights)
 Return for every coordinate the wanted processor number. Gets. More...
 
virtual labelList decompose (const polyMesh &mesh, const labelList &cellToRegion, const pointField &regionPoints)
 Like decompose but with uniform weights on the regions. More...
 
virtual labelList decompose (const labelListList &globalCellCells, const pointField &cc, const scalarField &cWeights)=0
 Return for every coordinate the wanted processor number. More...
 
virtual labelList decompose (const labelListList &globalCellCells, const pointField &cc)
 Like decompose but with uniform weights on the cells. More...
 
void setConstraints (const polyMesh &mesh, boolList &blockedFace, PtrList< labelList > &specifiedProcessorFaces, labelList &specifiedProcessor, List< labelPair > &explicitConnections)
 Helper: extract constraints: More...
 
virtual labelList decompose (const polyMesh &mesh, const scalarField &cellWeights, const boolList &blockedFace, const PtrList< labelList > &specifiedProcessorFaces, const labelList &specifiedProcessor, const List< labelPair > &explicitConnections)
 
labelList decompose (const polyMesh &mesh, const scalarField &cWeights)
 Decompose a mesh. Apply all constraints from decomposeParDict. More...
 

Static Public Member Functions

static autoPtr< decompositionMethodNew (const dictionary &decompositionDict)
 Return a reference to the selected decomposition method. More...
 
static void calcCellCells (const polyMesh &mesh, const labelList &agglom, const label nLocalCoarse, const bool global, CompactListList< label > &cellCells)
 Helper: determine (local or global) cellCells from mesh. More...
 

Protected Attributes

const dictionarydecompositionDict_
 
label nProcessors_
 

Detailed Description

Abstract base class for decomposition.

Source files

Definition at line 48 of file decompositionMethod.H.

Constructor & Destructor Documentation

decompositionMethod ( const dictionary decompositionDict)
inline

Construct given the decomposition dictionary.

Definition at line 100 of file decompositionMethod.H.

virtual ~decompositionMethod ( )
inlinevirtual

Destructor.

Definition at line 111 of file decompositionMethod.H.

Member Function Documentation

TypeName ( "decompositionMethod"  )

Runtime type information.

declareRunTimeSelectionTable ( autoPtr  ,
decompositionMethod  ,
dictionary  ,
( const dictionary &decompositionDict )  ,
(decompositionDict)   
)
Foam::autoPtr< Foam::decompositionMethod > New ( const dictionary decompositionDict)
static

Return a reference to the selected decomposition method.

Definition at line 50 of file decompositionMethod.C.

References decompositionMethod::decompose(), Foam::endl(), Foam::exit(), Foam::FatalError, FatalErrorIn, Foam::Info, dictionary::lookup(), Foam::nl, and UPstream::parRun().

Referenced by multiLevelDecomp::multiLevelDecomp(), NamedEnum< Enum, nEnum >::names(), and structuredDecomp::structuredDecomp().

Here is the call graph for this function:

Here is the caller graph for this function:

label nDomains ( ) const
inline

Definition at line 117 of file decompositionMethod.H.

References decompositionMethod::decompose(), decompositionMethod::nProcessors_, and decompositionMethod::parallelAware().

Referenced by multiLevelDecomp::multiLevelDecomp(), and structuredDecomp::structuredDecomp().

Here is the call graph for this function:

Here is the caller graph for this function:

virtual bool parallelAware ( ) const
pure virtual

Is method parallel aware (i.e. does it synchronize domains across.

proc boundaries)

Implemented in hierarchGeomDecomp, multiLevelDecomp, ptscotchDecomp, scotchDecomp, simpleGeomDecomp, structuredDecomp, metisDecomp, manualDecomp, and noDecomp.

Referenced by decompositionMethod::nDomains().

Here is the caller graph for this function:

virtual labelList decompose ( const pointField points,
const scalarField pointWeights 
)
inlinevirtual
virtual labelList decompose ( const pointField )
inlinevirtual

Like decompose but with uniform weights on the points.

Reimplemented in hierarchGeomDecomp, simpleGeomDecomp, and geomDecomp.

Definition at line 145 of file decompositionMethod.H.

References decompositionMethod::calcCellCells(), decompositionMethod::decompose(), mesh, notImplemented, and decompositionMethod::setConstraints().

Here is the call graph for this function:

virtual labelList decompose ( const polyMesh mesh,
const pointField points,
const scalarField pointWeights 
)
pure virtual

Return for every coordinate the wanted processor number. Use the.

mesh connectivity (if needed)

Implemented in hierarchGeomDecomp, ptscotchDecomp, multiLevelDecomp, scotchDecomp, simpleGeomDecomp, metisDecomp, structuredDecomp, manualDecomp, and noDecomp.

Foam::labelList decompose ( const polyMesh mesh,
const pointField points 
)
virtual

Like decompose but with uniform weights on the points.

Reimplemented in hierarchGeomDecomp, and simpleGeomDecomp.

Definition at line 85 of file decompositionMethod.C.

References decompositionMethod::decompose(), and List< T >::size().

Here is the call graph for this function:

Foam::labelList decompose ( const polyMesh mesh,
const labelList cellToRegion,
const pointField regionPoints,
const scalarField regionWeights 
)
virtual

Return for every coordinate the wanted processor number. Gets.

passed agglomeration map (from fine to coarse cells) and coarse cell location. Can be overridden by decomposers that provide this functionality natively. Coarse cells are local to the processor (if in parallel). If you want to have coarse cells spanning processors use the globalCellCells instead.

Reimplemented in ptscotchDecomp, scotchDecomp, and metisDecomp.

Definition at line 97 of file decompositionMethod.C.

References decompositionMethod::decompose(), forAll, and List< T >::size().

Here is the call graph for this function:

Foam::labelList decompose ( const polyMesh mesh,
const labelList cellToRegion,
const pointField regionPoints 
)
virtual

Like decompose but with uniform weights on the regions.

Definition at line 138 of file decompositionMethod.C.

References decompositionMethod::decompose(), and List< T >::size().

Here is the call graph for this function:

virtual labelList decompose ( const labelListList globalCellCells,
const pointField cc,
const scalarField cWeights 
)
pure virtual

Return for every coordinate the wanted processor number.

The connectivity is equal to mesh.cellCells() except for

  • in parallel the cell numbers are global cell numbers (starting from 0 at processor0 and then incrementing all through the processors)
  • the connections are across coupled patches

Implemented in hierarchGeomDecomp, ptscotchDecomp, scotchDecomp, metisDecomp, multiLevelDecomp, simpleGeomDecomp, manualDecomp, noDecomp, and structuredDecomp.

Foam::labelList decompose ( const labelListList globalCellCells,
const pointField cc 
)
virtual

Like decompose but with uniform weights on the cells.

Reimplemented in hierarchGeomDecomp.

Definition at line 157 of file decompositionMethod.C.

References decompositionMethod::calcCellCells(), and List< T >::size().

Here is the call graph for this function:

void calcCellCells ( const polyMesh mesh,
const labelList agglom,
const label  nLocalCoarse,
const bool  global,
CompactListList< label > &  cellCells 
)
static
void setConstraints ( const polyMesh mesh,
boolList blockedFace,
PtrList< labelList > &  specifiedProcessorFaces,
labelList specifiedProcessor,
List< labelPair > &  explicitConnections 
)
Foam::labelList decompose ( const polyMesh mesh,
const scalarField cellWeights,
const boolList blockedFace,
const PtrList< labelList > &  specifiedProcessorFaces,
const labelList specifiedProcessor,
const List< labelPair > &  explicitConnections 
)
virtual
Foam::labelList decompose ( const polyMesh mesh,
const scalarField cWeights 
)

Decompose a mesh. Apply all constraints from decomposeParDict.

('preserveFaceZones' etc). Calls either

  • no constraints, empty weights: decompose(mesh, cellCentres())
  • no constraints, set weights: decompose(mesh, cellCentres(), cellWeights)
  • valid constraints: decompose(mesh, cellToRegion, regionPoints, regionWeights)

Definition at line 1297 of file decompositionMethod.C.

Member Data Documentation

const dictionary& decompositionDict_
protected

Definition at line 55 of file decompositionMethod.H.

label nProcessors_
protected

Definition at line 56 of file decompositionMethod.H.

Referenced by manualDecomp::decompose(), and decompositionMethod::nDomains().


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