All pastes #100686 Raw Edit

Someone

public cpp v1 · immutable
#100686 ·published 2006-07-26 10:33 UTC
rendered paste body
#include <iostream>using namespace std;class myrunge{   public:   virtual double fk(double x) = 0;};class RungeKutta : public myrunge{      public:      void step(double *pt, double *px, double h);      double fk(double x);      double a;};double RungeKutta::fk(double x){   return  (a*x);}void RungeKutta::step(double *pt, double *px, double h){   double f;   *px = 1 + h * fk(1);   *px = 1 + (h / 2) * ( fk(1) + fk(*px));    f = fk(*pt);   *pt = *pt + 0.1;}int main(){    return 0;}