CLHEP VERSION Reference Documentation
   
CLHEP Home Page     CLHEP Documentation     CLHEP Bug Reports

CLHEP/GenericFunctions/SimpleRKStepper.hh
Go to the documentation of this file.
1 #ifndef _SimpleRKStepper_h_
2 #define _SimpleRKStepper_h_
4 //
5 // This is a stepper that steps with stepsize h using an
6 // Explicit Runge-Kutte method determined by a Butcher
7 // tableau.
8 //
9 // The stepsize is therefore not adaptively determined;
10 // so this type of stepper is mostly useful in attempting
11 // to categorize the different explicit RK Algorithms
12 // and probably not for real-life problems unless one has
13 // some a priori knowledge about how to set the stepsize.
14 //
16 namespace Genfun {
18 
19  public:
20 
21  // Constructor:
22  SimpleRKStepper(const ButcherTableau & tableau,
23  double stepsize);
24 
25  // Destructor:
26  virtual ~SimpleRKStepper();
27 
28  // Take a step:
29  virtual void step (const RKIntegrator::RKData * data, // functions
30  const RKIntegrator::RKData::Data & sdata, // start point
31  RKIntegrator::RKData::Data & ddata, // end point
32  double timeLimit // time limit
33  ) const ;
34  // Clone:
35  virtual SimpleRKStepper *clone() const;
36 
37 private:
38 
39  ButcherTableau tableau;
40  double stepsize;
41 
42  };
43 }
44 
45 #endif
SimpleRKStepper(const ButcherTableau &tableau, double stepsize)
virtual void step(const RKIntegrator::RKData *data, const RKIntegrator::RKData::Data &sdata, RKIntegrator::RKData::Data &ddata, double timeLimit) const
virtual SimpleRKStepper * clone() const