fixedInternalValueFvPatchField.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-2016 OpenFOAM Foundation
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 Class
27  Foam::fixedInternalValueFvPatchField
28 
29 Group
30  grpGenericBoundaryConditions
31 
32 Description
33  This boundary condition provides a mechanism to set boundary (cell) values
34  directly into a matrix, i.e. to set a constraint condition. Default
35  behaviour is to act as a zero gradient condition.
36 
37 Usage
38  Example of the boundary condition specification:
39  \verbatim
40  <patchName>
41  {
42  type fixedInternalValue;
43  value uniform 0; // place holder
44  }
45  \endverbatim
46 
47 Note
48  This is used as a base for conditions such as the turbulence \c epsilon
49  wall function, which applies a near-wall constraint for high Reynolds
50  number flows.
51 
52 See also
53  Foam::epsilonWallFunctionFvPatchScalarField
54 
55 SourceFiles
56  fixedInternalValueFvPatchField.C
57 
58 \*---------------------------------------------------------------------------*/
59 
60 #ifndef fixedInternalValueFvPatchField_H
61 #define fixedInternalValueFvPatchField_H
62 
64 
65 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
66 
67 namespace Foam
68 {
69 
70 /*---------------------------------------------------------------------------*\
71  Class fixedInternalValueFvPatchField Declaration
72 \*---------------------------------------------------------------------------*/
73 
74 template<class Type>
76 :
77  public zeroGradientFvPatchField<Type>
78 {
79 
80 public:
81 
82  //- Runtime type information
83  TypeName("fixedInternalValue");
84 
85 
86  // Constructors
87 
88  //- Construct from patch and internal field
90  (
91  const fvPatch&,
93  );
94 
95  //- Construct from patch, internal field and dictionary
97  (
98  const fvPatch&,
100  const dictionary&
101  );
102 
103  //- Construct by mapping the given fixedInternalValue patch field
104  //- onto a new patch
106  (
108  const fvPatch&,
110  const fvPatchFieldMapper&
111  );
112 
113  //- Construct as copy
115  (
117  );
118 
119  //- Construct as copy setting internal field reference
121  (
124  );
125 
126  //- Return a clone
127  virtual tmp<fvPatchField<Type>> clone() const
128  {
129  return fvPatchField<Type>::Clone(*this);
130  }
131 
132  //- Clone with an internal field reference
134  (
136  ) const
137  {
138  return fvPatchField<Type>::Clone(*this, iF);
139  }
140 
141 
142  // Member functions
143 
144  // Evaluation functions
146  //-Manipulate a matrix
147  virtual void manipulateMatrix(fvMatrix<Type>& matrix);
148 };
149 
150 
151 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
152 
153 } // End namespace Foam
154 
155 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
156 
157 #ifdef NoRepository
159 #endif
160 
161 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
162 
163 #endif
164 
165 // ************************************************************************* //
This boundary condition provides a mechanism to set boundary (cell) values directly into a matrix...
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Definition: dictionary.H:129
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
Definition: fvPatch.H:70
static tmp< fvPatchField< Type > > Clone(const DerivedPatchField &pf, Args &&... args)
Clone a patch field, optionally with internal field reference etc.
Definition: fvPatchField.H:597
A FieldMapper for finite-volume patch fields.
A special matrix type and solver, designed for finite volume solutions of scalar equations. Face addressing is used to make all matrix assembly and solution loops vectorise.
Definition: fvPatchField.H:64
This boundary condition applies a zero-gradient condition from the patch internal field onto the patc...
virtual void manipulateMatrix(fvMatrix< Type > &matrix)
Manipulate a matrix.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
A class for managing temporary objects.
Definition: HashPtrTable.H:50
fixedInternalValueFvPatchField(const fvPatch &, const DimensionedField< Type, volMesh > &)
Construct from patch and internal field.
virtual tmp< fvPatchField< Type > > clone() const
Return a clone.
Namespace for OpenFOAM.
TypeName("fixedInternalValue")
Runtime type information.