All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
variableHeatTransfer.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) 2011-2019 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::fv::variableHeatTransfer
26 
27 Description
28  Variable heat transfer model depending on local values. The area of contact
29  between regions (area) must be provided. The Nu number is calculated as:
30 
31  Nu = a*pow(Re, b)*pow(Pr, c)
32 
33  and the heat transfer coefficient as:
34 
35  htc = Nu*K/ds
36 
37  where:
38  K is the heat conduction
39  ds is the strut diameter
40 
41 \*---------------------------------------------------------------------------*/
42 
43 #ifndef variableHeatTransfer_H
44 #define variableHeatTransfer_H
45 
47 #include "autoPtr.H"
48 
49 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
50 
51 namespace Foam
52 {
53 namespace fv
54 {
55 
56 /*---------------------------------------------------------------------------*\
57  Class variableHeatTransfer Declaration
58 \*---------------------------------------------------------------------------*/
59 
61 :
63 {
64  // Private Data
65 
66  //- Name of neighbour velocity field; default = U
67  word UNbrName_;
68 
69  //- Model constants
70  scalar a_;
71  scalar b_;
72  scalar c_;
73 
74  //- Strut diameter
75  scalar ds_;
76 
77  //- Fluid Prandtl number
78  scalar Pr_;
79 
80  //- Area per unit volume of heat exchanger
82 
83 
84 public:
85 
86  //- Runtime type information
87  TypeName("variableHeatTransfer");
88 
89 
90  // Constructors
91 
92  //- Construct from dictionary
94  (
95  const word& name,
96  const word& modelType,
97  const dictionary& dict,
98  const fvMesh& mesh
99  );
100 
101 
102  //- Destructor
103  virtual ~variableHeatTransfer();
104 
105 
106  // Public Functions
107 
108  //- Calculate the heat transfer coefficient
109  virtual void calculateHtc();
110 
111 
112  // IO
113 
114  //- Read dictionary
115  virtual bool read(const dictionary& dict) ;
116 };
117 
118 
119 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 
121 } // End namespace fv
122 } // End namespace Foam
123 
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
125 
126 #endif
127 
128 // ************************************************************************* //
dictionary dict
Base class for inter region heat exchange. The derived classes must provide the heat transfer coeffic...
virtual ~variableHeatTransfer()
Destructor.
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:158
const fvMesh & mesh() const
Return const access to the mesh database.
Definition: fvOptionI.H:34
Variable heat transfer model depending on local values. The area of contact between regions (area) mu...
A class for handling words, derived from string.
Definition: word.H:59
labelList fv(nPoints)
virtual void calculateHtc()
Calculate the heat transfer coefficient.
const word & name() const
Return const access to the source name.
Definition: fvOptionI.H:28
variableHeatTransfer(const word &name, const word &modelType, const dictionary &dict, const fvMesh &mesh)
Construct from dictionary.
TypeName("variableHeatTransfer")
Runtime type information.
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:78
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
virtual bool read(const dictionary &dict)
Read dictionary.
Namespace for OpenFOAM.