00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef _ALARCON2004OXYGENBASEDCELLCYCLEODESYSTEM_HPP_
00029 #define _ALARCON2004OXYGENBASEDCELLCYCLEODESYSTEM_HPP_
00030
00031 #include "ChasteSerialization.hpp"
00032 #include <boost/serialization/base_object.hpp>
00033
00034 #include <cmath>
00035
00036 #include "AbstractOdeSystem.hpp"
00037
00051 class Alarcon2004OxygenBasedCellCycleOdeSystem : public AbstractOdeSystem
00052 {
00053 private:
00054
00060 double ma1;
00062 double ma2;
00064 double ma3;
00066 double ma4;
00068 double mb3;
00070 double mb4;
00072 double mc1;
00074 double mc2;
00076 double md1;
00078 double md2;
00080 double mJ3;
00082 double mJ4;
00084 double mEta;
00086 double mMstar;
00088 double mB;
00090 double mxThreshold;
00092 double myThreshold;
00093
00095 double mOxygenConcentration;
00096
00098 bool mIsLabelled;
00099
00100 friend class boost::serialization::access;
00107 template<class Archive>
00108 void serialize(Archive & archive, const unsigned int version)
00109 {
00110 archive & boost::serialization::base_object<AbstractOdeSystem>(*this);
00111 }
00112
00113 public:
00114
00122 Alarcon2004OxygenBasedCellCycleOdeSystem(double oxygenConcentration,
00123 bool isLabelled,
00124 std::vector<double> stateVariables=std::vector<double>());
00125
00129 ~Alarcon2004OxygenBasedCellCycleOdeSystem();
00130
00134 void Init();
00135
00146 void EvaluateYDerivatives(double time, const std::vector<double>& rY, std::vector<double>& rDY);
00147
00156 bool CalculateStoppingEvent(double time, const std::vector<double>& rY);
00157
00163 void SetIsLabelled(bool isLabelled);
00164
00168 bool IsLabelled() const;
00169
00173 double GetOxygenConcentration() const;
00174 };
00175
00176
00177 #include "SerializationExportWrapper.hpp"
00178 CHASTE_CLASS_EXPORT(Alarcon2004OxygenBasedCellCycleOdeSystem)
00179
00180 namespace boost
00181 {
00182 namespace serialization
00183 {
00187 template<class Archive>
00188 inline void save_construct_data(
00189 Archive & ar, const Alarcon2004OxygenBasedCellCycleOdeSystem * t, const BOOST_PFTO unsigned int file_version)
00190 {
00191
00192 const double oxygen_concentration = t->GetOxygenConcentration();
00193 ar & oxygen_concentration;
00194
00195 const bool is_labelled = t->IsLabelled();
00196 ar & is_labelled;
00197
00198 const std::vector<double> state_variables = t->rGetConstStateVariables();
00199 ar & state_variables;
00200 }
00201
00205 template<class Archive>
00206 inline void load_construct_data(
00207 Archive & ar, Alarcon2004OxygenBasedCellCycleOdeSystem * t, const unsigned int file_version)
00208 {
00209
00210 double oxygen_concentration;
00211 ar & oxygen_concentration;
00212
00213 bool is_labelled;
00214 ar & is_labelled;
00215
00216 std::vector<double> state_variables;
00217 ar & state_variables;
00218
00219
00220 ::new(t)Alarcon2004OxygenBasedCellCycleOdeSystem(oxygen_concentration, is_labelled, state_variables);
00221 }
00222 }
00223 }
00224
00225 #endif