AbstractCardiacCellFactory< SPACE_DIM > Class Template Reference

#include <AbstractCardiacCellFactory.hpp>

Inheritance diagram for AbstractCardiacCellFactory< SPACE_DIM >:

Inheritance graph
[legend]
Collaboration diagram for AbstractCardiacCellFactory< SPACE_DIM >:

Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual AbstractCardiacCellCreateCardiacCellForNode (unsigned)
virtual AbstractCardiacCellCreateCardiacCellForTissueNode (unsigned)=0
virtual void FinaliseCellCreation (std::vector< AbstractCardiacCell * > *pCellsDistributed, unsigned lo, unsigned hi)
virtual unsigned GetNumberOfCells ()
 AbstractCardiacCellFactory (AbstractIvpOdeSolver *pSolver=new EulerIvpOdeSolver)
virtual ~AbstractCardiacCellFactory ()
void SetMesh (AbstractMesh< SPACE_DIM, SPACE_DIM > *pMesh)
AbstractMesh< SPACE_DIM,
SPACE_DIM > * 
GetMesh ()

Protected Attributes

ZeroStimulusmpZeroStimulus
AbstractIvpOdeSolvermpSolver
AbstractMesh< SPACE_DIM,
SPACE_DIM > * 
mpMesh
AbstractCardiacCellmpFakeCell


Detailed Description

template<unsigned SPACE_DIM>
class AbstractCardiacCellFactory< SPACE_DIM >

Class which returns cardiac cells. For use with MonodomainPde and BidomainPdes.

The user should implement their own concrete class, in particular implementing CreateCardiacCellForTissueNode(unsigned), which should return the cell corresponding to a given node. The user should also implement GetNumberOfCells() if this isn't equal to the number of nodes. FinaliseCellCreation() can be used to (eg) add stimuli to certain cells after they have been created.

This class saves the user having to create cells in parallel, that work is done by the pde instead.

Definition at line 54 of file AbstractCardiacCellFactory.hpp.


Constructor & Destructor Documentation

template<unsigned SPACE_DIM>
AbstractCardiacCellFactory< SPACE_DIM >::AbstractCardiacCellFactory ( AbstractIvpOdeSolver pSolver = new EulerIvpOdeSolver  )  [inline]

Default constructor.

NB: The ODE solver passed to this class *must* have been allocated with new, since this class deletes the solver in its destructor.

Definition at line 63 of file AbstractCardiacCellFactory.cpp.

References AbstractCardiacCellFactory< SPACE_DIM >::mpFakeCell, AbstractCardiacCellFactory< SPACE_DIM >::mpMesh, and AbstractCardiacCellFactory< SPACE_DIM >::mpZeroStimulus.

template<unsigned SPACE_DIM>
AbstractCardiacCellFactory< SPACE_DIM >::~AbstractCardiacCellFactory (  )  [inline, virtual]

Destructor: free solver, zero stimulus and fake bath cell.

Definition at line 72 of file AbstractCardiacCellFactory.cpp.

References AbstractCardiacCellFactory< SPACE_DIM >::mpFakeCell, and AbstractCardiacCellFactory< SPACE_DIM >::mpZeroStimulus.


Member Function Documentation

template<unsigned SPACE_DIM>
AbstractCardiacCell * AbstractCardiacCellFactory< SPACE_DIM >::CreateCardiacCellForNode ( unsigned  nodeIndex  )  [inline, virtual]

Create a cell object for the given node.

The default implementation checks whether the node is in the bath (in which case a pointer to a (unique) fake cell is returned) and if not, calls CreateCardiacCellForTissueNode (which must be defined by subclasses).

Definition at line 34 of file AbstractCardiacCellFactory.cpp.

References AbstractCardiacCellFactory< SPACE_DIM >::CreateCardiacCellForTissueNode(), AbstractCardiacCellFactory< SPACE_DIM >::mpFakeCell, and AbstractCardiacCellFactory< SPACE_DIM >::mpMesh.

Referenced by AbstractCardiacPde< SPACE_DIM >::AbstractCardiacPde().

template<unsigned SPACE_DIM>
virtual AbstractCardiacCell* AbstractCardiacCellFactory< SPACE_DIM >::CreateCardiacCellForTissueNode ( unsigned   )  [pure virtual]

Must be overridden by subclasses to return a cell object for the given node.

Implemented in QuarterStimulusCellFactory< CELL, DIM >.

Referenced by AbstractCardiacCellFactory< SPACE_DIM >::CreateCardiacCellForNode().

template<unsigned SPACE_DIM>
void AbstractCardiacCellFactory< SPACE_DIM >::FinaliseCellCreation ( std::vector< AbstractCardiacCell * > *  pCellsDistributed,
unsigned  lo,
unsigned  hi 
) [inline, virtual]

May be overridden by subclasses to perform any necessary work after all cells have been created.

Definition at line 48 of file AbstractCardiacCellFactory.cpp.

Referenced by AbstractCardiacPde< SPACE_DIM >::AbstractCardiacPde().


Member Data Documentation

template<unsigned SPACE_DIM>
ZeroStimulus* AbstractCardiacCellFactory< SPACE_DIM >::mpZeroStimulus [protected]

template<unsigned SPACE_DIM>
AbstractMesh<SPACE_DIM,SPACE_DIM>* AbstractCardiacCellFactory< SPACE_DIM >::mpMesh [protected]

template<unsigned SPACE_DIM>
AbstractCardiacCell* AbstractCardiacCellFactory< SPACE_DIM >::mpFakeCell [protected]


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

Generated on Wed Mar 18 12:52:00 2009 for Chaste by  doxygen 1.5.5