Tacoma Narrows Bridge: November 7, 1940 · 4 ( 1) 3 ( 1) 2 ( 1) ( ) ln ( 1) 2 3 − 4 x x x f x x x...

Post on 02-Aug-2020

1 views 0 download

transcript

9.3 Taylor’s Theorem: Error Analysis for Series

Tacoma Narrows Bridge: November 7, 1940

Last time in BC…

...4

)1(

3

)1(

2

)1()1(ln)(

432 −−

−+

−−−==

xxxxxxf

∑−

−=∞

=

+

1

1 )1()1(

n

n

n

n

x

So the Taylor Series for ln x centered at x = 1 is given by…

Use the first two terms of the Taylor Series for ln x centered at x = 1 to

approximate:

2

1ln

2

3ln

2

)15.1()15.1(

2−−−≈

2

)15.0()15.0(

2−−−≈

375.02

25.05.0 =−=

625.02

25.05.0 −=−−=

068147.0|)625.0()5.0ln(| =−−=erroractual

0417.03

)15.0( 3

=−

≤→ error

Recall that the Taylor Series for ln x centered at x = 1 is given by…

Find the maximum error bound for each approximation.

2

1ln

2

3ln 0417.0

3

)15.1( 3

=−

≤→ error

03047.0|625.0)5.1ln(| =−=erroractual

Wait! How is the actual error bigger than the error bound for ln 0.5?

Because the series is alternating, we can start with…

f (x) = ln x = (x −1) −(x −1)

2

2+

(x −1)3

3−

(x −1)4

4... = (−1)n +1 (x −1)

n

nn =1

And now, the exciting

conclusion of Chapter 9…

Since each term of a convergent alternating series

moves the partial sum a little closer to the limit:

This is also a good tool to remember because it is

easier than the Lagrange Error Bound…which you’ll

find out about soon enough…

Muhahahahahahaaa!

Alternating Series Estimation Theorem

For a convergent alternating series, the truncation

error is less than the first missing term, and is the

same sign as that term.

Taylor’s Theorem with Remainder

If f has derivatives of all orders in an open interval I

containing a, then for each positive integer n and for each x

in I:

( ) ( ) ( )( )( )

( )( ) ( )

( ) ( )2

2! !

nn

n

f fa af f f Rx a a x a x a x a x

n

′′′= + + + ⋅⋅⋅ +− − −

Lagrange Error Bound ( )( ) ( )

( )( )

11

1 !

nn

n

f cR x x a

n

++

= −+

In this case, c is the number between x and a that will give

us the largest result for )(xRn

( )( ) ( )

( )( )

11

1 !

nn

n

f cR x x a

n

++

= −+

This remainder term is just like the Alternating Series error (note

that it uses the n + 1 term) except for the ( )( )cfn 1+

If our Taylor Series had

alternating terms:

Does any part of

this look familiar?

If our Taylor Series did not

have alternating terms:

nn

n axn

afxR )(

)!1(

)()(

1

−+

=+

( )( ) ( )

( )( )

11

1 !

nn

n

f cR x x a

n

++

= −+

This is just the next term of the

series which is all we need if it is

an Alternating Series

is the part that makes the Lagrange

Error Bound more complicated.

Note that working with( )( )cf n 1+

Taylor’s Theorem with Remainder

If f has derivatives of all orders in an open interval I

containing a, then for each positive integer n and for each x

in I:

( ) ( ) ( )( )( )

( )( ) ( )

( ) ( )2

2! !

nn

n

f fa af f f Rx a a x a x a x a x

n

′′′= + + + ⋅⋅⋅ +− − −

Lagrange Error Bound ( )( ) ( )

( )( )

11

1 !

nn

n

f cR x x a

n

++

= −+

Now let’s go back to our last problem…

Why this is the case involves a mind-bending proof so we just won’t do

it here.

068147.0|)625.0()5.0ln(| =−−=erroractual

0417.03

)15.0( 3

=−

≤→ error

Recall that the Taylor Series for ln x centered at x = 1 is given by…

Find the maximum error bound for each approximation.

2

1ln

2

3ln 0417.0

3

)15.1( 3

=−

≤→ error

03047.0|625.0)5.1ln(| =−=erroractual

Wait! How is the actual error bigger than the error bound for ln 0.5?

Because the series is alternating, we can start with…

∑∞

=

+ −−=

−−

−+

−−−=

1

1432 )1(

)1(...4

)1(

3

)1(

2

)1()1(ln

n

nn

n

xxxxxx

First of all, when plugging in ½ for x, what happens to your series?

∑∞

=

+ −−=

−+

−−−=

1

132 )5.0(

)1(...3

)15.0(

2

)15.0()15.0(

2

1ln

n

nn

n

Note that when x = ½, the series is no longer alternating.

So now what do we do?

Since the Remainder Term will work for any Taylor Series, we’ll have

to use it to find our error bound in this case

∑∞

=

+ −−=

−−

−+

−−−=

1

1432 )1(

)1(...4

)1(

3

)1(

2

)1()1(ln

n

nn

n

xxxxxx

Recall that the Taylor Series for ln x centered at x = 1 is given by…

∑∞

=

−=−−−=1

)5.0(...

3

0625.0

2

25.05.0

2

1ln

n

n

n

xxf

1)( =′ 1

1

1)1( ==′f

2

1)(

xxf

−=′′ 1

1

1)1(

2−=−=′′f

3

2)(

xxf =′′′ 3

32

2)( −==′′′ c

ccf

( )=

′′′

!3

cf 2c−3

3!

xxf ln)( = 01ln)1( ==f

xxf ln)( =The Taylor Series for centered at x = 1

Since we used terms up through n = 2, we will need to go to n = 3 to find our

Remainder Term(error bound):

This is the part

of the error

bound formula

that we need

The third derivative

gives us this

coefficient:

We saw that plugging in ½ for x makes each term of the series positive and

therefore it is no longer an alternating series. So we need to use the

Remainder Term which is also called…

2

1ln 0417.0

3

)15.0( 3

=−

≤→ error

068147.0|)625.0()5.0ln(| =−−=erroractual

3)15.0(!3

)(−

′′′=

cferror )125.0(

!3

2 3−

=c The third derivative

of ln x at x = c

What value of c will give us the maximum error?

Normally, we wouldn’t care about the actual value of c but in this case, we

need to find out what value of c will give us the maximum value for 2c–3.

The Lagrange Error Bound1

1

)()!1(

)( ++

−+

nn

axn

cf

3)15.0(!3

)(−

′′′=

cferror )125.0(

!3

2 3−

=c The third derivative

of ln x at x = c

The question is what value of c between x and a will give us the maximum error?

So we are looking for a number for c between 0.5 and 1.

Let’s rewrite it as

c = 0.5

2

c3 which has its largest value when c is smallest.

And therefore…

3)15.0(!3

)(−

′′′=

cferror )125.0(

!3

2 3−

=c

=2(0.5)−3

3!(0.125)

==8

1

6

16

3

1

068147.0|)625.0()5.0ln(| =−−=erroractual

Which is larger than the actual error!

And we always want the error bound to be larger than the actual error

Let’s try using Lagrange on an alternating series

ln(1+ x) ≈ x −x

2

2

We know that since this is an alternating

series, the error bound would be x3

3

But let’s apply Lagrange (which works on all Taylor Series)…

3

!3

)(x

cferror

′′′≤ 3)1(

2)(

xxf

+=′′′The third derivative

of ln(1+ x) is

error ≤2(1+ c)−3

3!x

3=

x3

3(1+ c)3

The value of c that will

maximize the error is 0 so…

x3

3(1+ c)3=

x3

3

Which is the same as the

Alternating Series error bound

Lagrange Form of the Remainder: ( )( ) ( )

( )( )

11

1 !

nn

n

f cR x x a

n

++

= −+

Remainder Estimation Theorem:

If M is the maximum value of on the interval

between a and x, then:

( ) ( )1nf x

+

( )( )

1

1 !

n

n

MR x x a

n

+≤ −

+

Most text books will describe the error bound two ways:

and

Note from the way that it is described above that M is just

another way of saying that you have to maximize ( )( )cf n 1+

Remember that the only difference you need to worry

about between Alternating Series error and La Grange is

finding ( )( )cf n 1+