7.5 Approximating Solutions Using Euler’s Method
- Syllabus
- 2020
- Topic
- 7.5
- Level
- —
For dy/dx=f(x,y), Euler’s method starts from a known point (xn,yn) and uses the tangent slope there to estimate the next point. Over a horizontal step h, the estimated vertical change is slope × step, or f(xn,yn)h.
x_{n+1}=x_n+h,\qquad y_{n+1}=y_n+h,f(x_n,y_n)
At each step: (1) evaluate the slope at the current point; (2) multiply it by the signed step size h; (3) add that change to the current y; (4) advance x by h; then recompute the slope at the new point.
For dy/dx=x+y, y(0)=1, and h=0.1: from (0,1) the slope is 1, so (x1,y1)=(0.1,1+0.1(1))=(0.1,1.1). Now the slope is 0.1+1.1=1.2, so (x2,y2)=(0.2,1.1+0.1(1.2))=(0.2,1.22). Thus y(0.2)≈1.22.
Euler’s method produces an approximation, not an exact solution. Do not reuse the first slope for every step: the derivative must be evaluated at each new approximate point. A smaller step generally follows changing slopes more closely, but it also requires more steps; moving toward smaller x requires a negative h.