For which value of the discretization step $h$ the Euler explicit method applied to the differential equation $y'(x)+\frac{1}{4}y(x)=x$ with the initial condition $y(1)=1$ is stable?

I wrote the equation as $y'(x)=-\frac{1}{4}y(x)+x$ and put the function into equation of explicit Euler's method: $$ y_{n+1} = y_{n} + h\left(x_{n}-\frac{1}{4}y_n\right) $$ But I'm stuck and don't know what more to do. I know that something has to be $<1$ for it to be a stable method, but don't know which part of the equation.

Possible answers: $\frac{1}{4}, \frac{2}{3}, \frac{1}{2}, 1$.


1 Answer 1


Solving the recurrence

$$ y_{n+1}-\left(1-\frac h4\right)y_n = h x_n $$

we got easily

$$ y_n = \left(1-\frac h4\right)^{n-1}\left(c_1 +h\sum_{k=0}^{n-1}\left(1-\frac h4\right)^{-k}x_k\right) $$

hence the condition is

$$ |1-\frac h4| \lt 1 $$


Here $x_n = 1 + nh$ so with the condition $y_0 = 1, x_0 = 1$ we have $c_1 = 1-\frac h4$ so we have finally

$$ y_n = 13 \left(1-\frac{h}{4}\right)^n+4 h n-12 $$

and as we can verify, $y_n$ approaches $y(x)$ maintaining stability for $0 < h < 8$

  • $\begingroup$ All of the possible answers fit into condition and that's my main problem :( I need to write exact value of h. $\endgroup$
    – jupyter51
    Jan 21 at 19:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .