InterfaceCompositionModel< Thermo, OtherThermo > Class Template Reference

Base class for interface composition models, templated on the two thermodynamic models either side of the interface. More...

Inheritance diagram for InterfaceCompositionModel< Thermo, OtherThermo >:
[legend]
Collaboration diagram for InterfaceCompositionModel< Thermo, OtherThermo >:
[legend]

Public Member Functions

 InterfaceCompositionModel (const dictionary &dict, const phasePair &pair)
 Construct from components. More...
 
 ~InterfaceCompositionModel ()=default
 Destructor. More...
 
virtual tmp< volScalarFielddY (const word &speciesName, const volScalarField &Tf) const
 Mass fraction difference between the interface and the field. More...
 
virtual tmp< volScalarFieldYf (const word &speciesName, const volScalarField &Tf) const
 Reference mass fraction for species based models. More...
 
virtual tmp< volScalarFieldD (const word &speciesName) const
 Mass diffusivity of the local thermo. More...
 
virtual tmp< volScalarFieldL (const word &speciesName, const volScalarField &Tf) const
 Latent heat (to - from)(thermo - otherThermo) More...
 
 InterfaceCompositionModel (const dictionary &dict, const phasePair &pair)
 Construct from components. More...
 
 ~InterfaceCompositionModel ()=default
 Destructor. More...
 
virtual tmp< volScalarFielddY (const word &speciesName, const volScalarField &Tf) const
 Mass fraction difference between the interface and the field. More...
 
virtual tmp< volScalarFieldD (const word &speciesName) const
 Mass diffusivity. More...
 
virtual tmp< volScalarFieldL (const word &speciesName, const volScalarField &Tf) const
 Latent heat. More...
 
virtual void addMDotL (const volScalarField &K, const volScalarField &Tf, volScalarField &mDotL, volScalarField &mDotLPrime) const
 Add latent heat flow rate to total. More...
 
template<class ThermoType >
const Foam::multiComponentMixture< ThermoType >::thermoType & getLocalThermo (const word &speciesName, const multiComponentMixture< ThermoType > &globalThermo) const
 
template<class ThermoType >
const Foam::pureMixture< ThermoType >::thermoType & getLocalThermo (const word &speciesName, const pureMixture< ThermoType > &globalThermo) const
 
template<class ThermoType >
Foam::tmp< Foam::volScalarFieldgetSpecieMassFraction (const word &speciesName, const multiComponentMixture< ThermoType > &mixture) const
 
template<class ThermoType >
Foam::tmp< Foam::volScalarFieldgetSpecieMassFraction (const word &speciesName, const pureMixture< ThermoType > &mixture) const
 
template<class ThermoType >
Foam::tmp< Foam::volScalarFieldMwMixture (const pureMixture< ThermoType > &mixture) const
 
template<class ThermoType >
Foam::tmp< Foam::volScalarFieldMwMixture (const multiComponentMixture< ThermoType > &mixture) const
 
- Public Member Functions inherited from interfaceCompositionModel
 TypeName ("interfaceCompositionModel")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, interfaceCompositionModel, dictionary,(const dictionary &dict, const phasePair &pair),(dict, pair))
 
 interfaceCompositionModel (const dictionary &dict, const phasePair &pair)
 Construct from a dictionary and a phase pair. More...
 
virtual ~interfaceCompositionModel ()=default
 Destructor. More...
 
const word transferSpecie () const
 Return the transferring species name. More...
 
const phasePairpair () const
 The phase pair. More...
 
virtual tmp< volScalarFieldKexp (const volScalarField &field)=0
 Explicit full mass transfer. More...
 
virtual tmp< volScalarFieldKSp (label modelVariable, const volScalarField &field)=0
 Implicit mass transfer. More...
 
virtual tmp< volScalarFieldKSu (label modelVariable, const volScalarField &field)=0
 Explicit mass transfer. More...
 
virtual const dimensionedScalarTactivate () const noexcept=0
 Reference value. More...
 
virtual bool includeDivU () const noexcept
 
bool includeVolChange ()
 Add volume change in pEq. More...
 
