Go to the documentation of this file.
51 "To be changed after Cantera 2.5. "
52 "Return string instead of magic number; use "
53 "Reactor::typeStr during transition");
67 void insert(shared_ptr<Solution> sol) {
97 virtual size_t neq() {
108 virtual void getState(doublereal* y);
119 virtual void evalEqs(doublereal t, doublereal* y,
120 doublereal* ydot, doublereal* params);
180 virtual size_t speciesIndex(
const std::string& nm)
const;
228 std::vector<SensitivityParameter> m_sensParams;
Kinetics * m_kin
Pointer to the homogeneous Kinetics object that handles the reactions.
Base class for stirred reactors.
virtual void initialize(doublereal t0=0.0)
Initialize the reactor.
virtual double evalSurfaces(double t, double *ydot)
Evaluate terms related to surface reactions.
bool hasAdvanceLimits()
Check whether Reactor object uses advance limits.
virtual void addSensitivitySpeciesEnthalpy(size_t k)
Add a sensitivity parameter associated with the enthalpy formation of species k (in the homogeneous p...
Public interface for kinetics managers.
void insert(G &contents)
Insert something into the reactor.
bool energyEnabled() const
Returns true if solution of the energy equation is enabled.
virtual void syncState()
Set the state of the reactor to correspond to the state of the associated ThermoPhase object.
virtual void getState(doublereal *y)
Get the the current state of the reactor.
std::vector< double > vector_fp
Turn on the use of stl vectors for the basic array type within cantera Vector of doubles.
virtual size_t componentIndex(const std::string &nm) const
Return the index in the solution vector for this reactor of the component named nm.
Class Reactor is a general-purpose class for stirred reactors.
virtual void updateConnected(bool updatePressure)
Update the state information needed by connected reactors and flow devices.
doublereal m_vdot
net rate of volume change from moving walls [m^3/s]
thermo_t & contents()
return a reference to the contents.
virtual void updateSurfaceState(double *y)
Update the state of SurfPhase objects attached to this reactor.
virtual void setEnergy(int eflag=1)
Set the energy equation on or off.
virtual std::string typeStr() const
String indicating the reactor model implemented.
vector_fp m_advancelimits
Advance step limit.
bool chemistryEnabled() const
Returns true if changes in the reactor composition due to chemical reactions are enabled.
void setAdvanceLimit(const std::string &nm, const double limit)
Set individual step size limit for compoment name nm
bool getAdvanceLimits(double *limits)
Retrieve absolute step size limits during advance.
vector_fp m_sdot
Production rates of gas phase species on surfaces [kmol/s].
virtual void setKineticsMgr(Kinetics &kin)
Specify chemical kinetics governing the reactor.
virtual void evalEqs(doublereal t, doublereal *y, doublereal *ydot, doublereal *params)
doublereal m_mass
total mass
virtual void setChemistry(bool cflag=true)
Enable or disable changes in reactor composition due to chemical reactions.
virtual size_t neq()
Number of equations (state variables) for this reactor.
virtual void addSensitivityReaction(size_t rxn)
Add a sensitivity parameter associated with the reaction number rxn (in the homogeneous phase).
virtual size_t nSensParams()
Number of sensitivity parameters associated with this reactor (including walls)
virtual void getSurfaceInitialConditions(double *y)
Get initial conditions for SurfPhase objects attached to this reactor.
virtual void updateState(doublereal *y)
Set the state of the reactor to correspond to the state vector y.
virtual size_t speciesIndex(const std::string &nm) const
Return the index in the solution vector for this reactor of the species named nm, in either the homog...
void setAdvanceLimits(const double *limits)
Set absolute step size limits during advance.
virtual void resetSensitivity(double *params)
Reset the reaction rate multipliers.
virtual void setThermoMgr(thermo_t &thermo)
Specify the mixture contained in the reactor.
virtual std::string componentName(size_t k)
Return the name of the solution component with index i.
virtual void applySensitivity(double *params)
Set reaction rate multipliers based on the sensitivity variables in params.
Namespace for the Cantera kernel.
virtual void evalWalls(double t)
Evaluate terms related to Walls.
vector_fp m_uk
Species molar internal energies.
doublereal m_Q
net heat transfer through walls [W]
vector_fp m_wdot
Species net molar production rates.