driftFluxFoam: add support for alphaMax and d of the dispersed-phase
This commit is contained in:
parent
8f7efd3035
commit
ddf38857fc
3 changed files with 88 additions and 6 deletions
|
|
@ -43,9 +43,23 @@
|
||||||
{
|
{
|
||||||
Info<< "Applying the previous iteration correction flux" << endl;
|
Info<< "Applying the previous iteration correction flux" << endl;
|
||||||
#ifdef LTSSOLVE
|
#ifdef LTSSOLVE
|
||||||
MULES::LTScorrect(alpha1, phiAlpha, tphiAlphaCorr0(), 1, 0);
|
MULES::LTScorrect
|
||||||
|
(
|
||||||
|
alpha1,
|
||||||
|
phiAlpha,
|
||||||
|
tphiAlphaCorr0(),
|
||||||
|
mixture.alphaMax(),
|
||||||
|
0
|
||||||
|
);
|
||||||
#else
|
#else
|
||||||
MULES::correct(alpha1, phiAlpha, tphiAlphaCorr0(), 1, 0);
|
MULES::correct
|
||||||
|
(
|
||||||
|
alpha1,
|
||||||
|
phiAlpha,
|
||||||
|
tphiAlphaCorr0(),
|
||||||
|
mixture.alphaMax(),
|
||||||
|
0
|
||||||
|
);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
phiAlpha += tphiAlphaCorr0();
|
phiAlpha += tphiAlphaCorr0();
|
||||||
|
|
@ -79,9 +93,23 @@
|
||||||
volScalarField alpha10(alpha1);
|
volScalarField alpha10(alpha1);
|
||||||
|
|
||||||
#ifdef LTSSOLVE
|
#ifdef LTSSOLVE
|
||||||
MULES::LTScorrect(alpha1, tphiAlphaUn(), tphiAlphaCorr(), 1, 0);
|
MULES::LTScorrect
|
||||||
|
(
|
||||||
|
alpha1,
|
||||||
|
tphiAlphaUn(),
|
||||||
|
tphiAlphaCorr(),
|
||||||
|
mixture.alphaMax(),
|
||||||
|
0
|
||||||
|
);
|
||||||
#else
|
#else
|
||||||
MULES::correct(alpha1, tphiAlphaUn(), tphiAlphaCorr(), 1, 0);
|
MULES::correct
|
||||||
|
(
|
||||||
|
alpha1,
|
||||||
|
tphiAlphaUn(),
|
||||||
|
tphiAlphaCorr(),
|
||||||
|
mixture.alphaMax(),
|
||||||
|
0
|
||||||
|
);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Under-relax the correction for all but the 1st corrector
|
// Under-relax the correction for all but the 1st corrector
|
||||||
|
|
@ -100,9 +128,23 @@
|
||||||
phiAlpha = tphiAlphaUn;
|
phiAlpha = tphiAlphaUn;
|
||||||
|
|
||||||
#ifdef LTSSOLVE
|
#ifdef LTSSOLVE
|
||||||
MULES::explicitLTSSolve(alpha1, phi, phiAlpha, 1, 0);
|
MULES::explicitLTSSolve
|
||||||
|
(
|
||||||
|
alpha1,
|
||||||
|
phi,
|
||||||
|
phiAlpha,
|
||||||
|
mixture.alphaMax(),
|
||||||
|
0
|
||||||
|
);
|
||||||
#else
|
#else
|
||||||
MULES::explicitSolve(alpha1, phi, phiAlpha, 1, 0);
|
MULES::explicitSolve
|
||||||
|
(
|
||||||
|
alpha1,
|
||||||
|
phi,
|
||||||
|
phiAlpha,
|
||||||
|
mixture.alphaMax(),
|
||||||
|
0
|
||||||
|
);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -82,6 +82,13 @@ incompressibleTwoPhaseInteractingMixture
|
||||||
|
|
||||||
rhod_("rho", dimDensity, muModel_->viscosityProperties().lookup("rho")),
|
rhod_("rho", dimDensity, muModel_->viscosityProperties().lookup("rho")),
|
||||||
rhoc_("rho", dimDensity, nucModel_->viscosityProperties().lookup("rho")),
|
rhoc_("rho", dimDensity, nucModel_->viscosityProperties().lookup("rho")),
|
||||||
|
dd_
|
||||||
|
(
|
||||||
|
"d",
|
||||||
|
dimLength,
|
||||||
|
muModel_->viscosityProperties().lookupOrDefault("d", 0.0)
|
||||||
|
),
|
||||||
|
alphaMax_(muModel_->viscosityProperties().lookupOrDefault("alphaMax", 1.0)),
|
||||||
|
|
||||||
U_(U),
|
U_(U),
|
||||||
phi_(phi),
|
phi_(phi),
|
||||||
|
|
@ -118,6 +125,20 @@ bool Foam::incompressibleTwoPhaseInteractingMixture::read()
|
||||||
muModel_->viscosityProperties().lookup("rho") >> rhod_;
|
muModel_->viscosityProperties().lookup("rho") >> rhod_;
|
||||||
nucModel_->viscosityProperties().lookup("rho") >> rhoc_;
|
nucModel_->viscosityProperties().lookup("rho") >> rhoc_;
|
||||||
|
|
||||||
|
dd_ = dimensionedScalar
|
||||||
|
(
|
||||||
|
"d",
|
||||||
|
dimLength,
|
||||||
|
muModel_->viscosityProperties().lookupOrDefault("d", 0)
|
||||||
|
);
|
||||||
|
|
||||||
|
alphaMax_ =
|
||||||
|
muModel_->viscosityProperties().lookupOrDefault
|
||||||
|
(
|
||||||
|
"alphaMax",
|
||||||
|
1.0
|
||||||
|
);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -69,6 +69,12 @@ protected:
|
||||||
dimensionedScalar rhod_;
|
dimensionedScalar rhod_;
|
||||||
dimensionedScalar rhoc_;
|
dimensionedScalar rhoc_;
|
||||||
|
|
||||||
|
//- Optional diameter of the dispersed phase particles
|
||||||
|
dimensionedScalar dd_;
|
||||||
|
|
||||||
|
//- Optional maximum dispersed phase-fraction (e.g. packing limit)
|
||||||
|
scalar alphaMax_;
|
||||||
|
|
||||||
const volVectorField& U_;
|
const volVectorField& U_;
|
||||||
const surfaceScalarField& phi_;
|
const surfaceScalarField& phi_;
|
||||||
|
|
||||||
|
|
@ -121,6 +127,19 @@ public:
|
||||||
return rhoc_;
|
return rhoc_;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
//- Return the diameter of the dispersed-phase particles
|
||||||
|
const dimensionedScalar& dd() const
|
||||||
|
{
|
||||||
|
return dd_;
|
||||||
|
}
|
||||||
|
|
||||||
|
//- Optional maximum phase-fraction (e.g. packing limit)
|
||||||
|
// Defaults to 1
|
||||||
|
scalar alphaMax() const
|
||||||
|
{
|
||||||
|
return alphaMax_;
|
||||||
|
}
|
||||||
|
|
||||||
//- Return const-access to the mixture velocity
|
//- Return const-access to the mixture velocity
|
||||||
const volVectorField& U() const
|
const volVectorField& U() const
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue