Chaste Release::3.1
ElectroMechanicsProblemDefinition< DIM > Class Template Reference

#include <ElectroMechanicsProblemDefinition.hpp>

Inheritance diagram for ElectroMechanicsProblemDefinition< DIM >:
Collaboration diagram for ElectroMechanicsProblemDefinition< DIM >:

List of all members.

Public Member Functions

 ElectroMechanicsProblemDefinition (QuadraticMesh< DIM > &rMesh)
 ~ElectroMechanicsProblemDefinition ()
void SetContractionModel (ContractionModelName contractionModel, double timestep)
void SetUseDefaultCardiacMaterialLaw (CompressibilityType compressibilityType)
void SetDeformationAffectsElectrophysiology (bool deformationAffectsConductivity, bool deformationAffectsCellModels)
void SetMechanicsSolveTimestep (double timestep)
void SetVariableFibreSheetDirectionsFile (const FileFinder &rFibreSheetDirectionsFile, bool definedPerQuadPoint)
void SetApplyCrossFibreTension (bool applyCrossFibreTension, double crossFibreTensionFraction)
ContractionModelName GetContractionModel ()
double GetContractionModelOdeTimestep ()
double GetMechanicsSolveTimestep ()
bool GetDeformationAffectsConductivity ()
bool GetDeformationAffectsCellModels ()
bool ReadFibreSheetDirectionsFromFile ()
FileFinder GetFibreSheetDirectionsFile ()
bool GetFibreSheetDirectionsDefinedPerQuadraturePoint ()
void SetNumIncrementsForInitialDeformation (unsigned numIncrements)
unsigned GetNumIncrementsForInitialDeformation ()
double GetApplyCrossFibreTension ()
double GetCrossFibreTensionFraction ()
virtual void Validate ()

Private Attributes

ContractionModelName mContractionModel
double mContractionModelOdeTimeStep
double mMechanicsSolveTimestep
bool mDeformationAffectsConductivity
bool mDeformationAffectsCellModels
AbstractMaterialLaw< DIM > * mpDefaultMaterialLaw
bool mReadFibreSheetInformationFromFile
FileFinder mFibreSheetDirectionsFile
bool mFibreSheetDirectionsDefinedPerQuadraturePoint
unsigned mNumIncrementsForInitialDeformation
bool mApplyCrossFibreTension
double mCrossFibreTensionFraction

Detailed Description

template<unsigned DIM>
class ElectroMechanicsProblemDefinition< DIM >

Subclass of SolidMechanicsProblemDefinition with some cardiac-electro-mechanics-specific methods.

Definition at line 50 of file ElectroMechanicsProblemDefinition.hpp.


Constructor & Destructor Documentation

template<unsigned DIM>
ElectroMechanicsProblemDefinition< DIM >::ElectroMechanicsProblemDefinition ( QuadraticMesh< DIM > &  rMesh)

Constructor

Parameters:
rMeshthe mesh

Definition at line 39 of file ElectroMechanicsProblemDefinition.cpp.

Destructor

Definition at line 53 of file ElectroMechanicsProblemDefinition.cpp.


Member Function Documentation

template<unsigned DIM>
double ElectroMechanicsProblemDefinition< DIM >::GetApplyCrossFibreTension ( ) [inline]

Returns true if cross-fibre tension is applied.

Definition at line 304 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mApplyCrossFibreTension.

template<unsigned DIM>
ContractionModelName ElectroMechanicsProblemDefinition< DIM >::GetContractionModel ( ) [inline]
template<unsigned DIM>
double ElectroMechanicsProblemDefinition< DIM >::GetContractionModelOdeTimestep ( ) [inline]

Get the contraction model timestep

Definition at line 215 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mContractionModelOdeTimeStep.

template<unsigned DIM>
double ElectroMechanicsProblemDefinition< DIM >::GetCrossFibreTensionFraction ( ) [inline]

Returns the value of the cross-fibre tension fraction.

Definition at line 312 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mCrossFibreTensionFraction.

template<unsigned DIM>
bool ElectroMechanicsProblemDefinition< DIM >::GetDeformationAffectsCellModels ( ) [inline]

Get whether the deformation affects the cardiac cell models, for example if there are stretch-activated channels in the cell model.

Definition at line 243 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mDeformationAffectsCellModels.

template<unsigned DIM>
bool ElectroMechanicsProblemDefinition< DIM >::GetDeformationAffectsConductivity ( ) [inline]

Get whether the deformation affects the electrical physiological conductivity (or whether this effect is neglected).

Definition at line 234 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mDeformationAffectsConductivity.

template<unsigned DIM>
bool ElectroMechanicsProblemDefinition< DIM >::GetFibreSheetDirectionsDefinedPerQuadraturePoint ( ) [inline]

Get whether the fibre-sheet info is defined for each quadrature point in the mesh (if not, if it defined for each element in the mesh). (Should only be called if ReadFibreSheetDirectionsFromFile() returns true).

Definition at line 271 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mFibreSheetDirectionsDefinedPerQuadraturePoint, and ElectroMechanicsProblemDefinition< DIM >::mReadFibreSheetInformationFromFile.

template<unsigned DIM>
FileFinder ElectroMechanicsProblemDefinition< DIM >::GetFibreSheetDirectionsFile ( ) [inline]
template<unsigned DIM>
double ElectroMechanicsProblemDefinition< DIM >::GetMechanicsSolveTimestep ( ) [inline]

Get how often the mechanics is solved

Definition at line 224 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mMechanicsSolveTimestep.

template<unsigned DIM>
unsigned ElectroMechanicsProblemDefinition< DIM >::GetNumIncrementsForInitialDeformation ( ) [inline]

Get the number of increments to be used in the initial deformation (see SetNumIncrementsForInitialDeformation() for more details).

Definition at line 296 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mNumIncrementsForInitialDeformation.

template<unsigned DIM>
bool ElectroMechanicsProblemDefinition< DIM >::ReadFibreSheetDirectionsFromFile ( ) [inline]

Whether the fibre-sheet info should be read from file (if not the defaults should be used).

Definition at line 251 of file ElectroMechanicsProblemDefinition.hpp.

References ElectroMechanicsProblemDefinition< DIM >::mReadFibreSheetInformationFromFile.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::SetApplyCrossFibreTension ( bool  applyCrossFibreTension,
double  crossFibreTensionFraction 
)

Set if active tension should be applied in the cross-fibre direction.

By default active tension is only applied in the fibre direction. This method allows the user to specify that a proportion of the active tension should also be applied in the cross-fibre direction. The fraction of the active tension that is applied in the cross-fibre direction can also be specified.

Parameters:
applyCrossFibreTensionactive tension is applied in the cross-fibre direction if set to true.
crossFibreTensionFractionThe fraction of the active tension to apply in the cross-fibre direction.

Definition at line 112 of file ElectroMechanicsProblemDefinition.cpp.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::SetContractionModel ( ContractionModelName  contractionModel,
double  timestep 
)

Set the contraction model to be used (throughout the tissue).

Note the timestep should be set to a (typical) ODE time-step even if the contraction model is not going to solve ODEs.

Parameters:
contractionModelcontraction model (from the enumeration ContractionModelName)
timesteptimestep to be used in solving (ODE-based) contraction models.

Definition at line 62 of file ElectroMechanicsProblemDefinition.cpp.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::SetDeformationAffectsElectrophysiology ( bool  deformationAffectsConductivity,
bool  deformationAffectsCellModels 
)

Set if and how the deformation should affect the electro-physiology.

Parameters:
deformationAffectsConductivityWhether the deformation should affect the electrical physiological conductivity (or whether this effect is neglected)
deformationAffectsCellModelsWhether the deformation should affect the cardiac cell models, for example if there are stretch-activated channels in the cell model.

Several important things to note: (i) this can't be called if fibre-sheet directions have been defined from file for each quadrature point (as opposed to each mechanics element) - this is because if the stretch is to be passed back to the electric mesh nodes, the fibre direction has to be defined at those nodes (ii) currently the set-up stage (computing mechanics mesh elements and weights for electrics mesh nodes) is inefficiently implemented - setup will be very slow for big meshes (iii) if deformationAffectsCellModels is true, the cell model ought to be one for which AbstractCardiacCell::SetStretch() has been implemented to do something (i.e. not generated automatically from CellML). (iv) deformationAffectsConductivity is not currently allowed in the compressible material law case as the effect of the determinant of the deformation gradient on the conductivity has not currently been implemented.

Definition at line 90 of file ElectroMechanicsProblemDefinition.cpp.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::SetMechanicsSolveTimestep ( double  timestep)

Set how often the mechanics is solved for.

Parameters:
timesteptimestep

Definition at line 97 of file ElectroMechanicsProblemDefinition.cpp.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::SetNumIncrementsForInitialDeformation ( unsigned  numIncrements) [inline]

The first deformation (to find the equilibrium state given the loading) may require the loading to be incremented, in order for the Solve() to converge. Set the number of increments to be used.

Parameters:
numIncrementsnumber of increments

Definition at line 283 of file ElectroMechanicsProblemDefinition.hpp.

References EXCEPTION, and ElectroMechanicsProblemDefinition< DIM >::mNumIncrementsForInitialDeformation.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::SetUseDefaultCardiacMaterialLaw ( CompressibilityType  compressibilityType)

Use the default material law (NashHunter in the incompressible case, exponential in the compressible case), throughout the tissue.

Parameters:
compressibilityTypeEither INCOMPRESSIBLE or COMPRESSIBLE

Definition at line 70 of file ElectroMechanicsProblemDefinition.cpp.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::SetVariableFibreSheetDirectionsFile ( const FileFinder rFibreSheetDirectionsFile,
bool  definedPerQuadPoint 
)

Set a variable fibre-sheet-normal direction (matrices), from file. If the second parameter is false, there should be one fibre-sheet definition for each element; otherwise there should be one fibre-sheet definition for each *quadrature point* in the mesh. In the first case, the file should be a standard .ortho file (ie each line has the fibre dir, sheet dir, normal dir for that element), in the second it should have .orthoquad as the format.

If this method is not called, the default fibre-sheet directions are used - ie fibres parallel to X-axis, sheets parallel to Y-axis.

Parameters:
rFibreSheetDirectionsFilethe file containing the fibre/sheet directions
definedPerQuadPointwhether the fibre-sheet definitions are for each quadrature point in the mesh (if not, one for each element is assumed).

Definition at line 104 of file ElectroMechanicsProblemDefinition.cpp.

template<unsigned DIM>
void ElectroMechanicsProblemDefinition< DIM >::Validate ( ) [virtual]

Check all variables are set appropriately. Exceptions are thrown if any are not. Derived classes can override but should call this version as well.

Reimplemented from SolidMechanicsProblemDefinition< DIM >.

Definition at line 119 of file ElectroMechanicsProblemDefinition.cpp.

References EXCEPTION, and SolidMechanicsProblemDefinition< DIM >::Validate().


Member Data Documentation

template<unsigned DIM>
bool ElectroMechanicsProblemDefinition< DIM >::mApplyCrossFibreTension [private]

Whether to apply active tension in the cross-fibre direction.

Definition at line 108 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetApplyCrossFibreTension().

template<unsigned DIM>
ContractionModelName ElectroMechanicsProblemDefinition< DIM >::mContractionModel [private]

The contraction model used (ContractionModelName is an enumeration containing all contraction models implemented.

Definition at line 57 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetContractionModel().

template<unsigned DIM>
double ElectroMechanicsProblemDefinition< DIM >::mCrossFibreTensionFraction [private]

The fraction of the fibre tension to apply in the cross-fibre direction.

Definition at line 111 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetCrossFibreTensionFraction().

template<unsigned DIM>
bool ElectroMechanicsProblemDefinition< DIM >::mDeformationAffectsCellModels [private]

Whether the deformation should affect the cardiac cell models, for example if there are stretch-activated channels in the cell model.

Definition at line 75 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetDeformationAffectsCellModels().

Whether the deformation should affect the electrical physiological conductivity (or whether this effect is neglected)

Definition at line 69 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetDeformationAffectsConductivity().

Whether the mFibreSheetDirectionsFile file gives the fibre-sheet info for each element or for each quadrature point

Definition at line 96 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetFibreSheetDirectionsDefinedPerQuadraturePoint().

.ortho/.orthoquad file from which to read element-wise, or quadrature-point-wise fibre-sheet-normal-directions

Definition at line 90 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetFibreSheetDirectionsFile().

template<unsigned DIM>
double ElectroMechanicsProblemDefinition< DIM >::mMechanicsSolveTimestep [private]

How often a mechanics solve should be done

Definition at line 63 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetMechanicsSolveTimestep().

The first deformation (to find the equilibrium state given the loading) may require the loading to be incremented, in order for the Solve() to converge - this stores the number of increments to be used (initialised to 1)

Definition at line 103 of file ElectroMechanicsProblemDefinition.hpp.

Referenced by ElectroMechanicsProblemDefinition< DIM >::GetNumIncrementsForInitialDeformation(), and ElectroMechanicsProblemDefinition< DIM >::SetNumIncrementsForInitialDeformation().

template<unsigned DIM>
AbstractMaterialLaw<DIM>* ElectroMechanicsProblemDefinition< DIM >::mpDefaultMaterialLaw [private]

This member variable is used if SetDefaultCardiacMateriawLaw() is called.

Definition at line 80 of file ElectroMechanicsProblemDefinition.hpp.


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