euler’s method bc only copyright © cengage learning. all rights reserved. 6.1 6.1 day 2 2014

Post on 27-Dec-2015

218 Views

Category:

Documents

3 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Euler’s Method

BC Only

Copyright © Cengage Learning. All rights reserved.

6.1

6.1 Day 2 2014

2

6.1 day 2

Euler’s Method

Leonhard Euler 1707 - 1783

Leonhard Euler made a huge number of contributions to mathematics, almost half after he was totally blind.

(When this portrait was made he had already lost most of the sight in his right eye.)

3Leonhard Euler 1707 - 1783

It was Euler who originated the following notations:

e (base of natural log)

f x (function notation)

(pi)

i 1

(summation)

y (finite change)

4

There are many differential equations that can not be solved.We can still find an approximate solution.

We will practice with an easy one that can be solved.

2dy

xdx

Initial value:0 1y

7

(0,1)

dydx dy

dx

1n ny dy y

2dy

xdx

0.5dx 0 1y

1+0(.5) = 1

(.5,1)

(1,1.5)

(1.5,2.5)

1+1(.5) = 1.5

1.5+2(.5) = 2.5

2.5+3(.5) = 4

(2, 4) 4+4(.5) = 6

8

2dy

xdx

0,1 0.5dx

2 dy x dx

2y x C

1 0 C

2 1y x

Exact Solution:

9

It is more accurate if a smaller value is

used for dx.

This is called Euler’s Method.

It gets less accurate as you move away from the initial value.

10

Euler’s Method – BC Only

Euler’s Method is a numerical approach to approximating the particular solution of the differential equation

y' = F(x, y)

that passes through the point (x0, y0).

From the given information, you know that the graph of the solution passes through the point (x0, y0) and has a slope of

F(x0, y0) at this point.

This gives you a “starting point” for approximating the solution.

11

Euler’s Method

From this starting point, you can proceed in the direction indicated by the slope.

Using a small step h, move along the

tangent line until you arrive at the

point (x1, y1) where

x1 = x0 + h and y1 = y0 + hF(x0, y0) as shown in Figure 6.6.

Figure 6.6

12

Euler’s Method

If you think of (x1, y1) as a new starting point, you can

repeat the process to obtain a second point (x2, y2).

The values of xi and yi are as follows.

1 0 0 0 2 1 1 1, , , ,y y deriv x y x y y deriv x y x etc

13

Example 6 – Approximating a Solution Using Euler’s Method

Use Euler’s Method to approximate the particular solution of the differential equation

y' = x – y

passing through the point (0, 1). Use a step of h = 0.1.

Solution:Using h = 0.1, x0 = 0, y0 = 1, and F(x, y) = x – y, you have x0 = 0, x1 = 0.1, x2 = 0.2, x3 = 0.3,…, and

y1 = y0 + hF(x0, y0) = 1 + (0 – 1)(0.1) = 0.9

y2 = y1 + hF(x1, y1) = 0.9 + (0.1 – 0.9)(0.1) = 0.82

y3 = y2 + hF(x2, y2) = 0.82 + (0.2 – 0.82)(0.1) = 0.758.

14

Example 6 – Solution

Figure 6.7

The first ten approximations are shown in the table.

cont’d

You can plot these values to see a

graph of the approximate solution,

as shown in Figure 6.7.

15

Homework 6.1 Day 2 (Euler’s Lesson) : Pg. 410: 69,71,73 and

Slope Fields WS

16

The TI-89 has Euler’s Method built in.

Example: .001 100dy

y ydx

0 10y

We will do the slopefield first:

6: DIFF EQUATIONSGraph…..

Y= 1 .001 1 100 1y y y We use:

y1 for yt for x

MODE

17

6: DIFF EQUATIONSGraph…..

1 .001 1 100 1y y y

WINDOW t0=0tmax=150tstep=.2tplot=0xmin=0xmax=300xscl=10

ymin=0ymax=150yscl=10ncurves=0diftol=.001fldres=14

not criticalGRAPH

We use:

y1 for yt for x

Y=

MODE

18

t0=0tmax=150tstep=.2tplot=0xmin=0xmax=300xscl=10

ymin=0ymax=150yscl=10ncurves=0diftol=.001fldres=14

WINDOW

GRAPH

19

While the calculator is still displaying the graph:

yi1=10

tstep = .2

If tstep is larger the graph is faster.If tstep is smaller the graph is more accurate.

I Press and change Solution Method to EULER.

WINDOW

GRAPH

Y=

20

To plot another curve with a different initial value:

Either move the curser or enter the initial conditions when prompted.

F8

You can also investigate the curve by using . F3

Trace

21

y1 2t

t0=0tmax=10tstep=.5tplot=0xmin=0xmax=10xscl=1

ymin=0ymax=5yscl=1ncurves=0Estep=1fldres=14

GRAPH

Now let’s use the calculator to reproduce our first graph:

2dy

xdx

0 1y yi1 1

We use:

y1 for yt for x

I Change Fields to FLDOFF.

WINDOW

Y=

22

Use to confirm that the points are the same as the ones we found by hand.

F3 Trace

TablePress

TblSetPress and set: tblstart... 0 tbl.... .5

23

This gives us a table of the points that we found in our first example.

TablePress

top related