Why Compare Step Sizes?
Forward Euler gives an approximate solution to an initial-value problem by repeatedly using the slope at the current point to estimate the next value. A smaller step usually gives a more accurate approximation, but it also requires more updates. Comparing step sizes makes this trade-off concrete: it shows how much the estimate changes and what extra computational work is involved.
We will use the same initial-value problem and the same time interval throughout, changing only the uniform step size. Because this problem has an exact solution, we can also measure the endpoint error rather than judging accuracy from the Euler estimates alone.
Uniform Forward Euler Steps
Here \(y_k\) denotes the Euler estimate at time \(t_k\), not necessarily the exact value \(y(t_k)\). Each step requires one evaluation of \(f\), followed by one update. We will estimate the solution at \(T=1\), starting from \(t_0=0\), and compare \(n=1,2,4,\) and \(8\) equal steps.
The Initial-Value Problem and Benchmark
Consider
The exact solution is \(y(t)=e^t\): its derivative is \(e^t\), which equals \(y(t)\), and its initial value is \(e^0=1\). Thus the exact endpoint value is \(y(1)=e\), approximately \(2.718281828\). We will use this value as a benchmark for the Euler estimates.
For this particular equation, the Euler update at any step is especially simple:
Each update multiplies the current estimate by the same factor, \(1+h\). That makes it possible to show all the intermediate values and to compare computations of different sizes directly.
Worked Example: One Step Across the Interval
Worked Example: One Step Across the Interval
Take \(n=1\), so \(h=(1-0)/1=1\). Begin with \(t_0=0\) and \(y_0=1\). The slope at the initial point is \(f(0,1)=1\), so the single Euler update gives
The endpoint estimate is therefore \(y_1=2\) at \(t_1=1\). Compared with the exact endpoint value \(e\), its absolute error is
Check the update: the step starts at \((0,1)\), uses slope \(1\), and moves one time unit, giving \(1+1=2\), as computed. This computation uses one slope evaluation and one update.
Worked Example: Two Uniform Steps
Worked Example: Two Uniform Steps
Take \(n=2\), so \(h=(1-0)/2=1/2\). The initial estimate is \(y_0=1\). At \(t_0=0\), the slope is \(f(0,1)=1\), giving
Now \(t_1=1/2\), and the current estimate is \(y_1=3/2\). Since \(f(t,y)=y\), the slope at this point is \(3/2\). The second update is
The endpoint estimate is \(9/4=2.25\). Its absolute error is
Check by applying the update factor twice: \((1+h)^2y_0=(3/2)^2(1)=9/4\), which agrees with the two individual steps. This computation uses two slope evaluations and two updates.
Worked Example: Four Uniform Steps
Worked Example: Four Uniform Steps
Take \(n=4\), so \(h=1/4\). The multiplier at each step is \(1+h=5/4\). Starting from \(y_0=1\), the successive estimates are
The four times are \(0,1/4,1/2,3/4,1\), so \(y_4\) is the endpoint estimate. Its absolute error is
Check the endpoint by multiplying the initial estimate by the update factor four times: \((5/4)^4(1)=625/256\), as found by the step-by-step calculation. The computation requires four slope evaluations and four updates.
Worked Example: Eight Uniform Steps
Worked Example: Eight Uniform Steps
Take \(n=8\), so \(h=1/8\). Each update multiplies the current value by \(9/8\). The full sequence of estimates is
Thus the endpoint estimate is \(y_8=43046721/16777216\). Its absolute error is
As a check, eight applications of the same Euler multiplier give \(y_8=(9/8)^8y_0=43046721/16777216\), matching the listed updates. This calculation uses eight slope evaluations and eight updates.
Comparing Accuracy and Computational Effort
The estimates and errors below are rounded to nine decimal places for display. The calculations above retain exact fractions where practical. Each choice reaches the same endpoint, \(t=1\), and uses \(n\) slope evaluations and \(n\) updates.
| Steps \(n\) | Step size \(h\) | Euler estimate at \(t=1\) | Absolute endpoint error | Slope evaluations |
|---|---|---|---|---|
| 1 | 1 | 2.000000000 | 0.718281828 | 1 |
| 2 | 0.5 | 2.250000000 | 0.468281828 | 2 |
| 4 | 0.25 | 2.441406250 | 0.276875578 | 4 |
| 8 | 0.125 | 2.565784514 | 0.152497315 | 8 |
For this example, halving the step size lowers the endpoint error each time, while the number of slope evaluations doubles. The reduction is not an exact factor of two: the error changes from about \(0.4683\) to \(0.2769\), then to \(0.1525\). In general, it is unsafe to assume that halving a step size will halve the error exactly. The observed changes depend on the problem and on the step sizes being compared.
Why These Estimates Approach the Exact Value
For \(n\) uniform steps over the interval from \(0\) to \(1\), \(h=1/n\). Since every step multiplies the estimate by \(1+1/n\), the endpoint estimate is
This formula explains the pattern in the examples: increasing \(n\) changes the multiplier but also applies it more times. It also gives a direct justification that these estimates lie below \(e\) and converge to it.
This argument establishes convergence for this particular initial-value problem. It does not say that every Euler computation behaves this way: the equation, interval, and step size matter. It does explain why the four estimates in our table are below the exact endpoint and move closer to it as the steps become finer.
A Practical Comparison
A step-size comparison is useful when choosing between computational cost and accuracy. Keep these points in view:
- Compare the same endpoint. Otherwise, differences in estimates may reflect different intervals rather than different step sizes.
- Count the steps. On a fixed interval of length \(T-t_0\), using \(n\) uniform steps requires \(n\) updates and, ordinarily, \(n\) evaluations of \(f\).
- Use a benchmark when one is available. Here the exact value \(e\) lets us calculate actual endpoint errors.
- Do not mistake a trend for an exact rule. Smaller steps improve the estimates in this example, but the listed errors do not halve exactly when the step size is halved.
The comparison therefore has two parts: how close the endpoint estimate is to the target value, and how many steps it took to produce that estimate. Reporting both makes a numerical result more informative than reporting an endpoint approximation alone.
Check Your Understanding
Use the problem \(y'=y,\ y(0)=1\) on \(0\le t\le 1\) to answer the following questions.
- For \(n=2\), what is the step size, and what slope is used at the second step?
- Write the endpoint estimate for \(n\) uniform steps as a power of \(1+1/n\).
- How many Euler updates and slope evaluations are required when \(n=8\)?
- For \(n=4\), calculate the absolute endpoint error using the exact value \(e\).
- Why does halving the step size not guarantee that the endpoint error is exactly halved?