icoTabulatedI.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) 2020 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 "icoTabulated.H"
27 
28 // * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
29 
30 template<class Specie>
32 (
33  const Specie& sp,
34  const nonUniformTable& rho
35 )
36 :
37  Specie(sp),
38  rho_(rho)
39 {}
40 
41 
42 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
43 
44 template<class Specie>
46 (
47  const word& name,
48  const icoTabulated<Specie>& ip
49 )
50 :
51  Specie(name, ip),
52  rho_(ip.rho_)
53 {}
54 
55 
56 template<class Specie>
59 {
61  (
62  new icoTabulated<Specie>(*this)
63  );
64 }
65 
66 
67 template<class Specie>
70 {
72  (
74  );
75 }
76 
77 
78 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
79 
80 template<class Specie>
81 inline Foam::scalar Foam::icoTabulated<Specie>::rho
82 (
83  scalar p,
84  scalar T
85 ) const
86 {
87  return rho_.f(p, T);
88 }
89 
90 
91 template<class Specie>
92 inline Foam::scalar Foam::icoTabulated<Specie>::H
93 (
94  scalar p,
95  scalar T
96 ) const
97 {
98  return p/this->rho(p, T);
99 }
100 
101 
102 template<class Specie>
103 inline Foam::scalar Foam::icoTabulated<Specie>::Cp
104 (
105  scalar p,
106  scalar T
107 ) const
108 {
109  return 0;
110 }
111 
112 
113 template<class Specie>
114 inline Foam::scalar Foam::icoTabulated<Specie>::E
115 (
116  scalar p,
117  scalar T
118 ) const
119 {
120  return 0;
121 }
122 
123 
124 template<class Specie>
125 inline Foam::scalar Foam::icoTabulated<Specie>::Cv
126 (
127  scalar p,
128  scalar T
129 ) const
130 {
131  return 0;
132 }
133 
134 
135 template<class Specie>
136 inline Foam::scalar Foam::icoTabulated<Specie>::Sp
137 (
138  scalar p,
139  scalar T
140 ) const
141 {
142  return 0;
143 }
144 
145 
146 template<class Specie>
147 inline Foam::scalar Foam::icoTabulated<Specie>::Sv
148 (
149  scalar p,
150  scalar T
151 ) const
152 {
153  return 0;
154 }
155 
156 
157 template<class Specie>
158 inline Foam::scalar Foam::icoTabulated<Specie>::psi
159 (
160  scalar p,
161  scalar T
162 ) const
163 {
164  return 0;
165 }
166 
167 
168 template<class Specie>
169 inline Foam::scalar Foam::icoTabulated<Specie>::Z
170 (
171  scalar p,
172  scalar T
173 ) const
174 {
175  return 0;
176 }
177 
178 
179 template<class Specie>
180 inline Foam::scalar Foam::icoTabulated<Specie>::CpMCv
181 (
182  scalar p,
183  scalar T
184 ) const
185 {
186  return 0;
187 }
188 
189 
190 // ************************************************************************* //
scalar Sp(const scalar p, const scalar T) const
Return entropy contribution to the integral of Cp/T [J/kg/K].
dictionary dict
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:158
scalar Cp(scalar p, scalar T) const
Return Cp contribution [J/(kg K].
scalar CpMCv(scalar p, scalar T) const
Return (Cp - Cv) [J/(kg K].
scalar psi(scalar p, scalar T) const
Return compressibility [s^2/m^2].
Incompressible of equation of state using non-uniform tabulated density vs temperature.
Definition: icoTabulated.H:77
scalar Cv(scalar p, scalar T) const
Return Cv contribution [J/(kg K].
scalar Sv(const scalar p, const scalar T) const
Return entropy contribution to the integral of Cv/T [J/kg/K].
A class for handling words, derived from string.
Definition: word.H:59
autoPtr< icoTabulated > clone() const
Construct and return a clone.
Definition: icoTabulatedI.H:58
static autoPtr< icoTabulated > New(const dictionary &dict)
Definition: icoTabulatedI.H:69
scalar rho(scalar p, scalar T) const
Return density [kg/m^3].
Definition: icoTabulatedI.H:82
icoTabulated(const Specie &sp, const nonUniformTable &rho)
Construct from components.
Definition: icoTabulatedI.H:32
scalar Z(scalar p, scalar T) const
Return compression factor [].
Non-uniform tabulated property function that linearly interpolates between the values.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
scalar H(const scalar p, const scalar T) const
Return enthalpy contribution [J/kg].
Definition: icoTabulatedI.H:93
scalar E(const scalar p, const scalar T) const
Return internal energy contribution [J/kg].