Home | Doxygen Documentation | Tutorials | Developer Tools (restricted)

timestepping/rungekutta4.hh
Go to the documentation of this file.
00001 
00002 // newmark strategy
00003 
00004 #ifndef rungekutta4_hh
00005 #define rungekutta4_hh
00006 
00007 #include "basics/typedefs.hh"
00008 #include "function/vector.hh"
00009 #include "strategy.hh"
00010 
00011 namespace concepts {
00012   template<typename F>
00013   class Operator;
00014 }
00015 
00016 namespace timestepping {
00017 
00018   using concepts::Real;
00019 
00020   class TimeVector;
00021 
00022   // ************************************************* Runge Kutta 4th order **
00023 
00034   class RungeKutta4 : public TimeStepStrategy {
00035   public:
00045     RungeKutta4(concepts::SolverFabric<Real>& fabric,
00046                 concepts::Operator<Real>& D1,
00047                 concepts::Operator<Real>& D0,
00048                 timestepping::TimeVector& trhs,
00049                 const concepts::Vector<Real>& Y0,
00050                 Real dt);
00051     virtual ~RungeKutta4();
00052   protected:
00053     virtual std::ostream& info(std::ostream& os) const;
00054     virtual void next();
00055   private:
00057     concepts::Operator<Real> &D1_, &D0_;
00059     timestepping::TimeVector &trhs_;
00061     concepts::Vector<Real> Yn1_;    // Yn1 = Y(t_{n-1})
00062   };
00063 
00064 }
00065 
00066 #endif // rungekutta4_hh

Home | Doxygen Documentation | Tutorials | Developer Tools (restricted)