Chaste  Release::3.4
NhsContractionModel Class Reference

#include <NhsContractionModel.hpp>

+ Inheritance diagram for NhsContractionModel:
+ Collaboration diagram for NhsContractionModel:

Public Member Functions

 NhsContractionModel ()
 
void SetStretchAndStretchRate (double lambda, double dlambdaDt)
 
void SetInputParameters (ContractionModelInputParameters &rInputParameters)
 
void SetIntracellularCalciumConcentration (double calciumConcentration)
 
double GetCalciumTroponinValue ()
 
void EvaluateYDerivatives (double time, const std::vector< double > &rY, std::vector< double > &rDY)
 
double GetActiveTension ()
 
double GetNextActiveTension ()
 
bool IsStretchDependent ()
 
bool IsStretchRateDependent ()
 
- Public Member Functions inherited from AbstractOdeBasedContractionModel
 AbstractOdeBasedContractionModel (unsigned numStateVariables)
 
virtual void RunDoNotUpdate (double startTime, double endTime, double timeStep)
 
void UpdateStateVariables ()
 
void RunAndUpdate (double startTime, double endTime, double timeStep)
 
- Public Member Functions inherited from AbstractOdeSystem
 AbstractOdeSystem (unsigned numberOfStateVariables)
 
virtual ~AbstractOdeSystem ()
 
virtual bool CalculateStoppingEvent (double time, const std::vector< double > &rY)
 
virtual double CalculateRootFunction (double time, const std::vector< double > &rY)
 
bool GetUseAnalyticJacobian ()
 
const std::vector< double > & rGetConstStateVariables () const
 
- Public Member Functions inherited from AbstractParameterisedSystem< std::vector< double > >
 AbstractParameterisedSystem (unsigned numberOfStateVariables)
 
std::vector< double > & rGetStateVariables ()
 
std::vector< doubleGetStateVariables ()
 
void SetStateVariables (const std::vector< double > &rStateVariables)
 
double GetStateVariable (unsigned index) const
 
double GetStateVariable (const std::string &rName) const
 
void SetStateVariable (unsigned index, double newValue)
 
void SetStateVariable (const std::string &rName, double newValue)
 
virtual void VerifyStateVariables ()
 
void SetDefaultInitialConditions (const std::vector< double > &rInitialConditions)
 
void SetDefaultInitialCondition (unsigned index, double initialCondition)
 
std::vector< doubleGetInitialConditions () const
 
void ResetToInitialConditions ()
 
double GetParameter (unsigned index) const
 
double GetParameter (const std::string &rName) const
 
void SetParameter (const std::string &rName, double value)
 
void SetParameter (unsigned index, double value)
 
double GetAnyVariable (unsigned index, double time=0.0, std::vector< double > *pDerivedQuantities=NULL)
 
double GetAnyVariable (const std::string &rName, double time=0.0, std::vector< double > *pDerivedQuantities=NULL)
 
void SetAnyVariable (unsigned index, double value)
 
void SetAnyVariable (const std::string &rName, double value)
 
virtual std::vector< doubleComputeDerivedQuantities (double time, const std::vector< double > &rState)
 
std::vector< doubleComputeDerivedQuantitiesFromCurrentState (double time)
 
- Public Member Functions inherited from AbstractUntemplatedParameterisedSystem
 AbstractUntemplatedParameterisedSystem (unsigned numberOfStateVariables)
 
virtual ~AbstractUntemplatedParameterisedSystem ()
 
boost::shared_ptr< const
AbstractOdeSystemInformation
GetSystemInformation () const
 
std::string GetSystemName () const
 
unsigned GetNumberOfAttributes () const
 
bool HasAttribute (const std::string &rName) const
 
double GetAttribute (const std::string &rName) const
 
unsigned GetNumberOfStateVariables () const
 
const std::vector< std::string > & rGetStateVariableNames () const
 
const std::vector< std::string > & rGetStateVariableUnits () const
 
unsigned GetStateVariableIndex (const std::string &rName) const
 
bool HasStateVariable (const std::string &rName) const
 
std::string GetStateVariableUnits (unsigned index) const
 
unsigned GetNumberOfParameters () const
 
const std::vector< std::string > & rGetParameterNames () const
 
const std::vector< std::string > & rGetParameterUnits () const
 
unsigned GetParameterIndex (const std::string &rName) const
 
bool HasParameter (const std::string &rName) const
 
std::string GetParameterUnits (unsigned index) const
 
unsigned GetNumberOfDerivedQuantities () const
 
const std::vector< std::string > & rGetDerivedQuantityNames () const
 
const std::vector< std::string > & rGetDerivedQuantityUnits () const
 
