Chaste Commit::ca8ccdedf819b6e02855bc0e8e6f50bdecbc5208
|
#include <SteadyStateRunner.hpp>
Public Member Functions | |
SteadyStateRunner (boost::shared_ptr< AbstractCvodeCell > pModel, bool twoPaces=false) | |
Public Member Functions inherited from AbstractSteadyStateRunner | |
AbstractSteadyStateRunner (boost::shared_ptr< AbstractCvodeCell > pModel) | |
virtual | ~AbstractSteadyStateRunner () |
bool | RunToSteadyState () |
void | SuppressOutput (bool suppress=true) |
unsigned | GetNumEvaluations () |
void | SetMaxNumPaces (unsigned numPaces) |
Protected Member Functions | |
virtual void | RunToSteadyStateImplementation () |
Private Attributes | |
bool | mTwoPaceScan |
Additional Inherited Members | |
Protected Attributes inherited from AbstractSteadyStateRunner | |
boost::shared_ptr< AbstractCvodeCell > | mpModel |
unsigned | mNumEvaluations |
unsigned | mMaxNumPaces |
bool | mSuppressOutput |
This class is to get a cell model to (approximately) steady state.
It does it by simply pacing and looking for a small change in the norm of the state variables between subsequent paces.
Note - because it looks for a small change in state variables between solves this method requires quite an accurate CVODE solution to do this efficiently (otherwise you just have to wait to get lucky on subsequent solves).
So although running with stricter tolerances takes longer per pace it can mean you detect a steady state in up to 3x fewer paces, so it is recommended to use a model with SetTolerances(1e-6, 1e-8); or stricter.
Definition at line 58 of file SteadyStateRunner.hpp.
|
inline |
Constructor of a helper class for getting action potential models to steady state
pModel | The cell model to run to steady state. |
twoPaces | Whether to run two paces at once, for detection of steady state alternans. |
Definition at line 80 of file SteadyStateRunner.hpp.
|
protectedvirtual |
Run the cell model to steady state
Here we don't do anything clever - we just gradually drift to the steady state, defined by < 1e-6 change in the norm of state variables between 1 (or 2 - see mTwoPaceScan) beats.
Implements AbstractSteadyStateRunner.
Definition at line 41 of file SteadyStateRunner.cpp.
References CopyToStdVector(), AbstractSteadyStateRunner::mMaxNumPaces, AbstractSteadyStateRunner::mNumEvaluations, AbstractSteadyStateRunner::mpModel, and mTwoPaceScan.
|
private |
whether we should do two paces at once (should detect steady alternans as well as single paces)
Definition at line 62 of file SteadyStateRunner.hpp.
Referenced by RunToSteadyStateImplementation().