1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
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
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
29 Base class of the thermophysical property types.
35 \*---------------------------------------------------------------------------*/
43 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
51 /*---------------------------------------------------------------------------*\
52 Class specie Declaration
53 \*---------------------------------------------------------------------------*/
62 //- Number of moles of this component in the mixture
65 //- Molecular weight of specie [kg/kmol]
69 // Private member functions
71 //- Construct from components without name
75 const scalar molWeight
83 // Thermodynamic constants
85 //- Universal gas constant [J/(kmol K)]
86 static const scalar RR;
88 //- Standard pressure [Pa]
89 static const scalar Pstd;
91 //- Standard temperature [K]
92 static const scalar Tstd;
97 //- Construct from components with name
102 const scalar molWeight
105 //- Construct as copy
106 inline specie(const specie&);
108 //- Construct as named copy
109 inline specie(const word& name, const specie&);
111 //- Construct from Istream
119 //- Molecular weight [kg/kmol]
120 inline scalar W() const;
122 //- No of moles of this species in mixture
123 inline scalar nMoles() const;
125 //- Gas constant [J/(kg K)]
126 inline scalar R() const;
131 inline void operator=(const specie&);
133 inline void operator+=(const specie&);
134 inline void operator-=(const specie&);
136 inline void operator*=(const scalar);
141 inline friend specie operator+(const specie&, const specie&);
142 inline friend specie operator-(const specie&, const specie&);
144 inline friend specie operator*(const scalar, const specie&);
146 inline friend specie operator==(const specie&, const specie&);
151 friend Ostream& operator<<(Ostream&, const specie&);
155 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
157 } // End namespace Foam
159 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
163 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
167 // ************************************************************************* //