11 #ifndef CT_IMPSURFCHEM_H 12 #define CT_IMPSURFCHEM_H 82 void integrate(doublereal t0, doublereal t1);
114 doublereal timeScaleOverride = 1.0);
131 virtual void eval(doublereal t, doublereal* y, doublereal* ydot,
145 size_t leny, doublereal* y);
153 virtual void getState(doublereal* y);
197 int checkMatch(std::vector<ThermoPhase*> m_vec,
ThermoPhase* thPtr);
199 void setIOFlag(
int ioFlag) {
230 std::vector<size_t> m_specStartIndex;
238 size_t m_numTotalBulkSpecies;
239 size_t m_numTotalSpecies;
241 std::vector<vector_int> pLocVec;
244 doublereal m_atol, m_rtol;
std::vector< size_t > m_surfindex
index of the surface phase in each InterfaceKinetics object
int m_mediumSpeciesStart
Index into the species vector of the kinetics manager, pointing to the first species from the surroun...
virtual void getState(doublereal *y)
Get the current state of the solution vector.
std::unique_ptr< Integrator > m_integ
Pointer to the CVODE integrator.
void solvePseudoSteadyStateProblem(int ifuncOverride=-1, doublereal timeScaleOverride=1.0)
Solve for the pseudo steady-state of the surface problem.
std::vector< ThermoPhase * > m_bulkPhases
Vector of pointers to bulk phases.
std::unique_ptr< solveSP > m_surfSolver
Pointer to the helper method, Placid, which solves the surface problem.
doublereal m_maxstep
max step size
std::vector< size_t > m_nsp
Vector of number of species in each Surface Phase.
friend class solveSS
We make the solveSS class a friend because we need to access all of the above information directly...
int m_surfSpeciesStart
Index into the species vector of the kinetics manager, pointing to the first species from the surface...
virtual size_t neq()
Return the number of equations.
std::vector< SurfPhase * > m_surf
vector of pointers to surface phases.
Base class for a phase with thermodynamic properties.
ImplicitSurfChem(std::vector< InterfaceKinetics *> k)
Constructor for multiple surfaces.
int m_ioFlag
Controls the amount of printing from this routine and underlying routines.
int m_bulkSpeciesStart
Index into the species vector of the kinetics manager, pointing to the first species from the condens...
bool m_commonTempPressForPhases
If true, a common temperature and pressure for all surface and bulk phases associated with the surfac...
virtual void getInitialConditions(doublereal t0, size_t leny, doublereal *y)
Set the initial conditions for the solution vector.
size_t m_nv
Total number of surface species in all surface phases.
virtual void eval(doublereal t, doublereal *y, doublereal *ydot, doublereal *p)
Evaluate the value of ydot[k] at the current conditions.
void integrate0(doublereal t0, doublereal t1)
Integrate from t0 to t1 without reinitializing the integrator.
void setConcSpecies(const doublereal *const vecConcSpecies)
Sets the concentrations within phases that are unknowns in the surface problem.
std::vector< InterfaceKinetics * > & getObjects()
Returns a reference to the vector of pointers to the InterfaceKinetics objects.
void getConcSpecies(doublereal *const vecConcSpecies) const
Advances the surface coverages of the associated set of SurfacePhase objects in time.
virtual void initialize(doublereal t0=0.0)
std::vector< double > vector_fp
Turn on the use of stl vectors for the basic array type within cantera Vector of doubles.
void setCommonState_TP(doublereal TKelvin, doublereal PresPa)
Sets the state variable in all thermodynamic phases (surface and surrounding bulk phases) to the inpu...
void updateState(doublereal *y)
Set the mixture to a state consistent with solution vector y.
Header file for implicit surface problem solver (see Chemical Kinetics and class solveSP).
std::vector< InterfaceKinetics * > m_vecKinPtrs
vector of pointers to InterfaceKinetics objects
Virtual base class for ODE right-hand-side function evaluators.
Namespace for the Cantera kernel.
vector_fp m_concSpecies
Temporary vector - length num species in the Kinetics object.
void integrate(doublereal t0, doublereal t1)
Integrate from t0 to t1. The integrator is reinitialized first.