const wordvariable () const
 Returns the variable on which the model is based. More...
 
 TypeName ("interfaceCompositionModel")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, interfaceCompositionModel, dictionary,(const dictionary &dict, const phasePair &pair),(dict, pair))
 
 interfaceCompositionModel (const dictionary &dict, const phasePair &pair)
 Construct from a dictionary and a phase pair. More...
 
virtual ~interfaceCompositionModel ()=default
 Destructor. More...
 
virtual void update (const volScalarField &Tf)=0
 Update the composition. More...
 
const hashedWordListspecies () const
 The transferring species names. More...
 
bool transports (word &speciesName) const
 
virtual tmp< volScalarFieldYfPrime (const word &speciesName, const volScalarField &Tf) const =0
 The interface mass fraction derivative w.r.t. temperature. More...
 

Protected Member Functions

template<class ThermoType >
const pureMixture< ThermoType >::thermoType & getLocalThermo (const word &speciesName, const pureMixture< ThermoType > &globalThermo) const
 Get a reference to the local thermo for a pure mixture. More...
 
template<class ThermoType >
const multiComponentMixture< ThermoType >::thermoType & getLocalThermo (const word &speciesName, const multiComponentMixture< ThermoType > &globalThermo) const
 Get a reference to the local thermo for a multi component mixture. More...
 
template<class ThermoType >
tmp< volScalarFieldgetSpecieMassFraction (const word &speciesName, const pureMixture< ThermoType > &thermo) const
 Return mass fraction for a pureMixture equal to one. More...
 
template<class ThermoType >
tmp< volScalarFieldgetSpecieMassFraction (const word &speciesName, const multiComponentMixture< ThermoType > &thermo) const
 Return mass fraction for speciesName. More...
 
template<class ThermoType >
tmp< volScalarFieldMwMixture (const pureMixture< ThermoType > &thermo) const
 Return moleculas weight of the mixture for pureMixture [Kg/mol]. More...
 
template<class ThermoType >
tmp< volScalarFieldMwMixture (const multiComponentMixture< ThermoType > &) const
 Return moleculas weight of the mixture for multiComponentMixture. More...
 
template<class ThermoType >
const pureMixture< ThermoType >::thermoType & getLocalThermo (const word &speciesName, const pureMixture< ThermoType > &globalThermo) const
 Get a reference to the local thermo for a pure mixture. More...
 
template<class ThermoType >
const multiComponentMixture< ThermoType >::thermoType & getLocalThermo (const word &speciesName, const multiComponentMixture< ThermoType > &globalThermo) const
 Get a reference to the local thermo for a multi component mixture. More...
 

Protected Attributes

const Thermo & fromThermo_
 Thermo (from) More...
 
const OtherThermo & toThermo_
 Other Thermo (to) More...
 
const dimensionedScalar Le_
 Lewis number. More...
 
const Thermo & thermo_
 Thermo. More...
 
const OtherThermo & otherThermo_
 Other Thermo. More...
 
- Protected Attributes inherited from interfaceCompositionModel
modelVariable modelVariable_
 Enumeration for the model variable. More...
 
bool includeVolChange_
 Add volume change in pEq. More...
 
const phasePairpair_
 Phase pair. More...
 
word speciesName_
 Names of the transferring specie. More...
 
const fvMeshmesh_
 Reference to mesh. More...
 
const hashedWordList speciesNames_
 Names of the transferring species. More...
 

Additional Inherited Members

- Public Types inherited from interfaceCompositionModel
enum  modelVariable { T, P, Y, alpha }
 Enumeration for variable based mass transfer models. More...
 
- Static Public Member Functions inherited from interfaceCompositionModel
static autoPtr< interfaceCompositionModelNew (const dictionary &dict, const phasePair &pair)
 
static autoPtr< interfaceCompositionModelNew (const dictionary &dict, const phasePair &pair)
 
- Static Protected Attributes inherited from interfaceCompositionModel
static const Enum< modelVariablemodelVariableNames_
 Selection names for the modelVariable. More...
 

Detailed Description

template<class Thermo, class OtherThermo>
class Foam::InterfaceCompositionModel< Thermo, OtherThermo >

