alphatWallBoilingWallFunctionFvPatchScalarField.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 | Copyright (C) 2015-2017 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
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.
15 
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.
20 
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/>.
23 
24 Class
25  Foam::compressible::alphatWallBoilingWallFunctionFvPatchScalarField
26 
27 Group
28  grpCmpWallFunctions
29 
30 Description
31  A thermal wall function for simulation of subcooled nucleate wall boiling
32  with runtime selctable submodels for:
33  - wall heat flux partitioning model
34  - nucleation site density
35  - bubble departure frequency
36  - bubble departure diameter
37 
38  Implements a version of the well-known RPI wall boiling model
39  (Kurul & Podowski, 1991). The model implementation is similar to the model
40  described by Peltola & Pättikangas (2012) but has been extended with the
41  wall heat flux partitioning models.
42 
43  References:
44  \verbatim
45  "On the modeling of multidimensional effects in boiling channels"
46  Kurul, N., Podowski, M.Z.,
47  ANS Proceedings, National Heat Transfer Conference,
48  Minneapolis, Minnesota, USA, July 28-31, 1991,
49  ISBN: 0-89448-162-1, pp. 30-40
50  \endverbatim
51 
52  \verbatim
53  "Development and validation of a boiling model for OpenFOAM
54  multiphase solver"
55  Peltola, J., Pättikangas, T.J.H.,
56  CFD4NRS-4 Conference Proceedings, paper 59,
57  Daejeon, Korea, September 10-12 2012
58  \endverbatim
59 
60 Usage
61  \table
62  Property | Description | Required | Default value
63  phaseType | 'vapor' or 'liquid' | yes |
64  relax |wall boiling model relaxation| yes |
65  Prt | inherited from alphatPhaseChangeJayatillekeWallFunction
66  Cmu | inherited from alphatPhaseChangeJayatillekeWallFunction
67  kappa | inherited from alphatPhaseChangeJayatillekeWallFunction
68  E | inherited from alphatPhaseChangeJayatillekeWallFunction
69  dmdt | phase change mass flux | yes |
70  value | initial alphat value | yes |
71 
72  if phaseType 'vapor':
73 
74  partitioningModel| | yes |
75 
76  if phaseType 'liquid':
77 
78  partitioningModel| | yes |
79  nucleationSiteModel| | yes |
80  departureDiamModel| | yes |
81  departureFreqModel| | yes |
82  \endtable
83 
84  NOTE: Runtime selectabale submodels may require model specific entries
85 
86  Example usage:
87  \verbatim
88  hotWall
89  {
90  type compressible::alphatWallBoiling2WallFunction;
91  phaseType liquid;
92  Prt 0.85;
93  Cmu 0.09;
94  kappa 0.41;
95  E 9.8;
96  relax 0.001;
97  dmdt uniform 0;
98  partitioningModel
99  {
100  type Lavieville;
101  alphaCrit 0.2;
102  }
103  nucleationSiteModel
104  {
105  type LemmertChawla;
106  }
107  departureDiamModel
108  {
109  type TolubinskiKostanchuk;
110  }
111  departureFreqModel
112  {
113  type Cole;
114  }
115  value uniform 0.01;
116  \endverbatim
117 
118 See also
119  Foam::alphatPhaseChangeJayatillekeWallFunctionFvPatchField
120 
121 SourceFiles
122  alphatWallBoilingWallFunctionFvPatchScalarField.C
123 
124 \*---------------------------------------------------------------------------*/
125 
126 #ifndef compressiblealphatWallBoilingWallFunctionFvPatchScalarField_H
127 #define compressiblealphatWallBoilingWallFunctionFvPatchScalarField_H
128 
130 #include "partitioningModel.H"
131 #include "nucleationSiteModel.H"
132 #include "departureDiameterModel.H"
133 #include "departureFrequencyModel.H"
134 
135 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
136 
137 namespace Foam
138 {
139 namespace compressible
140 {
141 
142 /*---------------------------------------------------------------------------*\
143  Class alphatWallBoilingWallFunctionFvPatchScalarField Declaration
144 \*---------------------------------------------------------------------------*/
145 
146 class alphatWallBoilingWallFunctionFvPatchScalarField
147 :
148  public alphatPhaseChangeJayatillekeWallFunctionFvPatchScalarField
149 {
150 public:
151 
152  // Data types
153 
154  //- Enumeration listing the possible operational modes
155  enum phaseType
156  {
157  vaporPhase,
159  };
160 
161 
162 private:
163 
164  // Private data
165 
166  //- Heat source type names
167  static const NamedEnum<phaseType, 2> phaseTypeNames_;
168 
169  //- Heat source type
170  phaseType phaseType_;
171 
172  //- dmdt relaxationFactor
173  scalar relax_;
174 
175  //- Patch face area by cell volume
176  scalarField AbyV_;
177 
178  //- Convective turbulent thermal diffusivity
179  scalarField alphatConv_;
180 
181  //- Departure diameter field
182  scalarField dDep_;
183 
184  //- Quenching surface heat flux
185  scalarField qq_;
186 
187  //- Run-time selected heat flux partitioning model
188  autoPtr<wallBoilingModels::partitioningModel>
189  partitioningModel_;
190 
191  //- Run-time selected nucleation site density model
192  autoPtr<wallBoilingModels::nucleationSiteModel>
193  nucleationSiteModel_;
194 
195  //- Run-time selected bubble departure diameter model
196  autoPtr<wallBoilingModels::departureDiameterModel>
197  departureDiamModel_;
198 
199  //- Run-time selected bubble departure frequency model
200  autoPtr<wallBoilingModels::departureFrequencyModel>
201  departureFreqModel_;
202 
203 
204 public:
205 
206  //- Runtime type information
207  TypeName("compressible::alphatWallBoilingWallFunction");
208 
209 
210  // Constructors
211 
212  //- Construct from patch and internal field
214  (
215  const fvPatch&,
217  );
218 
219  //- Construct from patch, internal field and dictionary
221  (
222  const fvPatch&,
224  const dictionary&
225  );
227  //- Construct by mapping given
228  // alphatWallBoilingWallFunctionFvPatchScalarField
229  // onto a new patch
231  (
233  const fvPatch&,
235  const fvPatchFieldMapper&
236  );
237 
238  //- Construct as copy
240  (
242  );
243 
244  //- Construct and return a clone
245  virtual tmp<fvPatchScalarField> clone() const
246  {
248  (
250  );
251  }
252 
253  //- Construct as copy setting internal field reference
255  (
258  );
259 
260  //- Construct and return a clone setting internal field reference
262  (
264  ) const
265  {
267  (
269  );
270  }
271 
272 
273  // Member functions
274 
275  //- Return the departure diameter field
276  const scalarField& dDeparture() const
277  {
278  return dDep_;
279  }
280 
281  //- Return the quenching surface heat flux [W/m2]
282  const scalarField& qq() const
283  {
284  return qq_;
285  }
286 
287  //- Return the evaporation surface heat flux [W/m2]
288  tmp<scalarField> qe() const
289  {
290  return mDotL_/AbyV_;
291  }
292 
293  // Evaluation functions
294 
295  //- Update the coefficients associated with the patch field
296  virtual void updateCoeffs();
297 
298 
299  // I-O
300 
301  //- Write
302  virtual void write(Ostream&) const;
303 };
304 
305 
306 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
307 
308 } // End namespace compressible
309 } // End namespace Foam
310 
311 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
312 
313 #endif
315 // ************************************************************************* //
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:137
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
Definition: fvPatch.H:61
A thermal wall function for simulation of subcooled nucleate wall boiling with runtime selctable subm...
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
Foam::fvPatchFieldMapper.
TypeName("compressible::alphatWallBoilingWallFunction")
Runtime type information.
virtual tmp< fvPatchScalarField > clone() const
Construct and return a clone.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Definition: Ostream.H:53
alphatWallBoilingWallFunctionFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
const scalarField & qq() const
Return the quenching surface heat flux [W/m2].
tmp< scalarField > qe() const
Return the evaporation surface heat flux [W/m2].
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: PtrList.H:53
Namespace for OpenFOAM.
bool compressible
Definition: pEqn.H:30