mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
twoPhaseEulerFoam: Added IATE
This commit is contained in:
@ -23,7 +23,7 @@
|
||||
)/rho1
|
||||
|
||||
//***HGW- fvm::laplacian(alpha1*turbulence1->alphaEff(), he1)
|
||||
- fvm::laplacian(alpha1*turbulence1->nuEff(), he1)
|
||||
- fvm::laplacian(alpha1*phase1.turbulence().nuEff(), he1)
|
||||
==
|
||||
heatTransferCoeff*(thermo2.T() - thermo1.T())/rho1
|
||||
+ heatTransferCoeff*he1/Cpv1/rho1
|
||||
@ -46,7 +46,7 @@
|
||||
)/rho2
|
||||
|
||||
//***HGW- fvm::laplacian(alpha2*turbulence2->alphaEff(), he2)
|
||||
- fvm::laplacian(alpha2*turbulence2->nuEff(), he2)
|
||||
- fvm::laplacian(alpha2*phase2.turbulence().nuEff(), he2)
|
||||
==
|
||||
heatTransferCoeff*(thermo1.T() - thermo2.T())/rho2
|
||||
+ heatTransferCoeff*he2/Cpv2/rho2
|
||||
|
||||
@ -26,7 +26,7 @@ volScalarField dragCoeff(fluid.dragCoeff());
|
||||
- fvm::Sp(fvc::div(phi1), U1)
|
||||
)
|
||||
|
||||
+ turbulence1->divDevReff(U1)
|
||||
+ phase1.turbulence().divDevReff(U1)
|
||||
==
|
||||
- fvm::Sp(dragCoeff/rho1, U1)
|
||||
- alpha1*alpha2/rho1*(liftForce - fluid.Cvm()*rho2*DDtU2)
|
||||
@ -50,7 +50,7 @@ volScalarField dragCoeff(fluid.dragCoeff());
|
||||
+ fvm::div(phi2, U2)
|
||||
- fvm::Sp(fvc::div(phi2), U2)
|
||||
)
|
||||
+ turbulence2->divDevReff(U2)
|
||||
+ phase2.turbulence().divDevReff(U2)
|
||||
==
|
||||
- fvm::Sp(dragCoeff/rho2, U2)
|
||||
+ alpha1*alpha2/rho2*(liftForce + fluid.Cvm()*rho2*DDtU1)
|
||||
|
||||
@ -1,165 +0,0 @@
|
||||
{
|
||||
word alphaScheme("div(phi," + alpha1.name() + ')');
|
||||
word alpharScheme("div(phir," + alpha1.name() + ')');
|
||||
|
||||
alpha1.correctBoundaryConditions();
|
||||
|
||||
surfaceScalarField phic("phic", phi);
|
||||
surfaceScalarField phir("phir", phi1 - phi2);
|
||||
|
||||
surfaceScalarField alpha1f(fvc::interpolate(max(alpha1, scalar(0))));
|
||||
|
||||
tmp<surfaceScalarField> pPrimeByA;
|
||||
|
||||
if (implicitPhasePressure)
|
||||
{
|
||||
pPrimeByA =
|
||||
fvc::interpolate((1.0/rho1)*rAU1*turbulence1().pPrime())
|
||||
+ fvc::interpolate((1.0/rho2)*rAU2*turbulence2().pPrime());
|
||||
|
||||
surfaceScalarField phiP
|
||||
(
|
||||
pPrimeByA()*fvc::snGrad(alpha1, "bounded")*mesh.magSf()
|
||||
);
|
||||
|
||||
phic += alpha1f*phiP;
|
||||
phir += phiP;
|
||||
}
|
||||
|
||||
for (int acorr=0; acorr<nAlphaCorr; acorr++)
|
||||
{
|
||||
volScalarField::DimensionedInternalField Sp
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"Sp",
|
||||
runTime.timeName(),
|
||||
mesh
|
||||
),
|
||||
mesh,
|
||||
dimensionedScalar("Sp", dgdt.dimensions(), 0.0)
|
||||
);
|
||||
|
||||
volScalarField::DimensionedInternalField Su
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"Su",
|
||||
runTime.timeName(),
|
||||
mesh
|
||||
),
|
||||
// Divergence term is handled explicitly to be
|
||||
// consistent with the explicit transport solution
|
||||
fvc::div(phi)*min(alpha1, scalar(1))
|
||||
);
|
||||
|
||||
forAll(dgdt, celli)
|
||||
{
|
||||
if (dgdt[celli] > 0.0 && alpha1[celli] > 0.0)
|
||||
{
|
||||
Sp[celli] -= dgdt[celli]*alpha1[celli];
|
||||
Su[celli] += dgdt[celli]*alpha1[celli];
|
||||
}
|
||||
else if (dgdt[celli] < 0.0 && alpha1[celli] < 1.0)
|
||||
{
|
||||
Sp[celli] += dgdt[celli]*(1.0 - alpha1[celli]);
|
||||
}
|
||||
}
|
||||
|
||||
dimensionedScalar totalDeltaT = runTime.deltaT();
|
||||
if (nAlphaSubCycles > 1)
|
||||
{
|
||||
alphaPhi1 = dimensionedScalar("0", alphaPhi1.dimensions(), 0);
|
||||
}
|
||||
|
||||
for
|
||||
(
|
||||
subCycle<volScalarField> alphaSubCycle(alpha1, nAlphaSubCycles);
|
||||
!(++alphaSubCycle).end();
|
||||
)
|
||||
{
|
||||
surfaceScalarField alphaPhic1
|
||||
(
|
||||
fvc::flux
|
||||
(
|
||||
phic,
|
||||
alpha1,
|
||||
alphaScheme
|
||||
)
|
||||
+ fvc::flux
|
||||
(
|
||||
-fvc::flux(-phir, scalar(1) - alpha1, alpharScheme),
|
||||
alpha1,
|
||||
alpharScheme
|
||||
)
|
||||
);
|
||||
|
||||
// Ensure that the flux at inflow BCs is preserved
|
||||
forAll(alphaPhic1.boundaryField(), patchi)
|
||||
{
|
||||
fvsPatchScalarField& alphaPhic1p =
|
||||
alphaPhic1.boundaryField()[patchi];
|
||||
|
||||
if (!alphaPhic1p.coupled())
|
||||
{
|
||||
const scalarField& phi1p = phi1.boundaryField()[patchi];
|
||||
const scalarField& alpha1p = alpha1.boundaryField()[patchi];
|
||||
|
||||
forAll(alphaPhic1p, facei)
|
||||
{
|
||||
if (phi1p[facei] < 0)
|
||||
{
|
||||
alphaPhic1p[facei] = alpha1p[facei]*phi1p[facei];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
MULES::explicitSolve
|
||||
(
|
||||
geometricOneField(),
|
||||
alpha1,
|
||||
phi,
|
||||
alphaPhic1,
|
||||
Sp,
|
||||
Su,
|
||||
1,
|
||||
0
|
||||
);
|
||||
|
||||
if (nAlphaSubCycles > 1)
|
||||
{
|
||||
alphaPhi1 += (runTime.deltaT()/totalDeltaT)*alphaPhic1;
|
||||
}
|
||||
else
|
||||
{
|
||||
alphaPhi1 = alphaPhic1;
|
||||
}
|
||||
}
|
||||
|
||||
if (implicitPhasePressure)
|
||||
{
|
||||
fvScalarMatrix alpha1Eqn
|
||||
(
|
||||
fvm::ddt(alpha1) - fvc::ddt(alpha1)
|
||||
- fvm::laplacian(alpha1f*pPrimeByA, alpha1, "bounded")
|
||||
);
|
||||
|
||||
alpha1Eqn.relax();
|
||||
alpha1Eqn.solve();
|
||||
|
||||
alphaPhi1 += alpha1Eqn.flux();
|
||||
}
|
||||
|
||||
alphaPhi2 = phi - alphaPhi1;
|
||||
alpha2 = scalar(1) - alpha1;
|
||||
|
||||
Info<< "Dispersed phase volume fraction = "
|
||||
<< alpha1.weightedAverage(mesh.V()).value()
|
||||
<< " Min(alpha1) = " << min(alpha1).value()
|
||||
<< " Max(alpha1) = " << max(alpha1).value()
|
||||
<< endl;
|
||||
}
|
||||
}
|
||||
|
||||
rho = fluid.rho();
|
||||
@ -10,19 +10,13 @@
|
||||
|
||||
volVectorField& U1 = phase1.U();
|
||||
surfaceScalarField& phi1 = phase1.phi();
|
||||
surfaceScalarField alphaPhi1
|
||||
(
|
||||
IOobject::groupName("alphaPhi", phase1.name()),
|
||||
fvc::interpolate(alpha1)*phi1
|
||||
);
|
||||
surfaceScalarField& alphaPhi1 = phase1.phiAlpha();
|
||||
|
||||
volVectorField& U2 = phase2.U();
|
||||
surfaceScalarField& phi2 = phase2.phi();
|
||||
surfaceScalarField alphaPhi2
|
||||
(
|
||||
IOobject::groupName("alphaPhi", phase2.name()),
|
||||
fvc::interpolate(alpha2)*phi2
|
||||
);
|
||||
surfaceScalarField& alphaPhi2 = phase2.phiAlpha();
|
||||
|
||||
surfaceScalarField& phi = fluid.phi();
|
||||
|
||||
dimensionedScalar pMin
|
||||
(
|
||||
@ -55,19 +49,6 @@
|
||||
fluid.U()
|
||||
);
|
||||
|
||||
surfaceScalarField phi
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"phi",
|
||||
runTime.timeName(),
|
||||
mesh,
|
||||
IOobject::NO_READ,
|
||||
IOobject::AUTO_WRITE
|
||||
),
|
||||
fluid.phi()
|
||||
);
|
||||
|
||||
volScalarField rho
|
||||
(
|
||||
IOobject
|
||||
@ -133,13 +114,6 @@
|
||||
scalar pRefValue = 0.0;
|
||||
setRefCell(p, mesh.solutionDict().subDict("PIMPLE"), pRefCell, pRefValue);
|
||||
|
||||
|
||||
volScalarField dgdt
|
||||
(
|
||||
pos(alpha2)*fvc::div(phi)/max(alpha2, scalar(0.0001))
|
||||
);
|
||||
|
||||
|
||||
Info<< "Creating field dpdt\n" << endl;
|
||||
volScalarField dpdt
|
||||
(
|
||||
@ -157,29 +131,3 @@
|
||||
Info<< "Creating field kinetic energy K\n" << endl;
|
||||
volScalarField K1(IOobject::groupName("K", phase1.name()), 0.5*magSqr(U1));
|
||||
volScalarField K2(IOobject::groupName("K", phase2.name()), 0.5*magSqr(U2));
|
||||
|
||||
autoPtr<PhaseIncompressibleTurbulenceModel<phaseModel> >
|
||||
turbulence1
|
||||
(
|
||||
PhaseIncompressibleTurbulenceModel<phaseModel>::New
|
||||
(
|
||||
alpha1,
|
||||
U1,
|
||||
alphaPhi1,
|
||||
phi1,
|
||||
phase1
|
||||
)
|
||||
);
|
||||
|
||||
autoPtr<PhaseIncompressibleTurbulenceModel<phaseModel> >
|
||||
turbulence2
|
||||
(
|
||||
PhaseIncompressibleTurbulenceModel<phaseModel>::New
|
||||
(
|
||||
alpha2,
|
||||
U2,
|
||||
alphaPhi2,
|
||||
phi2,
|
||||
phase2
|
||||
)
|
||||
);
|
||||
|
||||
@ -31,7 +31,7 @@
|
||||
surfaceScalarField phiP1
|
||||
(
|
||||
"phiP1",
|
||||
fvc::interpolate((1.0/rho1)*rAU1*turbulence1().pPrime())
|
||||
fvc::interpolate((1.0/rho1)*rAU1*phase1.turbulence().pPrime())
|
||||
*fvc::snGrad(alpha1)*mesh.magSf()
|
||||
);
|
||||
|
||||
@ -39,7 +39,7 @@
|
||||
surfaceScalarField phiP2
|
||||
(
|
||||
"phiP2",
|
||||
fvc::interpolate((1.0/rho2)*rAU2*turbulence2().pPrime())
|
||||
fvc::interpolate((1.0/rho2)*rAU2*phase2.turbulence().pPrime())
|
||||
*fvc::snGrad(alpha2)*mesh.magSf()
|
||||
);
|
||||
|
||||
@ -199,7 +199,7 @@
|
||||
|
||||
phi = alpha1f*phi1 + alpha2f*phi2;
|
||||
|
||||
dgdt =
|
||||
fluid.dgdt() =
|
||||
(
|
||||
pos(alpha2)*(pEqnComp2 & p)/rho2
|
||||
- pos(alpha1)*(pEqnComp1 & p)/rho1
|
||||
|
||||
@ -1,7 +0,0 @@
|
||||
#include "readTimeControls.H"
|
||||
#include "alphaControls.H"
|
||||
|
||||
Switch implicitPhasePressure
|
||||
(
|
||||
alphaControls.lookupOrDefault<Switch>("implicitPhasePressure", false)
|
||||
);
|
||||
@ -31,13 +31,10 @@ Description
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "fvCFD.H"
|
||||
#include "MULES.H"
|
||||
#include "subCycle.H"
|
||||
#include "rhoThermo.H"
|
||||
#include "twoPhaseSystem.H"
|
||||
#include "PhaseIncompressibleTurbulenceModel.H"
|
||||
#include "dragModel.H"
|
||||
#include "heatTransferModel.H"
|
||||
#include "PhaseIncompressibleTurbulenceModel.H"
|
||||
#include "pimpleControl.H"
|
||||
#include "IOMRFZoneList.H"
|
||||
#include "fixedFluxPressureFvPatchScalarField.H"
|
||||
@ -66,7 +63,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
while (runTime.run())
|
||||
{
|
||||
#include "readTwoPhaseEulerFoamControls.H"
|
||||
#include "readTimeControls.H"
|
||||
#include "CourantNos.H"
|
||||
#include "setDeltaT.H"
|
||||
|
||||
@ -76,7 +73,10 @@ int main(int argc, char *argv[])
|
||||
// --- Pressure-velocity PIMPLE corrector loop
|
||||
while (pimple.loop())
|
||||
{
|
||||
#include "alphaEqn.H"
|
||||
fluid.solve();
|
||||
rho = fluid.rho();
|
||||
fluid.correct();
|
||||
|
||||
#include "EEqns.H"
|
||||
#include "UEqns.H"
|
||||
|
||||
@ -90,8 +90,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
if (pimple.turbCorr())
|
||||
{
|
||||
turbulence1->correct();
|
||||
turbulence2->correct();
|
||||
fluid.correctTurbulence();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -4,6 +4,12 @@ diameterModels/diameterModel/newDiameterModel.C
|
||||
diameterModels/constantDiameter/constantDiameter.C
|
||||
diameterModels/isothermalDiameter/isothermalDiameter.C
|
||||
|
||||
diameterModels/IATE/IATE.C
|
||||
diameterModels/IATE/IATEsources/IATEsource/IATEsource.C
|
||||
diameterModels/IATE/IATEsources/wakeEntrainmentCoalescence/wakeEntrainmentCoalescence.C
|
||||
diameterModels/IATE/IATEsources/turbulentBreakUp/turbulentBreakUp.C
|
||||
diameterModels/IATE/IATEsources/randomCoalescence/randomCoalescence.C
|
||||
|
||||
twoPhaseSystem.C
|
||||
|
||||
LIB = $(FOAM_LIBBIN)/libcompressibleTwoPhaseSystem
|
||||
|
||||
@ -3,7 +3,10 @@ EXE_INC = \
|
||||
-I../interfacialModels/lnInclude \
|
||||
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
||||
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
|
||||
-I$(LIB_SRC)/transportModels/incompressible/lnInclude
|
||||
-I$(LIB_SRC)/transportModels/incompressible/lnInclude \
|
||||
-I$(LIB_SRC)/TurbulenceModels/turbulenceModels/lnInclude \
|
||||
-I$(LIB_SRC)/TurbulenceModels/incompressible/lnInclude \
|
||||
-I$(LIB_SRC)/TurbulenceModels/phaseIncompressible/lnInclude
|
||||
|
||||
LIB_LIBS = \
|
||||
-lincompressibleTransportModels \
|
||||
|
||||
@ -0,0 +1,188 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "IATE.H"
|
||||
#include "IATEsource.H"
|
||||
#include "twoPhaseSystem.H"
|
||||
#include "fvmDdt.H"
|
||||
#include "fvmDiv.H"
|
||||
#include "fvmSup.H"
|
||||
#include "fvcDdt.H"
|
||||
#include "fvcDiv.H"
|
||||
#include "fvcAverage.H"
|
||||
#include "mathematicalConstants.H"
|
||||
#include "fundamentalConstants.H"
|
||||
#include "addToRunTimeSelectionTable.H"
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
defineTypeNameAndDebug(IATE, 0);
|
||||
|
||||
addToRunTimeSelectionTable
|
||||
(
|
||||
diameterModel,
|
||||
IATE,
|
||||
dictionary
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::diameterModels::IATE::IATE
|
||||
(
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
)
|
||||
:
|
||||
diameterModel(diameterProperties, phase),
|
||||
kappai_
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
IOobject::groupName("kappai", phase.name()),
|
||||
phase_.U().time().timeName(),
|
||||
phase_.U().mesh(),
|
||||
IOobject::MUST_READ,
|
||||
IOobject::AUTO_WRITE
|
||||
),
|
||||
phase_.U().mesh()
|
||||
),
|
||||
dMax_("dMax", dimLength, diameterProperties_.lookup("dMax")),
|
||||
dMin_("dMin", dimLength, diameterProperties_.lookup("dMin")),
|
||||
d_
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
IOobject::groupName("d", phase.name()),
|
||||
phase_.U().time().timeName(),
|
||||
phase_.U().mesh(),
|
||||
IOobject::NO_READ,
|
||||
IOobject::AUTO_WRITE
|
||||
),
|
||||
dsm()
|
||||
),
|
||||
sources_
|
||||
(
|
||||
diameterProperties_.lookup("sources"),
|
||||
IATEsource::iNew(*this)
|
||||
)
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::diameterModels::IATE::~IATE()
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATE::dsm() const
|
||||
{
|
||||
return max(6/max(kappai_, 6/dMax_), dMin_);
|
||||
}
|
||||
|
||||
// Placeholder for the nucleation/condensation model
|
||||
// Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATE::Rph() const
|
||||
// {
|
||||
// const volScalarField& T = phase_.thermo().T();
|
||||
// const volScalarField& p = phase_.thermo().p();
|
||||
//
|
||||
// scalar A, B, C, sigma, vm, Rph;
|
||||
//
|
||||
// volScalarField ps(1e5*pow(10, A - B/(T + C)));
|
||||
// volScalarField Dbc
|
||||
// (
|
||||
// 4*sigma*vm/(constant::physicoChemical::k*T*log(p/ps))
|
||||
// );
|
||||
//
|
||||
// return constant::mathematical::pi*sqr(Dbc)*Rph;
|
||||
// }
|
||||
|
||||
void Foam::diameterModels::IATE::correct()
|
||||
{
|
||||
// Initialise the accumulated source term to the dilatation effect
|
||||
volScalarField R
|
||||
(
|
||||
(
|
||||
(2.0/3.0)
|
||||
/max
|
||||
(
|
||||
fvc::average(phase_ + phase_.oldTime()),
|
||||
phase_.fluid().residualPhaseFraction()
|
||||
)
|
||||
)
|
||||
*(fvc::ddt(phase_) + fvc::div(phase_.phiAlpha()))
|
||||
);
|
||||
|
||||
// Accumulate the run-time selectable sources
|
||||
forAll(sources_, j)
|
||||
{
|
||||
R -= sources_[j].R();
|
||||
}
|
||||
|
||||
// Construct the interfacial curvature equation
|
||||
fvScalarMatrix kappaiEqn
|
||||
(
|
||||
fvm::ddt(kappai_) + fvm::div(phase_.phi(), kappai_)
|
||||
- fvm::Sp(fvc::div(phase_.phi()), kappai_)
|
||||
==
|
||||
- fvm::SuSp(R, kappai_)
|
||||
//+ Rph() // Omit the nucleation/condensation term
|
||||
);
|
||||
|
||||
kappaiEqn.relax();
|
||||
kappaiEqn.solve();
|
||||
|
||||
// Update the Sauter-mean diameter
|
||||
d_ = dsm();
|
||||
}
|
||||
|
||||
|
||||
bool Foam::diameterModels::IATE::read(const dictionary& phaseProperties)
|
||||
{
|
||||
diameterModel::read(phaseProperties);
|
||||
|
||||
diameterProperties_.lookup("dMax") >> dMax_;
|
||||
diameterProperties_.lookup("dMin") >> dMin_;
|
||||
|
||||
// Re-create all the sources updating number, type and coefficients
|
||||
PtrList<IATEsource>
|
||||
(
|
||||
diameterProperties_.lookup("sources"),
|
||||
IATEsource::iNew(*this)
|
||||
).transfer(sources_);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,154 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::diameterModels::IATE
|
||||
|
||||
Description
|
||||
IATE (Interfacial Area Transport Equation) bubble diameter model.
|
||||
|
||||
Solves for the interfacial curvature per unit volume of the phase rather
|
||||
than interfacial area per unit volume to avoid stability issues relating to
|
||||
the consistency requirements between the phase fraction and interfacial area
|
||||
per unit volume. In every other respect this model is as presented in the
|
||||
paper:
|
||||
|
||||
\verbatim
|
||||
"Development of Interfacial Area Transport Equation"
|
||||
M. Ishii,
|
||||
S. Kim,
|
||||
J Kelly,
|
||||
Nuclear Engineering and Technology, Vol.37 No.6 December 2005
|
||||
\endverbatim
|
||||
|
||||
SourceFiles
|
||||
IATE.C
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#ifndef IATE_H
|
||||
#define IATE_H
|
||||
|
||||
#include "diameterModel.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
|
||||
// Forward declaration of classes
|
||||
class IATEsource;
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class IATE Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
class IATE
|
||||
:
|
||||
public diameterModel
|
||||
{
|
||||
// Private data
|
||||
|
||||
//- Interfacial curvature (alpha*interfacial area)
|
||||
volScalarField kappai_;
|
||||
|
||||
//- Maximum diameter used for stabilisation in the limit kappai->0
|
||||
dimensionedScalar dMax_;
|
||||
|
||||
//- Minimum diameter used for stabilisation in the limit kappai->inf
|
||||
dimensionedScalar dMin_;
|
||||
|
||||
//- The Sauter-mean diameter of the phase
|
||||
volScalarField d_;
|
||||
|
||||
//- IATE sources
|
||||
PtrList<IATEsource> sources_;
|
||||
|
||||
|
||||
// Private member functions
|
||||
|
||||
tmp<volScalarField> dsm() const;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
friend class IATEsource;
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("IATE");
|
||||
|
||||
|
||||
// Constructors
|
||||
|
||||
//- Construct from components
|
||||
IATE
|
||||
(
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
);
|
||||
|
||||
|
||||
//- Destructor
|
||||
virtual ~IATE();
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
//- Return the interfacial curvature
|
||||
const volScalarField& kappai() const
|
||||
{
|
||||
return kappai_;
|
||||
}
|
||||
|
||||
//- Return the interfacial area
|
||||
tmp<volScalarField> a() const
|
||||
{
|
||||
return phase_*kappai_;
|
||||
}
|
||||
|
||||
//- Return the Sauter-mean diameter
|
||||
virtual tmp<volScalarField> d() const
|
||||
{
|
||||
return d_;
|
||||
}
|
||||
|
||||
//- Correct the diameter field
|
||||
virtual void correct();
|
||||
|
||||
//- Read phaseProperties dictionary
|
||||
virtual bool read(const dictionary& phaseProperties);
|
||||
};
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
} // End namespace diameterModels
|
||||
} // End namespace Foam
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#endif
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,147 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "IATEsource.H"
|
||||
#include "twoPhaseSystem.H"
|
||||
#include "fvMatrix.H"
|
||||
#include "PhaseIncompressibleTurbulenceModel.H"
|
||||
#include "uniformDimensionedFields.H"
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
defineTypeNameAndDebug(IATEsource, 0);
|
||||
defineRunTimeSelectionTable(IATEsource, dictionary);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::autoPtr<Foam::diameterModels::IATEsource>
|
||||
Foam::diameterModels::IATEsource::New
|
||||
(
|
||||
const word& type,
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
)
|
||||
{
|
||||
dictionaryConstructorTable::iterator cstrIter =
|
||||
dictionaryConstructorTablePtr_->find(type);
|
||||
|
||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||
{
|
||||
FatalErrorIn
|
||||
(
|
||||
"IATEsource::New"
|
||||
"(const word& type, const IATE&, const dictionary&)"
|
||||
) << "Unknown IATE source type "
|
||||
<< type << nl << nl
|
||||
<< "Valid IATE source types : " << endl
|
||||
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||
<< exit(FatalError);
|
||||
}
|
||||
|
||||
return autoPtr<IATEsource>(cstrIter()(iate, dict));
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATEsource::Ur() const
|
||||
{
|
||||
const uniformDimensionedVectorField& g =
|
||||
phase().U().db().lookupObject<uniformDimensionedVectorField>("g");
|
||||
|
||||
return
|
||||
sqrt(2.0)
|
||||
*pow025
|
||||
(
|
||||
fluid().sigma()*mag(g)
|
||||
*(otherPhase().rho() - phase().rho())
|
||||
/sqr(otherPhase().rho())
|
||||
)
|
||||
*pow(max(1 - phase(), scalar(0)), 1.75);
|
||||
}
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATEsource::Ut() const
|
||||
{
|
||||
return sqrt(2*otherPhase().turbulence().k());
|
||||
}
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATEsource::Re() const
|
||||
{
|
||||
return max(Ur()*phase().d()/otherPhase().nu(), scalar(1.0e-3));
|
||||
}
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATEsource::CD() const
|
||||
{
|
||||
const volScalarField Eo(this->Eo());
|
||||
const volScalarField Re(this->Re());
|
||||
|
||||
return
|
||||
max
|
||||
(
|
||||
min
|
||||
(
|
||||
(16/Re)*(1 + 0.15*pow(Re, 0.687)),
|
||||
48/Re
|
||||
),
|
||||
8*Eo/(3*(Eo + 4))
|
||||
);
|
||||
}
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATEsource::Mo() const
|
||||
{
|
||||
const uniformDimensionedVectorField& g =
|
||||
phase().U().db().lookupObject<uniformDimensionedVectorField>("g");
|
||||
|
||||
return
|
||||
mag(g)*pow4(otherPhase().nu())*sqr(otherPhase().rho())
|
||||
*(otherPhase().rho() - phase().rho())
|
||||
/pow3(fluid().sigma());
|
||||
}
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATEsource::Eo() const
|
||||
{
|
||||
const uniformDimensionedVectorField& g =
|
||||
phase().U().db().lookupObject<uniformDimensionedVectorField>("g");
|
||||
|
||||
return
|
||||
mag(g)*sqr(phase().d())
|
||||
*(otherPhase().rho() - phase().rho())
|
||||
/fluid().sigma();
|
||||
}
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::diameterModels::IATEsource::We() const
|
||||
{
|
||||
return otherPhase().rho()*sqr(Ur())*phase().d()/fluid().sigma();
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,192 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::diameterModels::IATEsource
|
||||
|
||||
Description
|
||||
IATE (Interfacial Area Transport Equation) bubble diameter model
|
||||
run-time selectable sources.
|
||||
|
||||
SourceFiles
|
||||
IATEsource.C
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#ifndef IATEsource_H
|
||||
#define IATEsource_H
|
||||
|
||||
#include "IATE.H"
|
||||
#include "mathematicalConstants.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class IATEsource Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
class IATEsource
|
||||
{
|
||||
|
||||
protected:
|
||||
|
||||
// Protected data
|
||||
|
||||
//- Reference to the IATE this source applies to
|
||||
const IATE& iate_;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("IATEsource");
|
||||
|
||||
|
||||
// Declare run-time constructor selection table
|
||||
|
||||
declareRunTimeSelectionTable
|
||||
(
|
||||
autoPtr,
|
||||
IATEsource,
|
||||
dictionary,
|
||||
(
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
),
|
||||
(iate, dict)
|
||||
);
|
||||
|
||||
|
||||
//- Class used for the read-construction of
|
||||
// PtrLists of IATE sources
|
||||
class iNew
|
||||
{
|
||||
const IATE& iate_;
|
||||
|
||||
public:
|
||||
|
||||
iNew(const IATE& iate)
|
||||
:
|
||||
iate_(iate)
|
||||
{}
|
||||
|
||||
autoPtr<IATEsource> operator()(Istream& is) const
|
||||
{
|
||||
word type(is);
|
||||
dictionary dict(is);
|
||||
return IATEsource::New(type, iate_, dict);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
// Constructors
|
||||
|
||||
IATEsource(const IATE& iate)
|
||||
:
|
||||
iate_(iate)
|
||||
{}
|
||||
|
||||
autoPtr<IATEsource> clone() const
|
||||
{
|
||||
notImplemented("autoPtr<IATEsource> clone() const");
|
||||
return autoPtr<IATEsource>(NULL);
|
||||
}
|
||||
|
||||
|
||||
// Selectors
|
||||
|
||||
static autoPtr<IATEsource> New
|
||||
(
|
||||
const word& type,
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
);
|
||||
|
||||
|
||||
//- Destructor
|
||||
virtual ~IATEsource()
|
||||
{}
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
const phaseModel& phase() const
|
||||
{
|
||||
return iate_.phase();
|
||||
}
|
||||
|
||||
const twoPhaseSystem& fluid() const
|
||||
{
|
||||
return iate_.phase().fluid();
|
||||
}
|
||||
|
||||
const phaseModel& otherPhase() const
|
||||
{
|
||||
return phase().otherPhase();
|
||||
}
|
||||
|
||||
scalar phi() const
|
||||
{
|
||||
return 1.0/(36*constant::mathematical::pi);
|
||||
}
|
||||
|
||||
//- Return the bubble relative velocity
|
||||
tmp<volScalarField> Ur() const;
|
||||
|
||||
//- Return the bubble turbulent velocity
|
||||
tmp<volScalarField> Ut() const;
|
||||
|
||||
//- Return the bubble Reynolds number
|
||||
tmp<volScalarField> Re() const;
|
||||
|
||||
//- Return the bubble drag coefficient
|
||||
tmp<volScalarField> CD() const;
|
||||
|
||||
//- Return the bubble Morton number
|
||||
tmp<volScalarField> Mo() const;
|
||||
|
||||
//- Return the bubble Eotvos number
|
||||
tmp<volScalarField> Eo() const;
|
||||
|
||||
//- Return the bubble Webber number
|
||||
tmp<volScalarField> We() const;
|
||||
|
||||
virtual tmp<volScalarField> R() const = 0;
|
||||
};
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
} // End namespace diameterModels
|
||||
} // End namespace Foam
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#endif
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,66 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "dummy.H"
|
||||
#include "addToRunTimeSelectionTable.H"
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
defineTypeNameAndDebug(dummy, 0);
|
||||
addToRunTimeSelectionTable(IATEsource, dummy, word);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
Foam::tmp<Foam::volScalarField>
|
||||
Foam::diameterModels::IATEsources::dummy::R() const
|
||||
{
|
||||
return tmp<volScalarField>
|
||||
(
|
||||
new volScalarField
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"R",
|
||||
iate_.phase().U().time().timeName(),
|
||||
iate_.phase().mesh()
|
||||
),
|
||||
iate_.phase().U().mesh(),
|
||||
dimensionedScalar("R", dimless/dimTime, 0)
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,96 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::diameterModels::IATEsources::dummy
|
||||
|
||||
Description
|
||||
|
||||
SourceFiles
|
||||
dummy.C
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#ifndef dummy_H
|
||||
#define dummy_H
|
||||
|
||||
#include "IATEsource.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class dummy Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
class dummy
|
||||
:
|
||||
public IATEsource
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("dummy");
|
||||
|
||||
// Constructors
|
||||
|
||||
dummy
|
||||
(
|
||||
const word& name,
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
)
|
||||
:
|
||||
IATEsource(iate)
|
||||
{}
|
||||
|
||||
|
||||
//- Destructor
|
||||
virtual ~dummy()
|
||||
{}
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
virtual tmp<volScalarField> R() const;
|
||||
};
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
} // End namespace IATEsources
|
||||
} // End namespace diameterModels
|
||||
} // End namespace Foam
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#endif
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,109 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "randomCoalescence.H"
|
||||
#include "addToRunTimeSelectionTable.H"
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
defineTypeNameAndDebug(randomCoalescence, 0);
|
||||
addToRunTimeSelectionTable(IATEsource, randomCoalescence, dictionary);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::diameterModels::IATEsources::randomCoalescence::
|
||||
randomCoalescence
|
||||
(
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
)
|
||||
:
|
||||
IATEsource(iate),
|
||||
Crc_("Crc", dimless, dict.lookup("Crc")),
|
||||
C_("C", dimless, dict.lookup("C")),
|
||||
alphaMax_("alphaMax", dimless, dict.lookup("alphaMax"))
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
Foam::tmp<Foam::volScalarField>
|
||||
Foam::diameterModels::IATEsources::randomCoalescence::R() const
|
||||
{
|
||||
tmp<volScalarField> tR
|
||||
(
|
||||
new volScalarField
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"R",
|
||||
iate_.phase().U().time().timeName(),
|
||||
iate_.phase().mesh()
|
||||
),
|
||||
iate_.phase().U().mesh(),
|
||||
dimensionedScalar("R", dimless/dimTime, 0)
|
||||
)
|
||||
);
|
||||
|
||||
volScalarField R = tR();
|
||||
|
||||
scalar Crc = Crc_.value();
|
||||
scalar C = C_.value();
|
||||
scalar alphaMax = alphaMax_.value();
|
||||
volScalarField Ut(this->Ut());
|
||||
const volScalarField& alpha = phase();
|
||||
const volScalarField& kappai = iate_.kappai();
|
||||
scalar cbrtAlphaMax = cbrt(alphaMax);
|
||||
|
||||
forAll(R, celli)
|
||||
{
|
||||
if (alpha[celli] < alphaMax - SMALL)
|
||||
{
|
||||
scalar cbrtAlphaMaxMAlpha = cbrtAlphaMax - cbrt(alpha[celli]);
|
||||
|
||||
R[celli] =
|
||||
12*phi()*kappai[celli]*alpha[celli]
|
||||
*Crc
|
||||
*Ut[celli]
|
||||
*(1 - exp(-C*cbrt(alpha[celli]*alphaMax)/cbrtAlphaMaxMAlpha))
|
||||
/(cbrtAlphaMax*cbrtAlphaMaxMAlpha);
|
||||
}
|
||||
}
|
||||
|
||||
return tR;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,108 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::diameterModels::IATEsources::randomCoalescence
|
||||
|
||||
Description
|
||||
Random coalescence IATE source as defined in paper:
|
||||
|
||||
\verbatim
|
||||
"Development of Interfacial Area Transport Equation"
|
||||
M. Ishii,
|
||||
S. Kim,
|
||||
J Kelly,
|
||||
Nuclear Engineering and Technology, Vol.37 No.6 December 2005
|
||||
\endverbatim
|
||||
|
||||
|
||||
SourceFiles
|
||||
randomCoalescence.C
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#ifndef randomCoalescence_H
|
||||
#define randomCoalescence_H
|
||||
|
||||
#include "IATEsource.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class randomCoalescence Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
class randomCoalescence
|
||||
:
|
||||
public IATEsource
|
||||
{
|
||||
// Private data
|
||||
|
||||
dimensionedScalar Crc_;
|
||||
dimensionedScalar C_;
|
||||
dimensionedScalar alphaMax_;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("randomCoalescence");
|
||||
|
||||
// Constructors
|
||||
|
||||
randomCoalescence
|
||||
(
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
);
|
||||
|
||||
|
||||
//- Destructor
|
||||
virtual ~randomCoalescence()
|
||||
{}
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
virtual tmp<volScalarField> R() const;
|
||||
};
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
} // End namespace IATEsources
|
||||
} // End namespace diameterModels
|
||||
} // End namespace Foam
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#endif
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,104 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "turbulentBreakUp.H"
|
||||
#include "addToRunTimeSelectionTable.H"
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
defineTypeNameAndDebug(turbulentBreakUp, 0);
|
||||
addToRunTimeSelectionTable(IATEsource, turbulentBreakUp, dictionary);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::diameterModels::IATEsources::turbulentBreakUp::
|
||||
turbulentBreakUp
|
||||
(
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
)
|
||||
:
|
||||
IATEsource(iate),
|
||||
Cti_("Cti", dimless, dict.lookup("Cti")),
|
||||
WeCr_("WeCr", dimless, dict.lookup("WeCr"))
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
Foam::tmp<Foam::volScalarField>
|
||||
Foam::diameterModels::IATEsources::turbulentBreakUp::R() const
|
||||
{
|
||||
tmp<volScalarField> tR
|
||||
(
|
||||
new volScalarField
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"R",
|
||||
iate_.phase().U().time().timeName(),
|
||||
iate_.phase().mesh()
|
||||
),
|
||||
iate_.phase().U().mesh(),
|
||||
dimensionedScalar("R", dimless/dimTime, 0)
|
||||
)
|
||||
);
|
||||
|
||||
volScalarField R = tR();
|
||||
|
||||
scalar Cti = Cti_.value();
|
||||
scalar WeCr = WeCr_.value();
|
||||
volScalarField Ut(this->Ut());
|
||||
volScalarField We(this->We());
|
||||
const volScalarField& d(iate_.d()());
|
||||
|
||||
forAll(R, celli)
|
||||
{
|
||||
if (We[celli] > WeCr)
|
||||
{
|
||||
R[celli] =
|
||||
(1.0/3.0)
|
||||
*Cti/d[celli]
|
||||
*Ut[celli]
|
||||
*sqrt(1 - WeCr/We[celli])
|
||||
*exp(-WeCr/We[celli]);
|
||||
}
|
||||
}
|
||||
|
||||
return tR;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,106 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::diameterModels::IATEsources::turbulentBreakUp
|
||||
|
||||
Description
|
||||
Turbulence-induced break-up IATE source as defined in paper:
|
||||
|
||||
\verbatim
|
||||
"Development of Interfacial Area Transport Equation"
|
||||
M. Ishii,
|
||||
S. Kim,
|
||||
J Kelly,
|
||||
Nuclear Engineering and Technology, Vol.37 No.6 December 2005
|
||||
\endverbatim
|
||||
|
||||
SourceFiles
|
||||
turbulentBreakUp.C
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#ifndef turbulentBreakUp_H
|
||||
#define turbulentBreakUp_H
|
||||
|
||||
#include "IATEsource.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class turbulentBreakUp Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
class turbulentBreakUp
|
||||
:
|
||||
public IATEsource
|
||||
{
|
||||
// Private data
|
||||
|
||||
dimensionedScalar Cti_;
|
||||
dimensionedScalar WeCr_;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("turbulentBreakUp");
|
||||
|
||||
// Constructors
|
||||
|
||||
turbulentBreakUp
|
||||
(
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
);
|
||||
|
||||
|
||||
//- Destructor
|
||||
virtual ~turbulentBreakUp()
|
||||
{}
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
virtual tmp<volScalarField> R() const;
|
||||
};
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
} // End namespace IATEsources
|
||||
} // End namespace diameterModels
|
||||
} // End namespace Foam
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#endif
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,72 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "wakeEntrainmentCoalescence.H"
|
||||
#include "addToRunTimeSelectionTable.H"
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
defineTypeNameAndDebug(wakeEntrainmentCoalescence, 0);
|
||||
addToRunTimeSelectionTable
|
||||
(
|
||||
IATEsource,
|
||||
wakeEntrainmentCoalescence,
|
||||
dictionary
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::diameterModels::IATEsources::wakeEntrainmentCoalescence::
|
||||
wakeEntrainmentCoalescence
|
||||
(
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
)
|
||||
:
|
||||
IATEsource(iate),
|
||||
Cwe_("Cwe", dimless, dict.lookup("Cwe"))
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
Foam::tmp<Foam::volScalarField>
|
||||
Foam::diameterModels::IATEsources::wakeEntrainmentCoalescence::R() const
|
||||
{
|
||||
return (-12)*phi()*Cwe_*cbrt(CD())*iate_.a()*Ur();
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,105 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
|
||||
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||
under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::diameterModels::IATEsources::wakeEntrainmentCoalescence
|
||||
|
||||
Description
|
||||
Bubble coalescence due to wake entrainment IATE source as defined in paper:
|
||||
|
||||
\verbatim
|
||||
"Development of Interfacial Area Transport Equation"
|
||||
M. Ishii,
|
||||
S. Kim,
|
||||
J Kelly,
|
||||
Nuclear Engineering and Technology, Vol.37 No.6 December 2005
|
||||
\endverbatim
|
||||
|
||||
SourceFiles
|
||||
wakeEntrainmentCoalescence.C
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#ifndef wakeEntrainmentCoalescence_H
|
||||
#define wakeEntrainmentCoalescence_H
|
||||
|
||||
#include "IATEsource.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
namespace diameterModels
|
||||
{
|
||||
namespace IATEsources
|
||||
{
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class wakeEntrainmentCoalescence Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
class wakeEntrainmentCoalescence
|
||||
:
|
||||
public IATEsource
|
||||
{
|
||||
// Private data
|
||||
|
||||
dimensionedScalar Cwe_;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("wakeEntrainmentCoalescence");
|
||||
|
||||
// Constructors
|
||||
|
||||
wakeEntrainmentCoalescence
|
||||
(
|
||||
const IATE& iate,
|
||||
const dictionary& dict
|
||||
);
|
||||
|
||||
|
||||
//- Destructor
|
||||
virtual ~wakeEntrainmentCoalescence()
|
||||
{}
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
virtual tmp<volScalarField> R() const;
|
||||
};
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
} // End namespace IATEsources
|
||||
} // End namespace diameterModels
|
||||
} // End namespace Foam
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#endif
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -48,12 +48,12 @@ namespace diameterModels
|
||||
|
||||
Foam::diameterModels::constant::constant
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
)
|
||||
:
|
||||
diameterModel(dict, phase),
|
||||
d_("d", dimLength, dict.lookup("d"))
|
||||
diameterModel(diameterProperties, phase),
|
||||
d_("d", dimLength, diameterProperties_.lookup("d"))
|
||||
{}
|
||||
|
||||
|
||||
@ -84,4 +84,14 @@ Foam::tmp<Foam::volScalarField> Foam::diameterModels::constant::d() const
|
||||
}
|
||||
|
||||
|
||||
bool Foam::diameterModels::constant::read(const dictionary& phaseProperties)
|
||||
{
|
||||
diameterModel::read(phaseProperties);
|
||||
|
||||
diameterProperties_.lookup("d") >> d_;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -22,7 +22,7 @@ License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::constant
|
||||
Foam::diameterModels::constant
|
||||
|
||||
Description
|
||||
Constant dispersed-phase particle diameter model.
|
||||
@ -69,7 +69,7 @@ public:
|
||||
//- Construct from components
|
||||
constant
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
);
|
||||
|
||||
@ -80,7 +80,11 @@ public:
|
||||
|
||||
// Member Functions
|
||||
|
||||
tmp<volScalarField> d() const;
|
||||
//- Return the diameter as a field
|
||||
virtual tmp<volScalarField> d() const;
|
||||
|
||||
//- Read diameterProperties dictionary
|
||||
virtual bool read(const dictionary& diameterProperties);
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -38,11 +38,11 @@ namespace Foam
|
||||
|
||||
Foam::diameterModel::diameterModel
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
)
|
||||
:
|
||||
dict_(dict),
|
||||
diameterProperties_(diameterProperties),
|
||||
phase_(phase)
|
||||
{}
|
||||
|
||||
@ -53,4 +53,18 @@ Foam::diameterModel::~diameterModel()
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
void Foam::diameterModel::correct()
|
||||
{}
|
||||
|
||||
|
||||
bool Foam::diameterModel::read(const dictionary& phaseProperties)
|
||||
{
|
||||
diameterProperties_ = phaseProperties.subDict(type() + "Coeffs");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -36,26 +36,27 @@ SourceFiles
|
||||
#ifndef diameterModel_H
|
||||
#define diameterModel_H
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#include "dictionary.H"
|
||||
#include "phaseModel.H"
|
||||
#include "runTimeSelectionTables.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class diameterModel Declaration
|
||||
Class diameterModel Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
class diameterModel
|
||||
{
|
||||
|
||||
protected:
|
||||
|
||||
// Protected data
|
||||
|
||||
const dictionary& dict_;
|
||||
dictionary diameterProperties_;
|
||||
const phaseModel& phase_;
|
||||
|
||||
|
||||
@ -73,10 +74,10 @@ public:
|
||||
diameterModel,
|
||||
dictionary,
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
),
|
||||
(dict, phase)
|
||||
(diameterProperties, phase)
|
||||
);
|
||||
|
||||
|
||||
@ -84,7 +85,7 @@ public:
|
||||
|
||||
diameterModel
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
);
|
||||
|
||||
@ -97,15 +98,33 @@ public:
|
||||
|
||||
static autoPtr<diameterModel> New
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
);
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
//- Return the phase diameter properties dictionary
|
||||
const dictionary& diameterProperties() const
|
||||
{
|
||||
return diameterProperties_;
|
||||
}
|
||||
|
||||
//- Return the phase
|
||||
const phaseModel& phase() const
|
||||
{
|
||||
return phase_;
|
||||
}
|
||||
|
||||
//- Return the phase mean diameter field
|
||||
virtual tmp<volScalarField> d() const = 0;
|
||||
|
||||
//- Correct the diameter field
|
||||
virtual void correct();
|
||||
|
||||
//- Read phaseProperties dictionary
|
||||
virtual bool read(const dictionary& phaseProperties) = 0;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -48,13 +48,13 @@ namespace diameterModels
|
||||
|
||||
Foam::diameterModels::isothermal::isothermal
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
)
|
||||
:
|
||||
diameterModel(dict, phase),
|
||||
d0_("d0", dimLength, dict.lookup("d0")),
|
||||
p0_("p0", dimPressure, dict.lookup("p0"))
|
||||
diameterModel(diameterProperties, phase),
|
||||
d0_("d0", dimLength, diameterProperties_.lookup("d0")),
|
||||
p0_("p0", dimPressure, diameterProperties_.lookup("p0"))
|
||||
{}
|
||||
|
||||
|
||||
@ -77,4 +77,15 @@ Foam::tmp<Foam::volScalarField> Foam::diameterModels::isothermal::d() const
|
||||
}
|
||||
|
||||
|
||||
bool Foam::diameterModels::isothermal::read(const dictionary& phaseProperties)
|
||||
{
|
||||
diameterModel::read(phaseProperties);
|
||||
|
||||
diameterProperties_.lookup("d0") >> d0_;
|
||||
diameterProperties_.lookup("p0") >> p0_;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -22,7 +22,7 @@ License
|
||||
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Class
|
||||
Foam::isothermal
|
||||
Foam::diameterModels::isothermal
|
||||
|
||||
Description
|
||||
Isothermal dispersed-phase particle diameter model.
|
||||
@ -72,7 +72,7 @@ public:
|
||||
//- Construct from components
|
||||
isothermal
|
||||
(
|
||||
const dictionary& dict,
|
||||
const dictionary& diameterProperties,
|
||||
const phaseModel& phase
|
||||
);
|
||||
|
||||
@ -83,7 +83,11 @@ public:
|
||||
|
||||
// Member Functions
|
||||
|
||||
tmp<volScalarField> d() const;
|
||||
//- Return the diameter field
|
||||
virtual tmp<volScalarField> d() const;
|
||||
|
||||
//- Read phaseProperties dictionary
|
||||
virtual bool read(const dictionary& phaseProperties);
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -26,6 +26,8 @@ License
|
||||
#include "phaseModel.H"
|
||||
#include "twoPhaseSystem.H"
|
||||
#include "diameterModel.H"
|
||||
#include "fvMatrix.H"
|
||||
#include "PhaseIncompressibleTurbulenceModel.H"
|
||||
#include "dragModel.H"
|
||||
#include "heatTransferModel.H"
|
||||
#include "fixedValueFvPatchFields.H"
|
||||
@ -73,6 +75,17 @@ Foam::phaseModel::phaseModel
|
||||
IOobject::AUTO_WRITE
|
||||
),
|
||||
fluid.mesh()
|
||||
),
|
||||
phiAlpha_
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
IOobject::groupName("alphaPhi", name_),
|
||||
fluid.mesh().time().timeName(),
|
||||
fluid.mesh()
|
||||
),
|
||||
fluid.mesh(),
|
||||
dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0)
|
||||
)
|
||||
{
|
||||
thermo_->validate("phaseModel " + name_, "h", "e");
|
||||
@ -153,6 +166,16 @@ Foam::phaseModel::phaseModel
|
||||
phaseDict_,
|
||||
*this
|
||||
);
|
||||
|
||||
turbulence_ =
|
||||
PhaseIncompressibleTurbulenceModel<phaseModel>::New
|
||||
(
|
||||
*this,
|
||||
U_,
|
||||
phiAlpha_,
|
||||
phi(),
|
||||
*this
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@ -164,10 +187,39 @@ Foam::phaseModel::~phaseModel()
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
const Foam::phaseModel& Foam::phaseModel::otherPhase() const
|
||||
{
|
||||
return fluid_.otherPhase(*this);
|
||||
}
|
||||
|
||||
|
||||
Foam::tmp<Foam::volScalarField> Foam::phaseModel::d() const
|
||||
{
|
||||
return dPtr_().d();
|
||||
}
|
||||
|
||||
Foam::PhaseIncompressibleTurbulenceModel<Foam::phaseModel>&
|
||||
Foam::phaseModel::turbulence()
|
||||
{
|
||||
return turbulence_();
|
||||
}
|
||||
|
||||
const Foam::PhaseIncompressibleTurbulenceModel<Foam::phaseModel>&
|
||||
Foam::phaseModel::turbulence() const
|
||||
{
|
||||
return turbulence_();
|
||||
}
|
||||
|
||||
void Foam::phaseModel::correct()
|
||||
{
|
||||
return dPtr_->correct();
|
||||
}
|
||||
|
||||
bool Foam::phaseModel::read(const dictionary& phaseProperties)
|
||||
{
|
||||
phaseDict_ = phaseProperties.subDict(name_);
|
||||
return dPtr_->read(phaseDict_);
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -48,6 +48,9 @@ namespace Foam
|
||||
class twoPhaseSystem;
|
||||
class diameterModel;
|
||||
|
||||
template<class Phase>
|
||||
class PhaseIncompressibleTurbulenceModel;
|
||||
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class phaseModel Declaration
|
||||
@ -74,12 +77,18 @@ class phaseModel
|
||||
//- Velocity
|
||||
volVectorField U_;
|
||||
|
||||
//- Fluxes
|
||||
//- Volumetric flux of the phase
|
||||
surfaceScalarField phiAlpha_;
|
||||
|
||||
//- Volumetric flux of the phase
|
||||
autoPtr<surfaceScalarField> phiPtr_;
|
||||
|
||||
//- Diameter model
|
||||
autoPtr<diameterModel> dPtr_;
|
||||
|
||||
//- turbulence model
|
||||
autoPtr<PhaseIncompressibleTurbulenceModel<phaseModel> > turbulence_;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
@ -99,19 +108,47 @@ public:
|
||||
|
||||
// Member Functions
|
||||
|
||||
//- Return the name of this phase
|
||||
const word& name() const
|
||||
{
|
||||
return name_;
|
||||
}
|
||||
|
||||
//- Return the twoPhaseSystem to which this phase belongs
|
||||
const twoPhaseSystem& fluid() const
|
||||
{
|
||||
return fluid_;
|
||||
}
|
||||
|
||||
const word& name() const
|
||||
{
|
||||
return name_;
|
||||
}
|
||||
//- Return the other phase in this two-phase system
|
||||
const phaseModel& otherPhase() const;
|
||||
|
||||
//- Return the Sauter-mean diameter
|
||||
tmp<volScalarField> d() const;
|
||||
|
||||
//- Return the turbulence model
|
||||
const PhaseIncompressibleTurbulenceModel<phaseModel>&
|
||||
turbulence() const;
|
||||
|
||||
//- Return non-const access to the turbulence model
|
||||
// for correction
|
||||
PhaseIncompressibleTurbulenceModel<phaseModel>&
|
||||
turbulence();
|
||||
|
||||
//- Return the thermophysical model
|
||||
const rhoThermo& thermo() const
|
||||
{
|
||||
return thermo_();
|
||||
}
|
||||
|
||||
//- Return non-const access to the thermophysical model
|
||||
// for correction
|
||||
rhoThermo& thermo()
|
||||
{
|
||||
return thermo_();
|
||||
}
|
||||
|
||||
//- Return the laminar viscosity
|
||||
tmp<volScalarField> nu() const
|
||||
{
|
||||
return thermo_->nu();
|
||||
@ -123,57 +160,71 @@ public:
|
||||
return thermo_->nu(patchi);
|
||||
}
|
||||
|
||||
//- Return the thermal conductivity
|
||||
tmp<volScalarField> kappa() const
|
||||
{
|
||||
return thermo_->kappa();
|
||||
}
|
||||
|
||||
//- Return the specific heat capacity
|
||||
tmp<volScalarField> Cp() const
|
||||
{
|
||||
return thermo_->Cp();
|
||||
}
|
||||
|
||||
//- Return the density
|
||||
const volScalarField& rho() const
|
||||
{
|
||||
return thermo_->rho();
|
||||
}
|
||||
|
||||
const rhoThermo& thermo() const
|
||||
{
|
||||
return thermo_();
|
||||
}
|
||||
|
||||
rhoThermo& thermo()
|
||||
{
|
||||
return thermo_();
|
||||
}
|
||||
|
||||
//- Return the velocity
|
||||
const volVectorField& U() const
|
||||
{
|
||||
return U_;
|
||||
}
|
||||
|
||||
//- Return non-const access to the velocity
|
||||
// Used in the momentum equation
|
||||
volVectorField& U()
|
||||
{
|
||||
return U_;
|
||||
}
|
||||
|
||||
//- Return the volumetric flux
|
||||
const surfaceScalarField& phi() const
|
||||
{
|
||||
return phiPtr_();
|
||||
}
|
||||
|
||||
//- Return non-const access to the volumetric flux
|
||||
surfaceScalarField& phi()
|
||||
{
|
||||
return phiPtr_();
|
||||
}
|
||||
|
||||
//- Dummy correct
|
||||
void correct()
|
||||
{}
|
||||
//- Return the volumetric flux of the phase
|
||||
const surfaceScalarField& phiAlpha() const
|
||||
{
|
||||
return phiAlpha_;
|
||||
}
|
||||
|
||||
//- Dummy read
|
||||
bool read()
|
||||
//- Return non-const access to the volumetric flux of the phase
|
||||
surfaceScalarField& phiAlpha()
|
||||
{
|
||||
return phiAlpha_;
|
||||
}
|
||||
|
||||
//- Correct the phase properties
|
||||
// other than the thermodynamics and turbulence
|
||||
// which have special treatment
|
||||
void correct();
|
||||
|
||||
//- Read phaseProperties dictionary
|
||||
virtual bool read(const dictionary& phaseProperties);
|
||||
|
||||
//- Dummy Read for transportModel
|
||||
virtual bool read()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -24,9 +24,19 @@ License
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "twoPhaseSystem.H"
|
||||
#include "fvMatrix.H"
|
||||
#include "PhaseIncompressibleTurbulenceModel.H"
|
||||
#include "surfaceInterpolate.H"
|
||||
#include "fixedValueFvsPatchFields.H"
|
||||
#include "MULES.H"
|
||||
#include "subCycle.H"
|
||||
#include "fvcDdt.H"
|
||||
#include "fvcDiv.H"
|
||||
#include "fvcSnGrad.H"
|
||||
#include "fvcFlux.H"
|
||||
#include "fvcCurl.H"
|
||||
#include "fvmDdt.H"
|
||||
#include "fvmLaplacian.H"
|
||||
#include "fixedValueFvsPatchFields.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
@ -63,6 +73,37 @@ Foam::twoPhaseSystem::twoPhaseSystem
|
||||
wordList(lookup("phases"))[1]
|
||||
),
|
||||
|
||||
phi_
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"phi",
|
||||
mesh.time().timeName(),
|
||||
mesh,
|
||||
IOobject::NO_READ,
|
||||
IOobject::AUTO_WRITE
|
||||
),
|
||||
this->calcPhi()
|
||||
),
|
||||
|
||||
dgdt_
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"dgdt",
|
||||
mesh.time().timeName(),
|
||||
mesh
|
||||
),
|
||||
pos(phase2_)*fvc::div(phi_)/max(phase2_, scalar(0.0001))
|
||||
),
|
||||
|
||||
sigma_
|
||||
(
|
||||
"sigma",
|
||||
dimensionSet(1, 0, -2, 0, 0),
|
||||
lookup("sigma")
|
||||
),
|
||||
|
||||
Cvm_
|
||||
(
|
||||
"Cvm",
|
||||
@ -170,7 +211,7 @@ Foam::tmp<Foam::volVectorField> Foam::twoPhaseSystem::U() const
|
||||
}
|
||||
|
||||
|
||||
Foam::tmp<Foam::surfaceScalarField> Foam::twoPhaseSystem::phi() const
|
||||
Foam::tmp<Foam::surfaceScalarField> Foam::twoPhaseSystem::calcPhi() const
|
||||
{
|
||||
return
|
||||
fvc::interpolate(phase1_)*phase1_.phi()
|
||||
@ -366,18 +407,242 @@ Foam::tmp<Foam::volScalarField> Foam::twoPhaseSystem::heatTransferCoeff() const
|
||||
}
|
||||
|
||||
|
||||
void Foam::twoPhaseSystem::solve()
|
||||
{
|
||||
const Time& runTime = mesh_.time();
|
||||
|
||||
volScalarField& alpha1 = phase1_;
|
||||
volScalarField& alpha2 = phase2_;
|
||||
|
||||
const surfaceScalarField& phi1 = phase1_.phi();
|
||||
const surfaceScalarField& phi2 = phase2_.phi();
|
||||
|
||||
const dictionary& alphaControls = mesh_.solverDict
|
||||
(
|
||||
alpha1.name()
|
||||
);
|
||||
|
||||
label nAlphaSubCycles(readLabel(alphaControls.lookup("nAlphaSubCycles")));
|
||||
label nAlphaCorr(readLabel(alphaControls.lookup("nAlphaCorr")));
|
||||
Switch implicitPhasePressure
|
||||
(
|
||||
alphaControls.lookupOrDefault<Switch>("implicitPhasePressure", false)
|
||||
);
|
||||
|
||||
word alphaScheme("div(phi," + alpha1.name() + ')');
|
||||
word alpharScheme("div(phir," + alpha1.name() + ')');
|
||||
|
||||
alpha1.correctBoundaryConditions();
|
||||
|
||||
|
||||
surfaceScalarField phic("phic", phi_);
|
||||
surfaceScalarField phir("phir", phi1 - phi2);
|
||||
|
||||
surfaceScalarField alpha1f(fvc::interpolate(max(alpha1, scalar(0))));
|
||||
|
||||
tmp<surfaceScalarField> pPrimeByA;
|
||||
|
||||
if (implicitPhasePressure)
|
||||
{
|
||||
const volScalarField& rAU1 = mesh_.lookupObject<volScalarField>
|
||||
(
|
||||
IOobject::groupName("rAU", phase1_.name())
|
||||
);
|
||||
const volScalarField& rAU2 = mesh_.lookupObject<volScalarField>
|
||||
(
|
||||
IOobject::groupName("rAU", phase2_.name())
|
||||
);
|
||||
|
||||
pPrimeByA =
|
||||
fvc::interpolate((1.0/phase1_.rho())
|
||||
*rAU1*phase1_.turbulence().pPrime())
|
||||
+ fvc::interpolate((1.0/phase2_.rho())
|
||||
*rAU2*phase2_.turbulence().pPrime());
|
||||
|
||||
surfaceScalarField phiP
|
||||
(
|
||||
pPrimeByA()*fvc::snGrad(alpha1, "bounded")*mesh_.magSf()
|
||||
);
|
||||
|
||||
phic += alpha1f*phiP;
|
||||
phir += phiP;
|
||||
}
|
||||
|
||||
for (int acorr=0; acorr<nAlphaCorr; acorr++)
|
||||
{
|
||||
volScalarField::DimensionedInternalField Sp
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"Sp",
|
||||
runTime.timeName(),
|
||||
mesh_
|
||||
),
|
||||
mesh_,
|
||||
dimensionedScalar("Sp", dgdt_.dimensions(), 0.0)
|
||||
);
|
||||
|
||||
volScalarField::DimensionedInternalField Su
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
"Su",
|
||||
runTime.timeName(),
|
||||
mesh_
|
||||
),
|
||||
// Divergence term is handled explicitly to be
|
||||
// consistent with the explicit transport solution
|
||||
fvc::div(phi_)*min(alpha1, scalar(1))
|
||||
);
|
||||
|
||||
forAll(dgdt_, celli)
|
||||
{
|
||||
if (dgdt_[celli] > 0.0 && alpha1[celli] > 0.0)
|
||||
{
|
||||
Sp[celli] -= dgdt_[celli]*alpha1[celli];
|
||||
Su[celli] += dgdt_[celli]*alpha1[celli];
|
||||
}
|
||||
else if (dgdt_[celli] < 0.0 && alpha1[celli] < 1.0)
|
||||
{
|
||||
Sp[celli] += dgdt_[celli]*(1.0 - alpha1[celli]);
|
||||
}
|
||||
}
|
||||
|
||||
dimensionedScalar totalDeltaT = runTime.deltaT();
|
||||
if (nAlphaSubCycles > 1)
|
||||
{
|
||||
phase1_.phiAlpha() =
|
||||
dimensionedScalar("0", phase1_.phiAlpha().dimensions(), 0);
|
||||
}
|
||||
|
||||
for
|
||||
(
|
||||
subCycle<volScalarField> alphaSubCycle(alpha1, nAlphaSubCycles);
|
||||
!(++alphaSubCycle).end();
|
||||
)
|
||||
{
|
||||
surfaceScalarField alphaPhic1
|
||||
(
|
||||
fvc::flux
|
||||
(
|
||||
phic,
|
||||
alpha1,
|
||||
alphaScheme
|
||||
)
|
||||
+ fvc::flux
|
||||
(
|
||||
-fvc::flux(-phir, scalar(1) - alpha1, alpharScheme),
|
||||
alpha1,
|
||||
alpharScheme
|
||||
)
|
||||
);
|
||||
|
||||
// Ensure that the flux at inflow BCs is preserved
|
||||
forAll(alphaPhic1.boundaryField(), patchi)
|
||||
{
|
||||
fvsPatchScalarField& alphaPhic1p =
|
||||
alphaPhic1.boundaryField()[patchi];
|
||||
|
||||
if (!alphaPhic1p.coupled())
|
||||
{
|
||||
const scalarField& phi1p = phi1.boundaryField()[patchi];
|
||||
const scalarField& alpha1p = alpha1.boundaryField()[patchi];
|
||||
|
||||
forAll(alphaPhic1p, facei)
|
||||
{
|
||||
if (phi1p[facei] < 0)
|
||||
{
|
||||
alphaPhic1p[facei] = alpha1p[facei]*phi1p[facei];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
MULES::explicitSolve
|
||||
(
|
||||
geometricOneField(),
|
||||
alpha1,
|
||||
phi_,
|
||||
alphaPhic1,
|
||||
Sp,
|
||||
Su,
|
||||
1,
|
||||
0
|
||||
);
|
||||
|
||||
if (nAlphaSubCycles > 1)
|
||||
{
|
||||
phase1_.phiAlpha() += (runTime.deltaT()/totalDeltaT)*alphaPhic1;
|
||||
}
|
||||
else
|
||||
{
|
||||
phase1_.phiAlpha() = alphaPhic1;
|
||||
}
|
||||
}
|
||||
|
||||
if (implicitPhasePressure)
|
||||
{
|
||||
fvScalarMatrix alpha1Eqn
|
||||
(
|
||||
fvm::ddt(alpha1) - fvc::ddt(alpha1)
|
||||
- fvm::laplacian(alpha1f*pPrimeByA, alpha1, "bounded")
|
||||
);
|
||||
|
||||
alpha1Eqn.relax();
|
||||
alpha1Eqn.solve();
|
||||
|
||||
phase1_.phiAlpha() += alpha1Eqn.flux();
|
||||
}
|
||||
|
||||
phase2_.phiAlpha() = phi_ - phase1_.phiAlpha();
|
||||
alpha2 = scalar(1) - alpha1;
|
||||
|
||||
Info<< alpha1.name() << " volume fraction = "
|
||||
<< alpha1.weightedAverage(mesh_.V()).value()
|
||||
<< " Min(alpha1) = " << min(alpha1).value()
|
||||
<< " Max(alpha1) = " << max(alpha1).value()
|
||||
<< endl;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void Foam::twoPhaseSystem::correct()
|
||||
{
|
||||
phase1_.correct();
|
||||
phase2_.correct();
|
||||
}
|
||||
|
||||
|
||||
void Foam::twoPhaseSystem::correctTurbulence()
|
||||
{
|
||||
phase1_.turbulence().correct();
|
||||
phase2_.turbulence().correct();
|
||||
}
|
||||
|
||||
|
||||
bool Foam::twoPhaseSystem::read()
|
||||
{
|
||||
if (regIOobject::read())
|
||||
{
|
||||
bool readOK = true;
|
||||
|
||||
readOK &= phase1_.read();
|
||||
readOK &= phase2_.read();
|
||||
readOK &= phase1_.read(*this);
|
||||
readOK &= phase2_.read(*this);
|
||||
|
||||
lookup("sigma") >> sigma_;
|
||||
lookup("Cvm") >> Cvm_;
|
||||
lookup("Cl") >> Cl_;
|
||||
|
||||
// drag1_->read(*this);
|
||||
// drag2_->read(*this);
|
||||
|
||||
// heatTransfer1_->read(*this);
|
||||
// heatTransfer2_->read(*this);
|
||||
|
||||
lookup("dispersedPhase") >> dispersedPhase_;
|
||||
lookup("residualPhaseFraction") >> residualPhaseFraction_;
|
||||
lookup("residualSlip") >> residualSlip_;
|
||||
|
||||
return readOK;
|
||||
}
|
||||
else
|
||||
|
||||
@ -74,6 +74,12 @@ class twoPhaseSystem
|
||||
phaseModel phase1_;
|
||||
phaseModel phase2_;
|
||||
|
||||
surfaceScalarField phi_;
|
||||
|
||||
volScalarField dgdt_;
|
||||
|
||||
dimensionedScalar sigma_;
|
||||
|
||||
dimensionedScalar Cvm_;
|
||||
dimensionedScalar Cl_;
|
||||
|
||||
@ -88,6 +94,10 @@ class twoPhaseSystem
|
||||
dimensionedScalar residualSlip_;
|
||||
|
||||
|
||||
//- Return the mixture flux
|
||||
tmp<surfaceScalarField> calcPhi() const;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
// Constructors
|
||||
@ -140,6 +150,28 @@ public:
|
||||
return phase2_;
|
||||
}
|
||||
|
||||
//- Return the mixture flux
|
||||
const surfaceScalarField& phi() const
|
||||
{
|
||||
return phi_;
|
||||
}
|
||||
|
||||
//- Return the mixture flux
|
||||
surfaceScalarField& phi()
|
||||
{
|
||||
return phi_;
|
||||
}
|
||||
|
||||
const volScalarField& dgdt() const
|
||||
{
|
||||
return dgdt_;
|
||||
}
|
||||
|
||||
volScalarField& dgdt()
|
||||
{
|
||||
return dgdt_;
|
||||
}
|
||||
|
||||
const dragModel& drag1() const
|
||||
{
|
||||
return drag1_();
|
||||
@ -193,8 +225,11 @@ public:
|
||||
//- Return the mixture velocity
|
||||
tmp<volVectorField> U() const;
|
||||
|
||||
//- Return the mixture flux
|
||||
tmp<surfaceScalarField> phi() const;
|
||||
//- Return the surface tension coefficient
|
||||
dimensionedScalar sigma() const
|
||||
{
|
||||
return sigma_;
|
||||
}
|
||||
|
||||
//- Return the virtual-mass coefficient
|
||||
dimensionedScalar Cvm() const
|
||||
@ -208,9 +243,14 @@ public:
|
||||
return Cl_;
|
||||
}
|
||||
|
||||
//- Dummy correct
|
||||
void correct()
|
||||
{}
|
||||
//- Solve for the two-phase-fractions
|
||||
void solve();
|
||||
|
||||
//- Correct two-phase properties other than turbulence
|
||||
void correct();
|
||||
|
||||
//- Correct two-phase turbulence
|
||||
void correctTurbulence();
|
||||
|
||||
//- Read base phaseProperties dictionary
|
||||
bool read();
|
||||
|
||||
Reference in New Issue
Block a user