Lagrangian: Added support for automatic run-time load-balancing

Optional CPU load caching can be switched-on for Lagrangian cloud tracking
and/or chemistry integration using the new cpuLoad switch in the cloudProperties
or chemistryProperties dictionary files respectively and used for
multi-constraint load-balancing by the fvMeshDistributorsLoadBalancer specified
in the dynamicMeshDict file

distributor
{
    type            loadBalancer;

    libs            ("libfvMeshDistributors.so");

    multiConstraint true;
    redistributionInterval  10;
}

which used the distributor specified in the decomposeParDict file, e.g.

numberOfSubdomains 12;

decomposer      simple;
distributor     zoltan;
libs            ("libzoltanDecomp.so");

simpleCoeffs
{
    n           (2 2 3);
}

zoltanCoeffs
{
    lb_method   rcb;
}

The incompressibleDenseParticleFluid/cyclone case has been updated to
demonstrate this new functionality and shows a speedup ~50% using the Zoltan RCB
multi-constraint distributor.  The multicomponentFluid/counterFlowFlame2D_GRI
case has also been updated to use the new cpuLoad switch.
This commit is contained in:
Henry Weller
2024-05-16 13:46:20 +01:00
parent 476bb42b04
commit 41705e9eca
21 changed files with 252 additions and 78 deletions

View File

@ -20,6 +20,8 @@ internalField uniform (0 0 0);
boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"
inlet
{
type fixedValue;

View File

@ -19,6 +19,8 @@ internalField uniform 1;
boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"
inlet
{
type fixedValue;

View File

@ -19,6 +19,8 @@ internalField uniform 0;
boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"
inlet
{
type calculated;

View File

@ -19,6 +19,8 @@ internalField uniform 0;
boundaryField
{
#includeEtc "caseDicts/setConstraintTypes"
inlet
{
type fixedFluxPressure;

View File

@ -16,6 +16,8 @@ FoamFile
type MPPICCloud;
cpuLoad true;
solution
{
coupled true;

View File

@ -0,0 +1,27 @@
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: dev
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
format ascii;
class dictionary;
object dynamicMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
distributor
{
type loadBalancer;
libs ("libfvMeshDistributors.so");
multiConstraint true;
redistributionInterval 10;
}
// ************************************************************************* //

View File

@ -58,6 +58,12 @@ boundary
(4 5 6 7)
);
}
internalFaces
{
type internal;
faces ();
}
);
// ************************************************************************* //

View File

@ -18,7 +18,7 @@ application foamRun;
solver incompressibleDenseParticleFluid;
startFrom latestTime;
startFrom startTime;
startTime 0;

View File

@ -16,11 +16,25 @@ FoamFile
numberOfSubdomains 12;
method simple;
decomposer simple;
distributor zoltan;
libs ("libzoltanDecomp.so");
simpleCoeffs
{
n (2 2 3);
n (2 2 3);
}
hierarchicalCoeffs
{
n (2 2 3);
order xyz;
}
zoltanCoeffs
{
lb_method rcb;
}
// ************************************************************************* //