Loading...
Searching...
No Matches
fixedShearStressFvPatchVectorField.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-2015 OpenFOAM Foundation
9 Copyright (C) 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::fixedShearStressFvPatchVectorField
29
30Group
31 grpTurbulenceBoundaryConditions
32
33Description
34 This boundary condition sets a user-defined shear stress
35 constant and uniform across a given patch by using the expression:
36
37 \f[
38 tau_0 = -\nu_{eff} \frac{dU}{dn}
39 \f]
40
41Usage
42 Example of the boundary condition specification:
43 \verbatim
44 <patchName>
45 {
46 // Mandatory entries
47 type fixedShearStress;
48 tau <vector>;
49
50 // Inherited entries
51 ...
52 }
53 \endverbatim
54
55 where the entries mean:
56 \table
57 Property | Description | Type | Reqd | Deflt
58 type | Type name: fixedShearStress | word | yes | -
59 tau | Shear stress | vector | yes | -
60 \endtable
61
62 The inherited entries are elaborated in:
63 - \link fixedValueFvPatchFields.H \endlink
64
65SourceFiles
66 fixedShearStressFvPatchVectorField.C
67
68\*---------------------------------------------------------------------------*/
69
70#ifndef fixedShearStressFvPatchVectorField_H
71#define fixedShearStressFvPatchVectorField_H
72
73#include "fvPatchFields.H"
75
76// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
77
78namespace Foam
79{
80
81/*---------------------------------------------------------------------------*\
82 Class fixedShearStressFvPatchVectorField Declaration
83\*---------------------------------------------------------------------------*/
84
86:
87 public fixedValueFvPatchVectorField
88{
89 // Private Data
90
91 //- Constant shear stress
92 const vector tau0_;
93
94
95public:
96
97 //- Runtime type information
98 TypeName("fixedShearStress");
99
100
101 // Constructors
102
103 //- Construct from patch and internal field
105 (
106 const fvPatch&,
108 );
109
110 //- Construct from patch, internal field and dictionary
112 (
113 const fvPatch&,
116 );
117
118 //- Construct by mapping given
120 (
122 const fvPatch&,
124 const fvPatchFieldMapper&
125 );
126
127 //- Construct as copy
129 (
131 );
132
133 //- Construct as copy setting internal field reference
135 (
138 );
139
140 //- Return a clone
141 virtual tmp<fvPatchField<vector>> clone() const
142 {
143 return fvPatchField<vector>::Clone(*this);
144 }
145
146 //- Clone with an internal field reference
148 (
150 ) const
151 {
152 return fvPatchField<vector>::Clone(*this, iF);
153 }
154
155
156 // Member Functions
157
158 // Evaluation
159
160 //- Update the coefficients associated with the patch field
161 virtual void updateCoeffs();
162
163
164 // I-O
165
166 //- Write
167 virtual void write(Ostream&) const;
168};
169
171// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
172
173} // End namespace Foam
174
175// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
176
177#endif
179// ************************************************************************* //
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
This boundary condition sets a user-defined shear stress constant and uniform across a given patch by...
virtual tmp< fvPatchField< vector > > clone() const
Return a clone.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
virtual tmp< fvPatchField< vector > > clone(const DimensionedField< vector, volMesh > &iF) const
Clone with an internal field reference.
fixedShearStressFvPatchVectorField(const fvPatch &, const DimensionedField< vector, volMesh > &)
Construct from patch and internal field.
TypeName("fixedShearStress")
Runtime type information.
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
A class for managing temporary objects.
Definition tmp.H:75
Namespace for OpenFOAM.
Vector< scalar > vector
Definition vector.H:57
runTime write()
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition typeInfo.H:68