8 #ifndef CT_CVODESWRAPPER_H 9 #define CT_CVODESWRAPPER_H 14 #include "sundials/sundials_nvector.h" 46 virtual void setTolerances(
double reltol,
size_t n,
double* abstol);
51 virtual void reinitialize(
double t0,
FuncEval& func);
53 virtual doublereal
step(
double tout);
57 return static_cast<int>(m_neq);
59 virtual int nEvals()
const;
67 virtual void setMaxSteps(
int nmax);
69 virtual void setBandwidth(
int N_Upper,
int N_Lower) {
73 virtual int nSensParams() {
74 return static_cast<int>(m_np);
76 virtual double sensitivity(
size_t k,
size_t p);
93 void sensInit(
double t0,
FuncEval& func);
100 N_Vector m_y, m_abstol;
108 double m_reltolsens, m_abstolsens;
110 double m_hmax, m_hmin;
112 int m_maxErrTestFails;
115 int m_mupper, m_mlower;
virtual void setProblemType(int probtype)
Set the problem type.
void applyOptions()
Applies user-specified options to the underlying CVODES solver.
Wrapper class for 'cvodes' integrator from LLNL.
virtual int nEvals() const
The number of function evaluations.
Exception thrown when a CVODES error is encountered.
void warn_deprecated(const std::string &method, const std::string &extra)
Print a warning indicating that method is deprecated.
virtual void setMaxStepSize(double hmax)
Set the maximum step size.
virtual void setMethod(MethodType t)
Set the solution method.
CVodesIntegrator()
Constructor.
virtual void setMinStepSize(double hmin)
Set the minimum step size.
virtual void setIterator(IterType t)
Set the linear iterator.
virtual double * solution()
The current value of the solution of the system of equations.
virtual void integrate(double tout)
Integrate the system of equations.
Abstract base class for ODE system integrators.
virtual void setSensitivityTolerances(double reltol, double abstol)
Set the sensitivity error tolerances.
virtual std::string getErrorInfo(int N)
Returns a string listing the weighted error estimates associated with each solution component...
Base class for exceptions thrown by Cantera classes.
virtual void setMaxOrder(int n)
Set the maximum integration order that will be used.
CanteraError()
Protected default constructor discourages throwing errors containing no information.
virtual int nEquations() const
The number of equations.
virtual void setTolerances(double reltol, size_t n, double *abstol)
Set error tolerances.
virtual void setMaxErrTestFails(int n)
Set the maximum permissible number of error test failures.
bool m_sens_ok
Indicates whether the sensitivities stored in m_yS have been updated for at the current integrator ti...
IterType
Specifies the method used for iteration.
virtual doublereal step(double tout)
Integrate the system of equations.
std::string m_error_message
Error message information provide by CVodes.
Virtual base class for ODE right-hand-side function evaluators.
Namespace for the Cantera kernel.
Definitions for the classes that are thrown when Cantera experiences an error condition (also contain...
MethodType
Specifies the method used to integrate the system of equations.
double m_time
The current integrator time.
virtual void initialize(double t0, FuncEval &func)
Initialize the integrator for a new problem.