Read this lesson as text

Runge-Kutta Methods

Numerical Analysis · Axiom Academy

LESSON Runge-Kutta Methods Introduction Achieving high-order accuracy for ODEs without computing derivatives of f. Motivation: The Best of Both Worlds Consider solving y' = f(t, y). Taylor methods give us accuracy via: Requires computing f, f', f'', ... up to f (n-1) Can we achieve the accuracy of Taylor methods by evaluating f at multiple carefully chosen points instead of computing its derivatives? The general form of an s-stage explicit Runge-Kutta method is: Where each k i is a slope estimate: Multiple slope evaluations (arrows) are combined to estimate the solution curve Second-Order Runge-Kutta Methods (RK2) The simplest Runge-Kutta methods use two function evaluations per step: Uses k 1 to step to the midpoint, then uses the slope there for the full step. Heun's Method (Improved Euler) Averages the slopes at the start and end (predicted) of the interval. Both Methods Are Second-Order Accurate! Despite looking different, both midpoint and Heun's methods have local error O(h 3 ) and global error O(h 2 ). They differ in their error constants. For a 2-stage method with unknown parameters: Midpoint: alpha = 0, beta = 1, c 2 = 1/2, a 21 = 1/2 Heun: alpha = 1/2, beta = 1/2, c 2 = 1, a 21 = 1 Ralston: alpha = 1/4, beta = 3/4, c 2 = 2/3, a 21 = 2/3 (minimizes error) General RK Framework: Butcher Tableau For explicit methods, a ij = 0 for j >= i (upper triangle is zero). This ensures that k i is evaluated at time t n + c i h.

This is the written version of the interactive lesson above. See the full Numerical Analysis course.