mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: multiLevel decomposition method.
This commit is contained in:
@ -19,6 +19,7 @@ FoamFile
|
||||
|
||||
numberOfSubdomains 4;
|
||||
|
||||
|
||||
//- Keep owner and neighbour on same processor for faces in zones:
|
||||
// preserveFaceZones (heater solid1 solid3);
|
||||
|
||||
@ -28,15 +29,40 @@ numberOfSubdomains 4;
|
||||
//preservePatches (cyclic_half0 cyclic_half1);
|
||||
|
||||
|
||||
method scotch;
|
||||
// method scotch;
|
||||
// method hierarchical;
|
||||
// method simple;
|
||||
// method metis;
|
||||
// method manual;
|
||||
method multiLevel;
|
||||
|
||||
multiLevelCoeffs
|
||||
{
|
||||
level0
|
||||
{
|
||||
numberOfSubdomains 2;
|
||||
method simple;
|
||||
simpleCoeffs
|
||||
{
|
||||
n (2 1 1);
|
||||
delta 0.001;
|
||||
}
|
||||
}
|
||||
level1
|
||||
{
|
||||
numberOfSubdomains 2;
|
||||
method scotch;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Desired output
|
||||
|
||||
|
||||
|
||||
simpleCoeffs
|
||||
{
|
||||
n (2 2 1);
|
||||
n (2 1 1);
|
||||
delta 0.001;
|
||||
}
|
||||
|
||||
|
||||
@ -109,13 +109,12 @@ void Foam::domainDecomposition::distributeCells()
|
||||
|
||||
autoPtr<decompositionMethod> decomposePtr = decompositionMethod::New
|
||||
(
|
||||
decompositionDict_,
|
||||
*this
|
||||
decompositionDict_
|
||||
);
|
||||
|
||||
if (sameProcFaces.empty())
|
||||
{
|
||||
cellToProc_ = decomposePtr().decompose(cellCentres());
|
||||
cellToProc_ = decomposePtr().decompose(*this, cellCentres());
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -174,7 +173,12 @@ void Foam::domainDecomposition::distributeCells()
|
||||
|
||||
// Do decomposition on agglomeration
|
||||
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
cellToProc_ = decomposePtr().decompose(globalRegion, regionCentres);
|
||||
cellToProc_ = decomposePtr().decompose
|
||||
(
|
||||
*this,
|
||||
globalRegion,
|
||||
regionCentres
|
||||
);
|
||||
}
|
||||
|
||||
Info<< "\nFinished decomposition in "
|
||||
|
||||
@ -594,8 +594,7 @@ int main(int argc, char *argv[])
|
||||
(
|
||||
decompositionMethod::New
|
||||
(
|
||||
decompositionDict,
|
||||
mesh
|
||||
decompositionDict
|
||||
)
|
||||
);
|
||||
|
||||
@ -612,7 +611,7 @@ int main(int argc, char *argv[])
|
||||
<< endl;
|
||||
}
|
||||
|
||||
finalDecomp = decomposer().decompose(mesh.cellCentres());
|
||||
finalDecomp = decomposer().decompose(mesh, mesh.cellCentres());
|
||||
}
|
||||
|
||||
// Dump decomposition to volScalarField
|
||||
|
||||
Reference in New Issue
Block a user