AndradeTransportI.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) 2021-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 \*---------------------------------------------------------------------------*/
25 
26 #include "specie.H"
27 
28 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
29 
30 template<class Thermo>
32 (
33  const Thermo& t,
34  const coeffList& muCoeffs,
35  const coeffList& kappaCoeffs
36 )
37 :
38  Thermo(t),
39  muCoeffs_(muCoeffs),
40  kappaCoeffs_(kappaCoeffs)
41 {}
42 
43 
44 template<class Thermo>
46 (
47  const word& name,
48  const AndradeTransport& pt
49 )
50 :
51  Thermo(name, pt),
52  muCoeffs_(pt.muCoeffs_),
53  kappaCoeffs_(pt.kappaCoeffs_)
54 {}
55 
56 
57 template<class Thermo>
60 {
62  (
63  new AndradeTransport<Thermo>(*this)
64  );
65 }
66 
67 
68 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
69 
70 template<class Thermo>
72 (
73  const scalar p,
74  const scalar T
75 ) const
76 {
77  return exp
78  (
79  muCoeffs_[0]
80  + muCoeffs_[1]*T
81  + muCoeffs_[2]*sqr(T)
82  + muCoeffs_[3]/(muCoeffs_[4] + T)
83  );
84 }
85 
86 
87 template<class Thermo>
89 (
90  const scalar p,
91  const scalar T
92 ) const
93 {
94  return exp
95  (
96  kappaCoeffs_[0]
97  + kappaCoeffs_[1]*T
98  + kappaCoeffs_[2]*sqr(T)
99  + kappaCoeffs_[3]/(kappaCoeffs_[4] + T)
100  );
101 }
102 
103 
104 // ************************************************************************* //
Transport package using the Andrade function for the natural logarithm of dynamic viscosity and therm...
scalar mu(const scalar p, const scalar T) const
Dynamic viscosity [kg/m/s].
scalar kappa(const scalar p, const scalar T) const
Thermal conductivity [W/m/K].
autoPtr< AndradeTransport > clone() const
Construct and return a clone.
AndradeTransport(const Thermo &t, const coeffList &muCoeffs, const coeffList &kappaCoeffs)
Construct from components.
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 class for handling words, derived from string.
Definition: word.H:62
dimensionedScalar exp(const dimensionedScalar &ds)
dimensionedSymmTensor sqr(const dimensionedVector &dv)
word name(const complex &)
Return a string representation of a complex.
Definition: complex.C:47
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
volScalarField & p