/runge_kutta_4th_order

Runge-Kutta 4th order discrete function approximation in C++

Primary LanguageC++

Runge-Kutta 4th order differential equation solver

In numerical analysis, the Runge–Kutta methods are a family of implicit and explicit iterative methods, which include the well-known routine called the Euler Method, used in temporal discretization for the approximate solutions of ordinary differential equations.

Prerequisites

GCC Compiler, Boost Library and a terminal

Running

The project is supplied with a make file.

The following make commands are available:

> make

Compiles source and executes the program. Install any missing libs if prompted


> make clean

Cleans executable

Results

The program runs RK 4th order method to calculate value of Euler's constant e.

Two methods are used namely:

  • Generic RK method

  • Adaptive RK method

A graph is plotted for both the iteration cycles using gnuplot.

The header file for the same is already provided in the project.