36 #ifndef OFFLATTICESIMULATION_HPP_
37 #define OFFLATTICESIMULATION_HPP_
39 #include "AbstractCellBasedSimulation.hpp"
40 #include "AbstractForce.hpp"
41 #include "AbstractCellPopulationBoundaryCondition.hpp"
42 #include "AbstractNumericalMethod.hpp"
45 #include <boost/serialization/base_object.hpp>
46 #include <boost/serialization/set.hpp>
47 #include <boost/serialization/vector.hpp>
70 template<
unsigned ELEMENT_DIM,
unsigned SPACE_DIM=ELEMENT_DIM>
76 friend class boost::serialization::access;
77 friend class TestOffLatticeSimulation;
78 friend class TestOffLatticeSimulationWithNodeBasedCellPopulation;
86 template<
class Archive>
87 void serialize(Archive & archive,
const unsigned int version)
89 archive & boost::serialization::base_object<AbstractCellBasedSimulation<ELEMENT_DIM,SPACE_DIM> >(*this);
98 std::vector<boost::shared_ptr<AbstractForce<ELEMENT_DIM, SPACE_DIM> > >
mForceCollection;
101 std::vector<boost::shared_ptr<AbstractCellPopulationBoundaryCondition<ELEMENT_DIM,SPACE_DIM> > >
mBoundaryConditions;
150 bool deleteCellPopulationInDestructor=
false,
151 bool initialiseCells=
true);
187 const boost::shared_ptr<AbstractNumericalMethod<ELEMENT_DIM, SPACE_DIM> >
GetNumericalMethod()
const;
210 const std::vector<boost::shared_ptr<AbstractForce<ELEMENT_DIM, SPACE_DIM> > >&
rGetForceCollection()
const;
219 namespace serialization
224 template<
class Archive,
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
225 inline void save_construct_data(
230 ar & p_cell_population;
236 template<
class Archive,
unsigned ELEMENT_DIM,
unsigned SPACE_DIM>
237 inline void load_construct_data(
242 ar >> p_cell_population;
boost::shared_ptr< AbstractNumericalMethod< ELEMENT_DIM, SPACE_DIM > > mpNumericalMethod
const boost::shared_ptr< AbstractNumericalMethod< ELEMENT_DIM, SPACE_DIM > > GetNumericalMethod() const
void OutputAdditionalSimulationSetup(out_stream &rParamsFile)
virtual void WriteVisualizerSetupFile()
virtual void SetupSolve()
const std::vector< boost::shared_ptr< AbstractForce< ELEMENT_DIM, SPACE_DIM > > > & rGetForceCollection() const
AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM > & rGetCellPopulation()
std::vector< boost::shared_ptr< AbstractCellPopulationBoundaryCondition< ELEMENT_DIM, SPACE_DIM > > > mBoundaryConditions
void SetNumericalMethod(boost::shared_ptr< AbstractNumericalMethod< ELEMENT_DIM, SPACE_DIM > > pNumericalMethod)
void serialize(Archive &archive, const unsigned int version)
void ApplyBoundaries(std::map< Node< SPACE_DIM > *, c_vector< double, SPACE_DIM > > oldNodeLoctions)
void AddForce(boost::shared_ptr< AbstractForce< ELEMENT_DIM, SPACE_DIM > > pForce)
void RemoveAllCellPopulationBoundaryConditions()
void RevertToOldLocations(std::map< Node< SPACE_DIM > *, c_vector< double, SPACE_DIM > > oldNodeLoctions)
#define EXPORT_TEMPLATE_CLASS_ALL_DIMS(CLASS)
std::vector< boost::shared_ptr< AbstractForce< ELEMENT_DIM, SPACE_DIM > > > mForceCollection
OffLatticeSimulation(AbstractCellPopulation< ELEMENT_DIM, SPACE_DIM > &rCellPopulation, bool deleteCellPopulationInDestructor=false, bool initialiseCells=true)
gcov doesn't like this file...
virtual void OutputSimulationParameters(out_stream &rParamsFile)
virtual void UpdateCellLocationsAndTopology()
void AddCellPopulationBoundaryCondition(boost::shared_ptr< AbstractCellPopulationBoundaryCondition< ELEMENT_DIM, SPACE_DIM > > pBoundaryCondition)