Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
SpalartAllmaras< BasicTurbulenceModel > Class Template Reference

Spalart-Allmaras one-eqn mixing-length model for incompressible and compressible external flows. More...

Inheritance diagram for SpalartAllmaras< BasicTurbulenceModel >:
Inheritance graph
[legend]
Collaboration diagram for SpalartAllmaras< BasicTurbulenceModel >:
Collaboration graph
[legend]

Public Types

typedef BasicTurbulenceModel::alphaField alphaField
 
typedef BasicTurbulenceModel::rhoField rhoField
 
typedef BasicTurbulenceModel::transportModel transportModel
 
- Public Types inherited from eddyViscosity< RASModel< BasicTurbulenceModel > >
typedef RASModel< BasicTurbulenceModel >::alphaField alphaField
 
typedef RASModel< BasicTurbulenceModel >::rhoField rhoField
 
typedef RASModel< BasicTurbulenceModel >::transportModel transportModel
 
- Public Types inherited from linearViscousStress< RASModel< BasicTurbulenceModel > >
typedef RASModel< BasicTurbulenceModel >::alphaField alphaField
 
typedef RASModel< BasicTurbulenceModel >::rhoField rhoField
 
typedef RASModel< BasicTurbulenceModel >::transportModel transportModel
 
- Public Types inherited from RASModel< BasicTurbulenceModel >
typedef BasicTurbulenceModel::alphaField alphaField
 
typedef BasicTurbulenceModel::rhoField rhoField
 
typedef BasicTurbulenceModel::transportModel transportModel
 

Public Member Functions

 TypeName ("SpalartAllmaras")
 Runtime type information. More...
 
 SpalartAllmaras (const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &propertiesName=turbulenceModel::propertiesName, const word &type=typeName)
 Construct from components. More...
 
virtual ~SpalartAllmaras ()
 Destructor. More...
 
virtual bool read ()
 Read RASProperties dictionary. More...
 
tmp< volScalarFieldDnuTildaEff () const
 Return the effective diffusivity for nuTilda. More...
 
virtual tmp< volScalarFieldk () const
 Return the turbulence kinetic energy. More...
 
virtual tmp< volScalarFieldepsilon () const
 Return the turbulence kinetic energy dissipation rate. More...
 
virtual void correct ()
 Solve the turbulence equations and correct the turbulence viscosity. More...
 
- Public Member Functions inherited from eddyViscosity< RASModel< BasicTurbulenceModel > >
 eddyViscosity (const word &modelName, const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &propertiesName)
 Construct from components. More...
 
virtual ~eddyViscosity ()
 Destructor. More...
 
volScalarFieldevNut ()
 Return non-const access to the turbulence viscosity. More...
 
virtual tmp< volScalarFieldnut () const
 Return the turbulence viscosity. More...
 
virtual tmp< scalarFieldnut (const label patchi) const
 Return the turbulence viscosity on patch. More...
 
virtual tmp< volSymmTensorFieldR () const
 Return the Reynolds stress tensor. More...
 
- Public Member Functions inherited from linearViscousStress< RASModel< BasicTurbulenceModel > >
 linearViscousStress (const word &modelName, const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &propertiesName)
 Construct from components. More...
 
virtual ~linearViscousStress ()
 Destructor. More...
 
virtual tmp< volSymmTensorFielddevRhoReff () const
 Return the effective stress tensor. More...
 
virtual tmp< fvVectorMatrixdivDevRhoReff (volVectorField &U) const
 Return the source term for the momentum equation. More...
 
virtual tmp< fvVectorMatrixdivDevRhoReff (const volScalarField &rho, volVectorField &U) const
 Return the source term for the momentum equation. More...
 
- Public Member Functions inherited from RASModel< BasicTurbulenceModel >
 TypeName ("RAS")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, RASModel, dictionary,( const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &propertiesName ),(alpha, rho, U, alphaRhoPhi, phi, transport, propertiesName))
 
 RASModel (const word &type, const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &propertiesName)
 Construct from components. More...
 
virtual ~RASModel ()
 Destructor. More...
 
const dimensionedScalarkMin () const
 Return the lower allowable limit for k (default: SMALL) More...
 
const dimensionedScalarepsilonMin () const
 Return the lower allowable limit for epsilon (default: SMALL) More...
 
const dimensionedScalaromegaMin () const
 Return the lower allowable limit for omega (default: SMALL) More...
 
dimensionedScalarkMin ()
 Allow kMin to be changed. More...
 
dimensionedScalarepsilonMin ()
 Allow epsilonMin to be changed. More...
 
dimensionedScalaromegaMin ()
 Allow omegaMin to be changed. More...
 
virtual const dictionarycoeffDict () const
 Const access to the coefficients dictionary. More...
 
virtual tmp< volScalarFieldnuEff () const
 Return the effective viscosity. More...
 
