driftFluxFoam: Added MRF centrifugal acceleration effect to the relativeVelocityModels
This required changing the formulation of the relative velocity in terms of a
scalar velocity coefficient Vc rather than the velocity V0 such that
V0 = Vc*g
where g is the acceleration due to gravity. With MRF rotation
V0 = Vc*(g + <MRF centrifugal acceleration>)
This commit is contained in:
@ -63,15 +63,9 @@ surfaceScalarField rhoPhi
|
||||
);
|
||||
|
||||
|
||||
// Relative Velocity
|
||||
autoPtr<relativeVelocityModel> UdmModelPtr
|
||||
(
|
||||
relativeVelocityModel::New
|
||||
(
|
||||
mixture,
|
||||
mixture
|
||||
)
|
||||
);
|
||||
#include "readGravitationalAcceleration.H"
|
||||
#include "readhRef.H"
|
||||
#include "gh.H"
|
||||
|
||||
|
||||
// Construct compressible turbulence model
|
||||
@ -81,10 +75,6 @@ autoPtr<compressible::momentumTransportModel> turbulence
|
||||
);
|
||||
|
||||
|
||||
#include "readGravitationalAcceleration.H"
|
||||
#include "readhRef.H"
|
||||
#include "gh.H"
|
||||
|
||||
|
||||
volScalarField p
|
||||
(
|
||||
@ -120,5 +110,18 @@ mesh.setFluxRequired(alpha1.name());
|
||||
tmp<surfaceScalarField> talphaPhiCorr0;
|
||||
|
||||
#include "createMRF.H"
|
||||
|
||||
// Relative Velocity
|
||||
autoPtr<relativeVelocityModel> UdmModelPtr
|
||||
(
|
||||
relativeVelocityModel::New
|
||||
(
|
||||
mixture,
|
||||
mixture,
|
||||
g,
|
||||
MRF
|
||||
)
|
||||
);
|
||||
|
||||
#include "createFvModels.H"
|
||||
#include "createFvConstraints.H"
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2014-2018 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2014-2022 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -43,13 +43,15 @@ namespace relativeVelocityModels
|
||||
Foam::relativeVelocityModels::general::general
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
)
|
||||
:
|
||||
relativeVelocityModel(dict, mixture),
|
||||
relativeVelocityModel(dict, mixture, g, MRF),
|
||||
a_("a", dimless, dict),
|
||||
a1_("a1", dimless, dict),
|
||||
V0_("V0", dimVelocity, dict),
|
||||
Vc_("Vc", dimTime, dict),
|
||||
residualAlpha_("residualAlpha", dimless, dict)
|
||||
{}
|
||||
|
||||
@ -66,7 +68,8 @@ void Foam::relativeVelocityModels::general::correct()
|
||||
{
|
||||
Udm_ =
|
||||
(rhoc_/rho())
|
||||
*V0_
|
||||
*Vc_
|
||||
*(g_ + MRF_.centrifugalAcceleration())
|
||||
*(
|
||||
exp(-a_*max(alphad_ - residualAlpha_, scalar(0)))
|
||||
- exp(-a1_*max(alphad_ - residualAlpha_, scalar(0)))
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2014-2020 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2014-2022 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -60,8 +60,8 @@ class general
|
||||
//- a1 coefficient
|
||||
dimensionedScalar a1_;
|
||||
|
||||
//- Drift velocity
|
||||
dimensionedVector V0_;
|
||||
//- Drift velocity coefficient
|
||||
dimensionedScalar Vc_;
|
||||
|
||||
//- Residual phase fraction
|
||||
dimensionedScalar residualAlpha_;
|
||||
@ -79,7 +79,9 @@ public:
|
||||
general
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
);
|
||||
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2014-2018 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2014-2022 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -70,7 +70,9 @@ Foam::wordList Foam::relativeVelocityModel::UdmPatchFieldTypes() const
|
||||
Foam::relativeVelocityModel::relativeVelocityModel
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
)
|
||||
:
|
||||
mixture_(mixture),
|
||||
@ -78,6 +80,8 @@ Foam::relativeVelocityModel::relativeVelocityModel
|
||||
alphad_(mixture.alpha1()),
|
||||
rhoc_(mixture.rhoc()),
|
||||
rhod_(mixture.rhod()),
|
||||
g_(g),
|
||||
MRF_(MRF),
|
||||
|
||||
Udm_
|
||||
(
|
||||
@ -101,7 +105,9 @@ Foam::relativeVelocityModel::relativeVelocityModel
|
||||
Foam::autoPtr<Foam::relativeVelocityModel> Foam::relativeVelocityModel::New
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
)
|
||||
{
|
||||
word modelType(dict.lookup(typeName));
|
||||
@ -127,7 +133,9 @@ Foam::autoPtr<Foam::relativeVelocityModel> Foam::relativeVelocityModel::New
|
||||
cstrIter()
|
||||
(
|
||||
dict.optionalSubDict(modelType + "Coeffs"),
|
||||
mixture
|
||||
mixture,
|
||||
g,
|
||||
MRF
|
||||
)
|
||||
);
|
||||
}
|
||||
@ -141,19 +149,19 @@ Foam::relativeVelocityModel::~relativeVelocityModel()
|
||||
|
||||
// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
|
||||
|
||||
tmp<volScalarField> Foam::relativeVelocityModel::rho() const
|
||||
Foam::tmp<Foam::volScalarField> Foam::relativeVelocityModel::rho() const
|
||||
{
|
||||
return alphac_*rhoc_ + alphad_*rhod_;
|
||||
}
|
||||
|
||||
|
||||
tmp<volSymmTensorField> Foam::relativeVelocityModel::tauDm() const
|
||||
Foam::tmp<Foam::volSymmTensorField> Foam::relativeVelocityModel::tauDm() const
|
||||
{
|
||||
volScalarField betac(alphac_*rhoc_);
|
||||
volScalarField betad(alphad_*rhod_);
|
||||
const volScalarField betac(alphac_*rhoc_);
|
||||
const volScalarField betad(alphad_*rhod_);
|
||||
|
||||
// Calculate the relative velocity of the continuous phase w.r.t the mean
|
||||
volVectorField Ucm(betad*Udm_/betac);
|
||||
const volVectorField Ucm(betad*Udm_/betac);
|
||||
|
||||
return volSymmTensorField::New
|
||||
(
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2014-2020 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2014-2022 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -34,9 +34,9 @@ SourceFiles
|
||||
#ifndef relativeVelocityModel_H
|
||||
#define relativeVelocityModel_H
|
||||
|
||||
#include "fvCFD.H"
|
||||
#include "dictionary.H"
|
||||
#include "incompressibleTwoPhaseInteractingMixture.H"
|
||||
#include "uniformDimensionedFields.H"
|
||||
#include "MRFZoneList.H"
|
||||
#include "runTimeSelectionTables.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
@ -78,10 +78,15 @@ protected:
|
||||
//- Dispersed density
|
||||
const dimensionedScalar& rhod_;
|
||||
|
||||
//- Acceleration due to gravity
|
||||
const uniformDimensionedVectorField& g_;
|
||||
|
||||
//- MRF zones
|
||||
const MRFZoneList& MRF_;
|
||||
|
||||
//- Dispersed diffusion velocity
|
||||
mutable volVectorField Udm_;
|
||||
|
||||
|
||||
public:
|
||||
|
||||
//- Runtime type information
|
||||
@ -93,9 +98,13 @@ public:
|
||||
autoPtr,
|
||||
relativeVelocityModel,
|
||||
dictionary,
|
||||
(const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture),
|
||||
(dict, mixture)
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
),
|
||||
(dict, mixture, g, MRF)
|
||||
);
|
||||
|
||||
|
||||
@ -105,7 +114,9 @@ public:
|
||||
relativeVelocityModel
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
);
|
||||
|
||||
//- Disallow default bitwise copy construction
|
||||
@ -116,7 +127,9 @@ public:
|
||||
static autoPtr<relativeVelocityModel> New
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
);
|
||||
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2014-2018 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2014-2022 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -43,12 +43,14 @@ namespace relativeVelocityModels
|
||||
Foam::relativeVelocityModels::simple::simple
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
)
|
||||
:
|
||||
relativeVelocityModel(dict, mixture),
|
||||
relativeVelocityModel(dict, mixture, g, MRF),
|
||||
a_("a", dimless, dict),
|
||||
V0_("V0", dimVelocity, dict),
|
||||
Vc_("Vc", dimTime, dict),
|
||||
residualAlpha_("residualAlpha", dimless, dict)
|
||||
{}
|
||||
|
||||
@ -63,7 +65,10 @@ Foam::relativeVelocityModels::simple::~simple()
|
||||
|
||||
void Foam::relativeVelocityModels::simple::correct()
|
||||
{
|
||||
Udm_ = (rhoc_/rho())*V0_*pow(scalar(10), -a_*max(alphad_, scalar(0)));
|
||||
Udm_ =
|
||||
(rhoc_/rho())
|
||||
*Vc_*(g_ + MRF_.centrifugalAcceleration())
|
||||
*pow(scalar(10), -a_*max(alphad_, scalar(0)));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2014-2020 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2014-2022 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -57,8 +57,8 @@ class simple
|
||||
//- A coefficient
|
||||
dimensionedScalar a_;
|
||||
|
||||
//- Drift velocity
|
||||
dimensionedVector V0_;
|
||||
//- Drift velocity coefficient
|
||||
dimensionedScalar Vc_;
|
||||
|
||||
//- Residual phase fraction
|
||||
dimensionedScalar residualAlpha_;
|
||||
@ -76,7 +76,9 @@ public:
|
||||
simple
|
||||
(
|
||||
const dictionary& dict,
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture
|
||||
const incompressibleTwoPhaseInteractingMixture& mixture,
|
||||
const uniformDimensionedVectorField& g,
|
||||
const MRFZoneList& MRF
|
||||
);
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user