|
|
|
solidMixture.HGo to the documentation of this file.00001 /*---------------------------------------------------------------------------*\ 00002 ========= | 00003 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox 00004 \\ / O peration | 00005 \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd. 00006 \\/ M anipulation | 00007 ------------------------------------------------------------------------------- 00008 License 00009 This file is part of OpenFOAM. 00010 00011 OpenFOAM is free software; you can redistribute it and/or modify it 00012 under the terms of the GNU General Public License as published by the 00013 Free Software Foundation; either version 2 of the License, or (at your 00014 option) any later version. 00015 00016 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT 00017 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00018 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 00019 for more details. 00020 00021 You should have received a copy of the GNU General Public License 00022 along with OpenFOAM; if not, write to the Free Software Foundation, 00023 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00024 00025 Class 00026 Foam::solidMixture 00027 00028 Description 00029 Foam::solidMixture 00030 00031 \*---------------------------------------------------------------------------*/ 00032 00033 #ifndef solidMixture_H 00034 #define solidMixture_H 00035 00036 #include "scalarField.H" 00037 #include "PtrList.H" 00038 #include "solid.H" 00039 #include "autoPtr.H" 00040 00041 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00042 00043 namespace Foam 00044 { 00045 00046 /*---------------------------------------------------------------------------*\ 00047 Class solidMixture Declaration 00048 \*---------------------------------------------------------------------------*/ 00049 00050 class solidMixture 00051 { 00052 00053 // Private data 00054 00055 //- The names of the solids 00056 List<word> components_; 00057 00058 //- The solid properties 00059 PtrList<solid> properties_; 00060 00061 00062 public: 00063 00064 // Constructors 00065 00066 //- Construct from dictionary 00067 solidMixture 00068 ( 00069 const dictionary& 00070 ); 00071 00072 00073 // Selectors 00074 00075 //- Select construct from dictionary 00076 static autoPtr<solidMixture> New 00077 ( 00078 const dictionary& 00079 ); 00080 00081 00082 // Member Functions 00083 00084 //- Return the sold names 00085 inline const List<word>& components() const 00086 { 00087 return components_; 00088 } 00089 00090 //- Return the solid properties 00091 inline const PtrList<solid>& properties() const 00092 { 00093 return properties_; 00094 } 00095 00096 //- Returns the mass fractions, given mole fractions 00097 scalarField Y(const scalarField& X) const; 00098 00099 //- Returns the mole fractions, given mass fractions 00100 scalarField X(const scalarField& Y) const; 00101 00102 //- Calculate the mixture density [kg/m^3] as a function of 00103 // volume fractions 00104 scalar rho 00105 ( 00106 const scalarField& X 00107 ) const; 00108 00109 //- Calculate the mixture heat capacity [J/(kg K)] as a function 00110 // of mass fractions 00111 scalar cp 00112 ( 00113 const scalarField& Y 00114 ) const; 00115 }; 00116 00117 00118 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00119 00120 } // End namespace Foam 00121 00122 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00123 00124 #endif 00125 00126 // ************************************************************************* // |