diff --git a/Cantera/src/kinetics/InterfaceKinetics.cpp b/Cantera/src/kinetics/InterfaceKinetics.cpp index 446241019..db03c7cdc 100644 --- a/Cantera/src/kinetics/InterfaceKinetics.cpp +++ b/Cantera/src/kinetics/InterfaceKinetics.cpp @@ -153,6 +153,26 @@ namespace Cantera { return *this; } + //==================================================================================================================== + // Return the ID of the kinetics object + int InterfaceKinetics::ID() const { + return cInterfaceKinetics; + } + //==================================================================================================================== + int InterfaceKinetics::type() const { + return cInterfaceKinetics; + } + //==================================================================================================================== + // Set the electric potential in the nth phase + /* + * @param n phase Index in this kinetics object. + * @param V Electric potential (volts) + */ + void InterfaceKinetics::setElectricPotential(int n, doublereal V) { + thermo(n).setElectricPotential(V); + m_redo_rates = true; + } + //==================================================================================================================== // Duplication routine for objects which inherit from Kinetics /* @@ -547,7 +567,7 @@ namespace Cantera { multiply_each(kfwd, kfwd + nReactions(), m_perturb.begin()); } - + //==================================================================================================================== /** * Update the rates of progress of the reactions in the reaciton @@ -567,12 +587,12 @@ namespace Cantera { multiply_each(krev, krev + nReactions(), rkc.begin()); } } - + //==================================================================================================================== void InterfaceKinetics::getActivationEnergies(doublereal *E) { copy(m_E.begin(), m_E.end(), E); } - + //==================================================================================================================== /** * Update the rates of progress of the reactions in the reaction * mechanism. This routine operates on internal data. diff --git a/Cantera/src/kinetics/InterfaceKinetics.h b/Cantera/src/kinetics/InterfaceKinetics.h index 6f327dbfe..b569afc7f 100644 --- a/Cantera/src/kinetics/InterfaceKinetics.h +++ b/Cantera/src/kinetics/InterfaceKinetics.h @@ -127,20 +127,18 @@ namespace Cantera { */ virtual Kinetics *duplMyselfAsKinetics() const; + //! Return the ID of the kinetics object + virtual int ID() const; - virtual int ID() const { return cInterfaceKinetics; } - virtual int type() const { return cInterfaceKinetics; } + //! Retunr the type of the kinetics object + virtual int type() const; - //! Set the electric potential in the nth phase - /*! + /*! * @param n phase Index in this kinetics object. * @param V Electric potential (volts) */ - void setElectricPotential(int n, doublereal V) { - thermo(n).setElectricPotential(V); - m_redo_rates = true; - } + void setElectricPotential(int n, doublereal V); ///