All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
viscosityModel Class Referenceabstract

An abstract base class for incompressible viscosityModels. More...

Inheritance diagram for viscosityModel:
Collaboration diagram for viscosityModel:

Public Member Functions

 TypeName ("viscosityModel")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, viscosityModel, dictionary,(const word &name, const dictionary &viscosityProperties, const volVectorField &U, const surfaceScalarField &phi),(name, viscosityProperties, U, phi))
 
 viscosityModel (const word &name, const dictionary &viscosityProperties, const volVectorField &U, const surfaceScalarField &phi)
 Construct from components. More...
 
 viscosityModel (const viscosityModel &)
 Disallow default bitwise copy construction. More...
 
virtual ~viscosityModel ()
 Destructor. More...
 
const dictionaryviscosityProperties () const
 Return the phase transport properties dictionary. More...
 
tmp< volScalarFieldstrainRate () const
 Return the strain rate. More...
 
virtual tmp< volScalarFieldnu () const =0
 Return the laminar viscosity. More...
 
virtual tmp< scalarFieldnu (const label patchi) const =0
 Return the laminar viscosity for patch. More...
 
virtual void correct ()=0
 Correct the laminar viscosity. More...
 
virtual bool read (const dictionary &viscosityProperties)=0
 Read transportProperties dictionary. More...
 
void operator= (const viscosityModel &)=delete
 Disallow default bitwise assignment. More...
 

Static Public Member Functions

static autoPtr< viscosityModelNew (const word &name, const dictionary &viscosityProperties, const volVectorField &U, const surfaceScalarField &phi)
 Return a reference to the selected viscosity model. More...
 

Protected Attributes

word name_
 
dictionary viscosityProperties_
 
const volVectorFieldU_
 
const surfaceScalarFieldphi_
 

Detailed Description

An abstract base class for incompressible viscosityModels.

The strain rate is defined by:

mag(symm(grad(U)))

Source files

Definition at line 64 of file viscosityModel.H.

Constructor & Destructor Documentation

◆ viscosityModel() [1/2]

viscosityModel ( const word name,
const dictionary viscosityProperties,
const volVectorField U,
const surfaceScalarField phi 
)

Construct from components.

Definition at line 42 of file viscosityModel.C.

◆ viscosityModel() [2/2]

Disallow default bitwise copy construction.

◆ ~viscosityModel()

virtual ~viscosityModel ( )
inlinevirtual

Destructor.

Definition at line 129 of file viscosityModel.H.

Member Function Documentation

◆ TypeName()

TypeName ( "viscosityModel"  )

Runtime type information.

◆ declareRunTimeSelectionTable()

declareRunTimeSelectionTable ( autoPtr  ,
viscosityModel  ,
dictionary  ,
(const word &name, const dictionary &viscosityProperties, const volVectorField &U, const surfaceScalarField &phi ,
(name, viscosityProperties, U, phi  
)

◆ New()

Foam::autoPtr< Foam::viscosityModel > New ( const word name,
const dictionary viscosityProperties,
const volVectorField U,
const surfaceScalarField phi 
)
static

Return a reference to the selected viscosity model.

Definition at line 33 of file viscosityModelNew.C.

References Foam::endl(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Foam::Info, dictionary::lookup(), Foam::name(), Foam::nl, phi, and U.

Here is the call graph for this function:

◆ viscosityProperties()

const dictionary& viscosityProperties ( ) const
inline

Return the phase transport properties dictionary.

Definition at line 136 of file viscosityModel.H.

References viscosityModel::correct(), viscosityModel::nu(), viscosityModel::operator=(), patchi, viscosityModel::read(), viscosityModel::strainRate(), and viscosityModel::viscosityProperties_.

Here is the call graph for this function:

◆ strainRate()

Foam::tmp< Foam::volScalarField > strainRate ( ) const

Return the strain rate.

Definition at line 58 of file viscosityModel.C.

References Foam::fvc::grad(), Foam::mag(), Foam::sqrt(), and Foam::symm().

Referenced by viscosityModel::viscosityProperties().

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

◆ nu() [1/2]

virtual tmp<volScalarField> nu ( ) const
pure virtual

Return the laminar viscosity.

Implemented in Casson, strainRateFunction, BirdCarreau, HerschelBulkley, powerLaw, CrossPowerLaw, and Newtonian.

Referenced by viscosityModel::viscosityProperties().

Here is the caller graph for this function:

◆ nu() [2/2]

virtual tmp<scalarField> nu ( const label  patchi) const
pure virtual

Return the laminar viscosity for patch.

Implemented in Casson, strainRateFunction, BirdCarreau, HerschelBulkley, powerLaw, CrossPowerLaw, and Newtonian.

◆ correct()

virtual void correct ( )
pure virtual

Correct the laminar viscosity.

Implemented in Casson, BirdCarreau, strainRateFunction, HerschelBulkley, powerLaw, CrossPowerLaw, and Newtonian.

Referenced by viscosityModel::viscosityProperties().

Here is the caller graph for this function:

◆ read()

bool read ( const dictionary viscosityProperties)
pure virtual

◆ operator=()

void operator= ( const viscosityModel )
delete

Disallow default bitwise assignment.

Referenced by viscosityModel::viscosityProperties().

Here is the caller graph for this function:

Member Data Documentation

◆ name_

word name_
protected

Definition at line 71 of file viscosityModel.H.

◆ viscosityProperties_

dictionary viscosityProperties_
protected

Definition at line 72 of file viscosityModel.H.

Referenced by viscosityModel::viscosityProperties().

◆ U_

const volVectorField& U_
protected

Definition at line 74 of file viscosityModel.H.

◆ phi_

const surfaceScalarField& phi_
protected

Definition at line 75 of file viscosityModel.H.


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