Chaste
Release::2017.1
|
#include <AbstractOdeSrnModel.hpp>
Public Member Functions | |
AbstractOdeSrnModel (unsigned stateSize, boost::shared_ptr< AbstractCellCycleModelOdeSolver > pOdeSolver=boost::shared_ptr< AbstractCellCycleModelOdeSolver >()) | |
virtual | ~AbstractOdeSrnModel () |
virtual void | SimulateToCurrentTime () |
virtual void | ResetForDivision () |
void | SetInitialConditions (std::vector< double > initialConditions) |
virtual void | OutputSrnModelParameters (out_stream &rParamsFile)=0 |
Public Member Functions inherited from AbstractSrnModel | |
AbstractSrnModel () | |
virtual | ~AbstractSrnModel () |
void | SetCell (CellPtr pCell) |
virtual void | Initialise () |
virtual void | InitialiseDaughterCell () |
CellPtr | GetCell () |
void | SetSimulatedToTime (double simulatedToTime) |
double | GetSimulatedToTime () const |
virtual AbstractSrnModel * | CreateSrnModel ()=0 |
void | OutputSrnModelInfo (out_stream &rParamsFile) |
Public Member Functions inherited from Identifiable | |
virtual | ~Identifiable () |
std::string | GetIdentifier () const |
Public Member Functions inherited from CellCycleModelOdeHandler | |
CellCycleModelOdeHandler (double lastTime=SimulationTime::Instance() ->GetTime(), boost::shared_ptr< AbstractCellCycleModelOdeSolver > pOdeSolver=boost::shared_ptr< AbstractCellCycleModelOdeSolver >()) | |
virtual | ~CellCycleModelOdeHandler () |
AbstractOdeSystem * | GetOdeSystem () const |
void | SetOdeSystem (AbstractOdeSystem *pOdeSystem) |
const boost::shared_ptr< AbstractCellCycleModelOdeSolver > | GetOdeSolver () const |
void | SetLastTime (double lastTime) |
double | GetDt () |
void | SetDt (double timeStep) |
void | SetStateVariables (const std::vector< double > &rStateVariables) |
std::vector< double > | GetProteinConcentrations () const |
void | SetProteinConcentrationsForTestsOnly (double lastTime, std::vector< double > proteinConcentrations) |
Protected Member Functions | |
void | Initialise (AbstractOdeSystem *pOdeSystem) |
AbstractOdeSrnModel (const AbstractOdeSrnModel &rModel) | |
Protected Member Functions inherited from AbstractSrnModel | |
AbstractSrnModel (const AbstractSrnModel &rModel) | |
Protected Member Functions inherited from CellCycleModelOdeHandler | |
CellCycleModelOdeHandler (const CellCycleModelOdeHandler &rHandler) | |
bool | SolveOdeToTime (double currentTime) |
virtual void | AdjustOdeParameters (double currentTime) |
Protected Attributes | |
std::vector< double > | mInitialConditions |
unsigned | mStateSize |
Protected Attributes inherited from AbstractSrnModel | |
CellPtr | mpCell |
double | mSimulatedToTime |
Protected Attributes inherited from CellCycleModelOdeHandler | |
double | mDt |
AbstractOdeSystem * | mpOdeSystem |
boost::shared_ptr< AbstractCellCycleModelOdeSolver > | mpOdeSolver |
double | mLastTime |
bool | mFinishedRunningOdes |
Private Member Functions | |
template<class Archive > | |
void | serialize (Archive &archive, const unsigned int version) |
Friends | |
class | boost::serialization::access |
This class contains the abstract code for an ODE sub-cellular reaction network (SRN) model
Definition at line 56 of file AbstractOdeSrnModel.hpp.
|
protected |
Protected copy-constructor for use by CreateSrnModel(). The only way for external code to create a copy of a SRN model is by calling that method, to ensure that a model of the correct subclass is created. This copy-constructor helps subclasses to ensure that all member variables are correctly copied when this happens.
This method is called by child classes to set member variables for a daughter cell upon cell division. Note that the parent SRN model will have had ResetForDivision() called just before CreateSrnModel() is called, so performing an exact copy of the parent is suitable behaviour. Any daughter-cell-specific initialisation can be done in InitialiseDaughterCell().
rModel | the SRN model to copy. |
Definition at line 45 of file AbstractOdeSrnModel.cpp.
AbstractOdeSrnModel::AbstractOdeSrnModel | ( | unsigned | stateSize, |
boost::shared_ptr< AbstractCellCycleModelOdeSolver > | pOdeSolver = boost::shared_ptr<AbstractCellCycleModelOdeSolver>() |
||
) |
Create an AbstractOdeSrnModel.
stateSize | The number of state variables in the ODE system. |
pOdeSolver | An optional pointer to a cell-cycle model ODE solver object (allows the use of different ODE solvers). |
Definition at line 38 of file AbstractOdeSrnModel.cpp.
|
virtual |
Destructor.
Definition at line 67 of file AbstractOdeSrnModel.cpp.
|
protected |
Overridden Initialise() method, which here sets up the ODE system.
Note we bring virtual functions from AbstractSrnModel into derived namespace so overloading virtual works.
pOdeSystem | pointer to an ODE system |
Definition at line 97 of file AbstractOdeSrnModel.cpp.
References AbstractParameterisedSystem< VECTOR >::GetInitialConditions(), mInitialConditions, AbstractSrnModel::mpCell, CellCycleModelOdeHandler::mpOdeSystem, AbstractSrnModel::mSimulatedToTime, CellCycleModelOdeHandler::SetLastTime(), and AbstractParameterisedSystem< VECTOR >::SetStateVariables().
|
pure virtual |
Outputs SRN model parameters to file. Virtual void so needs to be specified in child classes.
rParamsFile | the file stream to which the parameters are output |
Reimplemented from AbstractSrnModel.
Implemented in DeltaNotchSrnModel, and Goldbeter1991SrnModel.
Definition at line 128 of file AbstractOdeSrnModel.cpp.
References CHASTE_CLASS_EXPORT, and AbstractSrnModel::OutputSrnModelParameters().
Referenced by Goldbeter1991SrnModel::OutputSrnModelParameters(), and DeltaNotchSrnModel::OutputSrnModelParameters().
|
virtual |
For a naturally cycling model this does not need to be overridden in the subclasses. But most models should override this function and then call AbstractSrnModel::ResetForDivision() from inside their version.
Reimplemented from AbstractSrnModel.
Definition at line 115 of file AbstractOdeSrnModel.cpp.
References CellCycleModelOdeHandler::mFinishedRunningOdes, CellCycleModelOdeHandler::mLastTime, AbstractSrnModel::mSimulatedToTime, and AbstractSrnModel::ResetForDivision().
|
inlineprivate |
Archive the SRN model and member variables.
archive | the archive |
version | the current version of this class |
Definition at line 69 of file AbstractOdeSrnModel.hpp.
References mInitialConditions, and mStateSize.
void AbstractOdeSrnModel::SetInitialConditions | ( | std::vector< double > | initialConditions | ) |
Set mInitialConditions. Used in CreateSrnModel().
initialConditions | the new value of mInitialConditions |
Definition at line 122 of file AbstractOdeSrnModel.cpp.
References mInitialConditions, and mStateSize.
|
virtual |
Here we solve the ODEs associated with the SRN.
Implements AbstractSrnModel.
Reimplemented in Goldbeter1991SrnModel, and DeltaNotchSrnModel.
Definition at line 71 of file AbstractOdeSrnModel.cpp.
References SimulationTime::GetTime(), SimulationTime::Instance(), CellCycleModelOdeHandler::mFinishedRunningOdes, CellCycleModelOdeHandler::mLastTime, CellCycleModelOdeHandler::mpOdeSystem, AbstractSrnModel::SetSimulatedToTime(), and CellCycleModelOdeHandler::SolveOdeToTime().
Referenced by DeltaNotchSrnModel::SimulateToCurrentTime(), and Goldbeter1991SrnModel::SimulateToCurrentTime().
|
friend |
Needed for serialization.
Definition at line 61 of file AbstractOdeSrnModel.hpp.
|
protected |
The initial condition for the ODE state variables.
Definition at line 82 of file AbstractOdeSrnModel.hpp.
Referenced by Initialise(), serialize(), and SetInitialConditions().
|
protected |
The number of state variables.
Definition at line 87 of file AbstractOdeSrnModel.hpp.
Referenced by serialize(), and SetInitialConditions().