Source

Adapted from my own handwritten and hand-typed notes from Year 1 to Year 3 of my EEE degree

The improved Euler method (also called Heun's method) predicts with Euler, then corrects using the average of the slopes at both ends of the step.

Idea

Integrating from to gives

Approximating the integral with the trapezoidal rule:

The unknown on the right is replaced by the plain Euler guess .

Formula

is the Euler increment (predictor) and is the increment using the slope at the predicted end point (corrector).

Error

Error behaviour:

  • local truncation error
  • global error , so it is a second order method

Worked example

Same IVP as the Euler example: , , .

Solution:

  • step 1: , ,
  • step 2: , ,
0.20.40.60.81.0
Heun 0.02000.08840.21580.41530.7027
exact0.02140.09180.22210.42550.7183

The error at drops from 0.23 (Euler) to 0.016. Going further to four slope samples per step gives the Fourth Order Runge-Kutta Method.