blendingMethod Class Referenceabstract

Abstract base class for functions that are used to combine interfacial sub-models according to the volume fractions of the phases that they apply to. More...

Inheritance diagram for blendingMethod:
Collaboration diagram for blendingMethod:

Public Member Functions

 TypeName ("blendingMethod")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, blendingMethod, dictionary,(const dictionary &dict, const phaseInterface &interface),(dict, interface))
 
 blendingMethod (const dictionary &dict, const phaseInterface &interface)
 Construct from a dictionary and an interface. More...
 
virtual ~blendingMethod ()
 Destructor. More...
 
virtual bool canBeContinuous (const label index) const =0
 Return whether or not a phase can be considered continuous. More...
 
virtual bool canSegregate () const =0
 Return whether or not this interface can segregate. More...
 
tmp< volScalarFieldf1DispersedIn2 (const UPtrList< const volScalarField > &alphas) const
 Return the coefficient for models in which phase 1 is dispersed in. More...
 
tmp< volScalarFieldf2DispersedIn1 (const UPtrList< const volScalarField > &alphas) const
 Return the coefficient for models in which phase 2 is dispersed in. More...
 
tmp< volScalarFieldfDisplaced (const UPtrList< const volScalarField > &alphas) const
 Return the coefficient for when the interface is displaced by a. More...
 

Static Public Member Functions

static autoPtr< blendingMethodNew (const word &modelTypeName, const dictionary &dict, const phaseInterface &interface)
 

Protected Member Functions

tmp< volScalarFieldconstant (const UPtrList< const volScalarField > &alphas, const scalar k) const
 Return a constant field with the given value. More...
 
tmp< volScalarFieldalpha (const UPtrList< const volScalarField > &alphas, const label set, const bool protect) const
 Get the volume fraction of the given set. More...
 
tmp< volScalarFieldparameter (const UPtrList< const volScalarField > &alphas, const label set, const Pair< blendingParameter > &parameters) const
 Get a blending parameter averaged for the given set. More...
 
tmp< volScalarFieldx (const UPtrList< const volScalarField > &alphas, const label phaseSet, const label systemSet) const
 Return the coordinate of the blending function. More...
 
virtual tmp< volScalarFieldfContinuous (const UPtrList< const volScalarField > &alphas, const label phaseSet, const label systemSet) const =0
 Evaluate the blending function for sets in which all phases can be. More...
 
virtual tmp< volScalarFieldf (const UPtrList< const volScalarField > &alphas, const label phaseSet, const label systemSet) const
 Evaluate the blending function. Filters out phases that cannot. More...
 

Static Protected Member Functions

static blendingParameter readParameter (const word &name, const dictionary &dict, const Pair< scalar > &bounds, const bool allowNone)
 Read a parameter and check it lies within specified bounds. More...
 
static Pair< blendingParameterreadParameters (const word &name, const dictionary &dict, const phaseInterface &interface, const Pair< scalar > &bounds, const bool allowNone)
 Read a parameter for each phase in the interface. More...
 

Protected Attributes

const phaseInterface interface_
 Interface. More...
 

Detailed Description

Abstract base class for functions that are used to combine interfacial sub-models according to the volume fractions of the phases that they apply to.

Source files

Definition at line 65 of file blendingMethod.H.

Constructor & Destructor Documentation

◆ blendingMethod()

blendingMethod ( const dictionary dict,
const phaseInterface interface 
)

Construct from a dictionary and an interface.

Definition at line 223 of file blendingMethod.C.

◆ ~blendingMethod()

~blendingMethod ( )
virtual

Destructor.

Definition at line 235 of file blendingMethod.C.

Member Function Documentation

◆ readParameter()

Foam::blendingParameter readParameter ( const word name,
const dictionary dict,
const Pair< scalar > &  bounds,
const bool  allowNone 
)
staticprotected

Read a parameter and check it lies within specified bounds.

Definition at line 40 of file blendingMethod.C.

References dict, Foam::exit(), Foam::FatalError, FatalErrorInFunction, Foam::FatalIOError, FatalIOErrorInFunction, forAll, token::info(), token::isNumber(), token::isWord(), Foam::name(), token::number(), s(), and token::wordToken().

Here is the call graph for this function:

◆ readParameters()

Foam::Pair< Foam::blendingParameter > readParameters ( const word name,
const dictionary dict,
const phaseInterface interface,
const Pair< scalar > &  bounds,
const bool  allowNone 
)
staticprotected

Read a parameter for each phase in the interface.

Definition at line 84 of file blendingMethod.C.

References dict, IOobject::groupName(), phaseModel::name(), Foam::name(), phaseInterface::phase1(), and phaseInterface::phase2().

