exponentialSolidTransport.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::exponentialSolidTransport
26 
27 Description
28  Exponential properties for solid heat transport
29  Templated into a given thermodynamics package.
30 
31 SourceFiles
32  exponentialSolidTransportI.H
33  exponentialSolidTransport.C
34 
35 \*---------------------------------------------------------------------------*/
36 
37 #ifndef exponentialSolidTransport_H
38 #define exponentialSolidTransport_H
39 
40 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
41 
42 namespace Foam
43 {
44 
45 template<class Thermo> class exponentialSolidTransport;
46 
47 template<class Thermo>
48 inline exponentialSolidTransport<Thermo> operator*
49 (
50  const scalar,
52 );
53 
54 template<class Thermo>
55 Ostream& operator<<
56 (
57  Ostream&,
59 );
60 
61 
62 /*---------------------------------------------------------------------------*\
63  Class exponentialSolidTransport Declaration
64 \*---------------------------------------------------------------------------*/
65 
66 template<class Thermo>
68 :
69  public Thermo
70 {
71  // Private Data
72 
73  //- Constant thermal coefficient.
74  scalar kappa0_;
75 
76  //- Exponent coefficient
77  scalar n0_;
78 
79  //- Reference temperature
80  scalar Tref_;
81 
82 
83  // Private Member Functions
84 
85  //- Construct from components
87  (
88  const Thermo& t,
89  const scalar kappa0,
90  const scalar n0,
91  const scalar Tref
92  );
93 
94 
95 public:
96 
97  // Constructors
98 
99  //- Construct as named copy
101  (
102  const word&,
104  );
105 
106  //- Construct from dictionary
108 
109  //- Construct and return a clone
111 
112  // Selector from dictionary
114  (
115  const dictionary& dict
116  );
117 
118 
119  // Member Functions
120 
121  //- Return the instantiated type name
122  static word typeName()
123  {
124  return "exponential<" + Thermo::typeName() + '>';
125  }
126 
127  //- Is the thermal conductivity isotropic
128  static const bool isotropic = true;
129 
130  //- Thermal conductivity [W/m/K]
131  inline scalar kappa(const scalar p, const scalar T) const;
132 
133  //- Thermal conductivity [W/m/K]
134  inline vector Kappa(const scalar p, const scalar T) const;
135 
136  //- Dynamic viscosity [kg/m/s]
137  inline scalar mu(const scalar p, const scalar T) const;
138 
139  //- Thermal diffusivity of enthalpy [kg/m/s]
140  inline scalar alphah(const scalar p, const scalar T) const;
141 
142  //- Write to Ostream
143  void write(Ostream& os) const;
144 
145 
146  // Member Operators
147 
148  inline void operator+=(const exponentialSolidTransport&);
149 
150 
151  // Friend operators
152 
153  friend exponentialSolidTransport operator* <Thermo>
154  (
155  const scalar,
157  );
158 
159  // Ostream Operator
160 
161  friend Ostream& operator<< <Thermo>
162  (
163  Ostream&,
165  );
166 };
167 
168 
169 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
170 
171 } // End namespace Foam
172 
173 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
174 
176 
177 #ifdef NoRepository
178  #include "exponentialSolidTransport.C"
179 #endif
180 
181 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
182 
183 #endif
184 
185 // ************************************************************************* //
dictionary dict
Exponential properties for solid heat transport Templated into a given thermodynamics package...
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:158
scalar kappa(const scalar p, const scalar T) const
Thermal conductivity [W/m/K].
scalar alphah(const scalar p, const scalar T) const
Thermal diffusivity of enthalpy [kg/m/s].
void write(Ostream &os) const
Write to Ostream.
autoPtr< exponentialSolidTransport > clone() const
Construct and return a clone.
static autoPtr< exponentialSolidTransport > New(const dictionary &dict)
static const bool isotropic
Is the thermal conductivity isotropic.
A class for handling words, derived from string.
Definition: word.H:59
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Definition: Ostream.H:54
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
static word typeName()
Return the instantiated type name.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
volScalarField & p
scalar mu(const scalar p, const scalar T) const
Dynamic viscosity [kg/m/s].
void operator+=(const exponentialSolidTransport &)
Namespace for OpenFOAM.
vector Kappa(const scalar p, const scalar T) const
Thermal conductivity [W/m/K].