velocityFilmShellFvPatchVectorField.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) 2020 OpenCFD Ltd.
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::compressible::velocityFilmShellFvPatchVectorField
28 
29 Group
30  grpLiquidFilmBoundaryConditions
31 
32 Description
33 
34 Usage
35  Example of the boundary condition specification:
36  \verbatim
37  <patchName>
38  {
39  type velocityFilmShell;
40 
41  active true;
42  infoOutput true;
43 
44  U U;
45  pRef 1e5;
46  T0 300;
47 
48  deltaWet 1e-4;
49  h0 1e-8;
50 
51  zeroWallVelocity true;
52 
53  thermo
54  {
55  H2O;
56  }
57 
58  turbulence laminar;
59 
60  laminarCoeffs
61  {
62  friction ManningStrickler; // Wall friction model
63  n 0.005; // Manning number
64  Cf 0.9; // Gas friction
65  }
66 
67  injectionModels
68  (
69  curvatureSeparation
70  );
71 
72  forces ();
73 
74  curvatureSeparationCoeffs
75  {
76  definedPatchRadii 0;
77  }
78 
79  region film;
80  liquidFilmModel kinematicThinFilm;
81 
82  value uniform (0 0 0);
83  }
84  \endverbatim
85 
86  where the entries mean:
87  \table
88  Property | Description | Type | Reqd | Deflt
89  type | Type name: velocityFilmShell | word | yes | -
90  U | Name of the primary U | word | yes | -
91  pRef | Reference pressure for thermo | scalar | yes | -
92  T0 | Film initial temperature | scalar | no | READ
93  thermo | Flow thermo | wordRes | yes | -
94  zeroWallVelocity | Flag to fix zero U for primary flow <!--
95  --> | bool | no | true
96  turbulence | Type of film turbulence model | word | yes | -
97  injectionModels | Lagrangian injection | | no | -
98  forces | Film force models | wordRes | no | -
99  deltaWet | Wet film thickness | scalar | no | 1e-4
100  h0 | Numerical minimum thickness | scalar | no | 1e-7
101  region | Name of the 2D region | word | yes | -
102  liquidFilmModel | Film model | word | yes | -
103  \endtable
104 
105 SourceFiles
106  velocityFilmShellFvPatchVectorField.C
107 
108 \*---------------------------------------------------------------------------*/
109 
110 #ifndef velocityFilmShellFvPatchVectorField_H
111 #define velocityFilmShellFvPatchVectorField_H
112 
113 #include "autoPtr.H"
114 #include "liquidFilmBase.H"
115 #include "mixedFvPatchFields.H"
116 
117 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
118 
119 namespace Foam
120 {
121 
122 /*---------------------------------------------------------------------------*\
123  Class velocityFilmShellFvPatchVectorField Declaration
124 \*---------------------------------------------------------------------------*/
125 
127 :
128  public mixedFvPatchField<vector>
129 {
130  // Typedefs
131 
132  //- The finite-area region model
134 
135 
136  // Private Data
137 
138  //- The liquid film
139  autoPtr<baffleType> baffle_;
140 
141  //- Dictionary
142  mutable dictionary dict_;
143 
144  //- Time index to evolve the film
145  label curTimeIndex_;
146 
147  //- Zero wall velocity. Fix U to zero or to film U
148  bool zeroWallVelocity_;
149 
150 
151 public:
152 
153  //- Runtime type information
154  TypeName("velocityFilmShell");
155 
156 
157  // Constructors
158 
159  //- Construct from patch and internal field
161  (
162  const fvPatch&,
164  );
165 
166  //- Construct from patch, internal field and dictionary
168  (
169  const fvPatch&,
171  const dictionary&
172  );
173 
174  //- Construct by mapping given
175  //- velocityFilmShellFvPatchVectorField onto a new patch
177  (
179  const fvPatch&,
181  const fvPatchFieldMapper&
182  );
183 
184  //- Construct and return a clone
185  virtual tmp<fvPatchVectorField> clone() const
186  {
188  (
190  );
191  }
192 
193  //- Construct as copy setting internal field reference
195  (
198  );
199 
200  //- Construct and return a clone setting internal field reference
202  (
204  ) const
205  {
207  (
209  );
210  }
211 
212 
213  // Member Functions
214 
215  //- Update the coefficients associated with the patch field
216  virtual void updateCoeffs();
217 
218  //- Write
219  virtual void write(Ostream&) const;
220 };
221 
222 
223 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
224 
225 } // End namespace Foam
226 
227 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
228 
229 
230 #endif
231 
232 // ************************************************************************* //
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
This boundary condition provides a base class for &#39;mixed&#39; type boundary conditions, i.e. conditions that mix fixed value and patch-normal gradient conditions.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
velocityFilmShellFvPatchVectorField(const fvPatch &, const DimensionedField< vector, volMesh > &)
Construct from patch and internal field.
TypeName("velocityFilmShell")
Runtime type information.
A FieldMapper for finite-volume patch fields.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Definition: Ostream.H:56
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
Definition: areaFieldsFwd.H:42
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
Definition: HashPtrTable.H:48
A class for managing temporary objects.
Definition: HashPtrTable.H:50
virtual tmp< fvPatchVectorField > clone() const
Construct and return a clone.
Namespace for OpenFOAM.