initial commit for version 1.5.x patch release
[OpenFOAM-1.5.x.git] / src / thermophysicalModels / liquids / aC10H7CH3 / aC10H7CH3.H
blob580b1c1bb1636d1b9e7dd744f2448766a9e63672
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 1991-2008 OpenCFD Ltd.
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
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 the
13     Free Software Foundation; either version 2 of the License, or (at your
14     option) any later version.
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.
21     You should have received a copy of the GNU General Public License
22     along with OpenFOAM; if not, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 Class
26     Foam::aC10H7CH3
28 Description
29     alphaMethylNaphthalene
31 SourceFiles
32     aC10H7CH3.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef aC10H7CH3_H
37 #define aC10H7CH3_H
39 #include "liquid.H"
40 #include "NSRDSfunc0.H"
41 #include "NSRDSfunc1.H"
42 #include "NSRDSfunc2.H"
43 #include "NSRDSfunc3.H"
44 #include "NSRDSfunc4.H"
45 #include "NSRDSfunc5.H"
46 #include "NSRDSfunc6.H"
47 #include "NSRDSfunc7.H"
48 #include "NSRDSfunc14.H"
49 #include "APIdiffCoefFunc.H"
51 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
53 namespace Foam
56 /*---------------------------------------------------------------------------*\
57                            Class aC10H7CH3 Declaration
58 \*---------------------------------------------------------------------------*/
60 class aC10H7CH3
62     public liquid
64     // Private data
66         NSRDSfunc5 rho_;
67         NSRDSfunc1 pv_;
68         NSRDSfunc6 hl_;
69         NSRDSfunc0 cp_;
70         NSRDSfunc0 h_;
71         NSRDSfunc7 cpg_;
72         NSRDSfunc4 B_;
73         NSRDSfunc1 mu_;
74         NSRDSfunc2 mug_;
75         NSRDSfunc0 K_;
76         NSRDSfunc2 Kg_;
77         NSRDSfunc6 sigma_;
78         APIdiffCoefFunc D_;
81 public:
83     //- Runtime type information
84     TypeName("aC11H10");
87     // Constructors
89         //- Construct null
90         aC10H7CH3()
91         :
92             liquid(142.2, 772.04, 3.66e+6, 0.523, 0.298, 242.67, 3.4929e-2, 517.83, 1.7012e-30, 0.3478, 2.0176e+4),
93             rho_(60.92559, 0.22408, 772.04, 0.25709),
94             pv_(73.716, -9103.2, -7.2253, 2.062e-06, 2),
95             hl_(772.04, 511744.022503516, 0.4164, 0, 0, 0),
96             cp_(965.893108298172, 1.16216596343179, 0.00298523206751055, 0, 0, 0),
97             // NN: enthalpy, h_, is not used in the sprayModel.
98             // For consistency, the enthalpy is derived from hlat and hl.
99             // It is, however, convenient to have it available.
100             h_(38161.6838138517, 965.893108298172, 0.581082981715893, 0.00099507735583685, 0, 0),
101             cpg_(743.389592123769, 2703.5864978903, 1548.5, 2031.64556962025, 722.06),
102             B_(0.00205555555555556, -3.34423347398031, -931153.305203938, 1.87601969057665e+18, -2.06448663853727e+21),
103             mu_(-93.6, 5784, 12, 0, 0),
104             mug_(2.5672e-06, 0.3566, 825.54, 0),
105             K_(0.19758, -0.0001796, 0, 0, 0, 0),
106             Kg_(0.3911, -0.1051, -213.52, 2318300),
107             sigma_(772.04, 0.076, 1.33, 0, 0, 0),
108             D_(147.18, 20.1, 142.2, 28) // NN: Same as nHeptane
109         {}
110         aC10H7CH3
111         (
112             const liquid& l,
113             const NSRDSfunc5& density,
114             const NSRDSfunc1& vapourPressure,
115             const NSRDSfunc6& heatOfVapourisation,
116             const NSRDSfunc0& heatCapacity,
117             const NSRDSfunc0& enthalpy,
118             const NSRDSfunc7& idealGasHeatCapacity,
119             const NSRDSfunc4& secondVirialCoeff,
120             const NSRDSfunc1& dynamicViscosity,
121             const NSRDSfunc2& vapourDynamicViscosity,
122             const NSRDSfunc0& thermalConductivity,
123             const NSRDSfunc2& vapourThermalConductivity,
124             const NSRDSfunc6& surfaceTension,
125             const APIdiffCoefFunc& vapourDiffussivity
126         )
127         :
128             liquid(l),
129             rho_(density),
130             pv_(vapourPressure),
131             hl_(heatOfVapourisation),
132             cp_(heatCapacity),
133             h_(enthalpy),
134             cpg_(idealGasHeatCapacity),
135             B_(secondVirialCoeff),
136             mu_(dynamicViscosity),
137             mug_(vapourDynamicViscosity),
138             K_(thermalConductivity),
139             Kg_(vapourThermalConductivity),
140             sigma_(surfaceTension),
141             D_(vapourDiffussivity)
142         {}
144         //- Construct from Istream
145         aC10H7CH3(Istream& is)
146         :
147             liquid(is),
148             rho_(is),
149             pv_(is),
150             hl_(is),
151             cp_(is),
152             h_(is),
153             cpg_(is),
154             B_(is),
155             mu_(is),
156             mug_(is),
157             K_(is),
158             Kg_(is),
159             sigma_(is),
160             D_(is)
161         {}
164     // Member Functions
166         //- Liquid density [kg/m^3]
167         scalar rho(scalar p, scalar T) const
168         {
169             return rho_.f(p, T);
170         }
172         //- Vapour pressure [Pa]
173         scalar pv(scalar p, scalar T) const
174         {
175             return pv_.f(p, T);
176         }
178         //- Heat of vapourisation [J/kg]
179         scalar hl(scalar p, scalar T) const
180         {
181             return hl_.f(p, T);
182         }
184         //- Liquid heat capacity [J/(kg K)]
185         scalar cp(scalar p, scalar T) const
186         {
187             return cp_.f(p, T);
188         }
190         //- Liquid Enthalpy [J/(kg)]
191         scalar h(scalar p, scalar T) const
192         {
193             return h_.f(p, T);
194         }
196         //- Ideal gas heat capacity [J/(kg K)]
197         scalar cpg(scalar p, scalar T) const
198         {
199             return cpg_.f(p, T);
200         }
202         //- Second Virial Coefficient [m^3/kg]
203         scalar B(scalar p, scalar T) const
204         {
205             return B_.f(p, T);
206         }
208         //- Liquid viscosity [Pa s]
209         scalar mu(scalar p, scalar T) const
210         {
211             return mu_.f(p, T);
212         }
214         //- Vapour viscosity [Pa s]
215         scalar mug(scalar p, scalar T) const
216         {
217             return mug_.f(p, T);
218         }
220         //- Liquid thermal conductivity  [W/(m K)]
221         scalar K(scalar p, scalar T) const
222         {
223             return K_.f(p, T);
224         }
226         //- Vapour thermal conductivity  [W/(m K)]
227         scalar Kg(scalar p, scalar T) const
228         {
229             return Kg_.f(p, T);
230         }
232         //- Surface tension [N/m]
233         scalar sigma(scalar p, scalar T) const
234         {
235             return sigma_.f(p, T);
236         }
238         //- Vapour diffussivity [m2/s]
239         scalar D(scalar p, scalar T) const
240         {
241             return D_.f(p, T);
242         }
245         //- Write the function coefficients
246         void writeData(Ostream& os) const
247         {
248             liquid::writeData(os); os << nl;
249             rho_.writeData(os); os << nl;
250             pv_.writeData(os); os << nl;
251             hl_.writeData(os); os << nl;
252             cp_.writeData(os); os << nl;
253             cpg_.writeData(os); os << nl;
254             B_.writeData(os); os << nl;
255             mu_.writeData(os); os << nl;
256             mug_.writeData(os); os << nl;
257             K_.writeData(os); os << nl;
258             Kg_.writeData(os); os << nl;
259             sigma_.writeData(os); os << nl;
260             D_.writeData(os); os << endl;
261         }
264     // Ostream Operator
266         friend Ostream& operator<<(Ostream& os, const aC10H7CH3& l)
267         {
268             l.writeData(os);
269             return os;
270         }
274 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
276 } // End namespace Foam
278 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
280 #endif
282 // ************************************************************************* //