Integrator

class Integrator : public rr::Solver

Subclassed by rr::CVODEIntegrator, rr::EulerIntegrator, rr::GillespieIntegrator, rr::RK45Integrator, rr::RK4Integrator

Public Types

enum IntegrationMethod

Values:

enumerator Deterministic
enumerator Stochastic
enumerator Hybrid
enumerator Other

Public Functions

explicit Integrator(ExecutableModel *model)
Integrator()
inline virtual ~Integrator()
virtual IntegrationMethod getIntegrationMethod() const = 0
virtual void syncWithModel(ExecutableModel *m)

Called whenever a new model is loaded to allow integrator to reset internal state.

Author

JKM

virtual void loadConfigSettings()
virtual void loadSBMLSettings(const std::string &filename)
virtual double integrate(double t0, double hstep) = 0
virtual void restart(double t0) = 0
virtual void tweakTolerances()

Fix tolerances for SBML tests.

In order to ensure that the results of the SBML test suite remain valid, this method enforces a lower bound on tolerance values. Sets minimum absolute and relative tolerances to Config::CVODE_MIN_ABSOLUTE and Config::CVODE_MIN_RELATIVE resp.

Author

JKM, WBC, ETS, MTK

virtual void setIndividualTolerance(std::string sid, double value)

Set tolerance for floating species or variables that have a rate rule, will only be used in CVODEIntegrator.

Author

FY

virtual void setConcentrationTolerance(Setting value)

Set tolerance based on concentration of species, will only be used in CVODEIntegrator.

Author

FY

virtual std::vector<double> getConcentrationTolerance()

Get tolerance based on concentration of species, will only be used in CVODEIntegrator.

Author

FY

virtual void setListener(IntegratorListenerPtr) = 0
virtual IntegratorListenerPtr getListener() = 0
virtual std::string toString() const

Return a std::string representation of the solver.

Author

JKM

virtual std::string toRepr() const

Return std::string representation a la Python repr method.

Author

JKM

void setIntegrationStartTime(double time)
Solver() = default
explicit Solver(ExecutableModel *model)
virtual void setValue(const std::string &key, Setting value)

Pull down the setValue from superclass.

We do not need to reimplement this but we make it explicit.

Protected Attributes

double mIntegrationStartTime