TAPs 0.7.7.3
TAPsODESolverEuler.hpp
Go to the documentation of this file.
00001 /******************************************************************************
00002 TAPsODESolverEuler.hpp
00003 ******************************************************************************/
00029 /******************************************************************************
00030 SUKITTI PUNAK   (07/10/2005)
00031 UPDATE          (08/18/2010)
00032 ******************************************************************************/
00033 #ifndef TAPs_ODE_SOLVER_EULER_HPP
00034 #define TAPs_ODE_SOLVER_EULER_HPP
00035 
00036 #include "TAPsODESolver.hpp"
00037 
00038 BEGIN_NAMESPACE_TAPs__Simulation
00039 //=============================================================================
00040 //-----------------------------------------------------------------------------
00041 template <typename T, typename T_SET = T>
00042 class ODESolverEuler : public ODESolver<T, T_SET>
00043 {
00044 public:
00045     ODESolverEuler ();
00046 
00047     virtual ~ODESolverEuler ();
00048 
00049     virtual void SetSize ( int vectorSize );    // set data size
00050 
00051     virtual void Solve ( 
00052         VectorSet<T_SET> &x0,   // i/p: x(t_0) an initial state vector
00053         VectorSet<T_SET> &xEnd, // o/p: x(t_1) an end state vector
00054         T t0, T t1,             // i/p: starting and ending times
00055         DerivFunc dxdt,         // i/p: a derivative function
00056         void *userData          // o/p: array of user data
00057     );
00058 
00059     //virtual void Solve_ForPtrData ( 
00060     //  VectorSetPtr<T_SET,T> &x0,      // i/p: x(t_0) an initial state vector
00061     //  VectorSetPtr<T_SET,T> &xEnd,    // o/p: x(t_1) an end state vector
00062     //  T t0, T t1,                     // i/p: starting and ending times
00063     //  DerivFunc_ForPtrData dxdt,      // i/p: a derivative function
00064     //  void *userData                  // o/p: array of user data
00065     //);
00066 
00067 private:
00068     // temp VectorSet used by the Euler ode solver
00069     VectorSet<T_SET> vStart;
00070 };
00071 //-----------------------------------------------------------------------------
00072 //=============================================================================
00073 END_NAMESPACE_TAPs__Simulation
00074 //-----------------------------------------------------------------------------
00075 // Include definition if TAPs_USE_EXPORT is not defined
00076 //#if !defined( TAPs_USE_EXPORT )
00077     #include "TAPsODESolverEuler.cpp"
00078 //#endif
00079 //-----------------------------------------------------------------------------
00080 #endif
00081 //34567890123456789012345678901234567890123456789012345678901234567890123456789
00082 //--+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines