Presentation is loading. Please wait.

Presentation is loading. Please wait.

Euler's method Rita Korsunsky.

Similar presentations


Presentation on theme: "Euler's method Rita Korsunsky."— Presentation transcript:

1 Euler's method Rita Korsunsky

2 Using tangent lines Making a chart Calculator
Euler’s method: Approximation of the solution to a differential equation Using tangent lines Making a chart Calculator

3 Given: dy/dx = 1+y and y(0)=0 and ∆x=0
Given: dy/dx = 1+y and y(0)=0 and ∆x=0.5 Construct the approximate y using 3 steps. First: construct a tangent line at (0,0) Slope =1 equation y-0 = 1(x-0) y = x new y y(0.5) = 0.5 starts at (0,0) ends at (0.5,0.5) 0.5

4 Given: dy/dx = 1+y and y(0)=0 and ∆x=0.5
Second: construct a tangent line at (.5,.5) slope = 1.5 equation y - .5 = 1.5(x-.5) y = 1.5x-.25 new y y(1) = =1.25 starts at (.5,.5) ends at (1,1.25) 2.5 2.0 1.5 1.0 0.5

5 Given: dy/dx = 1+y and y(0)=0 and ∆x=0.5
Third: construct a tangent line at (1,1.25) slope = 2.25 equation y = 2.25(x-1) y = 2.25x-1 new y y(1.5) = = 2.375 starts at (1,1.25) ends at (1.5,2.375) 2.0 1.5 1.0 0.5

6 Find the exact solution by
solving the differential equation:

7 Compare the exact y and approximate y
(1.5,2.375) y = ex - 1 approximate y (1,1.25) (0.5,0.5) link

8 Given: dy/dx =2x ,y(1)=3. Find y(2) using 5 steps.
Basic Idea: new y ≈ old y + dy/dx (∆x) Step size =∆x=(2-1)/5 = 1/5 x old y new y ≈ old y + dy/dx (∆x) 1 1.2 1.4 1.6 1.8 2.0 3 2(1/5)=0.40 3+0.40=3.40 3.4 2.4(1/5)=0.48 =3.88 3.88 2.8(1/5)=0.56 =4.44 4.44 3.2(1/5)=0.64 =5.08 5.08 3.6(1/5)=0.72 =5.80 5.80

9 Euler’s method on calculator
Given: dy/dx =2x ,y(1)=3. ∆x= 1/5. Find y(2). MODE: Change Graph Mode to Diff. Equations Press and F1 (Y=) Enter initial x condition under t0= and initial y under yi1= Type in the diff. equation for y1. Use t for x and y1 for y when inputting the differential equation 1 1.2 1.4 1.6 1.8 2.0 3.40 3.88 4.44 5.08 5.80 3 While still on the Y= page, press F1 and scroll down to 9: Format, press enter Scroll down to Solution Method and choose Euler Press F2 to go to the Window Page. Change the tstep to your Press and F4 (TblSet) and input your initial x under tblStart and the under and F5 to view the table

10 Euler’s Example Given: Solution: On the Y= Menu, When x=2.5, y=-5 t y1
4 1.5 -2 2 2.5 -5 When x=2.5, y=-5


Download ppt "Euler's method Rita Korsunsky."

Similar presentations


Ads by Google