47 psiThermo(U.
mesh(), word::null),
48 twoPhaseMixture(U.
mesh(), *this),
49 interfaceProperties(
alpha1(), U, *this),
59 U.mesh().time().timeName(),
63 calculatedFvPatchScalarField::typeName
74 U.mesh().time().timeName(),
78 calculatedFvPatchScalarField::typeName
108 thermo1_->he() = thermo1_->he(p_, T_);
112 thermo2_->he() = thermo2_->he(p_, T_);
119 psi_ =
alpha1()*thermo1_->psi() +
alpha2()*thermo2_->psi();
120 mu_ =
alpha1()*thermo1_->mu() +
alpha2()*thermo2_->mu();
121 alpha_ =
alpha1()*thermo1_->alpha() +
alpha2()*thermo2_->alpha();
129 return thermo1_->thermoName() +
',' + thermo2_->thermoName();
135 return thermo1_->incompressible() && thermo2_->incompressible();
141 return thermo1_->isochoric() && thermo2_->isochoric();
151 return alpha1()*thermo1_->he(p, T) +
alpha2()*thermo2_->he(p, T);
176 alpha1().boundaryField()[
patchi]*thermo1_->he(p, T, patchi)
177 +
alpha2().boundaryField()[
patchi]*thermo2_->he(p, T, patchi);
183 return alpha1()*thermo1_->hc() +
alpha2()*thermo2_->hc();
215 return alpha1()*thermo1_->Cp() +
alpha2()*thermo2_->Cp();
227 alpha1().boundaryField()[
patchi]*thermo1_->Cp(p, T, patchi)
228 +
alpha2().boundaryField()[
patchi]*thermo2_->Cp(p, T, patchi);
234 return alpha1()*thermo1_->Cv() +
alpha2()*thermo2_->Cv();
246 alpha1().boundaryField()[
patchi]*thermo1_->Cv(p, T, patchi)
247 +
alpha2().boundaryField()[
patchi]*thermo2_->Cv(p, T, patchi);
253 return alpha1()*thermo1_->gamma() +
alpha2()*thermo2_->gamma();
265 alpha1().boundaryField()[
patchi]*thermo1_->gamma(p, T, patchi)
266 +
alpha2().boundaryField()[
patchi]*thermo2_->gamma(p, T, patchi);
272 return alpha1()*thermo1_->Cpv() +
alpha2()*thermo2_->Cpv();
284 alpha1().boundaryField()[
patchi]*thermo1_->Cpv(p, T, patchi)
285 +
alpha2().boundaryField()[
patchi]*thermo2_->Cpv(p, T, patchi);
292 alpha1()*thermo1_->CpByCpv()
293 +
alpha2()*thermo2_->CpByCpv();
305 alpha1().boundaryField()[
patchi]*thermo1_->CpByCpv(p, T, patchi)
306 +
alpha2().boundaryField()[
patchi]*thermo2_->CpByCpv(p, T, patchi);
318 return mu()/(
alpha1()*thermo1_->rho() +
alpha2()*thermo2_->rho());
331 +
alpha2().boundaryField()[
patchi]*thermo2_->rho(patchi)
338 return alpha1()*thermo1_->kappa() +
alpha2()*thermo2_->kappa();
348 alpha1().boundaryField()[
patchi]*thermo1_->kappa(patchi)
349 +
alpha2().boundaryField()[
patchi]*thermo2_->kappa(patchi);
356 alpha1()*thermo1_->alphahe()
357 +
alpha2()*thermo2_->alphahe();
367 alpha1().boundaryField()[
patchi]*thermo1_->alphahe(patchi)
368 +
alpha2().boundaryField()[
patchi]*thermo2_->alphahe(patchi);
378 alpha1()*thermo1_->kappaEff(alphat)
379 +
alpha2()*thermo2_->kappaEff(alphat);
390 alpha1().boundaryField()[
patchi]*thermo1_->kappaEff(alphat, patchi)
391 +
alpha2().boundaryField()[
patchi]*thermo2_->kappaEff(alphat, patchi);
401 alpha1()*thermo1_->alphaEff(alphat)
402 +
alpha2()*thermo2_->alphaEff(alphat);
413 alpha1().boundaryField()[
patchi]*thermo1_->alphaEff(alphat, patchi)
414 +
alpha2().boundaryField()[
patchi]*thermo2_->alphaEff(alphat, patchi);
virtual tmp< scalarField > THE(const scalarField &h, const scalarField &p, const scalarField &T0, const labelList &cells) const
Temperature from enthalpy/internal energy for cell-set.
virtual tmp< volScalarField > Cp() const
Heat capacity at constant pressure [J/kg/K].
twoPhaseMixtureThermo(const volVectorField &U, const surfaceScalarField &phi)
Construct from components.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
virtual tmp< volScalarField > alphaEff(const volScalarField &alphat) const
Effective thermal diffusivity of mixture [J/m/s/K].
virtual tmp< volScalarField > hc() const
Chemical enthalpy [J/kg].
IOobject(const word &name, const fileName &instance, const objectRegistry ®istry, readOption r=NO_READ, writeOption w=NO_WRITE, bool registerObject=true)
Construct from name, instance, registry, io options.
static autoPtr< rhoThermo > New(const fvMesh &, const word &phaseName=word::null)
Selector.
bool read()
Read transportProperties dictionary.
virtual tmp< volScalarField > alphahe() const
Thermal diffusivity for energy of mixture [kg/m/s].
virtual void correctThermo()
Correct the thermodynamics of each phase.
virtual bool read()
Read base transportProperties dictionary.
virtual tmp< volScalarField > gamma() const
Gamma = Cp/Cv [].
GeometricField< vector, fvPatchField, volMesh > volVectorField
GeometricField< scalar, fvPatchField, volMesh > volScalarField
virtual bool isochoric() const
Return true if the equation of state is isochoric.
virtual tmp< volScalarField > Cv() const
Heat capacity at constant volume [J/kg/K].
A class for handling words, derived from string.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
static word groupName(Name name, const word &group)
const volScalarField & alpha1
virtual tmp< volScalarField > W() const
Molecular weight [kg/kmol].
virtual ~twoPhaseMixtureThermo()
Destructor.
List< label > labelList
A List of labels.
const fileOperation & fileHandler()
Get current file handler.
virtual tmp< volScalarField > CpByCpv() const
Heat capacity ratio [].
Info<< "Predicted p max-min : "<< max(p).value()<< " "<< min(p).value()<< endl;rho==max(psi *p+alphal *rhol0+((alphav *psiv+alphal *psil) - psi) *pSat, rhoMin);# 1 "/home/ubuntu/OpenFOAM-6/applications/solvers/multiphase/cavitatingFoam/alphavPsi.H" 1{ alphav=max(min((rho - rholSat)/(rhovSat - rholSat), scalar(1)), scalar(0));alphal=1.0 - alphav;Info<< "max-min alphav: "<< max(alphav).value()<< " "<< min(alphav).value()<< endl;psiModel-> correct()
defineTypeNameAndDebug(combustionModel, 0)
virtual tmp< volScalarField > Cpv() const
Heat capacity at constant pressure/volume [J/kg/K].
virtual volScalarField & he()
Enthalpy/Internal energy [J/kg].
virtual void flush() const
Forcibly wait until all output done. Flush any cached data.
virtual word thermoName() const
Return the name of the thermo physics.
const dimensionedScalar mu
Atomic mass unit.
volScalarField & h
Planck constant.
virtual void correct()
Update mixture properties.
virtual bool incompressible() const
Return true if the equation of state is incompressible.
virtual tmp< volScalarField > kappa() const
Thermal diffusivity for temperature of mixture [J/m/s/K].
virtual tmp< volScalarField > kappaEff(const volScalarField &alphat) const
Effective thermal diffusivity of mixture [J/m/s/K].
virtual tmp< volScalarField > nu() const
Kinematic viscosity of mixture [m^2/s].
virtual bool read()
Read thermophysical properties dictionary.
A class for managing temporary objects.
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
#define NotImplemented
Issue a FatalErrorIn for a function not currently implemented.