33 if (m_thermo ==
nullptr) {
35 "Specified kinetics manager does not represent a surface "
36 "kinetics mechanism.");
49 copy(cov, cov + m_cov.size(), m_cov.begin());
66 copy(m_cov.begin(), m_cov.end(), cov);
78 throw CanteraError(
"ReactorSurface::addSensitivityReaction",
79 "Reaction number out of range ({})", i);
82 m_kinetics->
reaction(i)->equation(), 1.0, 1.0);
83 m_params.emplace_back(
89 for (
auto& p : m_params) {
97 for (
auto& p : m_params) {
Base class for kinetics managers and also contains the kineticsmgr module documentation (see Kinetics...
Header file for class ReactorSurface.
Header for a simple thermodynamics model of a surface phase derived from ThermoPhase,...
Base class for exceptions thrown by Cantera classes.
Public interface for kinetics managers.
double multiplier(size_t i) const
The current value of the multiplier for reaction i.
ThermoPhase & thermo(size_t n=0)
This method returns a reference to the nth ThermoPhase object defined in this kinetics mechanism.
shared_ptr< Reaction > reaction(size_t i)
Return the Reaction object for reaction i.
size_t nReactions() const
Number of reactions in the reaction mechanism.
virtual void setMultiplier(size_t i, double f)
Set the multiplier for reaction i to f.
size_t nSpecies() const
Returns the number of species in the phase.
virtual void setTemperature(double temp)
Set the internally stored temperature of the phase (K).
Base class for stirred reactors.
double temperature() const
Returns the current temperature (K) of the reactor's contents.
ReactorNet & network()
The ReactorNet that this reactor belongs to.
size_t registerSensitivityParameter(const string &name, double value, double scale)
Used by Reactor and Wall objects to register the addition of sensitivity parameters so that the React...
double area() const
Returns the surface area [m^2].
void setReactor(ReactorBase *reactor)
Set the reactor that this Surface interacts with.
void setSensitivityParameters(const double *params)
Set reaction rate multipliers.
void getCoverages(double *cov) const
Get the surface coverages.
void setArea(double a)
Set the surface area [m^2].
void resetSensitivityParameters()
Set reaction rate multipliers back to their initial values.
void syncState()
Set the coverages and temperature in the surface phase object to the values for this surface.
void setCoverages(const double *cov)
Set the surface coverages.
void setKinetics(Kinetics *kin)
Set the InterfaceKinetics object for this surface.
void addSensitivityReaction(size_t i)
Enable calculation of sensitivities with respect to the rate constant for reaction i.
A simple thermodynamic model for a surface phase, assuming an ideal solution model.
void setCoveragesNoNorm(const double *theta)
Set the surface site fractions to a specified state.
void getCoverages(double *theta) const
Return a vector of surface coverages.
void setCoveragesByName(const string &cov)
Set the coverages from a string of colon-separated name:value pairs.
Namespace for the Cantera kernel.
map< string, double > Composition
Map from string names to doubles.