virtual tmp< scalarFieldnuEff (const label patchi) const
 Return the effective viscosity on patch. More...
 

Protected Member Functions

tmp< volScalarFieldchi () const
 
tmp< volScalarFieldfv1 (const volScalarField &chi) const
 
tmp< volScalarFieldfv2 (const volScalarField &chi, const volScalarField &fv1) const
 
tmp< volScalarFieldStilda (const volScalarField &chi, const volScalarField &fv1) const
 
tmp< volScalarFieldfw (const volScalarField &Stilda) const
 
void correctNut (const volScalarField &fv1)
 
virtual void correctNut ()
 
- Protected Member Functions inherited from RASModel< BasicTurbulenceModel >
virtual void printCoeffs (const word &type)
 Print model coefficients. More...
 

Protected Attributes

dimensionedScalar sigmaNut_
 
dimensionedScalar kappa_
 
dimensionedScalar Cb1_
 
dimensionedScalar Cb2_
 
dimensionedScalar Cw1_
 
dimensionedScalar Cw2_
 
dimensionedScalar Cw3_
 
dimensionedScalar Cv1_
 
dimensionedScalar Cs_
 
volScalarField nuTilda_
 
const volScalarFieldy_
 Wall distance. More...
 
- Protected Attributes inherited from eddyViscosity< RASModel< BasicTurbulenceModel > >
volScalarField nut_
 
- Protected Attributes inherited from RASModel< BasicTurbulenceModel >
dictionary RASDict_
 RAS coefficients dictionary. More...
 
Switch turbulence_
 Turbulence on/off flag. More...
 
Switch printCoeffs_
 Flag to print the model coeffs at run-time. More...
 
dictionary coeffDict_
 Model coefficients dictionary. More...
 
dimensionedScalar kMin_
 Lower limit of k. More...
 
dimensionedScalar epsilonMin_
 Lower limit of epsilon. More...
 
dimensionedScalar omegaMin_
 Lower limit for omega. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from RASModel< BasicTurbulenceModel >
static autoPtr< RASModelNew (const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &propertiesName=turbulenceModel::propertiesName)
 Return a reference to the selected RAS model. More...
 

Detailed Description

template<class BasicTurbulenceModel>
class Foam::RASModels::SpalartAllmaras< BasicTurbulenceModel >

Spalart-Allmaras one-eqn mixing-length model for incompressible and compressible external flows.

Reference:

    Spalart, P.R., & Allmaras, S.R. (1994).
    A one-equation turbulence model for aerodynamic flows.
    La Recherche Aerospatiale, 1, 5-21.

The model is implemented without the trip-term and hence the ft2 term is not needed.

It is necessary to limit the Stilda generation term as the model generates unphysical results if this term becomes negative which occurs for complex flow. Several approaches have been proposed to limit Stilda but it is not clear which is the most appropriate. Here the limiter proposed by Spalart is implemented in which Stilda is clipped at Cs*Omega with the default value of Cs = 0.3.

The default model coefficients are

    SpalartAllmarasCoeffs
    {
        Cb1         0.1355;
        Cb2         0.622;
        Cw2         0.3;
        Cw3         2.0;
        Cv1         7.1;
        Cs          0.3;
        sigmaNut    0.66666;
        kappa       0.41;
    }
Source files

Definition at line 88 of file SpalartAllmaras.H.

Member Typedef Documentation

typedef BasicTurbulenceModel::alphaField alphaField

Definition at line 153 of file SpalartAllmaras.H.

typedef BasicTurbulenceModel::rhoField rhoField

Definition at line 154 of file SpalartAllmaras.H.

typedef BasicTurbulenceModel::transportModel transportModel

Definition at line 155 of file SpalartAllmaras.H.

Constructor & Destructor Documentation

SpalartAllmaras ( const alphaField alpha,
const rhoField rho,
const volVectorField U,
const surfaceScalarField alphaRhoPhi,
const surfaceScalarField phi,
const transportModel transport,
const word propertiesName = turbulenceModel::propertiesName,
const word type = typeName 
)

Construct from components.

Definition at line 143 of file SpalartAllmaras.C.

virtual ~SpalartAllmaras ( )
inlinevirtual

Member Function Documentation

tmp< volScalarField > chi ( ) const
protected

Definition at line 40 of file SpalartAllmaras.C.

References SpalartAllmaras< BasicTurbulenceModel >::fv1(), and nu.

Here is the call graph for this function:

tmp< volScalarField > fv1 ( const volScalarField chi) const
protected

Definition at line 48 of file SpalartAllmaras.C.

References SpalartAllmaras< BasicTurbulenceModel >::fv2(), and Foam::pow3().

Referenced by SpalartAllmaras< BasicTurbulenceModel >::chi().

Here is the call graph for this function:

Here is the caller graph for this function:

tmp< volScalarField > fv2 ( const volScalarField chi,
const volScalarField fv1 
) const
protected