unsigned GetDerivedQuantityIndex (const std::string &rName) const
 
bool HasDerivedQuantity (const std::string &rName) const
 
std::string GetDerivedQuantityUnits (unsigned index) const
 
unsigned GetAnyVariableIndex (const std::string &rName) const
 
bool HasAnyVariable (const std::string &rName) const
 
std::string GetAnyVariableUnits (unsigned index) const
 
std::string GetAnyVariableUnits (const std::string &rName) const
 
- Public Member Functions inherited from AbstractContractionModel
 AbstractContractionModel ()
 
virtual ~AbstractContractionModel ()
 
void SetStretch (double stretch)
 

Protected Member Functions

void CalculateCalciumTrop50 ()
 
double CalculateT0 (double z)
 
- Protected Member Functions inherited from AbstractParameterisedSystem< std::vector< double > >
std::string DumpState (const std::string &rMessage)
 
std::string DumpState (const std::string &rMessage, std::vector< double >Y)
 
std::string DumpState (const std::string &rMessage, std::vector< double >Y, double time)
 
void CheckParametersOnLoad (const std::vector< double > &rParameters, const std::vector< std::string > &rParameterNames)
 

Protected Attributes

double mLambda
 
double mDLambdaDt
 
double mCalciumI
 
double mCalciumTrop50
 
double mK1
 
double mK2
 
- Protected Attributes inherited from AbstractOdeBasedContractionModel
std::vector< doublemTemporaryStateVariables
 
double mTime
 
- Protected Attributes inherited from AbstractOdeSystem
bool mUseAnalyticJacobian
 
- Protected Attributes inherited from AbstractParameterisedSystem< std::vector< double > >
std::vector< doublemStateVariables
 
std::vector< doublemParameters
 
- Protected Attributes inherited from AbstractUntemplatedParameterisedSystem
unsigned mNumberOfStateVariables
 
boost::shared_ptr
< AbstractOdeSystemInformation
mpSystemInfo
 

Static Protected Attributes

static const double mKon = 100
 
static const double mKrefoff = 0.2
 
static const double mGamma = 2
 
static const double mCalciumTroponinMax = 0.07
 
static const double mAlphaR1 = 0.002
 
static const double mAlphaR2 = 0.0017
 
static const double mKZ = 0.15
 
static const unsigned mNr = 3u
 
static const double mBeta1 = -4
 
static const double mAlpha0 = 0.008
 
static const unsigned mN = 3u
 
static const double mZp = 0.85
 
static const double mCalcium50ref = 0.00105
 
static const double mTref = 56.2
 
static const double mBeta0 = 4.9
 
static const double mA = 0.35
 
static const double mA1 = -29
 
static const double mA2 = 138
 
static const double mA3 = 129
 
static const double mAlpha1 = 0.03
 
static const double mAlpha2 = 0.130
 
static const double mAlpha3 = 0.625
 

Friends

class TestContractionModels
 

Detailed Description

NHS (Niederer, Hunter, Smith) model of active tension in cardiac cells.

A system of ODEs which determines the active potential, given the intracellular calcium concentration, the stretch (lambda) of the cell, and the stretch rate (dlambda_dt) of the cell.

The state variables are, in order: Calcium_troponin, z, Q1, Q2, Q3

Reference: S.A. Niederer, N.P. Smith, P.J. Hunter, "New developments in a strongly coupled cardiac electro-mechanical model" Europace 7, S118-S127

The active tension is returned in KPa.

Definition at line 56 of file NhsContractionModel.hpp.

Constructor & Destructor Documentation

NhsContractionModel::NhsContractionModel ( )

Constructor. Initialises all state variables to zero, lambda to 1, dlambda_dt to 0 and intracellular calcium concentration to 0

Definition at line 100 of file NhsContractionModel.cpp.

References CalculateCalciumTrop50(), OdeSystemInformation< ODE_SYSTEM >::Instance(), mAlphaR2, mCalciumI, mDLambdaDt, mK1, mK2, mKZ, mLambda, mNr, AbstractUntemplatedParameterisedSystem::mpSystemInfo, mZp, AbstractParameterisedSystem< std::vector< double > >::ResetToInitialConditions(), and SmallPow().

Member Function Documentation

void NhsContractionModel::CalculateCalciumTrop50 ( )
protected

Compute the calcium_trop50 concentration. This is a function of constants and lambda, so only needs to be called in the constructor or when lambda is set

Definition at line 74 of file NhsContractionModel.cpp.

References mBeta0, mBeta1, mCalcium50ref, mCalciumTrop50, mCalciumTroponinMax, mGamma, mKon, mKrefoff, and mLambda.

Referenced by NhsContractionModel(), and SetStretchAndStretchRate().

