ThermalDiffusivity: Refactored to support phase turbulence models

This commit is contained in:
Henry Weller
2015-08-20 17:54:51 +01:00
parent 3ecf04d441
commit c80e7cd4e5
8 changed files with 19 additions and 20 deletions

View File

@ -55,7 +55,7 @@ PDRkEpsilon::PDRkEpsilon
const word& modelName const word& modelName
) )
: :
Foam::RASModels::kEpsilon<eddyDiffusivity<compressible::turbulenceModel> > Foam::RASModels::kEpsilon<EddyDiffusivity<compressible::turbulenceModel> >
( (
geometricOneField(), geometricOneField(),
rho, rho,

View File

@ -80,7 +80,7 @@ class PDRkEpsilon
: :
public Foam::RASModels::kEpsilon public Foam::RASModels::kEpsilon
< <
eddyDiffusivity EddyDiffusivity
< <
compressible::turbulenceModel compressible::turbulenceModel
> >

View File

@ -36,8 +36,6 @@ SourceFiles
#ifndef EddyDiffusivity_H #ifndef EddyDiffusivity_H
#define EddyDiffusivity_H #define EddyDiffusivity_H
#include "CompressibleTurbulenceModel.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam namespace Foam

View File

@ -27,8 +27,8 @@ License
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template<class TransportModel> template<class BasicTurbulenceModel>
Foam::ThermalDiffusivity<TransportModel>::ThermalDiffusivity Foam::ThermalDiffusivity<BasicTurbulenceModel>::ThermalDiffusivity
( (
const word& type, const word& type,
const geometricOneField& alpha, const geometricOneField& alpha,
@ -40,7 +40,7 @@ Foam::ThermalDiffusivity<TransportModel>::ThermalDiffusivity
const word& propertiesName const word& propertiesName
) )
: :
CompressibleTurbulenceModel<TransportModel> BasicTurbulenceModel
( (
type, type,
alpha, alpha,
@ -56,9 +56,9 @@ Foam::ThermalDiffusivity<TransportModel>::ThermalDiffusivity
// * * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * //
template<class TransportModel> template<class BasicTurbulenceModel>
Foam::autoPtr<Foam::ThermalDiffusivity<TransportModel> > Foam::autoPtr<Foam::ThermalDiffusivity<BasicTurbulenceModel> >
Foam::ThermalDiffusivity<TransportModel>::New Foam::ThermalDiffusivity<BasicTurbulenceModel>::New
( (
const volScalarField& rho, const volScalarField& rho,
const volVectorField& U, const volVectorField& U,
@ -70,7 +70,7 @@ Foam::ThermalDiffusivity<TransportModel>::New
return autoPtr<ThermalDiffusivity> return autoPtr<ThermalDiffusivity>
( (
static_cast<ThermalDiffusivity*>( static_cast<ThermalDiffusivity*>(
CompressibleTurbulenceModel<transportModel>::New BasicTurbulenceModel::New
( (
rho, rho,
U, U,

View File

@ -25,8 +25,8 @@ Class
Foam::ThermalDiffusivity Foam::ThermalDiffusivity
Description Description
Templated abstract base class for single-phase compressible Templated wrapper class to provide compressible turbulence models
turbulence models. thermal diffusivity based thermal transport.
SourceFiles SourceFiles
ThermalDiffusivity.C ThermalDiffusivity.C
@ -36,8 +36,6 @@ SourceFiles
#ifndef ThermalDiffusivity_H #ifndef ThermalDiffusivity_H
#define ThermalDiffusivity_H #define ThermalDiffusivity_H
#include "CompressibleTurbulenceModel.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam namespace Foam
@ -47,17 +45,17 @@ namespace Foam
Class ThermalDiffusivity Declaration Class ThermalDiffusivity Declaration
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
template<class TransportModel> template<class BasicTurbulenceModel>
class ThermalDiffusivity class ThermalDiffusivity
: :
public CompressibleTurbulenceModel<TransportModel> public BasicTurbulenceModel
{ {
public: public:
typedef geometricOneField alphaField; typedef geometricOneField alphaField;
typedef volScalarField rhoField; typedef volScalarField rhoField;
typedef TransportModel transportModel; typedef typename BasicTurbulenceModel::transportModel transportModel;
// Constructors // Constructors

View File

@ -41,7 +41,8 @@ License
dictionary \ dictionary \
); \ ); \
\ \
typedef BaseModel<Transport> Transport##BaseModel; \ typedef BaseModel<CompressibleTurbulenceModel<Transport> > \
Transport##BaseModel; \
\ \
\ \
typedef laminar<Transport##BaseModel> Laminar##Transport##BaseModel; \ typedef laminar<Transport##BaseModel> Laminar##Transport##BaseModel; \

View File

@ -55,7 +55,8 @@ namespace Foam
{ {
namespace compressible namespace compressible
{ {
typedef ThermalDiffusivity<fluidThermo> turbulenceModel; typedef ThermalDiffusivity<CompressibleTurbulenceModel<fluidThermo> >
turbulenceModel;
typedef SpecificCompressibleTurbulenceModel typedef SpecificCompressibleTurbulenceModel
< <

View File

@ -28,6 +28,7 @@ License
#include "addToRunTimeSelectionTable.H" #include "addToRunTimeSelectionTable.H"
#include "makeTurbulenceModel.H" #include "makeTurbulenceModel.H"
#include "CompressibleTurbulenceModel.H"
#include "ThermalDiffusivity.H" #include "ThermalDiffusivity.H"
#include "EddyDiffusivity.H" #include "EddyDiffusivity.H"