Derivation: fourth-order Runge-Kutta
Applying Simpson's rule to the integral form of the IVP and approximating the unknown slopes with chained internal evaluations produces the classical RK4 and explains its 1, 2, 2, 1 weights.
Simpson on the integral form
First integrate the differential equation over the subinterval :
Applying the Fundamental Theorem of Calculus to the left-hand side gives the exact integral form of the IVP:
Approximate the integral with Simpson's rule, which uses the endpoints and the midpoint :
Problem: we know neither nor . Runge-Kutta's solution is to estimate them with chained internal slopes, each built by advancing with the previous one:
Simpson's central slope is approximated by averaging the two midpoint estimates, and the final one by :
Substituting into Simpson, the midpoint weight splits as , and the classical RK4 appears with its weights:
A Taylor analysis analogous to Heun's (but up to fourth order) confirms that these internal approximations preserve the local error, so the method is fourth order.