src/TurbulenceModels: Renamed template classes to start with capital letter

This commit is contained in:
Henry Weller
2015-08-20 15:30:53 +01:00
parent da2e7bdbbd
commit f95661df22
8 changed files with 52 additions and 52 deletions

View File

@ -23,12 +23,12 @@ License
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "eddyDiffusivity.H" #include "EddyDiffusivity.H"
// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // // * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * //
template<class BasicTurbulenceModel> template<class BasicTurbulenceModel>
void Foam::eddyDiffusivity<BasicTurbulenceModel>::correctNut() void Foam::EddyDiffusivity<BasicTurbulenceModel>::correctNut()
{ {
alphat_ = this->rho_*this->nut()/Prt_; alphat_ = this->rho_*this->nut()/Prt_;
alphat_.correctBoundaryConditions(); alphat_.correctBoundaryConditions();
@ -38,7 +38,7 @@ void Foam::eddyDiffusivity<BasicTurbulenceModel>::correctNut()
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class BasicTurbulenceModel> template<class BasicTurbulenceModel>
Foam::eddyDiffusivity<BasicTurbulenceModel>::eddyDiffusivity Foam::EddyDiffusivity<BasicTurbulenceModel>::EddyDiffusivity
( (
const word& type, const word& type,
const geometricOneField& alpha, const geometricOneField& alpha,
@ -92,8 +92,8 @@ Foam::eddyDiffusivity<BasicTurbulenceModel>::eddyDiffusivity
// * * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * //
template<class BasicTurbulenceModel> template<class BasicTurbulenceModel>
Foam::autoPtr<Foam::eddyDiffusivity<BasicTurbulenceModel> > Foam::autoPtr<Foam::EddyDiffusivity<BasicTurbulenceModel> >
Foam::eddyDiffusivity<BasicTurbulenceModel>::New Foam::EddyDiffusivity<BasicTurbulenceModel>::New
( (
const volScalarField& rho, const volScalarField& rho,
const volVectorField& U, const volVectorField& U,
@ -102,9 +102,9 @@ Foam::eddyDiffusivity<BasicTurbulenceModel>::New
const word& propertiesName const word& propertiesName
) )
{ {
return autoPtr<eddyDiffusivity> return autoPtr<EddyDiffusivity>
( (
static_cast<eddyDiffusivity*>( static_cast<EddyDiffusivity*>(
BasicTurbulenceModel::New BasicTurbulenceModel::New
( (
rho, rho,
@ -120,7 +120,7 @@ Foam::eddyDiffusivity<BasicTurbulenceModel>::New
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class BasicTurbulenceModel> template<class BasicTurbulenceModel>
bool Foam::eddyDiffusivity<BasicTurbulenceModel>::read() bool Foam::EddyDiffusivity<BasicTurbulenceModel>::read()
{ {
if (BasicTurbulenceModel::read()) if (BasicTurbulenceModel::read())
{ {

View File

@ -22,19 +22,19 @@ License
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>. along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
Class Class
Foam::eddyDiffusivity Foam::EddyDiffusivity
Description Description
Templated abstract base class for single-phase compressible Templated abstract base class for single-phase compressible
turbulence models. turbulence models.
SourceFiles SourceFiles
eddyDiffusivity.C EddyDiffusivity.C
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#ifndef eddyDiffusivity_H #ifndef EddyDiffusivity_H
#define eddyDiffusivity_H #define EddyDiffusivity_H
#include "CompressibleTurbulenceModel.H" #include "CompressibleTurbulenceModel.H"
@ -44,11 +44,11 @@ namespace Foam
{ {
/*---------------------------------------------------------------------------*\ /*---------------------------------------------------------------------------*\
Class eddyDiffusivity Declaration Class EddyDiffusivity Declaration
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
template<class BasicTurbulenceModel> template<class BasicTurbulenceModel>
class eddyDiffusivity class EddyDiffusivity
: :
public BasicTurbulenceModel public BasicTurbulenceModel
{ {
@ -81,7 +81,7 @@ public:
// Constructors // Constructors
//- Construct //- Construct
eddyDiffusivity EddyDiffusivity
( (
const word& type, const word& type,
const geometricOneField& alpha, const geometricOneField& alpha,
@ -97,7 +97,7 @@ public:
// Selectors // Selectors
//- Return a reference to the selected turbulence model //- Return a reference to the selected turbulence model
static autoPtr<eddyDiffusivity> New static autoPtr<EddyDiffusivity> New
( (
const volScalarField& rho, const volScalarField& rho,
const volVectorField& U, const volVectorField& U,
@ -108,7 +108,7 @@ public:
//- Destructor //- Destructor
virtual ~eddyDiffusivity() virtual ~EddyDiffusivity()
{} {}
@ -167,7 +167,7 @@ public:
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#ifdef NoRepository #ifdef NoRepository
# include "eddyDiffusivity.C" # include "EddyDiffusivity.C"
#endif #endif
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -23,12 +23,12 @@ License
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "thermalDiffusivity.H" #include "ThermalDiffusivity.H"
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class TransportModel> template<class TransportModel>
Foam::thermalDiffusivity<TransportModel>::thermalDiffusivity Foam::ThermalDiffusivity<TransportModel>::ThermalDiffusivity
( (
const word& type, const word& type,
const geometricOneField& alpha, const geometricOneField& alpha,
@ -57,8 +57,8 @@ Foam::thermalDiffusivity<TransportModel>::thermalDiffusivity
// * * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * //
template<class TransportModel> template<class TransportModel>
Foam::autoPtr<Foam::thermalDiffusivity<TransportModel> > Foam::autoPtr<Foam::ThermalDiffusivity<TransportModel> >
Foam::thermalDiffusivity<TransportModel>::New Foam::ThermalDiffusivity<TransportModel>::New
( (
const volScalarField& rho, const volScalarField& rho,
const volVectorField& U, const volVectorField& U,
@ -67,9 +67,9 @@ Foam::thermalDiffusivity<TransportModel>::New
const word& propertiesName const word& propertiesName
) )
{ {
return autoPtr<thermalDiffusivity> return autoPtr<ThermalDiffusivity>
( (
static_cast<thermalDiffusivity*>( static_cast<ThermalDiffusivity*>(
CompressibleTurbulenceModel<transportModel>::New CompressibleTurbulenceModel<transportModel>::New
( (
rho, rho,
@ -86,7 +86,7 @@ Foam::thermalDiffusivity<TransportModel>::New
template<class BasicTurbulenceModel> template<class BasicTurbulenceModel>
Foam::tmp<Foam::volScalarField> Foam::tmp<Foam::volScalarField>
Foam::thermalDiffusivity<BasicTurbulenceModel>::alphat() const Foam::ThermalDiffusivity<BasicTurbulenceModel>::alphat() const
{ {
return tmp<volScalarField> return tmp<volScalarField>
( (
@ -109,7 +109,7 @@ Foam::thermalDiffusivity<BasicTurbulenceModel>::alphat() const
template<class BasicTurbulenceModel> template<class BasicTurbulenceModel>
Foam::tmp<Foam::scalarField> Foam::tmp<Foam::scalarField>
Foam::thermalDiffusivity<BasicTurbulenceModel>::alphat Foam::ThermalDiffusivity<BasicTurbulenceModel>::alphat
( (
const label patchi const label patchi
) const ) const

View File

@ -22,19 +22,19 @@ License
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>. along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
Class Class
Foam::thermalDiffusivity Foam::ThermalDiffusivity
Description Description
Templated abstract base class for single-phase compressible Templated abstract base class for single-phase compressible
turbulence models. turbulence models.
SourceFiles SourceFiles
thermalDiffusivity.C ThermalDiffusivity.C
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#ifndef thermalDiffusivity_H #ifndef ThermalDiffusivity_H
#define thermalDiffusivity_H #define ThermalDiffusivity_H
#include "CompressibleTurbulenceModel.H" #include "CompressibleTurbulenceModel.H"
@ -44,11 +44,11 @@ namespace Foam
{ {
/*---------------------------------------------------------------------------*\ /*---------------------------------------------------------------------------*\
Class thermalDiffusivity Declaration Class ThermalDiffusivity Declaration
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
template<class TransportModel> template<class TransportModel>
class thermalDiffusivity class ThermalDiffusivity
: :
public CompressibleTurbulenceModel<TransportModel> public CompressibleTurbulenceModel<TransportModel>
{ {
@ -63,7 +63,7 @@ public:
// Constructors // Constructors
//- Construct //- Construct
thermalDiffusivity ThermalDiffusivity
( (
const word& type, const word& type,
const geometricOneField& alpha, const geometricOneField& alpha,
@ -79,7 +79,7 @@ public:
// Selectors // Selectors
//- Return a reference to the selected turbulence model //- Return a reference to the selected turbulence model
static autoPtr<thermalDiffusivity> New static autoPtr<ThermalDiffusivity> New
( (
const volScalarField& rho, const volScalarField& rho,
const volVectorField& U, const volVectorField& U,
@ -90,7 +90,7 @@ public:
//- Destructor //- Destructor
virtual ~thermalDiffusivity() virtual ~ThermalDiffusivity()
{} {}
@ -166,7 +166,7 @@ public:
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#ifdef NoRepository #ifdef NoRepository
# include "thermalDiffusivity.C" # include "ThermalDiffusivity.C"
#endif #endif
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -153,10 +153,10 @@ void Foam::totalFlowRateAdvectiveDiffusiveFvPatchScalarField::updateCoeffs()
const label patchI = patch().index(); const label patchI = patch().index();
const LESModel<eddyDiffusivity<compressible::turbulenceModel> >& turbModel = const LESModel<EddyDiffusivity<compressible::turbulenceModel> >& turbModel =
db().lookupObject db().lookupObject
< <
LESModel<eddyDiffusivity<compressible::turbulenceModel> > LESModel<EddyDiffusivity<compressible::turbulenceModel> >
> ( > (
IOobject::groupName IOobject::groupName
( (

View File

@ -56,7 +56,7 @@ License
); \ ); \
\ \
\ \
typedef RASModel<eddyDiffusivity<Transport##BaseModel> > \ typedef RASModel<EddyDiffusivity<Transport##BaseModel> > \
RAS##Transport##BaseModel; \ RAS##Transport##BaseModel; \
\ \
defineNamedTemplateTypeNameAndDebug(RAS##Transport##BaseModel, 0); \ defineNamedTemplateTypeNameAndDebug(RAS##Transport##BaseModel, 0); \
@ -72,7 +72,7 @@ License
); \ ); \
\ \
\ \
typedef LESModel<eddyDiffusivity<Transport##BaseModel> > \ typedef LESModel<EddyDiffusivity<Transport##BaseModel> > \
LES##Transport##BaseModel; \ LES##Transport##BaseModel; \
\ \
defineNamedTemplateTypeNameAndDebug(LES##Transport##BaseModel, 0); \ defineNamedTemplateTypeNameAndDebug(LES##Transport##BaseModel, 0); \
@ -90,7 +90,7 @@ License
#define makeTemplatedTurbulenceModel(BaseModel, SType, Type) \ #define makeTemplatedTurbulenceModel(BaseModel, SType, Type) \
typedef Foam::SType##Models::Type<Foam::eddyDiffusivity<Foam::BaseModel> > \ typedef Foam::SType##Models::Type<Foam::EddyDiffusivity<Foam::BaseModel> > \
Type##SType##BaseModel; \ Type##SType##BaseModel; \
defineNamedTemplateTypeNameAndDebug(Type##SType##BaseModel, 0); \ defineNamedTemplateTypeNameAndDebug(Type##SType##BaseModel, 0); \
\ \
@ -98,7 +98,7 @@ License
{ \ { \
namespace SType##Models \ namespace SType##Models \
{ \ { \
typedef Type<eddyDiffusivity<BaseModel> > Type##SType##BaseModel; \ typedef Type<EddyDiffusivity<BaseModel> > Type##SType##BaseModel; \
\ \
addToRunTimeSelectionTable \ addToRunTimeSelectionTable \
( \ ( \

View File

@ -43,8 +43,8 @@ SourceFiles
#define turbulentFluidThermoModel_H #define turbulentFluidThermoModel_H
#include "SpecificCompressibleTurbulenceModel.H" #include "SpecificCompressibleTurbulenceModel.H"
#include "thermalDiffusivity.H" #include "ThermalDiffusivity.H"
#include "eddyDiffusivity.H" #include "EddyDiffusivity.H"
#include "RASModel.H" #include "RASModel.H"
#include "LESModel.H" #include "LESModel.H"
#include "fluidThermo.H" #include "fluidThermo.H"
@ -55,16 +55,16 @@ namespace Foam
{ {
namespace compressible namespace compressible
{ {
typedef thermalDiffusivity<fluidThermo> turbulenceModel; typedef ThermalDiffusivity<fluidThermo> turbulenceModel;
typedef SpecificCompressibleTurbulenceModel typedef SpecificCompressibleTurbulenceModel
< <
RASModel<eddyDiffusivity<turbulenceModel> > RASModel<EddyDiffusivity<turbulenceModel> >
> RASModel; > RASModel;
typedef SpecificCompressibleTurbulenceModel typedef SpecificCompressibleTurbulenceModel
< <
LESModel<eddyDiffusivity<turbulenceModel> > LESModel<EddyDiffusivity<turbulenceModel> >
> LESModel; > LESModel;
} }
} }

View File

@ -28,8 +28,8 @@ License
#include "addToRunTimeSelectionTable.H" #include "addToRunTimeSelectionTable.H"
#include "makeTurbulenceModel.H" #include "makeTurbulenceModel.H"
#include "thermalDiffusivity.H" #include "ThermalDiffusivity.H"
#include "eddyDiffusivity.H" #include "EddyDiffusivity.H"
#include "laminar.H" #include "laminar.H"
#include "RASModel.H" #include "RASModel.H"
@ -42,17 +42,17 @@ makeBaseTurbulenceModel
geometricOneField, geometricOneField,
volScalarField, volScalarField,
compressibleTurbulenceModel, compressibleTurbulenceModel,
thermalDiffusivity, ThermalDiffusivity,
fluidThermo fluidThermo
); );
#define makeRASModel(Type) \ #define makeRASModel(Type) \
makeTemplatedTurbulenceModel \ makeTemplatedTurbulenceModel \
(fluidThermothermalDiffusivity, RAS, Type) (fluidThermoThermalDiffusivity, RAS, Type)
#define makeLESModel(Type) \ #define makeLESModel(Type) \
makeTemplatedTurbulenceModel \ makeTemplatedTurbulenceModel \
(fluidThermothermalDiffusivity, LES, Type) (fluidThermoThermalDiffusivity, LES, Type)
// -------------------------------------------------------------------------- // // -------------------------------------------------------------------------- //