Euler's Method: use to compute approx. y-values of soln to

calchere

Junior Member
Joined
Sep 13, 2006
Messages
50
Use Euler's method with step size 0.5 to compute the approximate y-values y1, y2, y3, and y4 of the solution of the initial-value problem y' = y - 2x , y(1) = 0.

I used these equations:

y1 = y0 + hF(x0, y0)
y2 = y1 + hF(x1, y1)
y3 = y2 + hF(x2, y2)
y4 = y3 + hF(x3, y3)

I'm assuming I have to start with the first equation and work my way up, but I'm not sure how to get y0 when they give me y(1) = 0. On the examples in the book they always give y(0), but (of course) on this problem they give y(1).

The answers are: -1, -3, -6.5, -12.25
 
\(\displaystyle \L\\y'=y-2x, \;\ y(1)=0\)

\(\displaystyle \L\\y_{1}=0+0.5(0-2(1))=-1\)

\(\displaystyle \L\\y_{2}=-1+0.5(-1-2(1.5))=-3\)

\(\displaystyle \L\\y_{3}=-3+0.5(-3-2(2.0))=-6.5\)

\(\displaystyle \L\\y_{4}=-6.5+0.5(-6.5+2(2.5))=-12.25\)
 
Top