Definition at line 59 of file SpalartAllmaras.C.

References SpalartAllmaras< BasicTurbulenceModel >::Stilda().

Referenced by SpalartAllmaras< BasicTurbulenceModel >::fv1().

Here is the call graph for this function:

Here is the caller graph for this function:

tmp< volScalarField > Stilda ( const volScalarField chi,
const volScalarField fv1 
) const
protected

Definition at line 70 of file SpalartAllmaras.C.

References SpalartAllmaras< BasicTurbulenceModel >::fw(), Foam::fvc::grad(), Foam::mag(), Foam::max(), Foam::skew(), Foam::sqr(), and Foam::sqrt().

Referenced by SpalartAllmaras< BasicTurbulenceModel >::fv2().

Here is the call graph for this function:

Here is the caller graph for this function:

tmp< volScalarField > fw ( const volScalarField Stilda) const
protected
void correctNut ( const volScalarField fv1)
protected

Definition at line 121 of file SpalartAllmaras.C.

References GeometricField< Type, PatchField, GeoMesh >::correctBoundaryConditions().

Here is the call graph for this function:

void correctNut ( )
protectedvirtual

Implements eddyViscosity< RASModel< BasicTurbulenceModel > >.

Definition at line 133 of file SpalartAllmaras.C.

Referenced by SpalartAllmaras< BasicTurbulenceModel >::fw().

Here is the caller graph for this function:

TypeName ( "SpalartAllmaras< BasicTurbulenceModel >"  )

Runtime type information.

bool read ( )
virtual

Read RASProperties dictionary.

Implements eddyViscosity< RASModel< BasicTurbulenceModel > >.

Definition at line 267 of file SpalartAllmaras.C.

References Foam::read(), dimensioned< Type >::readIfPresent(), and Foam::sqr().

Referenced by SpalartAllmaras< BasicTurbulenceModel >::~SpalartAllmaras().

Here is the call graph for this function:

Here is the caller graph for this function:

tmp< volScalarField > DnuTildaEff ( ) const

Return the effective diffusivity for nuTilda.

Definition at line 292 of file SpalartAllmaras.C.

References nu.

Referenced by SpalartAllmaras< BasicTurbulenceModel >::~SpalartAllmaras().

Here is the caller graph for this function:

tmp< volScalarField > k ( ) const
virtual

Return the turbulence kinetic energy.

Implements eddyViscosity< RASModel< BasicTurbulenceModel > >.

Definition at line 302 of file SpalartAllmaras.C.

Referenced by SpalartAllmaras< BasicTurbulenceModel >::~SpalartAllmaras().

Here is the caller graph for this function:

tmp< volScalarField > epsilon ( ) const
virtual

Return the turbulence kinetic energy dissipation rate.

Definition at line 322 of file SpalartAllmaras.C.

References Foam::endl(), and WarningIn.

Referenced by SpalartAllmaras< BasicTurbulenceModel >::~SpalartAllmaras().

Here is the call graph for this function:

Here is the caller graph for this function:

void correct ( )
virtual

Solve the turbulence equations and correct the turbulence viscosity.

Implements eddyViscosity< RASModel< BasicTurbulenceModel > >.

Definition at line 347 of file SpalartAllmaras.C.

References Foam::bound(), correct, GeometricField< Type, PatchField, GeoMesh >::correctBoundaryConditions(), Foam::fvm::ddt(), Foam::fvm::div(), Foam::fvc::grad(), Foam::fvm::laplacian(), Foam::magSqr(), Foam::solve(), Foam::fvm::Sp(), and Foam::sqr().

Referenced by SpalartAllmaras< BasicTurbulenceModel >::~SpalartAllmaras().

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

dimensionedScalar sigmaNut_
protected

Definition at line 105 of file SpalartAllmaras.H.

dimensionedScalar kappa_
protected

Definition at line 106 of file SpalartAllmaras.H.

dimensionedScalar Cb1_
protected

Definition at line 108 of file SpalartAllmaras.H.

dimensionedScalar Cb2_
protected

Definition at line 109 of file SpalartAllmaras.H.

dimensionedScalar Cw1_
protected

Definition at line 110 of file SpalartAllmaras.H.

dimensionedScalar Cw2_
protected

Definition at line 111 of file SpalartAllmaras.H.

dimensionedScalar Cw3_
protected

Definition at line 112 of file SpalartAllmaras.H.

dimensionedScalar Cv1_
protected

Definition at line 113 of file SpalartAllmaras.H.

dimensionedScalar Cs_
protected

Definition at line 114 of file SpalartAllmaras.H.

volScalarField nuTilda_
protected

Definition at line 119 of file SpalartAllmaras.H.

const volScalarField& y_
protected

Wall distance.

Note: different to wall distance in parent RASModel which is for near-wall cells only

Definition at line 124 of file SpalartAllmaras.H.


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