2. Given that y(1) = -3 and
𝑑𝑦
𝑑𝑥
= 2𝑥 + 𝑦, approximate y(2)
using Euler’s Method and two steps of equal size.
Since we have to get from x = 1 to x = 2 using two steps of equal size, our
step-size will be 0.5.
𝑥0 = 1
𝑦0 = −3
~~~~~~~~~~
𝑥1 = 1 + 0.5 = 1.5
𝑦1 = −3 + 0.5 2 1 − 3 = −3 + 0.5 −1 = −3.5
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
𝑥2 = 1.5 + 0.5 = 2
𝑦2 = −3.5 + 0.5 2 1.5 + −3.5 = −3.5 + 0.5 −0.5 = −3.75
So, 𝒚 𝟐 ≈ −𝟑. 𝟕𝟓.
3. Consider
𝑑𝑦
𝑑𝑥
= 𝑦 − 2, where y(0)=4. Use Euler’s Method with
4 equal subintervals to approximate y(4).
Since we have to get from x = 0 to x = 4 using four steps of equal size, our step-size will be 1.
𝑥0 = 0
𝑦0 = 4
~~~~~~~~~~
𝑥1 = 0 + 1 = 1
𝑦1 = 4 + 1 4 − 2 = 4 + 2 = 6
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
𝑥2 = 1 + 1 = 2
𝑦2 = 6 + 1 6 − 2 = 6 + 4 = 10
~~~~~~~~~~~~~~~~~~~~~~~~
𝑥3 = 2 + 1 = 3
𝑦3 = 10 + 1 10 − 2 = 10 + 8 = 18
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
𝑥4 = 3 + 1 = 4
𝑦4 = 18 + 1 18 − 2 = 18 + 16 = 34
So, 𝒚 𝟒 ≈ 𝟑𝟒.