Loading...
Searching...
No Matches
nutkWallFunctionFvPatchScalarField.H
Go to the documentation of this file.
1/*---------------------------------------------------------------------------*\
2 ========= |
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4 \\ / O peration |
5 \\ / A nd | www.openfoam.com
6 \\/ M anipulation |
7-------------------------------------------------------------------------------
8 Copyright (C) 2011-2019 OpenFOAM Foundation
9 Copyright (C) 2019-2022 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27Class
28 Foam::nutkWallFunctionFvPatchScalarField
29
30Group
31 grpWallFunctions
32
33Description
34 This boundary condition provides a wall function for the turbulent
35 viscosity (i.e. \c nut) based on the turbulent kinetic energy,
36 (i.e. \c k) for for low- and high-Reynolds number applications.
37
38Usage
39 Example of the boundary condition specification:
40 \verbatim
41 <patchName>
42 {
43 // Mandatory entries
44 type nutkWallFunction;
45
46 // Inherited entries
47 ...
48 }
49 \endverbatim
50
51 where the entries mean:
52 \table
53 Property | Description | Type | Reqd | Deflt
54 type | Type name: nutkWallFunction | word | yes | -
55 \endtable
56
57 The inherited entries are elaborated in:
58 - \link nutWallFunctionFvPatchScalarField.H \endlink
59 - \link wallFunctionBlenders.H \endlink
60
61SourceFiles
62 nutkWallFunctionFvPatchScalarField.C
63
64\*---------------------------------------------------------------------------*/
65
66#ifndef nutkWallFunctionFvPatchScalarField_H
67#define nutkWallFunctionFvPatchScalarField_H
68
71
72// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
73
74namespace Foam
75{
76
77/*---------------------------------------------------------------------------*\
78 Class nutkWallFunctionFvPatchScalarField Declaration
79\*---------------------------------------------------------------------------*/
80
82:
85{
86protected:
87
88 // Protected Member Functions
89
90 //- Calculate the turbulent viscosity
91 virtual tmp<scalarField> calcNut() const;
92
93 //- Write local wall function variables
94 void writeLocalEntries(Ostream&) const;
95
96
97public:
98
99 //- Runtime type information
100 TypeName("nutkWallFunction");
101
102
103 // Constructors
104
105 //- Construct from patch and internal field
107 (
108 const fvPatch&,
110 );
111
112 //- Construct from patch, internal field and dictionary
114 (
115 const fvPatch&,
117 const dictionary&
118 );
119
120 //- Construct by mapping given
121 //- nutkWallFunctionFvPatchScalarField
122 //- onto a new patch
124 (
126 const fvPatch&,
128 const fvPatchFieldMapper&
129 );
130
131 //- Construct as copy
133 (
135 );
136
137 //- Construct as copy setting internal field reference
139 (
142 );
143
144 //- Return a clone
145 virtual tmp<fvPatchField<scalar>> clone() const
146 {
147 return fvPatchField<scalar>::Clone(*this);
148 }
149
150 //- Clone with an internal field reference
152 (
154 ) const
155 {
156 return fvPatchField<scalar>::Clone(*this, iF);
157 }
158
159
160 // Member Functions
161
162 //- Calculate and return the yPlus at the boundary
163 virtual tmp<scalarField> yPlus() const;
164
165
166 // I-O
167
168 //- Write
169 virtual void write(Ostream&) const;
171
172
173// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
174
175} // End namespace Foam
176
177// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
179#endif
180
181// ************************************************************************* //
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition Ostream.H:59
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition dictionary.H:133
A FieldMapper for finite-volume patch fields.
static tmp< fvPatchField< Type > > Clone(const DerivedPatchField &pf, Args &&... args)
Clone a patch field, optionally with internal field reference etc.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
Definition fvPatch.H:71
The class nutWallFunction is an abstract base class that hosts calculation methods and common functi...
nutWallFunctionFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
This boundary condition provides a wall function for the turbulent viscosity (i.e....
virtual tmp< scalarField > yPlus() const
Calculate and return the yPlus at the boundary.
virtual tmp< fvPatchField< scalar > > clone(const DimensionedField< scalar, volMesh > &iF) const
Clone with an internal field reference.
virtual tmp< fvPatchField< scalar > > clone() const
Return a clone.
void writeLocalEntries(Ostream &) const
Write local wall function variables.
nutkWallFunctionFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
TypeName("nutkWallFunction")
Runtime type information.
virtual tmp< scalarField > calcNut() const
Calculate the turbulent viscosity.
A class for managing temporary objects.
Definition tmp.H:75
The class wallFunctionBlenders is a base class that hosts common entries for various derived wall-fun...
wallFunctionBlenders()
Default construct with default coefficients.
Namespace for OpenFOAM.
runTime write()
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition typeInfo.H:68