qZeta.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  Foam::incompressible::RASModels::qZeta
26 
27 Description
28  Gibson and Dafa'Alla's q-zeta two-equation low-Re turbulence model
29  for incompressible flows
30 
31  This turbulence model is described in:
32  \verbatim
33  Dafa'Alla, A.A., Juntasaro, E. & Gibson, M.M. (1996).
34  Calculation of oscillating boundary layers with the
35  q-zeta turbulence model.
36  Engineering Turbulence Modelling and Experiments 3:
37  Proceedings of the Third International Symposium,
38  Crete, Greece, May 27-29, 141.
39  \endverbatim
40  which is a development of the original q-zeta model described in:
41  \verbatim
42  Gibson, M. M., & Dafa'Alla, A. A. (1995).
43  Two-equation model for turbulent wall flow.
44  AIAA journal, 33(8), 1514-1518.
45  \endverbatim
46 
47 SourceFiles
48  qZeta.C
49 
50 \*---------------------------------------------------------------------------*/
51 
52 #ifndef qZeta_H
53 #define qZeta_H
54 
56 #include "eddyViscosity.H"
57 
58 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
59 
60 namespace Foam
61 {
62 namespace incompressible
63 {
64 namespace RASModels
65 {
66 
67 /*---------------------------------------------------------------------------*\
68  Class qZeta Declaration
69 \*---------------------------------------------------------------------------*/
70 
71 class qZeta
72 :
73  public eddyViscosity<incompressible::RASModel>
74 {
75 
76 protected:
77 
78  // Protected data
79 
80  // Model coefficients
81 
87 
88  //- Lower limit of q
90 
91  //- Lower limit of zeta
93 
94  // Fields
95 
98 
101 
102 
103  // Protected Member Functions
104 
105  tmp<volScalarField> fMu() const;
106  tmp<volScalarField> f2() const;
107  virtual void correctNut();
108 
109 
110 public:
111 
112  //- Runtime type information
113  TypeName("qZeta");
114 
115  // Constructors
116 
117  //- Construct from components
118  qZeta
119  (
120  const geometricOneField& alpha,
121  const geometricOneField& rho,
122  const volVectorField& U,
123  const surfaceScalarField& alphaRhoPhi,
124  const surfaceScalarField& phi,
125  const transportModel& transport,
126  const word& type = typeName
127  );
128 
129 
130  //- Destructor
131  virtual ~qZeta()
132  {}
133 
134 
135  // Member Functions
136 
137  //- Read RASProperties dictionary
138  virtual bool read();
139 
140  //- Return the lower allowable limit for q (default: small)
141  const dimensionedScalar& qMin() const
142  {
143  return qMin_;
144  }
145 
146  //- Return the lower allowable limit for zeta (default: small)
147  const dimensionedScalar& zetaMin() const
148  {
149  return zetaMin_;
150  }
151 
152  //- Allow qMin to be changed
154  {
155  return qMin_;
156  }
157 
158  //- Allow zetaMin to be changed
160  {
161  return zetaMin_;
162  }
163 
164  //- Return the effective diffusivity for q
165  tmp<volScalarField> DqEff() const
166  {
167  return volScalarField::New
168  (
169  "DqEff",
170  nut_ + nu()
171  );
172  }
173 
174  //- Return the effective diffusivity for epsilon
176  {
177  return volScalarField::New
178  (
179  "DzetaEff",
180  nut_/sigmaZeta_ + nu()
181  );
182  }
183 
184  //- Return the turbulence kinetic energy
185  virtual tmp<volScalarField> k() const
186  {
187  return k_;
188  }
189 
190  //- Return the turbulence kinetic energy dissipation rate
191  virtual tmp<volScalarField> epsilon() const
192  {
193  return epsilon_;
194  }
196  virtual const volScalarField& q() const
197  {
198  return q_;
199  }
201  virtual const volScalarField& zeta() const
202  {
203  return zeta_;
204  }
205 
206  //- Solve the turbulence equations and correct the turbulence viscosity
207  virtual void correct();
208 };
209 
210 
211 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
212 
213 } // End namespace RASModels
214 } // End namespace incompressible
215 } // End namespace Foam
216 
217 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
218 
219 #endif
220 
221 // ************************************************************************* //
const dimensionedScalar & qMin() const
Return the lower allowable limit for q (default: small)
Definition: qZeta.H:140
volScalarField alpha(IOobject("alpha", runTime.timeName(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
static tmp< GeometricField< scalar, fvPatchField, volMesh > > New(const word &name, const Internal &, const PtrList< fvPatchField< scalar >> &)
Return a temporary field constructed from name,.
virtual void correct()
Solve the turbulence equations and correct the turbulence viscosity.
Definition: qZeta.C:237
A simple wrapper around bool so that it can be read as a word: true/false, on/off, yes/no, y/n, t/f, or none/any.
Definition: Switch.H:60
TypeName("qZeta")
Runtime type information.
virtual ~qZeta()
Destructor.
Definition: qZeta.H:130
Eddy viscosity turbulence model base class.
Definition: eddyViscosity.H:49
tmp< volScalarField > DqEff() const
Return the effective diffusivity for q.
Definition: qZeta.H:164
virtual tmp< volScalarField > epsilon() const
Return the turbulence kinetic energy dissipation rate.
Definition: qZeta.H:190
tmp< volScalarField > DzetaEff() const
Return the effective diffusivity for epsilon.
Definition: qZeta.H:174
virtual const volScalarField & q() const
Definition: qZeta.H:195
tmp< volScalarField > f2() const
Definition: qZeta.C:63
A class representing the concept of a GeometricField of 1 used to avoid unnecessary manipulations for...
incompressible::RASModel ::transportModel transportModel
Definition: eddyViscosity.H:72
A class for handling words, derived from string.
Definition: word.H:59
Gibson and Dafa&#39;Alla&#39;s q-zeta two-equation low-Re turbulence model for incompressible flows...
Definition: qZeta.H:70
phi
Definition: correctPhi.H:3
virtual tmp< volScalarField > k() const
Return the turbulence kinetic energy.
Definition: qZeta.H:184
virtual const volScalarField & zeta() const
Definition: qZeta.H:200
U
Definition: pEqn.H:72
tmp< volScalarField > fMu() const
Definition: qZeta.C:46
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
Definition: POSIX.C:488
qZeta(const geometricOneField &alpha, const geometricOneField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &type=typeName)
Construct from components.
Definition: qZeta.C:80
A class for managing temporary objects.
Definition: PtrList.H:53
const dimensionedScalar & zetaMin() const
Return the lower allowable limit for zeta (default: small)
Definition: qZeta.H:146
virtual bool read()
Read RASProperties dictionary.
Definition: qZeta.C:215
dimensionedScalar sigmaZeta_
Definition: qZeta.H:84
dimensionedScalar qMin_
Lower limit of q.
Definition: qZeta.H:88
dimensionedScalar zetaMin_
Lower limit of zeta.
Definition: qZeta.H:91
Namespace for OpenFOAM.