1 /** 2 * @file InterfaceKinetics.h 3 * @ingroup chemkinetics 4 */ 5 6 // This file is part of Cantera. See License.txt in the top-level directory or 7 // at https://cantera.org/license.txt for license and copyright information. 8 9 #ifndef CT_IFACEKINETICS_H 10 #define CT_IFACEKINETICS_H 11 12 #include "Kinetics.h" 13 #include "RateCoeffMgr.h" 14 15 namespace Cantera 16 { 17 18 // forward declarations 19 class SurfPhase; 20 class ImplicitSurfChem; 21 class InterfaceReaction; 22 class BlowersMaselInterfaceReaction; 23 24 //! A kinetics manager for heterogeneous reaction mechanisms. The reactions are 25 //! assumed to occur at a 2D interface between two 3D phases. 26 /*! 27 * There are some important additions to the behavior of the kinetics class due 28 * to the presence of multiple phases and a heterogeneous interface. If a 29 * reactant phase doesn't exists, i.e., has a mole number of zero, a 30 * heterogeneous reaction can not proceed from reactants to products. Note it 31 * could perhaps proceed from products to reactants if all of the product phases 32 * exist. 33 * 34 * In order to make the determination of whether a phase exists or not actually 35 * involves the specification of additional information to the kinetics object., 36 * which heretofore has only had access to intrinsic field information about the 37 * phases (i.e., temperature pressure, and mole fraction). 38 * 39 * The extrinsic specification of whether a phase exists or not must be 40 * specified on top of the intrinsic calculation of the reaction rate. This 41 * class carries a set of booleans indicating whether a phase in the 42 * heterogeneous mechanism exists or not. 43 * 44 * Additionally, the class carries a set of booleans around indicating whether a 45 * product phase is stable or not. If a phase is not thermodynamically stable, 46 * it may be the case that a particular reaction in a heterogeneous mechanism 47 * will create a product species in the unstable phase. However, other reactions 48 * in the mechanism will destruct that species. This may cause oscillations in 49 * the formation of the unstable phase from time step to time step within a ODE 50 * solver, in practice. In order to avoid this situation, a set of booleans is 51 * tracked which sets the stability of a phase. If a phase is deemed to be 52 * unstable, then species in that phase will not be allowed to be birthed by the 53 * kinetics operator. Nonexistent phases are deemed to be unstable by default, 54 * but this can be changed. 55 * 56 * @ingroup chemkinetics 57 */ 58 class InterfaceKinetics : public Kinetics 59 { 60 public: 61 //! Constructor 62 /*! 63 * @param thermo The optional parameter may be used to initialize the object 64 * with one ThermoPhase object. 65 * HKM Note -> Since the interface kinetics object will 66 * probably require multiple ThermoPhase objects, this is 67 * probably not a good idea to have this parameter. 68 */ 69 InterfaceKinetics(ThermoPhase* thermo = 0); 70 71 virtual ~InterfaceKinetics(); 72 kineticsType()73 virtual std::string kineticsType() const { 74 return "Surf"; 75 } 76 77 //! Set the electric potential in the nth phase 78 /*! 79 * @param n phase Index in this kinetics object. 80 * @param V Electric potential (volts) 81 */ 82 void setElectricPotential(int n, doublereal V); 83 84 //! @name Reaction Rates Of Progress 85 //! @{ 86 87 //! Equilibrium constant for all reactions including the voltage term 88 /*! 89 * Kc = exp(deltaG/RT) 90 * 91 * where deltaG is the electrochemical potential difference between 92 * products minus reactants. 93 */ 94 virtual void getEquilibriumConstants(doublereal* kc); 95 96 //! values needed to convert from exchange current density to surface 97 //! reaction rate. 98 void updateExchangeCurrentQuantities(); 99 100 virtual void getDeltaGibbs(doublereal* deltaG); 101 102 virtual void getDeltaElectrochemPotentials(doublereal* deltaM); 103 virtual void getDeltaEnthalpy(doublereal* deltaH); 104 virtual void getDeltaEntropy(doublereal* deltaS); 105 106 virtual void getDeltaSSGibbs(doublereal* deltaG); 107 virtual void getDeltaSSEnthalpy(doublereal* deltaH); 108 virtual void getDeltaSSEntropy(doublereal* deltaS); 109 110 //! @} 111 //! @name Reaction Mechanism Informational Query Routines 112 //! @{ 113 114 virtual void getActivityConcentrations(doublereal* const conc); 115 116 //! Return the charge transfer rxn Beta parameter for the ith reaction 117 /*! 118 * Returns the beta parameter for a charge transfer reaction. This 119 * parameter is not important for non-charge transfer reactions. 120 * Note, the parameter defaults to zero. However, a value of 0.5 121 * should be supplied for every charge transfer reaction if 122 * no information is known, as a value of 0.5 pertains to a 123 * symmetric transition state. The value can vary between 0 to 1. 124 * 125 * @param irxn Reaction number in the kinetics mechanism 126 * 127 * @return Beta parameter. This defaults to zero, even for charge 128 * transfer reactions. 129 */ 130 doublereal electrochem_beta(size_t irxn) const; 131 isReversible(size_t i)132 virtual bool isReversible(size_t i) { 133 if (std::find(m_revindex.begin(), m_revindex.end(), i) 134 < m_revindex.end()) { 135 return true; 136 } else { 137 return false; 138 } 139 } 140 141 virtual void getFwdRateConstants(doublereal* kfwd); 142 virtual void getRevRateConstants(doublereal* krev, 143 bool doIrreversible = false); 144 145 //! Return effective preexponent for the specified reaction 146 /*! 147 * Returns effective preexponent, accounting for surface coverage 148 * dependencies. 149 * 150 * @param irxn Reaction number in the kinetics mechanism 151 * @return Effective preexponent 152 */ effectivePreExponentialFactor(size_t irxn)153 double effectivePreExponentialFactor(size_t irxn) { 154 return m_rates.effectivePreExponentialFactor(irxn); 155 } 156 157 //! Return effective activation energy for the specified reaction 158 /*! 159 * Returns effective activation energy, accounting for surface coverage 160 * dependencies. 161 * 162 * @param irxn Reaction number in the kinetics mechanism 163 * @return Effective activation energy divided by the gas constant 164 */ effectiveActivationEnergy_R(size_t irxn)165 double effectiveActivationEnergy_R(size_t irxn) { 166 return m_rates.effectiveActivationEnergy_R(irxn); 167 } 168 169 //! Return effective temperature exponent for the specified reaction 170 /*! 171 * Returns effective temperature exponent, accounting for surface coverage 172 * dependencies. Current parameterization in SurfaceArrhenius does not 173 * change this parameter with the change in surface coverages. 174 * 175 * @param irxn Reaction number in the kinetics mechanism 176 * @return Effective temperature exponent 177 */ effectiveTemperatureExponent(size_t irxn)178 double effectiveTemperatureExponent(size_t irxn) { 179 return m_rates.effectiveTemperatureExponent(irxn); 180 } 181 182 //! @} 183 //! @name Reaction Mechanism Construction 184 //! @{ 185 186 //! Add a phase to the kinetics manager object. 187 /*! 188 * This must be done before the function init() is called or 189 * before any reactions are input. 190 * 191 * This function calls Kinetics::addPhase(). It also sets the following 192 * fields: 193 * 194 * m_phaseExists[] 195 * 196 * @param thermo Reference to the ThermoPhase to be added. 197 */ 198 virtual void addPhase(ThermoPhase& thermo); 199 200 virtual void init(); 201 virtual void resizeSpecies(); 202 virtual bool addReaction(shared_ptr<Reaction> r, bool resize=true); 203 virtual void modifyReaction(size_t i, shared_ptr<Reaction> rNew); 204 //! @} 205 206 //! Internal routine that updates the Rates of Progress of the reactions 207 /*! 208 * This is actually the guts of the functionality of the object 209 */ 210 virtual void updateROP(); 211 212 //! Update properties that depend on temperature 213 /*! 214 * Current objects that this function updates: 215 * m_kdata->m_logtemp 216 * m_kdata->m_rfn 217 * m_rates. 218 * updateKc(); 219 */ 220 void _update_rates_T(); 221 222 //! Update properties that depend on the electric potential 223 void _update_rates_phi(); 224 225 //! Update properties that depend on the species mole fractions and/or 226 //! concentration, 227 /*! 228 * This method fills out the array of generalized concentrations by calling 229 * method getActivityConcentrations for each phase, which classes 230 * representing phases should overload to return the appropriate quantities. 231 */ 232 void _update_rates_C(); 233 234 //! Advance the surface coverages in time 235 /*! 236 * This method carries out a time-accurate advancement of the 237 * surface coverages for a specified amount of time. 238 * 239 * \f[ 240 * \dot {\theta}_k = \dot s_k (\sigma_k / s_0) 241 * \f] 242 * 243 * @param tstep Time value to advance the surface coverages 244 * @param rtol The relative tolerance for the integrator 245 * @param atol The absolute tolerance for the integrator 246 * @param maxStepSize The maximum step-size the integrator is allowed to take. 247 * If zero, this option is disabled. 248 * @param maxSteps The maximum number of time-steps the integrator can take. 249 * If not supplied, uses the default value in CVodeIntegrator (20000). 250 * @param maxErrTestFails the maximum permissible number of error test failures 251 * If not supplied, uses the default value in CVODES (7). 252 */ 253 void advanceCoverages(doublereal tstep, double rtol=1.e-7, 254 double atol=1.e-14, double maxStepSize=0, 255 size_t maxSteps=20000, size_t maxErrTestFails=7); 256 257 //! Solve for the pseudo steady-state of the surface problem 258 /*! 259 * This is the same thing as the advanceCoverages() function, 260 * but at infinite times. 261 * 262 * Note, a direct solve is carried out under the hood here, 263 * to reduce the computational time. 264 * 265 * @param ifuncOverride One of the values defined in @ref solvesp_methods. 266 * The default is -1, which means that the program will decide. 267 * @param timeScaleOverride When a pseudo transient is selected this value 268 * can be used to override the default time scale for 269 * integration which is one. When SFLUX_TRANSIENT is used, this 270 * is equal to the time over which the equations are integrated. 271 * When SFLUX_INITIALIZE is used, this is equal to the time used 272 * in the initial transient algorithm, before the equation 273 * system is solved directly. 274 */ 275 void solvePseudoSteadyStateProblem(int ifuncOverride = -1, 276 doublereal timeScaleOverride = 1.0); 277 278 void setIOFlag(int ioFlag); 279 280 //! Update the standard state chemical potentials and species equilibrium 281 //! constant entries 282 /*! 283 * Virtual because it is overridden when dealing with experimental open 284 * circuit voltage overrides 285 */ 286 virtual void updateMu0(); 287 288 //! Update the equilibrium constants and stored electrochemical potentials 289 //! in molar units for all reversible reactions and for all species. 290 /*! 291 * Irreversible reactions have their equilibrium constant set 292 * to zero. For reactions involving charged species the equilibrium 293 * constant is adjusted according to the electrostatic potential. 294 */ 295 void updateKc(); 296 297 //! Apply modifications for the forward reaction rate for interfacial charge 298 //! transfer reactions 299 /*! 300 * For reactions that transfer charge across a potential difference, 301 * the activation energies are modified by the potential difference. 302 * (see, for example, ...). This method applies this correction. 303 * 304 * @param kfwd Vector of forward reaction rate constants on which to have 305 * the voltage correction applied 306 */ 307 void applyVoltageKfwdCorrection(doublereal* const kfwd); 308 309 //! When an electrode reaction rate is optionally specified in terms of its 310 //! exchange current density, adjust kfwd to the standard reaction rate 311 //! constant form and units. When the BV reaction types are used, keep the 312 //! exchange current density form. 313 /*! 314 * For a reaction rate constant that was given in units of Amps/m2 315 * (exchange current density formulation with iECDFormulation == true), 316 * convert the rate to kmoles/m2/s. 317 * 318 * For a reaction rate constant that was given in units of kmol/m2/sec when 319 * the reaction type is a Butler-Volmer form, convert it to exchange 320 * current density form (amps/m2). 321 * 322 * @param kfwd Vector of forward reaction rate constants, given in either 323 * normal form or in exchange current density form. 324 */ 325 void convertExchangeCurrentDensityFormulation(doublereal* const kfwd); 326 327 //! Set the existence of a phase in the reaction object 328 /*! 329 * Tell the kinetics object whether a phase in the object exists. This is 330 * actually an extrinsic specification that must be carried out on top of 331 * the intrinsic calculation of the reaction rate. The routine will also 332 * flip the IsStable boolean within the kinetics object as well. 333 * 334 * @param iphase Index of the phase. This is the order within the 335 * internal thermo vector object 336 * @param exists Boolean indicating whether the phase exists or not 337 */ 338 void setPhaseExistence(const size_t iphase, const int exists); 339 340 //! Set the stability of a phase in the reaction object 341 /*! 342 * Tell the kinetics object whether a phase in the object is stable. 343 * Species in an unstable phase will not be allowed to have a positive 344 * rate of formation from this kinetics object. This is actually an 345 * extrinsic specification that must be carried out on top of the 346 * intrinsic calculation of the reaction rate. 347 * 348 * While conceptually not needed since kinetics is consistent with thermo 349 * when taken as a whole, in practice it has found to be very useful to 350 * turn off the creation of phases which shouldn't be forming. Typically 351 * this can reduce the oscillations in phase formation and destruction 352 * which are observed. 353 * 354 * @param iphase Index of the phase. This is the order within the 355 * internal thermo vector object 356 * @param isStable Flag indicating whether the phase is stable or not 357 */ 358 void setPhaseStability(const size_t iphase, const int isStable); 359 360 //! Gets the phase existence int for the ith phase 361 /*! 362 * @param iphase Phase Id 363 * @return The int specifying whether the kinetics object thinks the phase 364 * exists or not. If it exists, then species in that phase can be 365 * a reactant in reactions. 366 */ 367 int phaseExistence(const size_t iphase) const; 368 369 //! Gets the phase stability int for the ith phase 370 /*! 371 * @param iphase Phase Id 372 * @return The int specifying whether the kinetics object thinks the phase 373 * is stable with nonzero mole numbers. If it stable, then the 374 * kinetics object will allow for rates of production of of 375 * species in that phase that are positive. 376 */ 377 int phaseStability(const size_t iphase) const; 378 379 protected: 380 //! Build a SurfaceArrhenius object from a Reaction, taking into account 381 //! the possible sticking coefficient form and coverage dependencies 382 //! @param i Reaction number 383 //! @param r Reaction object containing rate coefficient parameters 384 //! @param replace True if replacing an existing reaction 385 SurfaceArrhenius buildSurfaceArrhenius(size_t i, InterfaceReaction& r, 386 bool replace); 387 388 //! Build a BMSurfaceArrhenius object from a Reaction, taking into account 389 //! the possible sticking coefficient form and coverage dependencies 390 //! @param i Reaction number 391 //! @param r Reaction object containing rate coefficient parameters 392 //! @param replace True if replacing an existing reaction 393 //! @todo This function duplicated most of the code from buildSurfaceArrhenius 394 //! to return a slightly different reaction rate class and could be refactored in the 395 //! future. 396 BMSurfaceArrhenius buildBMSurfaceArrhenius(size_t i, BlowersMaselInterfaceReaction& r, 397 bool replace); 398 399 //! Temporary work vector of length m_kk 400 vector_fp m_grt; 401 402 //! List of reactions numbers which are reversible reactions 403 /*! 404 * This is a vector of reaction numbers. Each reaction in the list is 405 * reversible. Length = number of reversible reactions 406 */ 407 std::vector<size_t> m_revindex; 408 409 //! Templated class containing the vector of reactions for this interface 410 /*! 411 * The templated class is described in RateCoeffMgr.h 412 * The class SurfaceArrhenius is described in RxnRates.h 413 */ 414 Rate1<SurfaceArrhenius> m_rates; 415 416 //! Templated class containing the vector of surface Blowers Masel reactions for this interface 417 /*! 418 * The templated class is described in RateCoeffMgr.h 419 * The class BMSurfaceArrhenius is described in RxnRates.h 420 */ 421 Rate1<BMSurfaceArrhenius> m_blowers_masel_rates; 422 423 bool m_redo_rates; 424 425 //! Vector of irreversible reaction numbers 426 /*! 427 * vector containing the reaction numbers of irreversible reactions. 428 */ 429 std::vector<size_t> m_irrev; 430 431 //! Array of concentrations for each species in the kinetics mechanism 432 /*! 433 * An array of generalized concentrations \f$ C_k \f$ that are defined 434 * such that \f$ a_k = C_k / C^0_k, \f$ where \f$ C^0_k \f$ is a standard 435 * concentration/ These generalized concentrations are used by this 436 * kinetics manager class to compute the forward and reverse rates of 437 * elementary reactions. The "units" for the concentrations of each phase 438 * depend upon the implementation of kinetics within that phase. The order 439 * of the species within the vector is based on the order of listed 440 * ThermoPhase objects in the class, and the order of the species within 441 * each ThermoPhase class. 442 */ 443 vector_fp m_conc; 444 445 //! Array of activity concentrations for each species in the kinetics object 446 /*! 447 * An array of activity concentrations \f$ Ca_k \f$ that are defined 448 * such that \f$ a_k = Ca_k / C^0_k, \f$ where \f$ C^0_k \f$ is a standard 449 * concentration. These activity concentrations are used by this 450 * kinetics manager class to compute the forward and reverse rates of 451 * elementary reactions. The "units" for the concentrations of each phase 452 * depend upon the implementation of kinetics within that phase. The order 453 * of the species within the vector is based on the order of listed 454 * ThermoPhase objects in the class, and the order of the species within 455 * each ThermoPhase class. 456 */ 457 vector_fp m_actConc; 458 459 //! Vector of standard state chemical potentials for all species 460 /*! 461 * This vector contains a temporary vector of standard state chemical 462 * potentials for all of the species in the kinetics object 463 * 464 * Length = m_kk. Units = J/kmol. 465 */ 466 vector_fp m_mu0; 467 468 //! Vector of chemical potentials for all species 469 /*! 470 * This vector contains a vector of chemical potentials for all of the 471 * species in the kinetics object 472 * 473 * Length = m_kk. Units = J/kmol. 474 */ 475 vector_fp m_mu; 476 477 //! Vector of standard state electrochemical potentials modified by a 478 //! standard concentration term. 479 /*! 480 * This vector contains a temporary vector of standard state electrochemical 481 * potentials + RTln(Cs) for all of the species in the kinetics object 482 * 483 * In order to get the units correct for the concentration equilibrium 484 * constant, each species needs to have an RT ln(Cs) added to its 485 * contribution to the equilibrium constant Cs is the standard concentration 486 * for the species. Frequently, for solid species, Cs is equal to 1. 487 * However, for gases Cs is P/RT. Length = m_kk. Units = J/kmol. 488 */ 489 vector_fp m_mu0_Kc; 490 491 //! Vector of phase electric potentials 492 /*! 493 * Temporary vector containing the potential of each phase in the kinetics 494 * object. length = number of phases. Units = Volts. 495 */ 496 vector_fp m_phi; 497 498 //! Vector of potential energies due to Voltages 499 /*! 500 * Length is the number of species in kinetics mech. It's used to store the 501 * potential energy due to the voltage. 502 */ 503 vector_fp m_pot; 504 505 //! Storage for the net electric energy change due to reaction. 506 /*! 507 * Length is number of reactions. It's used to store the net electric 508 * potential energy change due to the reaction. 509 * 510 * deltaElectricEnergy_[jrxn] = sum_i ( F V_i z_i nu_ij) 511 */ 512 vector_fp deltaElectricEnergy_; 513 514 //! Pointer to the single surface phase 515 SurfPhase* m_surf; 516 517 //! Pointer to the Implicit surface chemistry object 518 /*! 519 * Note this object is owned by this InterfaceKinetics object. It may only 520 * be used to solve this single InterfaceKinetics object's surface problem 521 * uncoupled from other surface phases. 522 */ 523 ImplicitSurfChem* m_integrator; 524 525 //! Electrochemical transfer coefficient for the forward direction 526 /*! 527 * Electrochemical transfer coefficient for all reactions that have 528 * transfer reactions the reaction is given by m_ctrxn[i] 529 */ 530 vector_fp m_beta; 531 532 //! Vector of reaction indexes specifying the id of the charge transfer 533 //! reactions in the mechanism 534 /*! 535 * Vector of reaction indices which involve charge transfers. This provides 536 * an index into the m_beta array. 537 * 538 * irxn = m_ctrxn[i] 539 */ 540 std::vector<size_t> m_ctrxn; 541 542 //! Vector of booleans indicating whether the charge transfer reaction rate constant 543 //! is described by an exchange current density rate constant expression 544 /*! 545 * Length is equal to the number of reactions with charge transfer coefficients, m_ctrxn[] 546 * 547 * m_ctrxn_ecdf[irxn] = 0 This means that the rate coefficient calculator will calculate 548 * the rate constant as a chemical forward rate constant, a standard format. 549 * m_ctrxn_ecdf[irxn] = 1 this means that the rate coefficient calculator will calculate 550 * the rate constant as an exchange current density rate constant expression. 551 */ 552 vector_int m_ctrxn_ecdf; 553 554 //! Vector of standard concentrations 555 /*! 556 * Length number of kinetic species 557 * units depend on the definition of the standard concentration within each phase 558 */ 559 vector_fp m_StandardConc; 560 561 //! Vector of delta G^0, the standard state Gibbs free energies for each reaction 562 /*! 563 * Length is the number of reactions 564 * units are Joule kmol-1 565 */ 566 vector_fp m_deltaG0; 567 568 //! Vector of deltaG[] of reaction, the delta Gibbs free energies for each reaction 569 /*! 570 * Length is the number of reactions 571 * units are Joule kmol-1 572 */ 573 vector_fp m_deltaG; 574 575 //! Vector of the products of the standard concentrations of the reactants 576 /*! 577 * Units vary wrt what the units of the standard concentrations are 578 * Length = number of reactions. 579 */ 580 vector_fp m_ProdStanConcReac; 581 582 bool m_ROP_ok; 583 584 //! Current temperature of the data 585 doublereal m_temp; 586 587 //! Current log of the temperature 588 doublereal m_logtemp; 589 590 //! Boolean flag indicating whether any reaction in the mechanism 591 //! has a coverage dependent forward reaction rate 592 /*! 593 * If this is true, then the coverage dependence is multiplied into 594 * the forward reaction rates constant 595 */ 596 bool m_has_coverage_dependence; 597 598 //! Boolean flag indicating whether any reaction in the mechanism 599 //! has a beta electrochemical parameter. 600 /*! 601 * If this is true, the Butler-Volmer correction is applied 602 * to the forward reaction rate for those reactions. 603 * 604 * fac = exp ( - beta * (delta_phi)) 605 */ 606 bool m_has_electrochem_rxns; 607 608 //! Boolean flag indicating whether any reaction in the mechanism 609 //! is described by an exchange current density expression 610 /*! 611 * If this is true, the standard state Gibbs free energy of the reaction 612 * and the product of the reactant standard concentrations must be 613 * precalculated in order to calculate the rate constant. 614 */ 615 bool m_has_exchange_current_density_formulation; 616 617 //! Int flag to indicate that some phases in the kinetics mechanism are 618 //! non-existent. 619 /*! 620 * We change the ROP vectors to make sure that non-existent phases are 621 * treated correctly in the kinetics operator. The value of this is equal 622 * to the number of phases which don't exist. 623 */ 624 int m_phaseExistsCheck; 625 626 //! Vector of booleans indicating whether phases exist or not 627 /*! 628 * Vector of booleans indicating whether a phase exists or not. We use this 629 * to set the ROP's so that unphysical things don't happen. For example, a 630 * reaction can't go in the forwards direction if a phase in which a 631 * reactant is present doesn't exist. Because InterfaceKinetics deals with 632 * intrinsic quantities only normally, nowhere else is this extrinsic 633 * concept introduced except here. 634 * 635 * length = number of phases in the object. By default all phases exist. 636 */ 637 std::vector<bool> m_phaseExists; 638 639 //! Vector of int indicating whether phases are stable or not 640 /*! 641 * Vector of booleans indicating whether a phase is stable or not under 642 * the current conditions. We use this to set the ROP's so that 643 * unphysical things don't happen. 644 * 645 * length = number of phases in the object. By default all phases are stable. 646 */ 647 vector_int m_phaseIsStable; 648 649 //! Vector of vector of booleans indicating whether a phase participates in 650 //! a reaction as a reactant 651 /*! 652 * m_rxnPhaseIsReactant[j][p] indicates whether a species in phase p 653 * participates in reaction j as a reactant. 654 */ 655 std::vector<std::vector<bool> > m_rxnPhaseIsReactant; 656 657 //! Vector of vector of booleans indicating whether a phase participates in a 658 //! reaction as a product 659 /*! 660 * m_rxnPhaseIsReactant[j][p] indicates whether a species in phase p 661 * participates in reaction j as a product. 662 */ 663 std::vector<std::vector<bool> > m_rxnPhaseIsProduct; 664 665 //! Values used for converting sticking coefficients into rate constants 666 struct StickData { 667 size_t index; //!< index of the sticking reaction in the full reaction list 668 double order; //!< exponent applied to site density term 669 double multiplier; //!< multiplicative factor in rate expression 670 bool use_motz_wise; //!< 'true' if Motz & Wise correction is being used 671 }; 672 673 //! Data for sticking reactions 674 std::vector<StickData> m_stickingData; 675 676 void applyStickingCorrection(double T, double* kf); 677 678 int m_ioFlag; 679 680 //! Number of dimensions of reacting phase (2 for InterfaceKinetics, 1 for 681 //! EdgeKinetics) 682 size_t m_nDim; 683 }; 684 685 } 686 687 #endif 688