linear.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2016-2023 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::wallBoilingModels::partitioningModels::linear
26 
27 Description
28  Linear wall heat flux partitioning model.
29 
30  Proposed threshold liquid fractions:
31  - alphaLiquid1 0.1
32  - alphaLiquid0 0.05
33 
34  \verbatim
35  Ioilev, A., Samigulin, M., Ustinenko (2007).
36  Advances in the modeling of cladding heat transfer
37  and critical heat flux in boiling water reactor fuel assemblies.
38  In Proc. 12th International Topical Meeting on
39  Nuclear Reactor Thermal Hydraulics (NURETH-12),
40  Pittsburgh, Pennsylvania, USA.
41  \endverbatim
42 
43 SourceFiles
44  linear.C
45 
46 \*---------------------------------------------------------------------------*/
47 
48 #ifndef linear_H
49 #define linear_H
50 
51 #include "partitioningModel.H"
52 
53 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
54 
55 namespace Foam
56 {
57 namespace wallBoilingModels
58 {
59 namespace partitioningModels
60 {
61 
62 /*---------------------------------------------------------------------------*\
63  Class linear Declaration
64 \*---------------------------------------------------------------------------*/
65 
66 class linear
67 :
68  public partitioningModel
69 {
70  // Private Data
71 
72  //- Lower threshold liquid phase fraction
73  const scalar alphaLiquid0_;
74 
75  //- Upper threshold liquid phase fraction
76  const scalar alphaLiquid1_;
77 
78 
79  // Private Member Functions
80 
81  //- Calculate and return the wet fraction
82  template<class ScalarFieldType>
83  tmp<ScalarFieldType> calculate
84  (
85  const ScalarFieldType& alphaLiquid
86  ) const;
87 
88 
89 public:
90 
91  //- Runtime type information
92  TypeName("linear");
93 
94 
95  // Constructors
96 
97  //- Construct from a dictionary
98  linear(const dictionary& dict);
99 
100  //- Copy construct
101  linear(const linear& model);
102 
103  //- Construct and return a clone
104  virtual autoPtr<partitioningModel> clone() const
105  {
106  return autoPtr<partitioningModel>(new linear(*this));
107  }
108 
109 
110  //- Destructor
111  virtual ~linear();
112 
113 
114  // Member Functions
115 
116  //- Return the wet fraction
118  (
119  const scalarField& alphaLiquid
120  ) const;
121 
122  //- Return the wet fraction
124  (
125  const volScalarField& alphaLiquid
126  ) const;
127 
128  //- Write to stream
129  virtual void write(Ostream& os) const;
130 };
131 
132 
133 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
134 
135 } // End namespace partitioningModels
136 } // End namespace wallBoilingModels
137 } // End namespace Foam
138 
139 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
140 
141 #endif
142 
143 // ************************************************************************* //
Generic GeometricField class.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition: Ostream.H:57
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: autoPtr.H:51
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:160
A class for managing temporary objects.
Definition: tmp.H:55
Base class for wall heat flux partitioning models.
Linear wall heat flux partitioning model.
Definition: linear.H:68
virtual autoPtr< partitioningModel > clone() const
Construct and return a clone.
Definition: linear.H:103
virtual tmp< scalarField > wetFraction(const scalarField &alphaLiquid) const
Return the wet fraction.
Definition: linear.C:105
virtual void write(Ostream &os) const
Write to stream.
Definition: linear.C:124
TypeName("linear")
Runtime type information.
linear(const dictionary &dict)
Construct from a dictionary.
Definition: linear.C:74
Namespace for OpenFOAM.
dictionary dict