![]() |
|
00001 /*---------------------------------------------------------------------------*\ 00002 ========= | 00003 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox 00004 \\ / O peration | 00005 \\ / A nd | Copyright (C) 1991-2005 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 hMixtureThermo 00027 00028 Description 00029 00030 SourceFiles 00031 hMixtureThermo.C 00032 00033 \*---------------------------------------------------------------------------*/ 00034 00035 #ifndef hMixtureThermo_H 00036 #define hMixtureThermo_H 00037 00038 #include "hCombustionThermo.H" 00039 00040 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00041 00042 namespace Foam 00043 { 00044 00045 /*---------------------------------------------------------------------------*\ 00046 Class hMixtureThermo Declaration 00047 \*---------------------------------------------------------------------------*/ 00048 00049 template<class MixtureType> 00050 class hMixtureThermo 00051 : 00052 public hCombustionThermo, 00053 public MixtureType 00054 { 00055 // Private member functions 00056 00057 void calculate(); 00058 00059 //- Construct as copy (not implemented) 00060 hMixtureThermo(const hMixtureThermo<MixtureType>&); 00061 00062 00063 public: 00064 00065 //- Runtime type information 00066 TypeName("hMixtureThermo"); 00067 00068 00069 // Constructors 00070 00071 //- Construct from mesh 00072 hMixtureThermo(const fvMesh&); 00073 00074 00075 // Destructor 00076 00077 virtual ~hMixtureThermo(); 00078 00079 00080 // Member functions 00081 00082 //- Return the compostion of the combustion mixture 00083 combustionMixture& composition() 00084 { 00085 return *this; 00086 } 00087 00088 //- Return the compostion of the combustion mixture 00089 const combustionMixture& composition() const 00090 { 00091 return *this; 00092 } 00093 00094 //- Update properties 00095 virtual void correct(); 00096 00097 00098 // Fields derived from thermodynamic state variables 00099 00100 //- Enthalpy for cell-set [J/kg] 00101 tmp<scalarField> h 00102 ( 00103 const scalarField& T, 00104 const labelList& cells 00105 ) const; 00106 00107 //- Enthalpy for patch [J/kg] 00108 tmp<scalarField> h 00109 ( 00110 const scalarField& T, 00111 const label patchi 00112 ) const; 00113 00114 //- Heat capacity at constant pressure for patch [J/kg/K] 00115 tmp<scalarField> Cp(const scalarField& T, const label patchi) const; 00116 00117 //- Heat capacity at constant pressure [J/kg/K] 00118 tmp<volScalarField> Cp() const; 00119 00120 00121 //- Read thermophysicalProperties dictionary 00122 virtual bool read(); 00123 }; 00124 00125 00126 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00127 00128 } // End namespace Foam 00129 00130 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00131 00132 #ifdef NoRepository 00133 # include "hMixtureThermo.C" 00134 #endif 00135 00136 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00137 00138 #endif 00139 00140 // ************************************************************************* //