double NhsContractionModel::CalculateT0 ( double  z)
protected
void NhsContractionModel::EvaluateYDerivatives ( double  time,
const std::vector< double > &  rY,
std::vector< double > &  rDY 
)
virtual

Evaluate the derivatives of the state variables

Parameters
timethe current time, in milliseconds
rYcurrent values of the state variables
rDYto be filled in with derivatives

Implements AbstractOdeSystem.

Definition at line 149 of file NhsContractionModel.cpp.

References CalculateT0(), EXCEPTION, mA, mA1, mA2, mA3, mAlpha0, mAlpha1, mAlpha2, mAlpha3, mAlphaR1, mAlphaR2, mCalciumI, mCalciumTrop50, mCalciumTroponinMax, mDLambdaDt, mGamma, mKon, mKrefoff, mKZ, mN, mNr, mTref, and SmallPow().

double NhsContractionModel::GetActiveTension ( )
virtual
Returns
the active tension, which is a function of the constants and current state variables. KILOPASCALS

Implements AbstractContractionModel.

Definition at line 207 of file NhsContractionModel.cpp.

References CalculateT0(), mA, and AbstractParameterisedSystem< std::vector< double > >::mStateVariables.

double NhsContractionModel::GetCalciumTroponinValue ( )
Returns
the current Calcium Troponin (one of the state variables) value. This may be needed if the cell model has Calcium troponin and might need overwriting

Definition at line 144 of file NhsContractionModel.cpp.

References AbstractParameterisedSystem< std::vector< double > >::mStateVariables.

double NhsContractionModel::GetNextActiveTension ( )
inlinevirtual
Returns
GetNextActiveTension() normally returns the active tension corresponding to the state variables that have been computed in RunDoNotUpdate. However, this only applies to when an implicit cardiac mechanics solver is used, in which case the NhsModelWithBackwardSolver should be used.

Implements AbstractContractionModel.

Reimplemented in NhsModelWithBackwardSolver.

Definition at line 211 of file NhsContractionModel.hpp.

References EXCEPTION.

bool NhsContractionModel::IsStretchDependent ( )
inlinevirtual
Returns
whether model is stretch-dependent

Implements AbstractContractionModel.

Definition at line 219 of file NhsContractionModel.hpp.

bool NhsContractionModel::IsStretchRateDependent ( )
inlinevirtual
Returns
whether model is stretch-rate-dependent

Implements AbstractContractionModel.

Definition at line 227 of file NhsContractionModel.hpp.

void NhsContractionModel::SetInputParameters ( ContractionModelInputParameters rInputParameters)
virtual

Set the current intracellular calcium concentration

Parameters
rInputParametersinput parameters (calcium, voltage, time, of which only calcium is used)

Implements AbstractContractionModel.

Definition at line 131 of file NhsContractionModel.cpp.

References DOUBLE_UNSET, ContractionModelInputParameters_::intracellularCalciumConcentration, and mCalciumI.

void NhsContractionModel::SetIntracellularCalciumConcentration ( double  calciumConcentration)

Directly set the intracellular calcium concentration.

Parameters
calciumConcentrationcalcium concentration.

Definition at line 138 of file NhsContractionModel.cpp.

References mCalciumI.

void NhsContractionModel::SetStretchAndStretchRate ( double  lambda,
double  dlambdaDt 
)
virtual

Set the current stretch and the stretch rate of the cell/fibre

Parameters
lambdacurrent stretch
dlambdaDtcurrent stretch rate

Implements AbstractContractionModel.

Definition at line 122 of file NhsContractionModel.cpp.

References CalculateCalciumTrop50(), mDLambdaDt, and mLambda.

Member Data Documentation

const double NhsContractionModel::mA = 0.35
staticprotected
const double NhsContractionModel::mA1 = -29
staticprotected

See reference. Dimensionless

Definition at line 128 of file NhsContractionModel.hpp.

Referenced by EvaluateYDerivatives(), and NhsModelWithBackwardSolver::ImplicitSolveForQ().

const double NhsContractionModel::mA2 = 138
staticprotected

See reference. Dimensionless

Definition at line 131 of file NhsContractionModel.hpp.

Referenced by EvaluateYDerivatives(), and NhsModelWithBackwardSolver::ImplicitSolveForQ().

const double NhsContractionModel::mA3 = 129
staticprotected

See reference. Dimensionless

Definition at line 134 of file NhsContractionModel.hpp.

Referenced by EvaluateYDerivatives(), and NhsModelWithBackwardSolver::ImplicitSolveForQ().

const double NhsContractionModel::mAlpha0 = 0.008
staticprotected
const double NhsContractionModel::mAlpha1 = 0.03
staticprotected

