IDEA.H
Go to the documentation of this file.
1/*---------------------------------------------------------------------------*\
2 ========= |
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4 \\ / O peration |
5 \\ / A nd | www.openfoam.com
6 \\/ M anipulation |
7-------------------------------------------------------------------------------
8 Copyright (C) 2011-2017 OpenFOAM Foundation
9-------------------------------------------------------------------------------
10License
11 This file is part of OpenFOAM.
12
13 OpenFOAM is free software: you can redistribute it and/or modify it
14 under the terms of the GNU General Public License as published by
15 the Free Software Foundation, either version 3 of the License, or
16 (at your option) any later version.
17
18 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 for more details.
22
23 You should have received a copy of the GNU General Public License
24 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25
26Class
27 Foam::IDEA
28
29Description
30 The IDEA fuel is constructed by adding 30% alphaMethylNaphthalene
31 with 70% n-decane.
32
33 The new properties have been calculated by adding the values in these
34 proportions and making a least square fit, using the same NSRDS-eq.
35 so that Y = 0.3*Y_naphthalene + 0.7*Y_decane
36
37 The valid Temperature range for n-decane is normally 243.51 - 617.70 K
38 and for the naphthalene it is 242.67 - 772.04 K
39 The least square fit was done in the interval 244 - 617 K
40
41 The critical temperature was taken to be 618.074 K, since this
42 is the 'c'-value in the rho-equation, which corresponds to Tcrit,
43 This value was then used in the fit for the NSRDS6-eq, which uses Tcrit.
44 (important for the latent heat and surface tension)
45
46 The molecular weights are 142.20 and 142.285 and for the IDEA fuel
47 it is thus 142.26 ( approximately 0.3*142.2 + 0.7*142.285 )
48
49 Critical pressure was set to the lowest one (n-Decane)
50
51 Critical volume... also the lowest one (naphthalene) 0.523 m^3/kmol
52
53 Second Virial Coefficient is n-Decane
54
55SourceFiles
56 IDEA.C
57
58\*---------------------------------------------------------------------------*/
59
60#ifndef IDEA_H
61#define IDEA_H
62
63#include "liquidProperties.H"
64#include "NSRDSfunc0.H"
65#include "NSRDSfunc1.H"
66#include "NSRDSfunc2.H"
67#include "NSRDSfunc3.H"
68#include "NSRDSfunc4.H"
69#include "NSRDSfunc5.H"
70#include "NSRDSfunc6.H"
71#include "NSRDSfunc7.H"
72#include "APIdiffCoefFunc.H"
73
74// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
75
76namespace Foam
77{
78
79/*---------------------------------------------------------------------------*\
80 Class IDEA Declaration
81\*---------------------------------------------------------------------------*/
83class IDEA
84:
85 public liquidProperties
86{
87 // Private data
88
89 NSRDSfunc5 rho_;
90 NSRDSfunc1 pv_;
91 NSRDSfunc6 hl_;
92 NSRDSfunc0 Cp_;
93 NSRDSfunc0 h_;
94 NSRDSfunc7 Cpg_;
95 NSRDSfunc4 B_;
96 NSRDSfunc1 mu_;
97 NSRDSfunc2 mug_;
98 NSRDSfunc0 kappa_;
99 NSRDSfunc2 kappag_;
100 NSRDSfunc6 sigma_;
102
103
104public:
106 friend class liquidProperties;
107
108 //- Runtime type information
109 TypeName("IDEA");
110
111
112 // Constructors
113
114 //- Construct null
115 IDEA();
116
117 // Construct from components
118 IDEA
119 (
120 const liquidProperties& l,
121 const NSRDSfunc5& density,
122 const NSRDSfunc1& vapourPressure,
123 const NSRDSfunc6& heatOfVapourisation,
124 const NSRDSfunc0& heatCapacity,
125 const NSRDSfunc0& enthalpy,
126 const NSRDSfunc7& idealGasHeatCapacity,
127 const NSRDSfunc4& secondVirialCoeff,
128 const NSRDSfunc1& dynamicViscosity,
129 const NSRDSfunc2& vapourDynamicViscosity,
130 const NSRDSfunc0& thermalConductivity,
131 const NSRDSfunc2& vapourThermalConductivity,
132 const NSRDSfunc6& surfaceTension,
133 const APIdiffCoefFunc& vapourDiffussivity
134 );
135
136 //- Construct from dictionary
137 IDEA(const dictionary& dict);
138
139 //- Construct and return clone
140 virtual autoPtr<liquidProperties> clone() const
141 {
143 }
144
145
146 // Member Functions
147
148 //- Liquid density [kg/m^3]
149 inline scalar rho(scalar p, scalar T) const;
150
151 //- Vapour pressure [Pa]
152 inline scalar pv(scalar p, scalar T) const;
153
154 //- Heat of vapourisation [J/kg]
155 inline scalar hl(scalar p, scalar T) const;
156
157 //- Liquid heat capacity [J/(kg K)]
158 inline scalar Cp(scalar p, scalar T) const;
159
160 //- Liquid Enthalpy [J/(kg)]
161 inline scalar h(scalar p, scalar T) const;
162
163 //- Ideal gas heat capacity [J/(kg K)]
164 inline scalar Cpg(scalar p, scalar T) const;
165
166 //- Second Virial Coefficient [m^3/kg]
167 inline scalar B(scalar p, scalar T) const;
168
169 //- Liquid viscosity [Pa s]
170 inline scalar mu(scalar p, scalar T) const;
171
172 //- Vapour viscosity [Pa s]
173 inline scalar mug(scalar p, scalar T) const;
174
175 //- Liquid thermal conductivity [W/(m K)]
176 inline scalar kappa(scalar p, scalar T) const;
177
178 //- Vapour thermal conductivity [W/(m K)]
179 inline scalar kappag(scalar p, scalar T) const;
180
181 //- Surface tension [N/m]
182 inline scalar sigma(scalar p, scalar T) const;
183
184 //- Vapour diffusivity [m2/s]
185 inline scalar D(scalar p, scalar T) const;
186
187 //- Vapour diffusivity [m2/s] with specified binary pair
188 inline scalar D(scalar p, scalar T, scalar Wb) const;
189
190
191 // I-O
192
193 //- Write the function coefficients
194 void writeData(Ostream& os) const;
195
196 //- Ostream Operator
197 friend Ostream& operator<<(Ostream& os, const IDEA& l);
198};
199
200
201Ostream& operator<<(Ostream& os, const IDEA& l);
202
203
204// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
205
206} // End namespace Foam
207
208// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
209
210#include "IDEAI.H"
211
212// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
213
214#endif
215
216// ************************************************************************* //
static const Foam::dimensionedScalar B("", Foam::dimless, 18.678)
API function for vapour mass diffusivity.
The IDEA fuel is constructed by adding 30% alphaMethylNaphthalene with 70% n-decane.
Definition: IDEA.H:85
friend Ostream & operator<<(Ostream &os, const IDEA &l)
Ostream Operator.
scalar Cpg(scalar p, scalar T) const
Ideal gas heat capacity [J/(kg K)].
Definition: IDEAI.H:58
void writeData(Ostream &os) const
Write the function coefficients.
Definition: IDEA.C:162
virtual autoPtr< liquidProperties > clone() const
Construct and return clone.
Definition: IDEA.H:139
IDEA()
Construct null.
Definition: IDEA.C:42
scalar kappa(scalar p, scalar T) const
Liquid thermal conductivity [W/(m K)].
Definition: IDEAI.H:82
TypeName("IDEA")
Runtime type information.
scalar mug(scalar p, scalar T) const
Vapour viscosity [Pa s].
Definition: IDEAI.H:76
scalar pv(scalar p, scalar T) const
Vapour pressure [Pa].
Definition: IDEAI.H:34
scalar hl(scalar p, scalar T) const
Heat of vapourisation [J/kg].
Definition: IDEAI.H:40
scalar kappag(scalar p, scalar T) const
Vapour thermal conductivity [W/(m K)].
Definition: IDEAI.H:88
NSRDS function number 100.
Definition: NSRDSfunc0.H:72
NSRDS function number 101.
Definition: NSRDSfunc1.H:72
NSRDS function number 102.
Definition: NSRDSfunc2.H:72
NSRDS function number 104.
Definition: NSRDSfunc4.H:72
NSRDS function number 105.
Definition: NSRDSfunc5.H:72
NSRDS function number 106.
Definition: NSRDSfunc6.H:72
NSRDS-AICHE function number 107.
Definition: NSRDSfunc7.H:72
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition: Ostream.H:62
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
The thermophysical properties of a liquid.
volScalarField & p
const volScalarField & T
const volScalarField & mu
const volScalarField & Cp
Definition: EEqn.H:7
OBJstream os(runTime.globalPath()/outputName)
Namespace for OpenFOAM.
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces)
Definition: boundaryPatch.C:83
dictionary dict
volScalarField & h
const dimensionedScalar & D
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73