Chaste
Release::2018.1
|
#include <NodeBasedCellPopulation.hpp>
Public Member Functions | |
void | SetNode (unsigned nodeIndex, ChastePoint< DIM > &rNewLocation) |
NodeBasedCellPopulation (NodesOnlyMesh< DIM > &rMesh, std::vector< CellPtr > &rCells, const std::vector< unsigned > locationIndices=std::vector< unsigned >(), bool deleteMesh=false, bool validate=true) | |
NodeBasedCellPopulation (NodesOnlyMesh< DIM > &rMesh) | |
virtual | ~NodeBasedCellPopulation () |
NodesOnlyMesh< DIM > & | rGetMesh () |
const NodesOnlyMesh< DIM > & | rGetMesh () const |
virtual TetrahedralMesh< DIM, DIM > * | GetTetrahedralMeshForPdeModifier () |
unsigned | GetNumNodes () |
virtual CellPtr | GetCellUsingLocationIndex (unsigned index) |
Node< DIM > * | GetNode (unsigned index) |
unsigned | RemoveDeadCells () |
void | Clear () |
void | Update (bool hasHadBirthsOrDeaths=true) |
std::vector< std::pair< Node < DIM > *, Node< DIM > * > > & | rGetNodePairs () |
void | OutputCellPopulationParameters (out_stream &rParamsFile) |
virtual void | AcceptPopulationWriter (boost::shared_ptr< AbstractCellPopulationWriter< DIM, DIM > > pPopulationWriter) |
virtual void | AcceptPopulationCountWriter (boost::shared_ptr< AbstractCellPopulationCountWriter< DIM, DIM > > pPopulationCountWriter) |
virtual void | AcceptCellWriter (boost::shared_ptr< AbstractCellWriter< DIM, DIM > > pCellWriter, CellPtr pCell) |
double | GetMechanicsCutOffLength () |
bool | GetUseVariableRadii () |
void | SetUseVariableRadii (bool useVariableRadii=true) |
void | SetLoadBalanceMesh (bool loadBalanceMesh) |
void | SetLoadBalanceFrequency (unsigned loadBalanceFrequency) |
double | GetWidth (const unsigned &rDimension) |
c_vector< double, DIM > | GetSizeOfCellPopulation () |
std::set< unsigned > | GetNodesWithinNeighbourhoodRadius (unsigned index, double neighbourhoodRadius) |
std::set< unsigned > | GetNeighbouringNodeIndices (unsigned index) |
virtual CellPtr | AddCell (CellPtr pNewCell, CellPtr pParentCell) |
double | GetVolumeOfCell (CellPtr pCell) |
void | SendCellsToNeighbourProcesses () |
void | NonBlockingSendCellsToNeighbourProcesses () |
void | GetReceivedCells () |
std::pair< CellPtr, Node< DIM > * > | GetCellNodePair (unsigned nodeIndex) |
void | AddReceivedCells () |
virtual void | UpdateCellProcessLocation () |
Public Member Functions inherited from AbstractCentreBasedCellPopulation< DIM > | |
AbstractCentreBasedCellPopulation (AbstractMesh< ELEMENT_DIM, ELEMENT_DIM > &rMesh, std::vector< CellPtr > &rCells, const std::vector< unsigned > locationIndices=std::vector< unsigned >()) | |
c_vector< double, ELEMENT_DIM > | GetLocationOfCellCentre (CellPtr pCell) |
Node< ELEMENT_DIM > * | GetNodeCorrespondingToCell (CellPtr pCell) |
virtual double | GetCellDataItemAtPdeNode (unsigned pdeNodeIndex, std::string &rVariableName, bool dirichletBoundaryConditionApplies=false, double dirichletBoundaryValue=0.0) |
CellPtr | AddCell (CellPtr pNewCell, CellPtr pParentCell=CellPtr()) |
std::pair< CellPtr, CellPtr > | CreateCellPair (CellPtr pCell1, CellPtr pCell2) |
bool | IsMarkedSpring (const std::pair< CellPtr, CellPtr > &rCellPair) |
void | MarkSpring (std::pair< CellPtr, CellPtr > &rCellPair) |
void | UnmarkSpring (std::pair< CellPtr, CellPtr > &rCellPair) |
bool | IsCellAssociatedWithADeletedLocation (CellPtr pCell) |
virtual std::set< unsigned > | GetNeighbouringLocationIndices (CellPtr pCell) |
virtual void | CheckForStepSizeException (unsigned nodeIndex, c_vector< double, ELEMENT_DIM > &rDisplacement, double dt) |
virtual double | GetDampingConstant (unsigned nodeIndex) |
virtual bool | IsGhostNode (unsigned index) |
virtual bool | IsParticle (unsigned index) |
double | GetMeinekeDivisionSeparation () |
void | SetMeinekeDivisionSeparation (double divisionSeparation) |
boost::shared_ptr < AbstractCentreBasedDivisionRule < ELEMENT_DIM, ELEMENT_DIM > > | GetCentreBasedDivisionRule () |
void | SetCentreBasedDivisionRule (boost::shared_ptr< AbstractCentreBasedDivisionRule< ELEMENT_DIM, ELEMENT_DIM > > pCentreBasedDivisionRule) |
virtual double | GetDefaultTimeStep () |
Public Member Functions inherited from AbstractOffLatticeCellPopulation< ELEMENT_DIM, SPACE_DIM > | |
AbstractOffLatticeCellPopulation (AbstractMesh< ELEMENT_DIM, SPACE_DIM > &rMesh, std::vector< CellPtr > &rCells, const std::vector< unsigned > locationIndices=std::vector< unsigned >()) | |
virtual unsigned | AddNode (Node< SPACE_DIM > *pNewNode)=0 |
virtual void | SetNode (unsigned nodeIndex, ChastePoint< SPACE_DIM > &rNewLocation)=0 |
virtual void | UpdateNodeLocations (double dt) |
virtual void | CheckForStepSizeException (unsigned nodeIndex, c_vector< double, SPACE_DIM > &rDisplacement, double dt)=0 |
void | SetDampingConstantNormal (double dampingConstantNormal) |
void | SetDampingConstantMutant (double dampingConstantMutant) |
void | SetAbsoluteMovementThreshold (double absoluteMovementThreshold) |
double | GetAbsoluteMovementThreshold () |
double | GetDampingConstantNormal () |
double | GetDampingConstantMutant () |
Public Member Functions inherited from AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM > | |
AbstractCellPopulation (AbstractMesh< ELEMENT_DIM, SPACE_DIM > &rMesh, std::vector< CellPtr > &rCells, const std::vector< unsigned > locationIndices=std::vector< unsigned >()) | |
virtual | ~AbstractCellPopulation () |
void | InitialiseCells () |
void | SetDataOnAllCells (const std::string &rDataName, double dataValue) |
AbstractMesh< ELEMENT_DIM, SPACE_DIM > & | rGetMesh () |
virtual bool | IsPdeNodeAssociatedWithNonApoptoticCell (unsigned pdeNodeIndex) |
std::list< CellPtr > & | rGetCells () |
virtual void | WriteDataToVisualizerSetupFile (out_stream &pVizSetupFile) |
std::vector< unsigned > | GetCellMutationStateCount () |
std::vector< unsigned > | GetCellProliferativeTypeCount () |
std::vector< unsigned > | GetCellCyclePhaseCount () |
unsigned | GetNumRealCells () |
unsigned | GetNumAllCells () |
void | SetCellAncestorsToLocationIndices () |
std::set< unsigned > | GetCellAncestors () |
std::set< CellPtr > | GetCellsUsingLocationIndex (unsigned index) |
virtual bool | IsCellAttachedToLocationIndex (unsigned index) |
void | SetCellUsingLocationIndex (unsigned index, CellPtr pCell) |
virtual void | AddCellUsingLocationIndex (unsigned index, CellPtr pCell) |
virtual void | RemoveCellUsingLocationIndex (unsigned index, CellPtr pCell) |
void | MoveCellInLocationMap (CellPtr pCell, unsigned old_index, unsigned new_index) |
unsigned | GetLocationIndexUsingCell (CellPtr pCell) |
boost::shared_ptr < CellPropertyRegistry > | GetCellPropertyRegistry () |
void | SetDefaultCellMutationStateAndProliferativeTypeOrdering () |
c_vector< double, SPACE_DIM > | GetCentroidOfCellPopulation () |
virtual void | OpenWritersFiles (OutputFileHandler &rOutputFileHandler) |
void | CloseWritersFiles () |
virtual void | WriteResultsToFiles (const std::string &rDirectory) |
virtual void | AcceptPopulationWriter (boost::shared_ptr< AbstractCellPopulationWriter< ELEMENT_DIM, SPACE_DIM > > pPopulationWriter)=0 |
virtual void | AcceptPopulationCountWriter (boost::shared_ptr< AbstractCellPopulationCountWriter< ELEMENT_DIM, SPACE_DIM > > pPopulationCountWriter)=0 |
virtual void | AcceptCellWriter (boost::shared_ptr< AbstractCellWriter< ELEMENT_DIM, SPACE_DIM > > pCellWriter, CellPtr pCell)=0 |
void | OutputCellPopulationInfo (out_stream &rParamsFile) |
virtual void | SimulationSetupHook (AbstractCellBasedSimulation< ELEMENT_DIM, SPACE_DIM > *pSimulation) |
bool | GetOutputResultsForChasteVisualizer () |
template<template< unsigned, unsigned > class T> | |
void | AddPopulationWriter () |
template<template< unsigned, unsigned > class T> | |
void | AddCellWriter () |
template<template< unsigned, unsigned > class T> | |
void | AddCellPopulationCountWriter () |
void | AddPopulationWriter (boost::shared_ptr< AbstractCellPopulationWriter< ELEMENT_DIM, SPACE_DIM > > pPopulationWriter) |
void | AddCellWriter (boost::shared_ptr< AbstractCellWriter< ELEMENT_DIM, SPACE_DIM > > pCellWriter) |
void | AddCellPopulationCountWriter (boost::shared_ptr< AbstractCellPopulationCountWriter< ELEMENT_DIM, SPACE_DIM > > pCellPopulationCountWriter) |
template<template< unsigned, unsigned > class T> | |
bool | HasWriter () const |
void | SetOutputResultsForChasteVisualizer (bool outputResultsForChasteVisualizer) |
c_vector< double, SPACE_DIM > | GetSizeOfCellPopulation () |
virtual bool | IsRoomToDivide (CellPtr pCell) |
std::pair< unsigned, unsigned > | CreateOrderedPair (unsigned index1, unsigned index2) |
Iterator | Begin () |
Iterator | End () |
Public Member Functions inherited from Identifiable | |
virtual | ~Identifiable () |
std::string | GetIdentifier () const |
Protected Member Functions | |
virtual void | UpdateParticlesAfterReMesh (NodeMap &rMap) |
virtual void | Validate () |
Protected Member Functions inherited from AbstractCentreBasedCellPopulation< DIM > | |
AbstractCentreBasedCellPopulation (AbstractMesh< ELEMENT_DIM, ELEMENT_DIM > &rMesh) | |
virtual void | AcceptCellWritersAcrossPopulation () |
Protected Member Functions inherited from AbstractOffLatticeCellPopulation< ELEMENT_DIM, SPACE_DIM > | |
AbstractOffLatticeCellPopulation (AbstractMesh< ELEMENT_DIM, SPACE_DIM > &rMesh) | |
Protected Member Functions inherited from AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM > | |
AbstractCellPopulation (AbstractMesh< ELEMENT_DIM, SPACE_DIM > &rMesh) | |
Private Member Functions | |
template<class Archive > | |
void | serialize (Archive &archive, const unsigned int version) |
unsigned | AddNode (Node< DIM > *pNewNode) |
void | AddMovedCell (CellPtr pCell, boost::shared_ptr< Node< DIM > > pNode) |
void | DeleteMovedCell (unsigned index) |
void | RefreshHaloCells () |
void | AddNodeAndCellToSendRight (unsigned nodeIndex) |
void | AddNodeAndCellToSendLeft (unsigned nodeIndex) |
void | AddCellsToSendRight (std::vector< unsigned > &cellLocationIndices) |
void | AddCellsToSendLeft (std::vector< unsigned > &cellLocationIndices) |
void | AddReceivedHaloCells () |
void | AddHaloCell (CellPtr pCell, boost::shared_ptr< Node< DIM > > pNode) |
void | UpdateMapsAfterRemesh (NodeMap &map) |
virtual void | WriteVtkResultsToFile (const std::string &rDirectory) |
Private Attributes | |
c_vector< double, DIM > | mMinSpatialPositions |
c_vector< double, DIM > | mMaxSpatialPositions |
std::vector< std::pair< Node < DIM > *, Node< DIM > * > > | mNodePairs |
bool | mDeleteMesh |
bool | mUseVariableRadii |
std::vector< std::pair < CellPtr, Node< DIM > * > > | mCellsToSendRight |
std::vector< std::pair < CellPtr, Node< DIM > * > > | mCellsToSendLeft |
boost::shared_ptr< std::vector < std::pair< CellPtr, Node < DIM > * > > > | mpCellsRecvRight |
boost::shared_ptr< std::vector < std::pair< CellPtr, Node < DIM > * > > > | mpCellsRecvLeft |
ObjectCommunicator < std::vector< std::pair < CellPtr, Node< DIM > * > > > | mRightCommunicator |
ObjectCommunicator < std::vector< std::pair < CellPtr, Node< DIM > * > > > | mLeftCommunicator |
std::vector< CellPtr > | mHaloCells |
std::map< unsigned, CellPtr > | mLocationHaloCellMap |
std::map< CellPtr, unsigned > | mHaloCellLocationMap |
bool | mLoadBalanceMesh |
unsigned | mLoadBalanceFrequency |
Static Private Attributes | |
static const unsigned | mCellCommunicationTag = 123 |
Friends | |
class | TestNodeBasedCellPopulation |
class | TestNodeBasedCellPopulationParallelMethods |
class | boost::serialization::access |
A NodeBasedCellPopulation is a CellPopulation consisting of only nodes in space with associated cells. There are no elements and no mesh.
Definition at line 52 of file NodeBasedCellPopulation.hpp.
NodeBasedCellPopulation< DIM >::NodeBasedCellPopulation | ( | NodesOnlyMesh< DIM > & | rMesh, |
std::vector< CellPtr > & | rCells, | ||
const std::vector< unsigned > | locationIndices = std::vector<unsigned>() , |
||
bool | deleteMesh = false , |
||
bool | validate = true |
||
) |
Default constructor.
Note that the cell population will take responsibility for freeing the memory used by the nodes.
rMesh | a mutable nodes-only mesh |
rCells | a vector of cells |
locationIndices | an optional vector of location indices that correspond to real cells |
deleteMesh | whether to delete nodes-only mesh in destructor |
validate | whether to call Validate() in the constructor or not |
Definition at line 41 of file NodeBasedCellPopulation.cpp.
References NodeBasedCellPopulation< DIM >::mpNodesOnlyMesh, AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >::mrMesh, and NodeBasedCellPopulation< DIM >::Validate().
NodeBasedCellPopulation< DIM >::NodeBasedCellPopulation | ( | NodesOnlyMesh< DIM > & | rMesh | ) |
Constructor for use by the de-serializer.
rMesh | a mutable nodes-only mesh |
Definition at line 61 of file NodeBasedCellPopulation.cpp.
References NodeBasedCellPopulation< DIM >::mpNodesOnlyMesh, and AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >::mrMesh.
|
virtual |
|
virtual |
A virtual method to accept a cell writer so it can write data from this object to file.
pCellWriter | the population writer. |
pCell | the cell whose data are being written. |
Definition at line 317 of file NodeBasedCellPopulation.cpp.
|
virtual |
A virtual method to accept a cell population count writer so it can write data from this object to file.
pPopulationCountWriter | the population count writer. |
Definition at line 311 of file NodeBasedCellPopulation.cpp.
|
virtual |
A virtual method to accept a cell population writer so it can write data from this object to file.
pPopulationWriter | the population writer. |
Definition at line 305 of file NodeBasedCellPopulation.cpp.
|
virtual |
Overridden AddCell() method.
Add a new cell to the cell population and update the vector of cell radii in the NodesOnlyMesh.
pNewCell | the cell to add |
pParentCell | pointer to a parent cell - this is required for node-based cell populations |
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Reimplemented in NodeBasedCellPopulationWithParticles< DIM >.
Definition at line 698 of file NodeBasedCellPopulation.cpp.
References AbstractCentreBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::AddCell(), Node< SPACE_DIM >::GetRadius(), and Node< SPACE_DIM >::SetRadius().
|
private |
Add a collection of cells to send left
cellLocationIndices | the list of location indices of cells to send. |
Definition at line 935 of file NodeBasedCellPopulation.cpp.
|
private |
Add a collection of cells to send right
cellLocationIndices | the list of location indices of cells to send. |
Definition at line 924 of file NodeBasedCellPopulation.cpp.
|
private |
Add a single halo cell with its node to the halo structures on this process.
pCell | the cell to add. |
pNode | the node to add. |
Definition at line 976 of file NodeBasedCellPopulation.cpp.
|
private |
Add a moved cell to this process along with its node.
pCell | the pointer to the cell that is to be added. |
pNode | the pointer to the node that is to be added. |
Definition at line 720 of file NodeBasedCellPopulation.cpp.
|
private |
Overridden AddNode() method.
Add a new node to the cell population.
pNewNode | pointer to the new node |
Definition at line 258 of file NodeBasedCellPopulation.cpp.
|
private |
Add the node and cell with index nodeIndex to the list of cells to send to the process left.
nodeIndex | the index of the node and cell to send. |
Definition at line 832 of file NodeBasedCellPopulation.cpp.
|
private |
Add the node and cell with index nodeIndex to the list of cells to send to the process right.
nodeIndex | the index of the node and cell to send. |
Definition at line 824 of file NodeBasedCellPopulation.cpp.
void NodeBasedCellPopulation< DIM >::AddReceivedCells | ( | ) |
Add the contents of mpCellsRecvRight and mpCellsRecvLeft to the local population.
Definition at line 840 of file NodeBasedCellPopulation.cpp.
References PetscTools::AmMaster(), and PetscTools::AmTopMost().
|
private |
Add halo cells to the halo structure on this process.
Definition at line 946 of file NodeBasedCellPopulation.cpp.
References PetscTools::AmMaster(), and PetscTools::AmTopMost().
void NodeBasedCellPopulation< DIM >::Clear | ( | ) |
Reset the member variables mNodePairs and mpBoxCollection in the underlying mesh.
Definition at line 113 of file NodeBasedCellPopulation.cpp.
|
private |
Delete a cell and its associated node that have moved off this process.
index | the location of the cell to be deleted |
Definition at line 733 of file NodeBasedCellPopulation.cpp.
std::pair< CellPtr, Node< DIM > * > NodeBasedCellPopulation< DIM >::GetCellNodePair | ( | unsigned | nodeIndex | ) |
Helper method to find and pack up nodes and cells together
nodeIndex | the global index of the node. |
Definition at line 812 of file NodeBasedCellPopulation.cpp.
|
virtual |
Overridden method from AbstractCellPopulation so that we can access halo cells through this method.
index | the global index of the node assocaited with a cell |
Reimplemented from AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 270 of file NodeBasedCellPopulation.cpp.
References AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >::GetCellUsingLocationIndex().
Referenced by NodeVelocityWriter< ELEMENT_DIM, SPACE_DIM >::Visit(), and HeterotypicBoundaryLengthWriter< ELEMENT_DIM, SPACE_DIM >::Visit().
double NodeBasedCellPopulation< DIM >::GetMechanicsCutOffLength | ( | ) |
Definition at line 323 of file NodeBasedCellPopulation.cpp.
|
virtual |
Overridden GetNeighbouringNodeIndices() method.
Not that this method only returns node indices for cells that are strictly touching each other.
index | the node index |
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 429 of file NodeBasedCellPopulation.cpp.
References EXCEPTION, Node< SPACE_DIM >::GetNeighboursSetUp(), Node< SPACE_DIM >::GetRadius(), Node< SPACE_DIM >::rGetLocation(), and Node< SPACE_DIM >::rGetNeighbours().
Referenced by BuskeCompressionForce< DIM >::AddForceContribution(), and HeterotypicBoundaryLengthWriter< ELEMENT_DIM, SPACE_DIM >::Visit().
|
virtual |
Overridden GetNode() method.
index | global index of the specified node |
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 137 of file NodeBasedCellPopulation.cpp.
Referenced by HeterotypicBoundaryLengthWriter< ELEMENT_DIM, SPACE_DIM >::Visit().
std::set< unsigned > NodeBasedCellPopulation< DIM >::GetNodesWithinNeighbourhoodRadius | ( | unsigned | index, |
double | neighbourhoodRadius | ||
) |
Method to return nodes within a given radius of a node. Note this is independent of cell radius and returns all nodes within a given radius.
index | the node index |
neighbourhoodRadius | the radius to find neighbours in. Note must be less than the MaximumInteractionDistance in the NodesOnlyMesh |
Definition at line 373 of file NodeBasedCellPopulation.cpp.
References EXCEPTION, Node< SPACE_DIM >::GetNeighboursSetUp(), Node< SPACE_DIM >::rGetLocation(), and Node< SPACE_DIM >::rGetNeighbours().
|
virtual |
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 264 of file NodeBasedCellPopulation.cpp.
void NodeBasedCellPopulation< DIM >::GetReceivedCells | ( | ) |
Obtain proper cell/node pair objects from a previous call to NonBlockingSendCellsToNeighbourProcesses();
Definition at line 799 of file NodeBasedCellPopulation.cpp.
References PetscTools::AmMaster(), and PetscTools::AmTopMost().
c_vector< double, DIM > NodeBasedCellPopulation< DIM >::GetSizeOfCellPopulation | ( | ) |
Overridden GetSizeOfCellPopulation to work in parallel.
Definition at line 359 of file NodeBasedCellPopulation.cpp.
References AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >::GetSizeOfCellPopulation(), and PetscTools::GetWorld().
|
virtual |
Overridden GetTetrahedralMeshForPdeModifier() method.
This method is called by AbstractGrowingDomainPdeModifier.
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 94 of file NodeBasedCellPopulation.cpp.
References AbstractMesh< ELEMENT_DIM, SPACE_DIM >::GetNodeIteratorBegin(), and PetscTools::IsSequential().
bool NodeBasedCellPopulation< DIM >::GetUseVariableRadii | ( | ) |
Definition at line 329 of file NodeBasedCellPopulation.cpp.
|
virtual |
Overridden GetVolumeOfCell() method.
pCell | boost shared pointer to a cell |
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 495 of file NodeBasedCellPopulation.cpp.
References Node< SPACE_DIM >::GetRadius(), and Node< SPACE_DIM >::rGetLocation().
|
virtual |
Overridden GetWidth() method.
Calculate the 'width' of any dimension of the cell population by computing the maximum distance between any nodes in this dimension.
rDimension | a dimension (0,1 or 2) |
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 353 of file NodeBasedCellPopulation.cpp.
void NodeBasedCellPopulation< DIM >::NonBlockingSendCellsToNeighbourProcesses | ( | ) |
Send the contents of mCellsToSendRight/Left to neighbouring processes using asynchronous communication. mpCellsRecvLeft/Right will not be updated until the equivalent GetReceivedCells() is called.
Definition at line 771 of file NodeBasedCellPopulation.cpp.
References PetscTools::AmMaster(), PetscTools::AmTopMost(), PetscTools::GetMyRank(), and SmallPow().
|
virtual |
Outputs CellPopulation parameters to file
As this method is pure virtual, it must be overridden in subclasses.
rParamsFile | the file stream to which the parameters are output |
Reimplemented from AbstractCentreBasedCellPopulation< DIM >.
Reimplemented in NodeBasedCellPopulationWithParticles< DIM >, and NodeBasedCellPopulationWithBuskeUpdate< DIM >.
Definition at line 295 of file NodeBasedCellPopulation.cpp.
References AbstractCentreBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::OutputCellPopulationParameters().
Referenced by NodeBasedCellPopulationWithBuskeUpdate< DIM >::OutputCellPopulationParameters(), and NodeBasedCellPopulationWithParticles< DIM >::OutputCellPopulationParameters().
|
private |
Send and receive halo nodes with neighbours and populate memory structures to store them
Definition at line 906 of file NodeBasedCellPopulation.cpp.
|
virtual |
Remove all cells labelled as dead.
Note that after calling this method the cell population will be in an inconsistent state until the equivalent of a 'remesh' is performed! So don't try iterating over cells or anything like that.
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 227 of file NodeBasedCellPopulation.cpp.
NodesOnlyMesh< DIM > & NodeBasedCellPopulation< DIM >::rGetMesh | ( | ) |
Definition at line 82 of file NodeBasedCellPopulation.cpp.
Referenced by NodeVelocityWriter< ELEMENT_DIM, SPACE_DIM >::Visit(), and HeterotypicBoundaryLengthWriter< ELEMENT_DIM, SPACE_DIM >::Visit().
const NodesOnlyMesh< DIM > & NodeBasedCellPopulation< DIM >::rGetMesh | ( | ) | const |
Definition at line 88 of file NodeBasedCellPopulation.cpp.
|
virtual |
Overridden rGetNodePairs method
Implements AbstractCentreBasedCellPopulation< DIM >.
Definition at line 289 of file NodeBasedCellPopulation.cpp.
void NodeBasedCellPopulation< DIM >::SendCellsToNeighbourProcesses | ( | ) |
Send the contents of mCellsToSendRight/Left to neighbouring processes and receive from them into mpCellsRecvRight/Left.
Definition at line 754 of file NodeBasedCellPopulation.cpp.
References PetscTools::AmMaster(), PetscTools::AmTopMost(), and PetscTools::GetMyRank().
|
inlineprivate |
Serialize the object and its member variables.
Note that serialization of the nodes is handled by load/save_construct_data, so we don't actually have to do anything here except delegate to the base class.
archive | the archive |
version | the current version of this class |
Definition at line 127 of file NodeBasedCellPopulation.hpp.
References NodeBasedCellPopulation< DIM >::mUseVariableRadii, and NodeBasedCellPopulation< DIM >::Validate().
void NodeBasedCellPopulation< DIM >::SetLoadBalanceFrequency | ( | unsigned | loadBalanceFrequency | ) |
Set the freqeuncy, in number of time steps, with which the underlying mesh should be load balanced.
loadBalanceFrequency | the frequency for load balancing. |
Definition at line 347 of file NodeBasedCellPopulation.cpp.
void NodeBasedCellPopulation< DIM >::SetLoadBalanceMesh | ( | bool | loadBalanceMesh | ) |
Set whether to carry out the dynamic load balance algorithm on this mesh when it is updated
loadBalanceMesh | whether to do dynamic load balancing. |
Definition at line 341 of file NodeBasedCellPopulation.cpp.
void NodeBasedCellPopulation< DIM >::SetNode | ( | unsigned | nodeIndex, |
ChastePoint< DIM > & | rNewLocation | ||
) |
Move the node with a given index to a new point in space.
nodeIndex | the index of the node to be moved |
rNewLocation | the new target location of the node |
Definition at line 143 of file NodeBasedCellPopulation.cpp.
void NodeBasedCellPopulation< DIM >::SetUseVariableRadii | ( | bool | useVariableRadii = true | ) |
Set mUseVariableRadii.
useVariableRadii | the new value of mUseVariableRadii |
Definition at line 335 of file NodeBasedCellPopulation.cpp.
|
virtual |
Remove nodes that have been marked as deleted and update the node cell map.
hasHadBirthsOrDeaths | whether cell population has had Births Or Deaths |
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 149 of file NodeBasedCellPopulation.cpp.
References PetscTools::Barrier(), and SimulationTime::Instance().
Referenced by HeterotypicBoundaryLengthWriter< ELEMENT_DIM, SPACE_DIM >::Visit().
|
virtual |
Update which process each cell is owned by.
Reimplemented from AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Definition at line 866 of file NodeBasedCellPopulation.cpp.
|
private |
Update the map between nodes and cells after a call to remesh.
map | The node map from ReMesh. |
Definition at line 195 of file NodeBasedCellPopulation.cpp.
References NodeMap::GetNewIndex(), NodeMap::IsDeleted(), and NodeMap::IsIdentityMap().
|
protectedvirtual |
Update mIsParticle if required by a remesh.
rMap | A map between node indices before and after remesh |
Reimplemented in NodeBasedCellPopulationWithParticles< DIM >.
Definition at line 284 of file NodeBasedCellPopulation.cpp.
|
protectedvirtual |
Check consistency of our internal data structures.
Implements AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM >.
Reimplemented in NodeBasedCellPopulationWithParticles< DIM >.
Definition at line 119 of file NodeBasedCellPopulation.cpp.
References EXCEPTION, AbstractMesh< ELEMENT_DIM, SPACE_DIM >::GetNodeIteratorBegin(), and SimulationTime::Instance().
Referenced by NodeBasedCellPopulation< DIM >::NodeBasedCellPopulation(), and NodeBasedCellPopulation< DIM >::serialize().
|
privatevirtual |
Overridden WriteVtkResultsToFile() method.
rDirectory | pathname of the output directory, relative to where Chaste output is stored |
Implements AbstractCentreBasedCellPopulation< DIM >.
Reimplemented in NodeBasedCellPopulationWithParticles< DIM >.
Definition at line 585 of file NodeBasedCellPopulation.cpp.
References PetscTools::GetMyRank(), SimulationTime::GetTimeStepsElapsed(), SimulationTime::Instance(), PetscTools::IsSequential(), and VtkMeshWriter< ELEMENT_DIM, SPACE_DIM >::SetParallelFiles().
|
friend |
Needed for serialization.
Definition at line 116 of file NodeBasedCellPopulation.hpp.
|
staticprivate |
The tag used to send and recieve cell information
Definition at line 98 of file NodeBasedCellPopulation.hpp.
|
private |
The cells to send to the left process
Definition at line 83 of file NodeBasedCellPopulation.hpp.
|
private |
The cells to send to the right process
Definition at line 80 of file NodeBasedCellPopulation.hpp.
|
private |
Whether to delete the nodes-only mesh (taken in one of the constructors, defaults to false).
Definition at line 74 of file NodeBasedCellPopulation.hpp.
|
private |
Map halo cells back to location indices
Definition at line 107 of file NodeBasedCellPopulation.hpp.
|
private |
Pointers to halo cells
Definition at line 101 of file NodeBasedCellPopulation.hpp.
|
private |
A communicator to send cells to the left hand process
Definition at line 95 of file NodeBasedCellPopulation.hpp.
|
private |
The frequency at which the mesh is rebalanced
Definition at line 113 of file NodeBasedCellPopulation.hpp.
|
private |
Whether to load balance the underlying mesh dynamically
Definition at line 110 of file NodeBasedCellPopulation.hpp.
|
private |
Map location indices back to halo cells
Definition at line 104 of file NodeBasedCellPopulation.hpp.
|
private |
Vector of maximal spatial positions in each dimension.
Definition at line 68 of file NodeBasedCellPopulation.hpp.
|
private |
Vector of minimal spatial positions in each dimension.
Definition at line 65 of file NodeBasedCellPopulation.hpp.
|
private |
Node pairs for force calculations.
Definition at line 71 of file NodeBasedCellPopulation.hpp.
|
private |
A pointer to the cells received from the left process
Definition at line 89 of file NodeBasedCellPopulation.hpp.
|
private |
A shared pointer to the cells received from the right process
Definition at line 86 of file NodeBasedCellPopulation.hpp.
|
protected |
Static cast of the mesh from AbstractCellPopulation.
Definition at line 60 of file NodeBasedCellPopulation.hpp.
Referenced by NodeBasedCellPopulation< DIM >::NodeBasedCellPopulation().
|
private |
A communicator to send cells to the right hand process
Definition at line 92 of file NodeBasedCellPopulation.hpp.
|
private |
Whether or not to have cell radii updated from CellData defaults to false.
Definition at line 77 of file NodeBasedCellPopulation.hpp.
Referenced by NodeBasedCellPopulation< DIM >::serialize().