Chaste  Release::2018.1
MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator Class Reference

#include <MeshBasedCellPopulation.hpp>

+ Collaboration diagram for MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator:

Public Member Functions

Node< SPACE_DIM > * GetNodeA ()
 
Node< SPACE_DIM > * GetNodeB ()
 
CellPtr GetCellA ()
 
CellPtr GetCellB ()
 
bool operator!= (const typename MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator &rOther)
 
SpringIteratoroperator++ ()
 
 SpringIterator (MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM > &rCellPopulation, typename MutableMesh< ELEMENT_DIM, SPACE_DIM >::EdgeIterator edgeIter)
 

Private Attributes

std::set< std::set< unsigned > > mSpringsVisited
 
MeshBasedCellPopulation
< ELEMENT_DIM, SPACE_DIM > & 
mrCellPopulation
 
MutableMesh< ELEMENT_DIM,
SPACE_DIM >::EdgeIterator 
mEdgeIter
 

Detailed Description

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
class MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator

Iterator over edges in the mesh, which correspond to springs between cells.

This class takes care of the logic to make sure that you consider each edge exactly once.

Definition at line 444 of file MeshBasedCellPopulation.hpp.

Constructor & Destructor Documentation

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::SpringIterator ( MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM > &  rCellPopulation,
typename MutableMesh< ELEMENT_DIM, SPACE_DIM >::EdgeIterator  edgeIter 
)

Constructor for a new iterator.

Parameters
rCellPopulationthe cell population
edgeIteriterator over edges in the mesh

Definition at line 914 of file MeshBasedCellPopulation.cpp.

References TetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::EdgesEnd(), MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::mEdgeIter, and MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::mrCellPopulation.

Member Function Documentation

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
CellPtr MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::GetCellA ( )
Returns
the cell at end A of the spring.

Definition at line 873 of file MeshBasedCellPopulation.cpp.

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
CellPtr MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::GetCellB ( )
Returns
the cell at end B of the spring.

Definition at line 880 of file MeshBasedCellPopulation.cpp.

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
Node< SPACE_DIM > * MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::GetNodeA ( )
Returns
a pointer to the node in the mesh at end A of the spring.

Definition at line 861 of file MeshBasedCellPopulation.cpp.

References MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::mEdgeIter.

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
Node< SPACE_DIM > * MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::GetNodeB ( )
Returns
a pointer to the node in the mesh at end B of the spring.

Definition at line 867 of file MeshBasedCellPopulation.cpp.

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
bool MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::operator!= ( const typename MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator rOther)

Comparison not-equal-to.

Parameters
rOtherSpringIterator with which comparison is made
Returns
not-equal

Definition at line 887 of file MeshBasedCellPopulation.cpp.

References MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::mEdgeIter.

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator & MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::operator++ ( )

Prefix increment operator.

Returns
incremented object

Definition at line 893 of file MeshBasedCellPopulation.cpp.

Member Data Documentation

template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
MutableMesh<ELEMENT_DIM, SPACE_DIM>::EdgeIterator MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::mEdgeIter
private
template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
MeshBasedCellPopulation<ELEMENT_DIM, SPACE_DIM>& MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::mrCellPopulation
private
template<unsigned ELEMENT_DIM, unsigned SPACE_DIM = ELEMENT_DIM>
std::set<std::set<unsigned> > MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::SpringIterator::mSpringsVisited
private

Keep track of what edges have been visited.

Definition at line 493 of file MeshBasedCellPopulation.hpp.


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