Base class for interface composition models, templated on the two thermodynamic models either side of the interface.

Source files

Source files

Definition at line 58 of file InterfaceCompositionModel.H.

Constructor & Destructor Documentation

◆ InterfaceCompositionModel() [1/2]

InterfaceCompositionModel ( const dictionary dict,
const phasePair pair 
)

Construct from components.

Definition at line 181 of file InterfaceCompositionModel.C.

◆ ~InterfaceCompositionModel() [1/2]

Destructor.

◆ InterfaceCompositionModel() [2/2]

InterfaceCompositionModel ( const dictionary dict,
const phasePair pair 
)

Construct from components.

◆ ~InterfaceCompositionModel() [2/2]

Destructor.

Member Function Documentation

◆ getLocalThermo() [1/6]

const pureMixture<ThermoType>::thermoType& getLocalThermo ( const word speciesName,
const pureMixture< ThermoType > &  globalThermo 
) const
protected

Get a reference to the local thermo for a pure mixture.

◆ getLocalThermo() [2/6]

const multiComponentMixture<ThermoType>::thermoType& getLocalThermo ( const word speciesName,
const multiComponentMixture< ThermoType > &  globalThermo 
) const
protected

Get a reference to the local thermo for a multi component mixture.

◆ getSpecieMassFraction() [1/4]

tmp<volScalarField> getSpecieMassFraction ( const word speciesName,
const pureMixture< ThermoType > &  thermo 
) const
protected

Return mass fraction for a pureMixture equal to one.

◆ getSpecieMassFraction() [2/4]

tmp<volScalarField> getSpecieMassFraction ( const word speciesName,
const multiComponentMixture< ThermoType > &  thermo 
) const
protected

Return mass fraction for speciesName.

◆ MwMixture() [1/4]

tmp<volScalarField> MwMixture ( const pureMixture< ThermoType > &  thermo) const
protected

Return moleculas weight of the mixture for pureMixture [Kg/mol].

◆ MwMixture() [2/4]

tmp<volScalarField> MwMixture ( const multiComponentMixture< ThermoType > &  ) const
protected

Return moleculas weight of the mixture for multiComponentMixture.

[Kg/mol]

◆ dY() [1/2]

Foam::tmp< Foam::volScalarField > dY ( const word speciesName,
const volScalarField Tf 
) const
virtual

Mass fraction difference between the interface and the field.

Implements interfaceCompositionModel.

Definition at line 306 of file InterfaceCompositionModel.C.

References NotImplemented.

◆ Yf()

Foam::tmp< Foam::volScalarField > Yf ( const word speciesName,
const volScalarField Tf 
) const
virtual

Reference mass fraction for species based models.

Implements interfaceCompositionModel.

Reimplemented in NonRandomTwoLiquid< Thermo, OtherThermo >, Saturated< Thermo, OtherThermo >, Henry< Thermo, OtherThermo >, and Raoult< Thermo, OtherThermo >.

Definition at line 319 of file InterfaceCompositionModel.C.

References NotImplemented.

◆ D() [1/2]

Foam::tmp< Foam::volScalarField > D ( const word speciesName) const
virtual

Mass diffusivity of the local thermo.

Implements interfaceCompositionModel.

Definition at line 218 of file InterfaceCompositionModel.C.

References D, Foam::dimArea, Foam::dimTime, forAll, Foam::New(), p, T, and Foam::Zero.

Here is the call graph for this function:

◆ L() [1/2]

Foam::tmp< Foam::volScalarField > L ( const word speciesName,
const volScalarField Tf 
) const
virtual

Latent heat (to - from)(thermo - otherThermo)

Implements interfaceCompositionModel.

Definition at line 264 of file InterfaceCompositionModel.C.

References Foam::dimEnergy, Foam::dimMass, forAll, L(), Foam::New(), p, and Foam::Zero.

Here is the call graph for this function:

◆ getLocalThermo() [3/6]

const pureMixture<ThermoType>::thermoType& getLocalThermo ( const word speciesName,
const pureMixture< ThermoType > &  globalThermo 
) const
protected

