tabulatedAnIsoSolidTransport.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) 2022 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::tabulatedAnIsoSolidTransport
28 
29 Description
30  Transport properties package using \c Function1 type data
31  for anisotropic thermal conductivity.
32 
33 Usage
34  Example of the specification of the transport properties:
35  \verbatim
36  transport
37  {
38  // kappa <Function1<vector>>;
39 
40  kappa table
41  (
42  // T kappa
43  ( 200 (2.56e-5 2e-5 2e-5) )
44  ( 350 (3.33e-5 1e-5 1e-5) )
45  ( 400 (4.72e-5 3e-5 3-e5) )
46  );
47  }
48  \endverbatim
49 
50  where the entries mean:
51  \table
52  Property | Description | Type | Reqd | Deflt
53  kappa | Thermal conductivity | Function1<vector> | yes | -
54  \endtable
55 
56 SourceFiles
57  tabulatedAnIsoSolidTransportI.H
58  tabulatedAnIsoSolidTransport.C
59 
60 \*---------------------------------------------------------------------------*/
61 
62 #ifndef Foam_tabulatedAnIsoSolidTransport_H
63 #define Foam_tabulatedAnIsoSolidTransport_H
64 
65 #include "Function1.H"
66 
67 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
68 
69 namespace Foam
70 {
71 
72 // Forward Declarations
73 template<class Thermo> class tabulatedAnIsoSolidTransport;
74 
75 template<class Thermo>
76 Ostream& operator<<(Ostream&, const tabulatedAnIsoSolidTransport<Thermo>&);
77 
78 
79 /*---------------------------------------------------------------------------*\
80  Class tabulatedAnIsoSolidTransport Declaration
81 \*---------------------------------------------------------------------------*/
82 
83 template<class Thermo>
85 :
86  public Thermo
87 {
88  // Private Data
89 
90  //- Thermal conductivity data [W/m/K]
92 
93 
94  // Constructors
95 
96  //- Construct from components
98  (
99  const Thermo& t,
101  );
102 
103 
104 public:
105 
106  // Constructors
107 
108  //- Construct as named copy
110  (
111  const word&,
113  );
114 
115  //- Construct from dictionary
117 
118  //- Return a clone
120 
121  // Selector from dictionary
123  (
124  const dictionary& dict
125  );
126 
127 
128  // Member Functions
129 
130  //- The instantiated type name
131  static word typeName()
132  {
133  return "tabulatedAnIso<" + Thermo::typeName() + '>';
134  }
135 
136  //- Is the thermal conductivity isotropic
137  static const bool isotropic = false;
138 
139  //- Dynamic viscosity [kg/m/s]
140  inline scalar mu(const scalar p, const scalar T) const;
141 
142  //- Thermal conductivity [W/m/K]
143  inline scalar kappa(const scalar p, const scalar T) const;
144 
145  //- Thermal conductivity [W/m/K]
146  inline vector Kappa(const scalar p, const scalar T) const;
147 
148  //- Thermal diffusivity of enthalpy [kg/m/s]
149  inline scalar alphah(const scalar p, const scalar T) const;
151  //- Write to Ostream
152  void write(Ostream& os) const;
153 
154 
155  // Ostream Operator
156 
157  friend Ostream& operator<< <Thermo>
158  (
159  Ostream&,
161  );
162 };
163 
164 
165 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
166 
167 } // End namespace Foam
168 
169 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
170 
172 
173 #ifdef NoRepository
175 #endif
176 
177 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
178 
179 #endif
180 
181 // ************************************************************************* //
vector Kappa(const scalar p, const scalar T) const
Thermal conductivity [W/m/K].
Top level data entry class for use in dictionaries. Provides a mechanism to specify a variable as a c...
dictionary dict
autoPtr< tabulatedAnIsoSolidTransport > clone() const
Return a clone.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Definition: dictionary.H:129
An isotropic regularisationRadius (same in all spatial directions)
scalar alphah(const scalar p, const scalar T) const
Thermal diffusivity of enthalpy [kg/m/s].
A class for handling words, derived from Foam::string.
Definition: word.H:63
void write(Ostream &os) const
Write to Ostream.
scalar mu(const scalar p, const scalar T) const
Dynamic viscosity [kg/m/s].
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Definition: Ostream.H:56
A Vector of values with scalar precision, where scalar is float/double depending on the compilation f...
static autoPtr< tabulatedAnIsoSolidTransport > New(const dictionary &dict)
Transport properties package using Function1 type data for anisotropic thermal conductivity.
OBJstream os(runTime.globalPath()/outputName)
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
scalar kappa(const scalar p, const scalar T) const
Thermal conductivity [W/m/K].
static word typeName()
The instantiated type name.
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
Definition: HashPtrTable.H:48
volScalarField & p
Namespace for OpenFOAM.