36 #ifndef POTTSBASEDCELLPOPULATION_HPP_ 37 #define POTTSBASEDCELLPOPULATION_HPP_ 39 #include "AbstractOnLatticeCellPopulation.hpp" 40 #include "PottsMesh.hpp" 41 #include "VertexMesh.hpp" 42 #include "AbstractUpdateRule.hpp" 43 #include "MutableMesh.hpp" 46 #include <boost/serialization/base_object.hpp> 47 #include <boost/serialization/vector.hpp> 59 template<
unsigned DIM>
62 friend class TestPottsBasedCellPopulation;
94 friend class boost::serialization::access;
106 template<
class Archive>
107 void serialize(Archive & archive,
const unsigned int version)
109 archive & boost::serialization::base_object<AbstractOnLatticeCellPopulation<DIM> >(*this);
116 mpElementTessellation =
nullptr;
155 std::vector<CellPtr>& rCells,
156 bool deleteMesh=
false,
158 const std::vector<unsigned> locationIndices=std::vector<unsigned>());
259 CellPtr
AddCell(CellPtr pNewCell, CellPtr pParentCell=CellPtr());
293 void Update(
bool hasHadBirthsOrDeaths=
true);
353 double GetWidth(
const unsigned& rDimension);
432 std::string& rVariableName,
433 bool dirichletBoundaryConditionApplies=
false,
434 double dirichletBoundaryValue=0.0);
442 namespace serialization
447 template<
class Archive,
unsigned DIM>
448 inline void save_construct_data(
460 template<
class Archive,
unsigned DIM>
461 inline void load_construct_data(
PottsMesh< DIM > * mpPottsMesh
Node< DIM > * GetNode(unsigned index)
PottsMesh< DIM > & rGetMesh()
MutableMesh< DIM, DIM > * mpMutableMesh
VertexMesh< DIM, DIM > * GetElementTessellation()
std::set< unsigned > GetNeighbouringLocationIndices(CellPtr pCell)
PottsElement< DIM > * GetElementCorrespondingToCell(CellPtr pCell)
unsigned GetNumElements()
unsigned RemoveDeadCells()
virtual void AcceptPopulationCountWriter(boost::shared_ptr< AbstractCellPopulationCountWriter< DIM, DIM > > pPopulationCountWriter)
virtual double GetCellDataItemAtPdeNode(unsigned pdeNodeIndex, std::string &rVariableName, bool dirichletBoundaryConditionApplies=false, double dirichletBoundaryValue=0.0)
void CreateElementTessellation()
c_vector< double, DIM > GetLocationOfCellCentre(CellPtr pCell)
virtual void AcceptCellWriter(boost::shared_ptr< AbstractCellWriter< DIM, DIM > > pCellWriter, CellPtr pCell)
#define EXPORT_TEMPLATE_CLASS_SAME_DIMS(CLASS)
void OutputCellPopulationParameters(out_stream &rParamsFile)
void SetTemperature(double temperature)
virtual void WriteVtkResultsToFile(const std::string &rDirectory)
virtual void AcceptPopulationWriter(boost::shared_ptr< AbstractCellPopulationWriter< DIM, DIM > > pPopulationWriter)
void Update(bool hasHadBirthsOrDeaths=true)
virtual void AddUpdateRule(boost::shared_ptr< AbstractUpdateRule< DIM > > pUpdateRule)
double GetVolumeOfCell(CellPtr pCell)
void serialize(Archive &archive, const unsigned int version)
unsigned mNumSweepsPerTimestep
virtual void WriteResultsToFiles(const std::string &rDirectory)
CellPtr AddCell(CellPtr pNewCell, CellPtr pParentCell=CellPtr())
virtual TetrahedralMesh< DIM, DIM > * GetTetrahedralMeshForPdeModifier()
MutableMesh< DIM, DIM > * GetMutableMesh()
void UpdateCellLocations(double dt)
PottsElement< DIM > * GetElement(unsigned elementIndex)
double GetWidth(const unsigned &rDimension)
virtual void OpenWritersFiles(OutputFileHandler &rOutputFileHandler)
unsigned GetNumSweepsPerTimestep()
gcov doesn't like this file...
virtual ~PottsBasedCellPopulation()
void SetNumSweepsPerTimestep(unsigned numSweepsPerTimestep)
VertexMesh< DIM, DIM > * mpElementTessellation
PottsBasedCellPopulation(PottsMesh< DIM > &rMesh, std::vector< CellPtr > &rCells, bool deleteMesh=false, bool validate=true, const std::vector< unsigned > locationIndices=std::vector< unsigned >())
bool IsCellAssociatedWithADeletedLocation(CellPtr pCell)