OpenFOAM logo
The Open Source CFD Toolbox
  Source Guide OpenCFD Solutions Contact OpenFOAM

COxidationKineticDiffusionLimitedRate.H

Go 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) 2008-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     COxidationKineticDiffusionLimitedRate
00027 
00028 Description
00029     Kinetic/diffusion limited rate surface reaction model for coal parcels.
00030     Limited to:
00031 
00032         C(s) + Sb*O2 -> CO2
00033 
00034     where Sb is the stoichiometry of the reaction
00035 
00036 \*---------------------------------------------------------------------------*/
00037 
00038 #ifndef COxidationKineticDiffusionLimitedRate_H
00039 #define COxidationKineticDiffusionLimitedRate_H
00040 
00041 #include "SurfaceReactionModel.H"
00042 
00043 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00044 
00045 namespace Foam
00046 {
00047 
00048 // Forward class declarations
00049 template<class CloudType>
00050 class COxidationKineticDiffusionLimitedRate;
00051 
00052 /*---------------------------------------------------------------------------*\
00053             Class COxidationKineticDiffusionLimitedRate Declaration
00054 \*---------------------------------------------------------------------------*/
00055 
00056 template<class CloudType>
00057 class COxidationKineticDiffusionLimitedRate
00058 :
00059     public SurfaceReactionModel<CloudType>
00060 {
00061     // Private data
00062 
00063         // Model constants
00064 
00065             //- Stoichiometry of reaction
00066             const scalar Sb_;
00067 
00068             //- Mass diffusion limited rate constant, C1
00069             const scalar C1_;
00070 
00071             //- Kinetics limited rate pre-exponential constant, C2
00072             const scalar C2_;
00073 
00074             //- Kinetics limited rate activation energy
00075             const scalar E_;
00076 
00077 
00078         // Addressing
00079 
00080             //- Cs positions in global/local lists
00081             label CsLocalId_;
00082 
00083             //- O2 position in global list
00084             label O2GlobalId_;
00085 
00086             //- CO2 positions in global list
00087             label CO2GlobalId_;
00088 
00089 
00090         // Local copies of thermo properties
00091 
00092             //- Molecular weight of C [kg/kmol]
00093             scalar WC_;
00094 
00095             //- Molecular weight of O2 [kg/kmol]
00096             scalar WO2_;
00097 
00098             //- Chemical enthalpy of CO2 [J/kg]
00099             scalar HcCO2_;
00100 
00101 
00102 public:
00103 
00104     //- Runtime type information
00105     TypeName("COxidationKineticDiffusionLimitedRate");
00106 
00107 
00108     // Constructors
00109 
00110         //- Construct from dictionary
00111         COxidationKineticDiffusionLimitedRate
00112         (
00113             const dictionary& dict,
00114             CloudType& owner
00115         );
00116 
00117 
00118     //- Destructor
00119     virtual ~COxidationKineticDiffusionLimitedRate();
00120 
00121 
00122     // Member Functions
00123 
00124         //- Flag to indicate whether model activates surface reaction model
00125         virtual bool active() const;
00126 
00127         //- Update surface reactions
00128         virtual scalar calculate
00129         (
00130             const scalar dt,
00131             const label cellI,
00132             const scalar d,
00133             const scalar T,
00134             const scalar Tc,
00135             const scalar pc,
00136             const scalar rhoc,
00137             const scalar mass,
00138             const scalarField& YGas,
00139             const scalarField& YLiquid,
00140             const scalarField& YSolid,
00141             const scalarField& YMixture,
00142             const scalarField& dMassVolatile,
00143             scalarField& dMassGas,
00144             scalarField& dMassLiquid,
00145             scalarField& dMassSolid,
00146             scalarField& dMassSRCarrier
00147         ) const;
00148 };
00149 
00150 
00151 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00152 
00153 } // End namespace Foam
00154 
00155 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00156 
00157 #ifdef NoRepository
00158     #include "COxidationKineticDiffusionLimitedRate.C"
00159 #endif
00160 
00161 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00162 
00163 #endif
00164 
00165 // ************************************************************************* //
Copyright © 2000-2009 OpenCFD Ltd