next up previous index
Next: Example Code Up: Pushing Particles Previous: The Mid-Point Method

The Fourth-Order Runge-Kutta Method

The most often used method of the Runge-Kutta family is the Fourth-Order one, which extends the idea of the mid-point method, by jumping 1/4th of the way first, then going half-way, a la the mid-point method, then going 3/4th of the way and finally juping all the way.

The formula for this method looks as follows:

k1 = $\displaystyle f\left(x_n, t_n\right) \Delta t$  
k2 = $\displaystyle f\left(x_n + k_1 / 2, t_n + \Delta t / 2\right) \Delta t$  
k3 = $\displaystyle f\left(x_n + k_2 / 2, t_n + \Delta t / 2\right) \Delta t$  
k4 = $\displaystyle f\left(x_n + k_3, t_n + \Delta t\right)\Delta t$  
xn+1 = $\displaystyle x_n + \frac{k_1}{6} + \frac{k_2}{3} + \frac{k_3}{3}
+ \frac{k_4}{6} + {\cal O}\left((\Delta t)^5\right)$  


Zdzislaw Meglicki