34 namespace regionModels
36 namespace surfaceFilmModels
64 return 0.037*
pow(Re, 0.8)*
cbrt(Sc);
71 standardPhaseChange::standardPhaseChange
78 deltaMin_(
readScalar(coeffDict_.lookup(
"deltaMin"))),
80 TbFactor_(coeffDict_.lookupOrDefault<scalar>(
"TbFactor", 1.1))
105 const label vapId = thermo.carrierId(filmThermo.
name());
127 const scalar pc = pInf[celli];
130 const scalar Tb = filmThermo.
Tb(pc);
136 const scalar pSat = filmThermo.
pv(pc, Tloc);
139 const scalar hVap = filmThermo.
hl(pc, Tloc);
145 const scalar Cp = filmThermo.
Cp(pc, Tloc);
146 const scalar Tcorr =
max(0.0, T[celli] - Tb);
147 const scalar qCorr = limMass[celli]*Cp*(Tcorr);
148 dMass[celli] = qCorr/hVap;
153 const scalar rhoInfc = rhoInf[celli];
156 const scalar muInfc = muInf[celli];
159 const scalar Re = rhoInfc*
mag(dU[celli])*
L_/muInfc;
162 const scalar Wvap = thermo.carrier().W(vapId);
165 const scalar Wliq = filmThermo.
W();
168 const scalar Ys = Wliq*pSat/(Wliq*pSat + Wvap*(pc - pSat));
171 const scalar Dab = filmThermo.
D(pc, Tloc);
174 const scalar Sc = muInfc/(rhoInfc*(Dab + ROOTVSMALL));
177 const scalar
Sh = this->
Sh(Re, Sc);
180 const scalar hm = Sh*Dab/(
L_ + ROOTVSMALL);
184 dt*magSf[celli]*rhoInfc*hm*(Ys - YInf[celli])/(1.0 - Ys);
187 dMass[celli] =
min(limMass[celli],
max(0.0, dMass[celli]));
188 dEnergy[celli] = dMass[celli]*hVap;
virtual const volScalarField & magSf() const
Return the face area magnitudes / [m2].
const volVectorField & UPrimary() const
Velocity / [m/s].
#define forAll(list, i)
Loop across all elements in list.
virtual const word & name() const =0
Return the specie name.
virtual void correctModel(const scalar dt, scalarField &availableMass, scalarField &dMass, scalarField &dEnergy)
Correct.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const filmThermoModel & filmThermo() const
Film thermo.
const volScalarField & muPrimary() const
Viscosity / [Pa.s].
A list of keyword definitions, which are a keyword followed by any number of values (e...
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
virtual scalar Cp(const scalar p, const scalar T) const =0
Return specific heat capacity [J/kg/K].
const scalar L_
Length scale / [m].
scalar Sh(const scalar Re, const scalar Sc) const
Return Sherwood number as a function of Reynolds and Schmidt numbers.
virtual scalar hl(const scalar p, const scalar T) const =0
Return latent heat [J/kg].
dimensionedScalar sqrt(const dimensionedScalar &ds)
virtual const volScalarField & rho() const
Return the film density [kg/m3].
Macros for easy insertion into run-time selection tables.
addToRunTimeSelectionTable(surfaceFilmModel, kinematicSingleLayer, mesh)
virtual ~standardPhaseChange()
Destructor.
const volScalarField & delta() const
Return const access to the film thickness / [m].
const scalar TbFactor_
Boiling temperature factor / [].
dimensionedScalar cbrt(const dimensionedScalar &ds)
Thermo package for (S)olids (L)iquids and (G)ases Takes reference to thermo package, and provides:
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if succesful.
const SLGThermo & thermo() const
Return const reference to the SLGThermo object.
virtual scalar D(const scalar p, const scalar T) const =0
Return diffusivity [m2/s].
virtual scalar Tb(const scalar p) const =0
Return boiling temperature [K].
virtual const volVectorField & Us() const
Return the film surface velocity [m/s].
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
virtual const volScalarField & T() const
Return the film mean temperature [K].
const PtrList< volScalarField > & YPrimary() const
Specie mass fractions / [0-1].
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
const volScalarField & rhoPrimary() const
Density / [kg/m3].
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
virtual scalar W() const =0
Return molecular weight [kg/kmol].
Base class for surface film models.
dimensioned< scalar > mag(const dimensioned< Type > &)
const scalar deltaMin_
Minimum film height for model to be active.
defineTypeNameAndDebug(kinematicSingleLayer, 0)
const volScalarField & pPrimary() const
Pressure / [Pa].
virtual scalar pv(const scalar p, const scalar T) const =0
Return vapour pressure [Pa].