See reference. (ms)^-1

Definition at line 137 of file NhsContractionModel.hpp.

Referenced by EvaluateYDerivatives(), and NhsModelWithBackwardSolver::ImplicitSolveForQ().

const double NhsContractionModel::mAlpha2 = 0.130
staticprotected

See reference. (ms)^-1

Definition at line 140 of file NhsContractionModel.hpp.

Referenced by EvaluateYDerivatives(), and NhsModelWithBackwardSolver::ImplicitSolveForQ().

const double NhsContractionModel::mAlpha3 = 0.625
staticprotected

See reference. (ms)^-1

Definition at line 143 of file NhsContractionModel.hpp.

Referenced by EvaluateYDerivatives(), and NhsModelWithBackwardSolver::ImplicitSolveForQ().

const double NhsContractionModel::mAlphaR1 = 0.002
staticprotected
const double NhsContractionModel::mAlphaR2 = 0.0017
staticprotected
const double NhsContractionModel::mBeta0 = 4.9
staticprotected

See reference. Dimensionless

Definition at line 122 of file NhsContractionModel.hpp.

Referenced by CalculateCalciumTrop50(), and CalculateT0().

const double NhsContractionModel::mBeta1 = -4
staticprotected

See reference. Dimensionless

Definition at line 104 of file NhsContractionModel.hpp.

Referenced by CalculateCalciumTrop50().

const double NhsContractionModel::mCalcium50ref = 0.00105
staticprotected

See reference. mMols

Definition at line 116 of file NhsContractionModel.hpp.

Referenced by CalculateCalciumTrop50().

double NhsContractionModel::mCalciumI
protected

The intracellular calcium concentration. To be specified by the caller

Definition at line 66 of file NhsContractionModel.hpp.

Referenced by NhsModelWithBackwardSolver::CalculateCaTropAndZDerivatives(), EvaluateYDerivatives(), NhsContractionModel(), SetInputParameters(), and SetIntracellularCalciumConcentration().

double NhsContractionModel::mCalciumTrop50
protected

A parameter only dependent on constants and lambda, so updated whenever lambda is updated

Definition at line 70 of file NhsContractionModel.hpp.

Referenced by CalculateCalciumTrop50(), NhsModelWithBackwardSolver::CalculateCaTropAndZDerivatives(), CalculateT0(), and EvaluateYDerivatives().

const double NhsContractionModel::mCalciumTroponinMax = 0.07
staticprotected
double NhsContractionModel::mDLambdaDt
protected

The stretch rate. To be specified by the caller

Definition at line 64 of file NhsContractionModel.hpp.

Referenced by EvaluateYDerivatives(), NhsModelWithBackwardSolver::ImplicitSolveForQ(), NhsContractionModel(), and SetStretchAndStretchRate().

const double NhsContractionModel::mGamma = 2
staticprotected
double NhsContractionModel::mK1
protected

A constant determined from the other constrants. Set up in the constructor

Definition at line 73 of file NhsContractionModel.hpp.

Referenced by CalculateT0(), and NhsContractionModel().

double NhsContractionModel::mK2
protected

A constant determined from the other constrants. Set up in the constructor

Definition at line 75 of file NhsContractionModel.hpp.

Referenced by CalculateT0(), and NhsContractionModel().

const double NhsContractionModel::mKon = 100
staticprotected

See reference. (mMols)^-1 (ms)^-1

Definition at line 80 of file NhsContractionModel.hpp.

Referenced by CalculateCalciumTrop50(), NhsModelWithBackwardSolver::CalculateCaTropAndZDerivatives(), and EvaluateYDerivatives().

const double NhsContractionModel::mKrefoff = 0.2
staticprotected
const double NhsContractionModel::mKZ = 0.15
staticprotected
double NhsContractionModel::mLambda
protected

The stretch. To be specified by the caller

Definition at line 62 of file NhsContractionModel.hpp.

Referenced by CalculateCalciumTrop50(), CalculateT0(), NhsContractionModel(), and SetStretchAndStretchRate().

const unsigned NhsContractionModel::mN = 3u
staticprotected

See reference. Dimensionless

Definition at line 110 of file NhsContractionModel.hpp.

Referenced by NhsModelWithBackwardSolver::CalculateCaTropAndZDerivatives(), CalculateT0(), and EvaluateYDerivatives().

const unsigned NhsContractionModel::mNr = 3u
staticprotected
const double NhsContractionModel::mTref = 56.2
staticprotected
const double NhsContractionModel::mZp = 0.85
staticprotected

See reference. Dimensionless

Definition at line 113 of file NhsContractionModel.hpp.

Referenced by NhsContractionModel().


The documentation for this class was generated from the following files: