Practice Problem for Differential Equations

1. Consider the initial value problem

y' = 2 y + t2 , y(0) = -1/4

(a) Perform 3 steps of the Euler method with h=1.

(b) Use the partial derivative of f with respect to y to make a statement about the stability of the problem. What behavior do you expect for the errors of the numerical method for increasing values of t ?

(c) Check that y(t) = -t2/2 - t/2 - 1/4 is exact solution of the problem. Find the errors of the Euler values. Compare the behavior of the Euler values with the behavior of the exact solution for increasing t.

2. Consider the initial value problem

y'' + y = 1 , y(0) = 2 , y'(0) = -1

(a) Convert this problem to an equivalent first order system for two functions. (Example)

(b) Perform one step of the Euler method with h=1 for the first order system and give the resulting approximation for y(1).

(c) Perform one step of the improved Euler method with h=1 for the first order system and give the resulting approximation for y(1).

(d) Compare the two approximations for y(1) from (b), (c) with the exact value for y(1). Based on this information, try to predict the error of the Euler method for y(1) for h=1/2, h=1/4. Try to predict the error of the improved Euler method for y(1) for h=1/2, h=1/4.
(e) Perform one step of the backward Euler method with h=1 and give the resulting approximation for y(1).

(Solutions)