CryptSimulation1d Class Reference

#include <CryptSimulation1d.hpp>

Inherits OffLatticeSimulation< 1 >.

Collaboration diagram for CryptSimulation1d:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 CryptSimulation1d (AbstractCellPopulation< 1 > &rCellPopulation, bool deleteCellPopulationInDestructor=false, bool initialiseCells=true)
virtual ~CryptSimulation1d ()
void OutputSimulationParameters (out_stream &rParamsFile)

Private Member Functions

template<class Archive >
void serialize (Archive &archive, const unsigned int version)
c_vector< double, 1 > CalculateCellDivisionVector (CellPtr pParentCell)

Private Attributes

MeshBasedCellPopulation< 1 > * mpStaticCastCellPopulation

Friends

class TestCryptSimulation1d
class boost::serialization::access

Detailed Description

A 1D crypt simulation object. The model is a simplified version of a 2D crypt model developed by Meineke et al (doi:10.1046/j.0960-7722.2001.00216.x).

Definition at line 48 of file CryptSimulation1d.hpp.


Constructor & Destructor Documentation

CryptSimulation1d::CryptSimulation1d ( AbstractCellPopulation< 1 > &  rCellPopulation,
bool  deleteCellPopulationInDestructor = false,
bool  initialiseCells = true 
)

Constructor.

Parameters:
rCellPopulation A cell population object
deleteCellPopulationInDestructor Whether to delete the cell population on destruction to free up memory (defaults to false)
initialiseCells whether to initialise cells (defaults to true, set to false when loading from an archive)

Definition at line 33 of file CryptSimulation1d.cpp.

References OffLatticeSimulation< 1 >::AddCellPopulationBoundaryCondition(), MAKE_PTR_ARGS, AbstractCellBasedSimulation< DIM >::mDeleteCellPopulationInDestructor, mpStaticCastCellPopulation, and AbstractCellBasedSimulation< DIM >::mrCellPopulation.

CryptSimulation1d::~CryptSimulation1d (  )  [virtual]

Destructor.

This frees the CryptSimulationBoundaryCondition.

Definition at line 50 of file CryptSimulation1d.cpp.


Member Function Documentation

c_vector< double, 1 > CryptSimulation1d::CalculateCellDivisionVector ( CellPtr  pParentCell  )  [private, virtual]

Calculates the new locations of a dividing cell's cell centres. Moves the dividing node a bit and returns co-ordinates for the new node. It does this by picking a random direction (0->2PI) and placing the parent and daughter in opposing directions on this axis.

Parameters:
pParentCell the parent cell
Returns:
daughter_coords the coordinates for the daughter cell.

Reimplemented from OffLatticeSimulation< 1 >.

Definition at line 54 of file CryptSimulation1d.cpp.

References AbstractCellPopulation< DIM >::GetLocationIndexUsingCell(), AbstractCentreBasedCellPopulation< DIM >::GetLocationOfCellCentre(), AbstractCentreBasedCellPopulation< DIM >::GetMeinekeDivisionSeparation(), RandomNumberGenerator::Instance(), mpStaticCastCellPopulation, AbstractCellBasedSimulation< DIM >::mrCellPopulation, and RandomNumberGenerator::ranf().

void CryptSimulation1d::OutputSimulationParameters ( out_stream &  rParamsFile  )  [virtual]

Outputs simulation parameters to file

As this method is pure virtual, it must be overridden in subclasses.

Parameters:
rParamsFile the file stream to which the parameters are output

Reimplemented from OffLatticeSimulation< 1 >.

Definition at line 108 of file CryptSimulation1d.cpp.

template<class Archive >
void CryptSimulation1d::serialize ( Archive &  archive,
const unsigned int  version 
) [inline, private]

Archive the simulation and member variables.

Parameters:
archive the archive
version the current version of this class

Reimplemented from OffLatticeSimulation< 1 >.

Definition at line 64 of file CryptSimulation1d.hpp.


Friends And Related Function Documentation

friend class boost::serialization::access [friend]

Needed for serialization.

Reimplemented from OffLatticeSimulation< 1 >.

Definition at line 56 of file CryptSimulation1d.hpp.


Member Data Documentation

Helper member that is a static cast of the cell population.

Definition at line 73 of file CryptSimulation1d.hpp.

Referenced by CalculateCellDivisionVector(), and CryptSimulation1d().


The documentation for this class was generated from the following files:
Generated on Thu Dec 22 13:03:55 2011 for Chaste by  doxygen 1.6.3