MB.C
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
26\*---------------------------------------------------------------------------*/
27
28#include "MB.H"
30
31// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
32
33namespace Foam
34{
38}
39
40// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
41
43:
45 (
46 102.133,
47 554.5,
48 3.4734e+6,
49 0.34,
50 0.256,
51 187.35,
52 1.0102e-1,
53 375.90,
54 5.7373e-30,
55 0.3807,
56 1.7713e+4
57 ),
58 rho_(76.6099633, 0.257, 554.5, 0.2772),
59 pv_(107.51, -8112.9, -12.77, 9.2919e-06, 2.0),
60 hl_(554.5, 508307.794738233, 0.392, 0.0, 0.0, 0.0),
61 Cp_(1135.77394182096, 2.89818178257762, 0.0, 0.0, 0.0, 0.0),
62 h_(-5255966.14542938, 1135.77394182096, 1.44909089128881, 0.0, 0.0, 0.0),
63 Cpg_(875.329227575808, 2849.22600922327, 1570.0, 2029.70636327142, 678.3),
64 B_
65 (
66 0.00220496803188,
67 -2.42184210783978,
68 -401045.695318849,
69 -2.85079259397061e+17,
70 -3.57377145486767e+19
71 ),
72 mu_(-12.206, 1141.7, 0.15014, 0.0, 0.0),
73 mug_(3.733e-07, 0.6177, 256.5, 0.0),
74 kappa_(0.2298, -0.0003002, 0.0, 0.0, 0.0, 0.0),
75 kappag_(1333.1, 0.9962, 12317000000.0, 0.0),
76 sigma_(554.5, 0.064084, 1.2418, 0.0, 0.0, 0.0),
77 D_(147.18, 20.1, 102.133, 28.0) // note: Same as nHeptane
78{}
79
80
82(
83 const liquidProperties& l,
84 const NSRDSfunc5& density,
85 const NSRDSfunc1& vapourPressure,
86 const NSRDSfunc6& heatOfVapourisation,
87 const NSRDSfunc0& heatCapacity,
88 const NSRDSfunc0& enthalpy,
89 const NSRDSfunc7& idealGasHeatCapacity,
90 const NSRDSfunc4& secondVirialCoeff,
91 const NSRDSfunc1& dynamicViscosity,
92 const NSRDSfunc2& vapourDynamicViscosity,
93 const NSRDSfunc0& thermalConductivity,
94 const NSRDSfunc2& vapourThermalConductivity,
95 const NSRDSfunc6& surfaceTension,
96 const APIdiffCoefFunc& vapourDiffussivity
97)
98:
100 rho_(density),
101 pv_(vapourPressure),
102 hl_(heatOfVapourisation),
103 Cp_(heatCapacity),
104 h_(enthalpy),
105 Cpg_(idealGasHeatCapacity),
106 B_(secondVirialCoeff),
107 mu_(dynamicViscosity),
108 mug_(vapourDynamicViscosity),
109 kappa_(thermalConductivity),
110 kappag_(vapourThermalConductivity),
111 sigma_(surfaceTension),
112 D_(vapourDiffussivity)
113{}
114
115
117:
118 MB()
119{
120 readIfPresent(*this, dict);
121}
122
123
124// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
125
127{
128 liquidProperties::writeData(*this, os);
129}
130
131
132// * * * * * * * * * * * * * * * Ostream Operator * * * * * * * * * * * * * //
133
135{
136 l.writeData(os);
137 return os;
138}
139
140
141// ************************************************************************* //
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
API function for vapour mass diffusivity.
Liquid nC3H7COOCH3 or (MB) methyl butyrate (used for biodiesel surrogate)
Definition: MB.H:63
void writeData(Ostream &os) const
Write the function coefficients.
Definition: MB.C:126
MB()
Construct null.
Definition: MB.C:42
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
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.
void readIfPresent(const dictionary &dict)
Read and set the properties present it the given dictionary.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
Definition: className.H:121
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