CMD + K

Kapittel 4 · Differensialligningernumerical ODEs

Euler vs RK4: Same Step Size, Different Curves

0:53Fortellerstemme
0:00 / 0:00

Same ODE, same step size, two methods. Euler uses one tangent per step and drifts; classical Runge-Kutta samples four slopes per step, averages them, and hugs the true curve. A log-log error plot lays the order claim bare: slope 1 for Euler, slope 4 for RK4.

Runge-Kutta methodRK4order of accuracyglobal errorlog-log error plotEuler's method