1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | foam-extend: Open Source CFD
4 \\ / O peration | Version: 3.2
5 \\ / A nd | Web: http://www.foam-extend.org
6 \\/ M anipulation | For copyright notice see file Copyright
7 -------------------------------------------------------------------------------
9 This file is part of foam-extend.
11 foam-extend 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 3 of the License, or (at your
14 option) any later version.
16 foam-extend is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
25 Foam::basicMultiComponentMixture
31 basicMultiComponentMixture.C
33 \*---------------------------------------------------------------------------*/
35 #ifndef basicMultiComponentMixture_H
36 #define basicMultiComponentMixture_H
38 #include "volFields.H"
40 #include "speciesTable.H"
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 /*---------------------------------------------------------------------------*\
48 Class basicMultiComponentMixture Declaration
49 \*---------------------------------------------------------------------------*/
51 class basicMultiComponentMixture
58 //- Table of specie names
59 speciesTable species_;
61 //- Species mass fractions
62 PtrList<volScalarField> Y_;
69 //- Construct from dictionary and mesh
70 basicMultiComponentMixture
73 const wordList& specieNames,
80 virtual ~basicMultiComponentMixture()
86 //- Return the table of species
87 const speciesTable& species() const
92 //- Return the mass-fraction fields
93 inline PtrList<volScalarField>& Y();
95 //- Return the const mass-fraction fields
96 inline const PtrList<volScalarField>& Y() const;
98 //- Return the mass-fraction field for a specie given by index
99 inline volScalarField& Y(const label i);
101 //- Return the const mass-fraction field for a specie given by index
102 inline const volScalarField& Y(const label i) const;
104 //- Return the mass-fraction field for a specie given by name
105 inline volScalarField& Y(const word& specieName);
107 //- Return the const mass-fraction field for a specie given by name
108 inline const volScalarField& Y(const word& specieName) const;
110 //- Does the mixture include this specie?
111 inline bool contains(const word& specieName) const;
113 inline scalar fres(const scalar ft, const scalar stoicRatio) const;
115 inline tmp<volScalarField> fres
117 const volScalarField& ft,
118 const dimensionedScalar& stoicRatio
123 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
125 } // End namespace Foam
127 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
129 #include "basicMultiComponentMixtureI.H"
131 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
135 // ************************************************************************* //