Transferred copyright to the OpenFOAM Foundation
[OpenFOAM-2.0.x.git] / src / turbulenceModels / incompressible / RAS / derivedFvPatchFields / wallFunctions / kqRWallFunctions / kqRWallFunction / kqRWallFunctionFvPatchField.H
blob292fe79a890b60f404989383196ca8fa8dfe311e
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 2011 OpenFOAM Foundation
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
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.
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.
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/>.
24 Class
25     Foam::incompressible::RASModels::kqRWallFunctionFvPatchField
27 Description
28     Boundary condition for turbulence k, Q, and R when using wall functions.
29     Simply acts as a zero gradient condition.
31 SourceFiles
32     kqRWallFunctionFvPatchField.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef kqRWallFunctionFvPatchField_H
37 #define kqRWallFunctionFvPatchField_H
39 #include "zeroGradientFvPatchField.H"
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 namespace Foam
45 namespace incompressible
47 namespace RASModels
50 /*---------------------------------------------------------------------------*\
51                 Class kqRWallFunctionFvPatchField Declaration
52 \*---------------------------------------------------------------------------*/
54 template<class Type>
55 class kqRWallFunctionFvPatchField
57     public zeroGradientFvPatchField<Type>
60     // Private Member Functions
62         //- Check the type of the patch
63         void checkType();
66 public:
68     //- Runtime type information
69     TypeName("kqRWallFunction");
72     // Constructors
74         //- Construct from patch and internal field
75         kqRWallFunctionFvPatchField
76         (
77             const fvPatch&,
78             const DimensionedField<Type, volMesh>&
79         );
81         //- Construct from patch, internal field and dictionary
82         kqRWallFunctionFvPatchField
83         (
84             const fvPatch&,
85             const DimensionedField<Type, volMesh>&,
86             const dictionary&
87         );
89         //- Construct by mapping given
90         // kqRWallFunctionFvPatchField
91         //  onto a new patch
92         kqRWallFunctionFvPatchField
93         (
94             const kqRWallFunctionFvPatchField&,
95             const fvPatch&,
96             const DimensionedField<Type, volMesh>&,
97             const fvPatchFieldMapper&
98         );
100         //- Construct as copy
101         kqRWallFunctionFvPatchField
102         (
103             const kqRWallFunctionFvPatchField&
104         );
106         //- Construct and return a clone
107         virtual tmp<fvPatchField<Type> > clone() const
108         {
109             return tmp<fvPatchField<Type> >
110             (
111                 new kqRWallFunctionFvPatchField(*this)
112             );
113         }
115         //- Construct as copy setting internal field reference
116         kqRWallFunctionFvPatchField
117         (
118             const kqRWallFunctionFvPatchField&,
119             const DimensionedField<Type, volMesh>&
120         );
122         //- Construct and return a clone setting internal field reference
123         virtual tmp<fvPatchField<Type> > clone
124         (
125             const DimensionedField<Type, volMesh>& iF
126         ) const
127         {
128             return tmp<fvPatchField<Type> >
129             (
130                 new kqRWallFunctionFvPatchField(*this, iF)
131             );
132         }
135     // Member functions
137         // Evaluation functions
139             //- Evaluate the patchField
140             virtual void evaluate
141             (
142                 const Pstream::commsTypes commsType=Pstream::Pstream::blocking
143             );
146         // I-O
148             //- Write
149             virtual void write(Ostream&) const;
153 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
155 } // End namespace RASModels
156 } // End namespace incompressible
157 } // End namespace Foam
159 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
161 #ifdef NoRepository
162 #   include "kqRWallFunctionFvPatchField.C"
163 #endif
165 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
167 #endif
169 // ************************************************************************* //