Get a reference to the local thermo for a pure mixture.

◆ getLocalThermo() [4/6]

const multiComponentMixture<ThermoType>::thermoType& getLocalThermo ( const word speciesName,
const multiComponentMixture< ThermoType > &  globalThermo 
) const
protected

Get a reference to the local thermo for a multi component mixture.

◆ dY() [2/2]

virtual tmp<volScalarField> dY ( const word speciesName,
const volScalarField Tf 
) const
virtual

Mass fraction difference between the interface and the field.

Implements interfaceCompositionModel.

◆ D() [2/2]

virtual tmp<volScalarField> D ( const word speciesName) const
virtual

Mass diffusivity.

Implements interfaceCompositionModel.

◆ L() [2/2]

virtual tmp<volScalarField> L ( const word speciesName,
const volScalarField Tf 
) const
virtual

Latent heat.

Implements interfaceCompositionModel.

◆ addMDotL()

void addMDotL ( const volScalarField K,
const volScalarField Tf,
volScalarField mDotL,
volScalarField mDotLPrime 
) const
virtual

Add latent heat flow rate to total.

Implements interfaceCompositionModel.

Definition at line 209 of file InterfaceCompositionModel.C.

References D, and L().

Here is the call graph for this function:

◆ getLocalThermo() [5/6]

const Foam::multiComponentMixture< ThermoType >::thermoType & getLocalThermo ( const word speciesName,
const multiComponentMixture< ThermoType > &  globalThermo 
) const

Definition at line 42 of file InterfaceCompositionModel.C.

References multiComponentMixture< ThermoType >::getLocalThermo().

Here is the call graph for this function:

◆ getLocalThermo() [6/6]

const Foam::pureMixture< ThermoType >::thermoType & getLocalThermo ( const word speciesName,
const pureMixture< ThermoType > &  globalThermo 
) const

Definition at line 62 of file InterfaceCompositionModel.C.

References pureMixture< ThermoType >::cellMixture().

Here is the call graph for this function:

◆ getSpecieMassFraction() [3/4]

Foam::tmp<Foam::volScalarField> getSpecieMassFraction ( const word speciesName,
const multiComponentMixture< ThermoType > &  mixture 
) const

Definition at line 75 of file InterfaceCompositionModel.C.

References Foam::dimless, mesh, Foam::New(), and Foam::Zero.

Here is the call graph for this function:

◆ getSpecieMassFraction() [4/4]

Foam::tmp<Foam::volScalarField> getSpecieMassFraction ( const word speciesName,
const pureMixture< ThermoType > &  mixture 
) const

Definition at line 109 of file InterfaceCompositionModel.C.

References Foam::dimless, mesh, and Foam::New().

Here is the call graph for this function:

◆ MwMixture() [3/4]

Foam::tmp<Foam::volScalarField> MwMixture ( const pureMixture< ThermoType > &  mixture) const

Definition at line 137 of file InterfaceCompositionModel.C.

References Foam::dimMass, Foam::dimMoles, Foam::constant::electromagnetic::e, mesh, and Foam::New().

Here is the call graph for this function:

◆ MwMixture() [4/4]

Foam::tmp<Foam::volScalarField> MwMixture ( const multiComponentMixture< ThermoType > &  mixture) const

Definition at line 169 of file InterfaceCompositionModel.C.

Member Data Documentation

◆ fromThermo_

const Thermo& fromThermo_
protected

Thermo (from)

Definition at line 67 of file InterfaceCompositionModel.H.

◆ toThermo_

const OtherThermo& toThermo_
protected

Other Thermo (to)

Definition at line 70 of file InterfaceCompositionModel.H.

◆ Le_

const dimensionedScalar Le_
protected

Lewis number.

Definition at line 73 of file InterfaceCompositionModel.H.

◆ thermo_

const Thermo& thermo_
protected

Thermo.

Definition at line 67 of file InterfaceCompositionModel.H.

◆ otherThermo_

const OtherThermo& otherThermo_
protected

Other Thermo.

Definition at line 70 of file InterfaceCompositionModel.H.


The documentation for this class was generated from the following files: