DeltaNotchOdeSystem.hpp
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
00029
00030
00031
00032
00033
00034
00035
00036 #ifndef DELTANOTCHODESYSTEM_HPP_
00037 #define DELTANOTCHODESYSTEM_HPP_
00038
00039 #include "ChasteSerialization.hpp"
00040 #include <boost/serialization/base_object.hpp>
00041
00042 #include <cmath>
00043 #include <iostream>
00044
00045 #include "AbstractOdeSystem.hpp"
00046
00053 class DeltaNotchOdeSystem : public AbstractOdeSystem
00054 {
00055 private:
00056
00057 friend class boost::serialization::access;
00064 template<class Archive>
00065 void serialize(Archive & archive, const unsigned int version)
00066 {
00067 archive & boost::serialization::base_object<AbstractOdeSystem>(*this);
00068 }
00069
00071
00072 public:
00073
00079 DeltaNotchOdeSystem(std::vector<double> stateVariables=std::vector<double>());
00080
00084 ~DeltaNotchOdeSystem();
00085
00096 void EvaluateYDerivatives(double time, const std::vector<double>& rY, std::vector<double>& rDY);
00097 };
00098
00099
00100 #include "SerializationExportWrapper.hpp"
00101 CHASTE_CLASS_EXPORT(DeltaNotchOdeSystem)
00102
00103 namespace boost
00104 {
00105 namespace serialization
00106 {
00110 template<class Archive>
00111 inline void save_construct_data(
00112 Archive & ar, const DeltaNotchOdeSystem * t, const BOOST_PFTO unsigned int file_version)
00113 {
00114 const std::vector<double> state_variables = t->rGetConstStateVariables();
00115 ar & state_variables;
00116 }
00117
00121 template<class Archive>
00122 inline void load_construct_data(
00123 Archive & ar, DeltaNotchOdeSystem * t, const unsigned int file_version)
00124 {
00125 std::vector<double> state_variables;
00126 ar & state_variables;
00127
00128
00129 ::new(t)DeltaNotchOdeSystem(state_variables);
00130 }
00131 }
00132 }
00133
00134 #endif