1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
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.
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
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/>.
28 Constant properties Transport package.
29 Templated into a given thermodynamics package (needed for thermal
36 \*---------------------------------------------------------------------------*/
38 #ifndef constTransport_H
39 #define constTransport_H
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 // Forward declaration of friend functions and operators
48 template<class Thermo> class constTransport;
50 template<class Thermo>
51 inline constTransport<Thermo> operator+
53 const constTransport<Thermo>&,
54 const constTransport<Thermo>&
57 template<class Thermo>
58 inline constTransport<Thermo> operator-
60 const constTransport<Thermo>&,
61 const constTransport<Thermo>&
64 template<class Thermo>
65 inline constTransport<Thermo> operator*
68 const constTransport<Thermo>&
71 template<class Thermo>
72 inline constTransport<Thermo> operator==
74 const constTransport<Thermo>&,
75 const constTransport<Thermo>&
78 template<class Thermo>
82 const constTransport<Thermo>&
86 /*---------------------------------------------------------------------------*\
87 Class constTransport Declaration
88 \*---------------------------------------------------------------------------*/
90 template<class Thermo>
97 //- Constant dynamic viscosity [Pa.s]
100 //- Reciprocal Prandtl Number []
104 // Private Member Functions
106 //- Construct from components
107 inline constTransport
119 //- Construct as named copy
120 inline constTransport(const word&, const constTransport&);
122 //- Construct from Istream
123 constTransport(Istream&);
125 //- Construct from dictionary
126 constTransport(const dictionary& dict);
131 //- Dynamic viscosity [kg/ms]
132 inline scalar mu(const scalar T) const;
134 //- Thermal conductivity [W/mK]
135 inline scalar kappa(const scalar T) const;
137 //- Thermal diffusivity for enthalpy [kg/ms]
138 inline scalar alpha(const scalar T) const;
140 // Species diffusivity
141 //inline scalar D(const scalar T) const;
144 void write(Ostream& os) const;
149 inline constTransport& operator=
151 const constTransport&
157 friend constTransport operator+ <Thermo>
159 const constTransport&,
160 const constTransport&
163 friend constTransport operator- <Thermo>
165 const constTransport&,
166 const constTransport&
169 friend constTransport operator* <Thermo>
172 const constTransport&
175 friend constTransport operator== <Thermo>
177 const constTransport&,
178 const constTransport&
184 friend Ostream& operator<< <Thermo>
187 const constTransport&
192 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
194 } // End namespace Foam
196 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
198 #include "constTransportI.H"
201 # include "constTransport.C"
204 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
208 // ************************************************************************* //