Here is the call graph for this function:

◆ constant()

Foam::tmp< Foam::volScalarField > constant ( const UPtrList< const volScalarField > &  alphas,
const scalar  k 
) const
protected

Return a constant field with the given value.

Definition at line 106 of file blendingMethod.C.

References Foam::dimless, UPtrList< T >::first(), k, Foam::name(), and GeometricField< Type, PatchField, GeoMesh >::New().

Referenced by continuous::fContinuous(), and segregated::fContinuous().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ alpha()

Foam::tmp< Foam::volScalarField > alpha ( const UPtrList< const volScalarField > &  alphas,
const label  set,
const bool  protect 
) const
protected

Get the volume fraction of the given set.

Definition at line 122 of file blendingMethod.C.

References forAllConstIter, Foam::max(), and tmp< T >::ref().

Here is the call graph for this function:

◆ parameter()

Foam::tmp< Foam::volScalarField > parameter ( const UPtrList< const volScalarField > &  alphas,
const label  set,
const Pair< blendingParameter > &  parameters 
) const
protected

Get a blending parameter averaged for the given set.

Definition at line 146 of file blendingMethod.C.

References alpha(), forAllConstIter, Foam::max(), and tmp< T >::ref().

Referenced by hyperbolic::fContinuous(), and linear::fContinuous().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ x()

Foam::tmp< Foam::volScalarField > x ( const UPtrList< const volScalarField > &  alphas,
const label  phaseSet,
const label  systemSet 
) const
protected

Return the coordinate of the blending function.

Definition at line 169 of file blendingMethod.C.

References alpha().

Referenced by hyperbolic::fContinuous(), and linear::fContinuous().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fContinuous()

virtual tmp<volScalarField> fContinuous ( const UPtrList< const volScalarField > &  alphas,
const label  phaseSet,
const label  systemSet 
) const
protectedpure virtual

Evaluate the blending function for sets in which all phases can be.

continuous

Implemented in segregated, linear, hyperbolic, and continuous.

◆ f()

Foam::tmp< Foam::volScalarField > f ( const UPtrList< const volScalarField > &  alphas,
const label  phaseSet,
const label  systemSet 
) const
protectedvirtual

Evaluate the blending function. Filters out phases that cannot.

become continuous from the sets, then calls fContinuous

Definition at line 183 of file blendingMethod.C.

References forAllConstIter.

Referenced by linear::fContinuous().

Here is the caller graph for this function:

◆ TypeName()

TypeName ( "blendingMethod"  )

Runtime type information.

◆ declareRunTimeSelectionTable()

declareRunTimeSelectionTable ( autoPtr  ,
blendingMethod  ,
dictionary  ,
(const dictionary &dict, const phaseInterface &interface)  ,
(dict, interface)   
)

◆ New()

Foam::autoPtr< Foam::blendingMethod > New ( const word modelTypeName,
const dictionary dict,
const phaseInterface interface 
)
static

Definition at line 30 of file blendingMethodNew.C.

References dict, Foam::endl(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Foam::Info, and phaseInterface::name().

Referenced by BlendedInterfacialModel< ModelType >::BlendedInterfacialModel().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ canBeContinuous()

virtual bool canBeContinuous ( const label  index) const
pure virtual

Return whether or not a phase can be considered continuous.

Implemented in segregated, linear, hyperbolic, and continuous.

◆ canSegregate()

virtual bool canSegregate ( ) const
pure virtual

Return whether or not this interface can segregate.

Implemented in segregated, linear, hyperbolic, and continuous.

◆ f1DispersedIn2()

Foam::tmp< Foam::volScalarField > f1DispersedIn2 ( const UPtrList< const volScalarField > &  alphas) const

Return the coefficient for models in which phase 1 is dispersed in.

phase 2

Definition at line 241 of file blendingMethod.C.

References f().

Here is the call graph for this function:

◆ f2DispersedIn1()

Foam::tmp< Foam::volScalarField > f2DispersedIn1 ( const UPtrList< const volScalarField > &  alphas) const

Return the coefficient for models in which phase 2 is dispersed in.

phase 1

Definition at line 250 of file blendingMethod.C.

References f().

Here is the call graph for this function:

◆ fDisplaced()

Foam::tmp< Foam::volScalarField > fDisplaced ( const UPtrList< const volScalarField > &  alphas) const

Return the coefficient for when the interface is displaced by a.

third phase

Definition at line 259 of file blendingMethod.C.

References f().

Here is the call graph for this function:

Member Data Documentation

◆ interface_

const phaseInterface interface_
protected

Interface.

Definition at line 72 of file blendingMethod.H.

Referenced by continuous::fContinuous().


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