37namespace phaseChangeTwoPhaseMixtures
42 phaseChangeTwoPhaseMixture,
54 const volVectorField&
U,
55 const surfaceScalarField&
phi
58 phaseChangeTwoPhaseMixture(typeName,
U,
phi),
61 dNuc_(
"dNuc",
dimLength, phaseChangeTwoPhaseMixtureCoeffs_),
62 Cc_(
"Cc",
dimless, phaseChangeTwoPhaseMixtureCoeffs_),
63 Cv_(
"Cv",
dimless, phaseChangeTwoPhaseMixtureCoeffs_),
65 p0_(pSat().dimensions(), Zero)
74Foam::phaseChangeTwoPhaseMixtures::SchnerrSauer::rRb
76 const volScalarField& limitedAlpha1
82 *limitedAlpha1/(1.0 + alphaNuc() - limitedAlpha1),
89Foam::phaseChangeTwoPhaseMixtures::SchnerrSauer::alphaNuc()
const
92 return Vnuc/(1 + Vnuc);
97Foam::phaseChangeTwoPhaseMixtures::SchnerrSauer::pCoeff
105 limitedAlpha1*
rho1() + (scalar(1) - limitedAlpha1)*
rho2()
110 *rRb(limitedAlpha1)/(
rho*
sqrt(
mag(
p - pSat()) + 0.01*pSat()));
122 return Pair<tmp<volScalarField>>
124 Cc_*limitedAlpha1*pCoeff*
max(
p - pSat(), p0_),
126 Cv_*(1.0 + alphaNuc() - limitedAlpha1)*pCoeff*
min(
p - pSat(), p0_)
140 return Pair<tmp<volScalarField>>
142 Cc_*(1.0 - limitedAlpha1)*
pos0(
p - pSat())*apCoeff,
144 (-Cv_)*(1.0 + alphaNuc() - limitedAlpha1)*
neg(
p - pSat())*apCoeff
157 phaseChangeTwoPhaseMixtureCoeffs_ = optionalSubDict(
type() +
"Coeffs");
159 phaseChangeTwoPhaseMixtureCoeffs_.readEntry(
"n", n_);
160 phaseChangeTwoPhaseMixtureCoeffs_.readEntry(
"dNuc", dNuc_);
161 phaseChangeTwoPhaseMixtureCoeffs_.readEntry(
"Cc", Cc_);
162 phaseChangeTwoPhaseMixtureCoeffs_.readEntry(
"Cv", Cv_);
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
An ordered pair of two objects of type <T> with first() and second() elements.
virtual bool read()=0
Read the transportProperties dictionary and update.
SchnerrSauer cavitation model.
virtual Pair< tmp< volScalarField > > mDotP() const
Return the mass condensation and vaporisation rates as coefficients.
virtual Pair< tmp< volScalarField > > mDotAlphal() const
Return the mass condensation and vaporisation rates as a.
virtual void correct()
Correct the SchnerrSauer phaseChange model.
virtual bool read()
Read the transportProperties dictionary and update.
A class for managing temporary objects.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
constexpr scalar pi(M_PI)
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
const dimensionSet dimless
Dimensionless.
dimensionedScalar pos0(const dimensionedScalar &ds)
const dimensionSet dimLength(0, 1, 0, 0, 0, 0, 0)
dimensionedScalar pow3(const dimensionedScalar &ds)
GeometricField< scalar, fvPatchField, volMesh > volScalarField
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
dimensionedScalar sqrt(const dimensionedScalar &ds)
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
dimensionedScalar neg(const dimensionedScalar &ds)
const dimensionSet dimVolume(pow3(dimLength))