





The following are not stiff differential equations, however, the techniques may still be applied.
Example 1
Given the IVP y(1)(t) = 1 - t y(t) with y(0) = 1, approximate y(1) with one step.
First, let t0 = 0, y0 = 1, and h = 1. Thus, we write down the equation
and, after substituting the appropriate values, we get
Solving this equation yields υ = 1, and therefore we set y1 = 1. The absolute error is 0.33.
Example 2
Given the same IVP shown in Example 1, approximate y(0.5).
First, let t0 = 0, t1 = 0.5, y0 = 1, and h = 0.5. Thus, we write down the equation
and, after substituting the appropriate values, we get
Solving this equation yields υ = 1.2, and therefore we set y1 = 1.2. The absolute error is 0.14 which is approximately the absolute error in Example 1.
Example 3
Repeat Examples 1 and 2 but with with the initial value y(0.5) = 2.5 and approximating y(1.5) and y(1.0).
To find y(1.5), let t0 = 0.0, t1 = 1.5, y0 = 2.5, and h = 1. Thus, the equation
Solving this equation yields υ = 1.4, and therefore we set y1 = 1.4. The actual value is y(1.5) = 1.502483616, and therefore the absolute error is 0.102.
To find y(1.0), let t0 = 0.0, t1 = 1.0, y0 = 2.5, and h = 0.5. Thus, the equation is
Solving this equation yields υ = 2, and therefore we set y1 = 2. The actual value is y(1) = 2.126611964 and therefore the absolute error is 0.127.
This absolute error is larger than it was when h = 1.0, and thus, to show that the error is O(h2), we must use smaller values of h. These are shown in Table 1.
Table 1. Errors when approximating y(t0 + h) for decreasing values of h.
h | Approximation of y(0.5 + h) | Error |
---|---|---|
1. | 1.4 | 0.102 |
0.5 | 2. | 0.127 |
0.25 | 2.315789474 | 0.0528 |
0.125 | 2.434782609 | 0.0160 |
0.0625 | 2.475471698 | 0.00434 |
0.03125 | 2.489913546 | 0.00112 |
0.015625 | 2.495519495 | 0.000285 |
0.0078125 | 2.497902608 | 0.0000719 |
0.00390625 | 2.498987283 | 0.0000181 |
0.001953125 | 2.499502670 | 0.00000452 |
0.0009765625 | 2.499753595 | 0.00000113 |
The quadratic behaviour becomes obvious with the last step, being smaller by almost exactly 4.
Copyright ©2005 by Douglas Wilhelm Harder. All rights reserved.