Differential Equations 3 – Euler’s Method
Since not all differential equation initial values problems (IVP) can be solved, it is often necessary to approximate the solution. There are several ways of doing this. The one that AP students are required to know is Euler’s Method.
The idea behind Euler’s Method is to first write the equation of the line tangent to the solution at the initial condition point. To find the approximate value of the solution near the initial condition, then take short steps from the initial point to the point with the x-value you need.
Since you have the initial point and the differential equation will give you the slope, it is easy to write the equation of the tangent line. You then approximate the point on the solution by using the point on this line a short distance (called the step-size or ) from the initial point. The first step is exactly the local linear approximation idea.
Next, you write the equation of another line through the approximated point using the differential equation to give you the slope at the approximated point (i.e. not the point on the curve which you do not know). This gives you a second (approximate) point.
Then you repeat the process (called iteration) until you get to the x-value you need.
The equations look like this:
The first equation says that the x-values increase by the same amount each time. may be negative if the required value is at an x-value to the left of the initial point.
The second equation gives the y-value of a point on the line through the previous point where the slope, , is found by substituting the coordinates of the previous point into the differential equation. It has the form of the equation of a line.
Example: Let f be the solution of the differential equation with the initial point (1, 3). Approximate the value of f(2) using Euler’s method with two steps of equal size.
Solution: At the initial point . Then
Now using the point (1.5, 0.5) where
Therefore, . The exact value is 2.5545. A better approximation could be found using smaller steps.
Some textbooks and some teachers make tables to organize this procedure. This is fine, but not necessary on the AP exams. Showing the computations as above will earn the credit. It is easy to remember: you are just writing the equation of a line.
There are calculator programs available on-line that will compute successive iterations of Euler’s method and others that will compute and graph the values so you can examine the approximate solution graph. Of course in real situations computers using this or more advanced techniques can produce approximate numerical solutions to initial value problems.
Here is a graphical look at what Euler’s Method does. Consider this easy IVP: with the initial condition . The screen is two units wide extending from x = 0 to x = 2. The calculator graph below shows three graphs. The top graph is the particular solution . (I said it was easy.) The lower graph shows an approximate solution with the rather large step size of with the two points connected; look closely and you will see the two segments. The middle graph has a step size of . There are 8 segments, but they appear to be a smooth curve approximating the solution. Notice it is closer to the actual solution graph. An even smaller step size would show an even smoother graph closer to the particular solution.