FreeFOAM The Cross-Platform CFD Toolkit
COxidationKineticDiffusionLimitedRate.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | Copyright (C) 2008-2010 OpenCFD Ltd.
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
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
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
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
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  COxidationKineticDiffusionLimitedRate
26 
27 Description
28  Kinetic/diffusion limited rate surface reaction model for coal parcels.
29  Limited to:
30 
31  C(s) + Sb*O2 -> CO2
32 
33  where Sb is the stoichiometry of the reaction
34 
35 \*---------------------------------------------------------------------------*/
36 
37 #ifndef COxidationKineticDiffusionLimitedRate_H
38 #define COxidationKineticDiffusionLimitedRate_H
39 
41 
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 
44 namespace Foam
45 {
46 
47 // Forward class declarations
48 template<class CloudType>
50 
51 /*---------------------------------------------------------------------------*\
52  Class COxidationKineticDiffusionLimitedRate Declaration
53 \*---------------------------------------------------------------------------*/
54 
55 template<class CloudType>
57 :
58  public SurfaceReactionModel<CloudType>
59 {
60  // Private data
61 
62  // Model constants
63 
64  //- Stoichiometry of reaction
65  const scalar Sb_;
66 
67  //- Mass diffusion limited rate constant, C1
68  const scalar C1_;
69 
70  //- Kinetics limited rate pre-exponential constant, C2
71  const scalar C2_;
72 
73  //- Kinetics limited rate activation energy
74  const scalar E_;
75 
76 
77  // Addressing
78 
79  //- Cs positions in global/local lists
80  label CsLocalId_;
81 
82  //- O2 position in global list
83  label O2GlobalId_;
84 
85  //- CO2 positions in global list
86  label CO2GlobalId_;
87 
88 
89  // Local copies of thermo properties
90 
91  //- Molecular weight of C [kg/kmol]
92  scalar WC_;
93 
94  //- Molecular weight of O2 [kg/kmol]
95  scalar WO2_;
96 
97  //- Chemical enthalpy of CO2 [J/kg]
98  scalar HcCO2_;
99 
100 
101 public:
102 
103  //- Runtime type information
104  TypeName("COxidationKineticDiffusionLimitedRate");
105 
106 
107  // Constructors
108 
109  //- Construct from dictionary
111  (
112  const dictionary& dict,
113  CloudType& owner
114  );
115 
116 
117  //- Destructor
119 
120 
121  // Member Functions
122 
123  //- Flag to indicate whether model activates surface reaction model
124  virtual bool active() const;
125 
126  //- Update surface reactions
127  virtual scalar calculate
128  (
129  const scalar dt,
130  const label cellI,
131  const scalar d,
132  const scalar T,
133  const scalar Tc,
134  const scalar pc,
135  const scalar rhoc,
136  const scalar mass,
137  const scalarField& YGas,
138  const scalarField& YLiquid,
139  const scalarField& YSolid,
140  const scalarField& YMixture,
141  const scalar N,
142  scalarField& dMassGas,
143  scalarField& dMassLiquid,
144  scalarField& dMassSolid,
145  scalarField& dMassSRCarrier
146  ) const;
147 };
148 
149 
150 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
151 
152 } // End namespace Foam
153 
154 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
155 
156 #ifdef NoRepository
158 #endif
159 
160 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
161 
162 #endif
163 
164 // ************************ vim: set sw=4 sts=4 et: ************************ //