All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
C2H6.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-2019 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 "C2H6.H"
28 
29 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
30 
31 namespace Foam
32 {
33  defineTypeNameAndDebug(C2H6, 0);
34  addToRunTimeSelectionTable(liquidProperties, C2H6,);
35  addToRunTimeSelectionTable(liquidProperties, C2H6, dictionary);
36 }
37 
38 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
39 
41 :
43  (
44  30.070,
45  305.32,
46  4.872e+6,
47  0.14550,
48  0.279,
49  90.35,
50  1.13,
51  184.55,
52  0.0,
53  0.0995,
54  1.24e+4
55  ),
56  rho_(57.499854, 0.27937, 305.32, 0.29187),
57  pv_(51.857, -2598.7, -5.1283, 1.4913e-05, 2.0),
58  hl_(305.32, 701396.740937812, 0.60646, -0.55492, 0.32799, 0.0),
59  Cp_
60  (
61  305.32,
62  8.02554965861611,
63  2983.63817758563,
64  167.548325566287,
65  -343.93389207094
66  ),
67  h_(0.0, 0.0, 0.0, 0.0, 0.0, 0.0),
68  Cpg_(1341.07083471899, 4463.58496840705, 1655.5, 2435.08480212837, 752.87),
69  B_
70  (
71  0.00269205187894912,
72  -2.05221150648487,
73  -47721.9820419022,
74  2.24808779514466e+15,
75  -3.23910874625873e+17
76  ),
77  mu_(-3.4134, 197.05, -1.2193, -9.2023e-26, 10.0),
78  mug_(2.5906e-07, 0.67988, 98.902, 0.0),
79  kappa_(0.35758, -0.0011458, 6.1866e-07, 0.0, 0.0, 0.0),
80  kappag_(7.3869e-05, 1.1689, 500.73, 0.0),
81  sigma_(305.32, 0.048643, 1.1981, 0.0, 0.0, 0.0),
82  D_(147.18, 20.1, 30.070, 28) // note: Same as nHeptane
83 {}
84 
85 
87 (
88  const liquidProperties& l,
89  const thermophysicalFunctions::NSRDS5& density,
90  const thermophysicalFunctions::NSRDS1& vapourPressure,
91  const thermophysicalFunctions::NSRDS6& heatOfVapourisation,
92  const thermophysicalFunctions::NSRDS14& heatCapacity,
93  const thermophysicalFunctions::NSRDS0& enthalpy,
94  const thermophysicalFunctions::NSRDS7& idealGasHeatCapacity,
95  const thermophysicalFunctions::NSRDS4& secondVirialCoeff,
96  const thermophysicalFunctions::NSRDS1& dynamicViscosity,
97  const thermophysicalFunctions::NSRDS2& vapourDynamicViscosity,
98  const thermophysicalFunctions::NSRDS0& thermalConductivity,
99  const thermophysicalFunctions::NSRDS2& vapourThermalConductivity,
100  const thermophysicalFunctions::NSRDS6& surfaceTension,
101  const thermophysicalFunctions::APIdiffCoef& vapourDiffusivity
102 )
103 :
104  liquidProperties(l),
105  rho_(density),
106  pv_(vapourPressure),
107  hl_(heatOfVapourisation),
108  Cp_(heatCapacity),
109  h_(enthalpy),
110  Cpg_(idealGasHeatCapacity),
111  B_(secondVirialCoeff),
112  mu_(dynamicViscosity),
113  mug_(vapourDynamicViscosity),
114  kappa_(thermalConductivity),
115  kappag_(vapourThermalConductivity),
116  sigma_(surfaceTension),
117  D_(vapourDiffusivity)
118 {}
119 
120 
122 :
123  C2H6()
124 {
125  readIfPresent(*this, dict);
126 }
127 
128 
129 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
130 
131 void Foam::C2H6::write(Ostream& os) const
132 {
133  liquidProperties::write(*this, os);
134 }
135 
136 
137 // ************************************************************************* //
dictionary dict
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:158
C2H6()
Construct null.
Definition: C2H6.C:40
void readIfPresent(const dictionary &dict)
Read and set the properties present it the given dictionary.
Macros for easy insertion into run-time selection tables.
ethane
Definition: C2H6.H:58
void write(Ostream &os) const
Write the function coefficients.
Definition: C2H6.C:131
The thermophysical properties of a liquid.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Definition: Ostream.H:54
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)
defineTypeNameAndDebug(combustionModel, 0)
friend class liquidProperties
Definition: C2H6.H:81
const doubleScalar e
Elementary charge.
Definition: doubleScalar.H:105
virtual void write(Ostream &os) const =0
Write the function coefficients.
Namespace for OpenFOAM.