kOmegaSSTFieldInversion.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2 
3  DAFoam : Discrete Adjoint with OpenFOAM
4  Version : v3
5 
6  Description:
7  kOmegaSST turbulence model with a multiplicative betaFieldInversion
8  field.
9 
10 \*---------------------------------------------------------------------------*/
11 
12 #ifndef kOmegaSSTFieldInversion_H
13 #define kOmegaSSTFieldInversion_H
14 
15 #include "RASModel.H"
16 #include "eddyViscosity.H"
17 
18 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
19 
20 namespace Foam
21 {
22 namespace RASModels
23 {
24 
25 /*---------------------------------------------------------------------------*\
26  Class kOmegaSSTFieldInversion Declaration
27 \*---------------------------------------------------------------------------*/
28 
29 template<class BasicTurbulenceModel>
31  : public eddyViscosity<RASModel<BasicTurbulenceModel>>
32 {
33  // Private Member Functions
34 
35  // Disallow default bitwise copy construct and assignment
37  void operator=(const kOmegaSSTFieldInversion&);
38 
39 protected:
40  // Protected data
41 
42  // Fields
43 
45  volScalarField omega_;
46 
47  volScalarField k_;
48 
50  volScalarField betaFieldInversion_;
51 
53  volScalarField surfaceFriction_;
54 
56  volScalarField surfaceFrictionData_;
57 
59  volScalarField pData_;
60 
62  volVectorField UData_;
63 
65  volScalarField USingleComponentData_;
66 
67  //- Wall distance
68  // Note: different to wall distance in parent RASModel
69  // which is for near-wall cells only
70  const volScalarField& y_;
71 
72  virtual void correctNut();
73 
74 public:
75  typedef typename BasicTurbulenceModel::alphaField alphaField;
76  typedef typename BasicTurbulenceModel::rhoField rhoField;
77  typedef typename BasicTurbulenceModel::transportModel transportModel;
78 
79  //- Runtime type information
80  TypeName("kOmegaSSTFieldInversion");
81 
82  // Constructors
83 
84  //- Construct from components
86  const alphaField& alpha,
87  const rhoField& rho,
88  const volVectorField& U,
89  const surfaceScalarField& alphaRhoPhi,
90  const surfaceScalarField& phi,
91  const transportModel& transport,
92  const word& propertiesName = turbulenceModel::propertiesName,
93  const word& type = typeName);
94 
95  //- Destructor
97  {
98  }
99 
100  // Member Functions
101 
102  //- Re-read model coefficients if they have changed
103  virtual bool read();
104 
105  //- Return the turbulence kinetic energy
106  virtual tmp<volScalarField> k() const;
107 
108  //- Return the turbulence kinetic energy dissipation rate
109  virtual tmp<volScalarField> epsilon() const;
110 
111  //- Solve the turbulence equations and correct the turbulence viscosity
112  virtual void correct();
113 };
114 
115 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
116 
117 } // End namespace RASModels
118 } // End namespace Foam
119 
120 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
121 
122 #ifdef NoRepository
123 #include "kOmegaSSTFieldInversion.C"
124 #endif
125 
126 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
127 
128 #endif
129 
130 // ************************************************************************* //
Foam::RASModels::kOmegaSSTFieldInversion::transportModel
BasicTurbulenceModel::transportModel transportModel
Definition: kOmegaSSTFieldInversion.H:77
U
U
Definition: pEqnPimpleDyM.H:60
Foam::RASModels::kOmegaSSTFieldInversion::USingleComponentData_
volScalarField USingleComponentData_
the reference pressure field data
Definition: kOmegaSSTFieldInversion.H:65
Foam::RASModels::kOmegaSSTFieldInversion::read
virtual bool read()
Definition: kOmegaSSTFieldInversion.C:130
kOmegaSSTFieldInversion.C
Foam::RASModels::kOmegaSSTFieldInversion::betaFieldInversion_
volScalarField betaFieldInversion_
A beta field multiplying to the production term.
Definition: kOmegaSSTFieldInversion.H:50
Foam::RASModels::kOmegaSSTFieldInversion::correctNut
virtual void correctNut()
Definition: kOmegaSSTFieldInversion.C:23
Foam::RASModels::kOmegaSSTFieldInversion::UData_
volVectorField UData_
reference field (e.g. velocity for DNS)
Definition: kOmegaSSTFieldInversion.H:62
Foam::RASModels::kOmegaSSTFieldInversion::k_
volScalarField k_
Definition: kOmegaSSTFieldInversion.H:47
Foam::RASModels::kOmegaSSTFieldInversion::y_
const volScalarField & y_
Definition: kOmegaSSTFieldInversion.H:70
phi
surfaceScalarField & phi
Definition: createRefsPimple.H:8
Foam::RASModels::kOmegaSSTFieldInversion::TypeName
TypeName("kOmegaSSTFieldInversion")
Foam::RASModels::kOmegaSSTFieldInversion::omega_
volScalarField omega_
turbulence variables for k-omega SST
Definition: kOmegaSSTFieldInversion.H:45
Foam::RASModels::kOmegaSSTFieldInversion::pData_
volScalarField pData_
the reference field for surfacePressure
Definition: kOmegaSSTFieldInversion.H:59
Foam
Definition: multiFreqScalarFvPatchField.C:144
Foam::RASModels::kOmegaSSTFieldInversion::k
virtual tmp< volScalarField > k() const
Definition: kOmegaSSTFieldInversion.C:137
Foam::RASModels::kOmegaSSTFieldInversion::correct
virtual void correct()
Definition: kOmegaSSTFieldInversion.C:149
Foam::RASModels::kOmegaSSTFieldInversion::surfaceFrictionData_
volScalarField surfaceFrictionData_
the reference field for surfaceFriction
Definition: kOmegaSSTFieldInversion.H:56
Foam::RASModels::kOmegaSSTFieldInversion::~kOmegaSSTFieldInversion
virtual ~kOmegaSSTFieldInversion()
Definition: kOmegaSSTFieldInversion.H:96
Foam::RASModels::kOmegaSSTFieldInversion::alphaField
BasicTurbulenceModel::alphaField alphaField
Definition: kOmegaSSTFieldInversion.H:75
Foam::RASModels::kOmegaSSTFieldInversion
Definition: kOmegaSSTFieldInversion.H:30
Foam::RASModels::kOmegaSSTFieldInversion::surfaceFriction_
volScalarField surfaceFriction_
a surface friction 'field' when using skin friction data for field inversion
Definition: kOmegaSSTFieldInversion.H:53
Foam::RASModels::kOmegaSSTFieldInversion::epsilon
virtual tmp< volScalarField > epsilon() const
Definition: kOmegaSSTFieldInversion.C:143
rho
volScalarField & rho
Definition: createRefsRhoSimpleC.H:8
Foam::RASModels::kOmegaSSTFieldInversion::rhoField
BasicTurbulenceModel::rhoField rhoField
Definition: kOmegaSSTFieldInversion.H:76