Chaste
Release::2017.1
|
#include <HeartConfigRelatedCellFactory.hpp>
Private Member Functions | |
void | PreconvertCellmlFiles () |
DynamicCellModelLoaderPtr | LoadDynamicModel (const cp::ionic_model_selection_type &rModel, bool isCollective) |
Private Attributes | |
cp::ionic_model_selection_type | mDefaultIonicModel |
std::vector< boost::shared_ptr< AbstractChasteRegion< SPACE_DIM > > > | mIonicModelRegions |
std::vector< cp::ionic_model_selection_type > | mIonicModelsDefined |
std::vector< boost::shared_ptr< AbstractChasteRegion< SPACE_DIM > > > | mStimulatedAreas |
std::vector< boost::shared_ptr< AbstractStimulusFunction > > | mStimuliApplied |
std::vector< boost::shared_ptr< AbstractChasteRegion< SPACE_DIM > > > | mCellHeterogeneityAreas |
std::vector< double > | mScaleFactorGks |
std::vector< double > | mScaleFactorIto |
std::vector< double > | mScaleFactorGkr |
std::vector< std::map< std::string, double > > | mParameterSettings |
Additional Inherited Members | |
Protected Attributes inherited from AbstractCardiacCellFactory< SPACE_DIM > | |
boost::shared_ptr< ZeroStimulus > | mpZeroStimulus |
boost::shared_ptr< AbstractIvpOdeSolver > | mpSolver |
This is a cardiac cell factory which uses the settings from HeartConfig to set up the cells.
It thus supports such features as heterogeneities (in both the type of cell, and for some cells, cell model parameters), and the ability to dynamically convert CellML files into C++ code, compile this, and load the resulting model.
Definition at line 96 of file HeartConfigRelatedCellFactory.hpp.
HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory | ( | ) |
Constructor reads settings from the configuration file.
Definition at line 50 of file HeartConfigRelatedCellFactory.cpp.
References EXCEPTION, HeartConfig::GetCellHeterogeneities(), HeartConfig::GetIonicModelRegions(), HeartConfig::GetStimuli(), HeartConfig::Instance(), HeartConfig::IsElectrodesPresent(), HeartConfigRelatedCellFactory< SPACE_DIM >::mCellHeterogeneityAreas, HeartConfigRelatedCellFactory< SPACE_DIM >::mIonicModelRegions, HeartConfigRelatedCellFactory< SPACE_DIM >::mIonicModelsDefined, HeartConfigRelatedCellFactory< SPACE_DIM >::mParameterSettings, HeartConfigRelatedCellFactory< SPACE_DIM >::mScaleFactorGkr, HeartConfigRelatedCellFactory< SPACE_DIM >::mScaleFactorGks, HeartConfigRelatedCellFactory< SPACE_DIM >::mScaleFactorIto, HeartConfigRelatedCellFactory< SPACE_DIM >::mStimulatedAreas, HeartConfigRelatedCellFactory< SPACE_DIM >::mStimuliApplied, and HeartConfigRelatedCellFactory< SPACE_DIM >::PreconvertCellmlFiles().
HeartConfigRelatedCellFactory< SPACE_DIM >::~HeartConfigRelatedCellFactory | ( | ) |
Destructor
Definition at line 106 of file HeartConfigRelatedCellFactory.cpp.
AbstractCardiacCellInterface * HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCardiacCellForTissueNode | ( | Node< SPACE_DIM > * | pNode | ) |
pNode | pointer to the node. |
Definition at line 334 of file HeartConfigRelatedCellFactory.cpp.
References HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCellWithIntracellularStimulus(), Node< SPACE_DIM >::GetIndex(), Node< SPACE_DIM >::GetPoint(), HeartConfigRelatedCellFactory< SPACE_DIM >::mStimulatedAreas, and HeartConfigRelatedCellFactory< SPACE_DIM >::mStimuliApplied.
AbstractCardiacCellInterface * HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCellWithIntracellularStimulus | ( | boost::shared_ptr< AbstractStimulusFunction > | intracellularStimulus, |
unsigned | nodeIndex | ||
) |
intracellularStimulus | is computed in CreateCardiacCellForTissueNode determined by the list of stimulation regions |
nodeIndex | is the global index within the mesh |
Definition at line 111 of file HeartConfigRelatedCellFactory.cpp.
References EXCEPTION, HeartConfig::GetCheckpointSimulation(), AbstractCardiacCellInterface::GetLookupTableCollection(), AbstractCardiacCellFactory< SPACE_DIM >::GetMesh(), HeartConfig::Instance(), HeartConfigRelatedCellFactory< SPACE_DIM >::LoadDynamicModel(), HeartConfigRelatedCellFactory< SPACE_DIM >::mDefaultIonicModel, HeartConfigRelatedCellFactory< SPACE_DIM >::mIonicModelRegions, HeartConfigRelatedCellFactory< SPACE_DIM >::mIonicModelsDefined, AbstractCardiacCellFactory< SPACE_DIM >::mpSolver, NEVER_REACHED, and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellParameters().
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCardiacCellForTissueNode().
|
virtual |
Helper method to calculate and fill in the heterogeneities areas (mCellHeterogeneityAreas)
Reimplemented from AbstractCardiacCellFactory< SPACE_DIM >.
Definition at line 355 of file HeartConfigRelatedCellFactory.cpp.
References NEVER_REACHED.
|
virtual |
Method that fills in the vector of heterogeneity areas with the NodesLists that correspond to a given layer (implemented in subclasses)
Reimplemented from AbstractCardiacCellFactory< SPACE_DIM >.
Definition at line 362 of file HeartConfigRelatedCellFactory.cpp.
References HeartGeometryInformation< SPACE_DIM >::DetermineLayerForEachNode(), AbstractMesh< ELEMENT_DIM, SPACE_DIM >::GetDistributedVectorFactory(), HeartConfig::GetEndoLayerFraction(), HeartConfig::GetEndoLayerIndex(), HeartConfig::GetEpiLayerFraction(), HeartConfig::GetEpiLayerIndex(), AbstractCardiacCellFactory< SPACE_DIM >::GetMesh(), HeartConfig::GetMeshName(), HeartConfig::GetMidLayerIndex(), AbstractMesh< ELEMENT_DIM, SPACE_DIM >::GetNumNodes(), HeartConfig::Instance(), DistributedVectorFactory::IsGlobalIndexLocal(), HeartConfigRelatedCellFactory< SPACE_DIM >::mCellHeterogeneityAreas, NEVER_REACHED, and HeartGeometryInformation< SPACE_DIM >::rGetLayerForEachNode().
|
private |
rModel | model to load |
isCollective | whether we are being called collectively |
Definition at line 95 of file HeartConfigRelatedCellFactory.cpp.
References CellMLToSharedLibraryConverter::Convert().
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCellWithIntracellularStimulus(), and HeartConfigRelatedCellFactory< SPACE_DIM >::PreconvertCellmlFiles().
|
private |
Called by the constructor to convert any CellML files used as dynamically loaded cell models to shared libraries. This is necessary since the conversion process must be done collectively.
Definition at line 79 of file HeartConfigRelatedCellFactory.cpp.
References HeartConfigRelatedCellFactory< SPACE_DIM >::LoadDynamicModel(), HeartConfigRelatedCellFactory< SPACE_DIM >::mDefaultIonicModel, and HeartConfigRelatedCellFactory< SPACE_DIM >::mIonicModelsDefined.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory().
void HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellIntracellularStimulus | ( | AbstractCardiacCellInterface * | pCell, |
unsigned | nodeIndex | ||
) |
Set the intracellular stimulus for a cell based on the definitions in HeartConfig.
pCell | the cell to set stimulus of |
nodeIndex | the index of the node corresponding to this cell in the mesh |
Definition at line 316 of file HeartConfigRelatedCellFactory.cpp.
References AbstractCardiacCellFactory< SPACE_DIM >::GetMesh(), HeartConfigRelatedCellFactory< SPACE_DIM >::mStimulatedAreas, HeartConfigRelatedCellFactory< SPACE_DIM >::mStimuliApplied, and AbstractCardiacCellInterface::SetIntracellularStimulusFunction().
Referenced by CardiacSimulation::CreateAndRun().
void HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellParameters | ( | AbstractCardiacCellInterface * | pCell, |
unsigned | nodeIndex | ||
) |
Set parameters of a cell based on heterogeneity definitions in HeartConfig.
pCell | the cell to set parameters of |
nodeIndex | the index of the node corresponding to this cell in the mesh |
#1166 applying Hill function for drug action
Definition at line 250 of file HeartConfigRelatedCellFactory.cpp.
References HeartConfig::GetDrugDose(), HeartConfig::GetIc50Values(), AbstractCardiacCellFactory< SPACE_DIM >::GetMesh(), AbstractCardiacCellInterface::GetParameter(), HeartConfig::Instance(), HeartConfigRelatedCellFactory< SPACE_DIM >::mCellHeterogeneityAreas, HeartConfigRelatedCellFactory< SPACE_DIM >::mParameterSettings, HeartConfigRelatedCellFactory< SPACE_DIM >::mScaleFactorGkr, HeartConfigRelatedCellFactory< SPACE_DIM >::mScaleFactorGks, HeartConfigRelatedCellFactory< SPACE_DIM >::mScaleFactorIto, and AbstractCardiacCellInterface::SetParameter().
Referenced by CardiacSimulation::CreateAndRun(), and HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCellWithIntracellularStimulus().
|
private |
List of regions which represent areas in which to give parametric heterogeneity (scaling gating parameters) This vector will be filled in by the HeartConfig::GetCellHeterogeneity method if the user requested to specify the heterogeneity areas by cuboids, or, alternatively, by the FillInCellularTransmuralAreas method in the cell factory called by the problem class AFTER setting the mesh (which is needed for the calculations of the distance maps for the calculations of heterogeneities).
When creating a cardiac cell for each node (CreateCardiacCellForTissueNode) the code will check whether that node is contained in the heterogeneity area or not.
Definition at line 122 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::FillInCellularTransmuralAreas(), HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellParameters().
|
private |
Default cardiac cell model to be used in all tissue (except heterogeneous regions)
Definition at line 100 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCellWithIntracellularStimulus(), and HeartConfigRelatedCellFactory< SPACE_DIM >::PreconvertCellmlFiles().
|
private |
List of axis-aligned box regions which contain heterogeneous cardiac ionic model types
Definition at line 102 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCellWithIntracellularStimulus(), and HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory().
|
private |
List of ionic model (size matches that of mIonicModelRegions)
Definition at line 104 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCellWithIntracellularStimulus(), HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::PreconvertCellmlFiles().
|
private |
Named parameters to be set in each region (size of list matches that of mCellHeterogeneityAreas)
Definition at line 131 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellParameters().
|
private |
List of scale factors for Gkr scaling in each region (size of list matches that of mCellHeterogeneityAreas)
Definition at line 128 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellParameters().
|
private |
List of scale factors for Gks scaling in each region (size of list matches that of mCellHeterogeneityAreas)
Definition at line 124 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellParameters().
|
private |
List of scale factors for Ito scaling in each region (size of list matches that of mCellHeterogeneityAreas)
Definition at line 126 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellParameters().
|
private |
List of axis-aligned box or ellipsoid regions which represent areas to stimulate
Definition at line 107 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCardiacCellForTissueNode(), HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellIntracellularStimulus().
|
private |
List of intracellular current stimuli to apply (size matches that of mStimulatedAreas)
Definition at line 109 of file HeartConfigRelatedCellFactory.hpp.
Referenced by HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCardiacCellForTissueNode(), HeartConfigRelatedCellFactory< SPACE_DIM >::HeartConfigRelatedCellFactory(), and HeartConfigRelatedCellFactory< SPACE_DIM >::SetCellIntracellularStimulus().