IDEA.C
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-2021 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 "IDEA.H"
28 
29 #include "thermodynamicConstants.H"
30 using namespace Foam::constant::thermodynamic;
31 
32 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
33 
34 namespace Foam
35 {
39 }
40 
41 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
42 
44 :
46  (
47  typeName,
48  142.26,
49  618.074,
50  2.11e+6,
51  0.523,
52  0.247,
53  242.67,
54  3.4929e-2,
55  447.3,
56  1.7012e-30,
57  0.3478,
58  1.57e+4
59  ),
60  rho_("rho", 152.012105, 3.87150382e-1, 618.073893, 4.00790044e-1),
61  pv_
62  (
63  "pv",
64  8.4817774623e+01,
65  -8.6782398353e+03,
66  -9.1277694857,
67  4.6153144498e-06,
68  2.0
69  ),
70  hl_
71  (
72  "hl",
73  618.074,
74  2.1671983789e+05,
75  -4.2413153435e+00,
76  1.1656811532e+01,
77  -1.1656446689e+01,
78  4.3667661492
79  ),
80  Cp_("Cp", 1.6604957e+3, -6.250871e-1, 6.1778552e-3, 0.0, 0.0, 0.0),
81  h_("h", 0.0, 0.0, 0.0, 0.0, 0.0, 0.0),
82  Cpg_
83  (
84  "Cpg",
85  1.0457515243e+03,
86  3.4410492875e+03,
87  1.5976862298e+03,
88  2.4697705752e+03,
89  7.3699710536e+02
90  ),
91  B_
92  (
93  "B",
94  0.00337351091119935,
95  -4.13606494008504,
96  -534560.916470464,
97  -1.13364022911762e+19,
98  2.80704220402713e+21
99  ),
100  mu_("mu", -6.9645853822e+01, 4.4390635942e+03, 8.4680722718e+00, 0.0, 0.0),
101  mug_("mug", 4.2629382158e-08, 8.8144402122e-01, 9.6918097636e+01, 0.0),
102  kappa_("kappa", 2.03684e-01, -2.3168e-04, 0.0, 0.0, 0.0, 0.0),
103  kappag_
104  (
105  "kappag",
106  -5.664925956707e+02,
107  8.896721676320e-01,
108  -2.849783998688e+09,
109  6.914935658053e+05
110  ),
111  sigma_
112  (
113  "sigma",
114  618.074,
115  8.3846525429e-03,
116  -1.0044759047e+01,
117  2.7261918781e+01,
118  -2.5529134309e+01,
119  8.6488806234
120  ),
121  D_("D", 147.18, 20.1, 142.2, 28.0), // note: Same as nHeptane
122  Hf_(h_.value(Tstd))
123 {}
124 
125 
127 (
128  const liquidProperties& l,
129  const Function1s::NSRDS5& density,
130  const Function1s::NSRDS1& vapourPressure,
131  const Function1s::NSRDS6& heatOfVapourisation,
132  const Function1s::NSRDS0& heatCapacity,
133  const Function1s::NSRDS0& enthalpy,
134  const Function1s::NSRDS7& idealGasHeatCapacity,
135  const Function1s::NSRDS4& secondVirialCoeff,
136  const Function1s::NSRDS1& dynamicViscosity,
137  const Function1s::NSRDS2& vapourDynamicViscosity,
138  const Function1s::NSRDS0& thermalConductivity,
139  const Function1s::NSRDS2& vapourThermalConductivity,
140  const Function1s::NSRDS6& surfaceTension,
141  const Function2s::APIdiffCoef& vapourDiffusivity
142 )
143 :
144  liquidProperties(l),
145  rho_(density),
146  pv_(vapourPressure),
147  hl_(heatOfVapourisation),
148  Cp_(heatCapacity),
149  h_(enthalpy),
150  Cpg_(idealGasHeatCapacity),
151  B_(secondVirialCoeff),
152  mu_(dynamicViscosity),
153  mug_(vapourDynamicViscosity),
154  kappa_(thermalConductivity),
155  kappag_(vapourThermalConductivity),
156  sigma_(surfaceTension),
157  D_(vapourDiffusivity),
158  Hf_(h_.value(Tstd))
159 {}
160 
161 
163 :
164  IDEA()
165 {
166  readIfPresent(*this, dict);
167 }
168 
169 
170 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
171 
172 void Foam::IDEA::write(Ostream& os) const
173 {
174  liquidProperties::write(*this, os);
175 }
176 
177 
178 // ************************************************************************* //
Macros for easy insertion into run-time selection tables.
NSRDS function number 100.
Definition: NSRDS0.H:72
NSRDS function number 101.
Definition: NSRDS1.H:72
NSRDS function number 102.
Definition: NSRDS2.H:72
NSRDS function number 104.
Definition: NSRDS4.H:72
NSRDS function number 105.
Definition: NSRDS5.H:72
NSRDS function number 106.
Definition: NSRDS6.H:72
NSRDS-AICHE function number 107.
Definition: NSRDS7.H:72
The IDEA fuel is constructed by adding 30% alphaMethylNaphthalene with 70% n-decane.
Definition: IDEA.H:83
IDEA()
Construct null.
Definition: IDEA.C:43
void write(Ostream &os) const
Write the function coefficients.
Definition: IDEA.C:172
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition: Ostream.H:57
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:160
The thermophysical properties of a liquid.
virtual void write(Ostream &os) const =0
Write the function coefficients.
void readIfPresent(const dictionary &dict)
Read and set the properties present it the given dictionary.
const dimensionedScalar Tstd
Standard temperature.
Thermodynamic scalar constants.
const scalar & Tstd
Standard temperature (default in [K])
Namespace for OpenFOAM.
defineTypeNameAndDebug(combustionModel, 0)
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)
dictionary dict