TurbulenceModels::ReynoldsStress: Added support for incompressible VoF solvers
and other incompressible mixture-based multiphase solvers.
This commit is contained in:
parent
6f4908ed00
commit
c696e71fce
2 changed files with 31 additions and 20 deletions
|
|
@ -227,9 +227,11 @@ Foam::ReynoldsStress<BasicTurbulenceModel>::devRhoReff() const
|
||||||
|
|
||||||
|
|
||||||
template<class BasicTurbulenceModel>
|
template<class BasicTurbulenceModel>
|
||||||
|
template<class RhoFieldType>
|
||||||
Foam::tmp<Foam::fvVectorMatrix>
|
Foam::tmp<Foam::fvVectorMatrix>
|
||||||
Foam::ReynoldsStress<BasicTurbulenceModel>::divDevRhoReff
|
Foam::ReynoldsStress<BasicTurbulenceModel>::DivDevRhoReff
|
||||||
(
|
(
|
||||||
|
const RhoFieldType& rho,
|
||||||
volVectorField& U
|
volVectorField& U
|
||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
|
|
@ -239,19 +241,19 @@ Foam::ReynoldsStress<BasicTurbulenceModel>::divDevRhoReff
|
||||||
(
|
(
|
||||||
fvc::laplacian
|
fvc::laplacian
|
||||||
(
|
(
|
||||||
(1.0 - couplingFactor_)*this->alpha_*this->rho_*this->nut(),
|
(1.0 - couplingFactor_)*this->alpha_*rho*this->nut(),
|
||||||
U,
|
U,
|
||||||
"laplacian(nuEff,U)"
|
"laplacian(nuEff,U)"
|
||||||
)
|
)
|
||||||
+ fvc::div
|
+ fvc::div
|
||||||
(
|
(
|
||||||
this->alpha_*this->rho_*R_
|
this->alpha_*rho*R_
|
||||||
+ couplingFactor_
|
+ couplingFactor_
|
||||||
*this->alpha_*this->rho_*this->nut()*fvc::grad(U),
|
*this->alpha_*rho*this->nut()*fvc::grad(U),
|
||||||
"div(devRhoReff)"
|
"div(devRhoReff)"
|
||||||
)
|
)
|
||||||
- fvc::div(this->alpha_*this->rho_*this->nu()*dev2(T(fvc::grad(U))))
|
- fvc::div(this->alpha_*rho*this->nu()*dev2(T(fvc::grad(U))))
|
||||||
- fvm::laplacian(this->alpha_*this->rho_*this->nuEff(), U)
|
- fvm::laplacian(this->alpha_*rho*this->nuEff(), U)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
@ -260,21 +262,26 @@ Foam::ReynoldsStress<BasicTurbulenceModel>::divDevRhoReff
|
||||||
(
|
(
|
||||||
fvc::laplacian
|
fvc::laplacian
|
||||||
(
|
(
|
||||||
this->alpha_*this->rho_*this->nut(),
|
this->alpha_*rho*this->nut(),
|
||||||
U,
|
U,
|
||||||
"laplacian(nuEff,U)"
|
"laplacian(nuEff,U)"
|
||||||
)
|
)
|
||||||
+ fvc::div(this->alpha_*this->rho_*R_)
|
+ fvc::div(this->alpha_*rho*R_)
|
||||||
- fvc::div(this->alpha_*this->rho_*this->nu()*dev2(T(fvc::grad(U))))
|
- fvc::div(this->alpha_*rho*this->nu()*dev2(T(fvc::grad(U))))
|
||||||
- fvm::laplacian(this->alpha_*this->rho_*this->nuEff(), U)
|
- fvm::laplacian(this->alpha_*rho*this->nuEff(), U)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return
|
|
||||||
(
|
template<class BasicTurbulenceModel>
|
||||||
- fvc::div((this->alpha_*this->rho_*this->nuEff())*dev2(T(fvc::grad(U))))
|
Foam::tmp<Foam::fvVectorMatrix>
|
||||||
- fvm::laplacian(this->alpha_*this->rho_*this->nuEff(), U)
|
Foam::ReynoldsStress<BasicTurbulenceModel>::divDevRhoReff
|
||||||
);
|
(
|
||||||
|
volVectorField& U
|
||||||
|
) const
|
||||||
|
{
|
||||||
|
return DivDevRhoReff(this->rho_, U);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -286,11 +293,7 @@ Foam::ReynoldsStress<BasicTurbulenceModel>::divDevRhoReff
|
||||||
volVectorField& U
|
volVectorField& U
|
||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
return
|
return DivDevRhoReff(rho, U);
|
||||||
(
|
|
||||||
- fvc::div((this->alpha_*rho*this->nuEff())*dev2(T(fvc::grad(U))))
|
|
||||||
- fvm::laplacian(this->alpha_*rho*this->nuEff(), U)
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -75,6 +75,14 @@ protected:
|
||||||
//- Update the eddy-viscosity
|
//- Update the eddy-viscosity
|
||||||
virtual void correctNut() = 0;
|
virtual void correctNut() = 0;
|
||||||
|
|
||||||
|
//- Return the source term for the momentum equation
|
||||||
|
template<class RhoFieldType>
|
||||||
|
tmp<fvVectorMatrix> DivDevRhoReff
|
||||||
|
(
|
||||||
|
const RhoFieldType& rho,
|
||||||
|
volVectorField& U
|
||||||
|
) const;
|
||||||
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue