Let y = f (x) be a solution to the IVP

What is the error when Euler's method is used to estimate f (2) with a step size of 0.5? With a step size of 0.25?
Answer
Since we're asked about error, we'll need to know the exact value of f (2). Thinking backwards, f (x) = 2x2 + C. Since f (1) = 3,
2(1)2 + C = 3
so C = 1 and f (x) = 2x2 + 1. The exact value in question is
f (2) = 2(2)2 + 1 = 9.
Euler's method with step size 0.5 gets us this table:

The error is 1, since the exact value of f (2) is 9 but Euler's method approximated f (2) ≅ 8. Euler's method with step size .25 gets us this table:

With step size 0.25 Euler's method approximates f (2) ≅ 8.5. The error in this case is 0.5.