Download as pdf or txt
Download as pdf or txt
You are on page 1of 12

lOMoARcPSD|12841845

M575 Chapter 9 - LECTURE NOTES, EXERCISE, AND


SOLUTION
Introduction To Numerical Analysis (Universiti Teknologi MARA)

StuDocu is not sponsored or endorsed by any college or university


Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)
lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

Chapter 9

Richardson
Extrapolation
At the end of this chapter, students should be able to:
 Derive Richardson extrapolation
 Identify and apply Richardson extrapolation technique
 Determine error involve in the Richardson extrapolation method

9.1 Introduction
Earlier, we have mentioned that in the study of numerical differentiation the
three-point methods are better than the two-point methods to find the
estimate of the first derivative. In addition, among the three-point methods,
the central method is the best method. In addition, we have also shown via
several examples that the smaller the step size h, the better the
approximations will be. Since we are talking about the estimates of the first
derivatives only, it is perhaps wise to consider another interesting method to
approximate the first derivative which is far better than any of the three-point
methods discussed in the preceding chapter. It is known as Richardson
extrapolation. The general idea behind Richardson extrapolation is that he
uses two derivative estimates to compute a third approximation and thus
providing more accurate approximation for the derivatives. The following
topic is a brief discussion on the Richardson extrapolation method which is
about a paper written by Richardson and J.A. Gaunt in 1927.

141

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

9.2 Richardson extrapolation


To see how Richardson extrapolation works, let us begin by considering an
example where the best three point method for finding f ’(x), i.e. the central
difference, is used to come up with the formula. As we have mentioned
earlier, the central difference formula is given by:

f ( x  h)  f ( x  h)
f ( x )   O(h2 )
2h
Now, using different values of h into the formula, say h1 we have
f ( x  h1 )  f ( x  h1 )
f ( x )   O(h12 )
2h1

That is, the exact value of

f ' (x)  R1  c1h12 ,

where R1 is estimates of f ' (x) using h1 . Similarly, by substituting another


value of h, say h2, we have

That is, the exact value of

f ' (x)  R 2  c 2h 22 ,

here R 2 is estimates of f ' (x) using h 2 . The values for c1 and c2 could be

different. Now, let us assume that c1  c 2  c , so from above we have

R1  ch12  R 2  ch22  exact value of f ' (x)

 
c h12  h 22  R 2  R1
R 2  R1
Solving for c, we have c 
h12  h 22

So,
R 2  R1 R 2  R1
exact value of f ' (x)  R 2   h 22  R 2   h 22
h12  h 22  2 
2  h1
h2  1
 2 
Upon simplifying, we have  h2 

R 2  R1
exact value of f ' (x)  R 2 
2
 h1   1
 h2 

142

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

Example 1
Let f(x) = x3. Use central difference with Richardson extrapolation to
compute f ’(1), using h1 = 0.1 and h2 = 0.05.

Solution

h1  0.1 f (1)  3.01  R1


h 2  0.05 f (1)  3.0025  R 2

3.0025  3.01
exact  3.0025   3.0000
2
 0.1 
  1
 0.05 

This process of finding a better estimate by combining earlier estimates is


called Richardson Extrapolation. There is yet another better estimate using
Richardson extrapolation from the one given above. Recall, the central
difference approximation with step size h is given by

f ( x0  h )  f ( x0  h ) h2 h4 v
 f ' ( x0 )  f ' ' ' ( x0 )  f ( x0 )  ... (1)
2h 3! 5!
The central difference approximation with step size 2h is given by

f ( x0  2h)  f ( x0  2h) 4h 2 16h 4 v


 f ' ( x0 )  f ' ' ' ( x0 )  f ( x0 )  ... (2)
4h 3! 5!
Notice that (1) is a better derivative estimates than (2) based on its step size.
However combining the two estimates yields an approximation that is better
than either of them.
Now, 4 times (1) minus (2) gives the following:

f ( x0  2h)  8f ( x0  h)  8f ( x0  h)  f ( x0  2h) 12h 4 v


 3f ' ( x0 )  f ( x0 )  ...
4h 5!
So upon simplifying for f ‘(x), an improved estimate is given by

f ( x0  2h)  8f ( x0  h)  8f ( x0  h)  f ( x0  2h) 12h 4 v


f ' ( x0 )   f ( x0 )  ...
12h 5!

4h 4 (5)
The error is O(h4) and is given by R  f ( x0 ) x  2h    x  2h
5!

Thus, to summarize the Richardson extrapolation formula is given in the box

below.

143

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

Richardson Extrapolat ion Formula


f(x  2h)  8f(x  h)  8f(x  h)  f(x  2h)
f (x) ≈ ; error  O(h 4 )
12h

Steps – Richardson Extrapolation method


 Identify the point x that needs to be evaluated
 Identify the step size h
 Apply the Richardson extrapolation formula

f(x  2h)  8f(x  h)  8f(x  h)  f(x  2h)


f (x) ≈
12h

Example 2
A function is given in tabular form below. Find approximation to the first
derivative of f(x) at x = 0.8 with error O(h4).

x 0.6 0.7 0.8 0.9 1

f(x) 5.9072 6.0092 6.3552 6.9992 8.0000

Solution
 Identify the point x that needs to be evaluated
x = 0.8
 Identify the step size h
h = 0.1.

 Apply the Richardson extrapolation formula

f(x  2h)  8f(x  h)  8f(x  h)  f(x  2h)


f'(x) 
12h
So

f (0.8  2(0.1))  8f (0.8  0.1)  8f (0.8  0.1)  f (0.8  2(0.1))


f ' (0.8) 
12(0.1)

f (0.6))  8f (0.7)  8f (0.9)  f (1)



12(0.1)
5.9072  8(6.0092 )  8(6.9992 )  8

1.2
= 4.856

144

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

We are now going to make a comparison of the first derivative estimates


between the two-point method, and the three-point methods which we have
discussed in the preceding chapter and the Richardson extrapolation. The
following example should serve this purpose.

Example 3
The following data was taken during a physics experiment about a moving
particle at time t and velocity v(t). Calculate the acceleration of the particle
at t = 30 seconds.

t(seconds) 10 20 30 40 50

v(t) (m/s) 50 110 160 180 210

Solution

Note that the acceleration is the first derivative of velocity function v(t).
 Identify the point t that needs to be evaluated
t = 30
 Identify the step size h
h = 10

 Apply the Richardson extrapolation formula

v(t  2h)  8v(t  h)  8v(t  h)  v(t  2h)


v' (t) 
12h
So
v(30  2(10))  8v(30  10)  8v(30  10)  v(30  2(10))
v' (30) 
12(10)

v(10)  8v(20)  8v( 40)  v(50)


v' (30) 
120

50  8(110 )  8(180 )  210


v' (30 ) 
120
 3.333 m/s 2

Thus the acceleration of the moving particle at t = 30 seconds is


2
approximately 3.333 m/s

145

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

Example 4
The distance x of a runner from a fixed point is measured (in meters) at
intervals of half a second. The data obtained are as follows:

Approximate the runner’s velocity at times t = 1.0 second with error


(a) O(h) (b) O(h2) (c) O(h4)

Solution

(a) (i) Using two-point forward difference with O(h) we have:

f (1.5)  f (1.0)
f ' (1.0) 
( 0 .5 )
9.90  6.80

0 .5
 6 .2
(ii) Using two-point backward with O(h):
f (1.0)  f (0.5)
f ' (1.0) 
( 0 .5 )
6.80  3.65

0 .5
 6 .3
(b) Using three-point central difference with O(h2):

f ( x  h)  f ( x  h)
f ( x ) 
2h
f (1.5)  f (0.5)
f (1) 
2(0.5)
9.90  3.65

0 .1
 6.25

(c) Using Richardson Extrapolation with O(h4):


 Identify the point x that needs to be evaluated
x = 0.1
 Identify the step size h
h = 0.5
 Apply the Richardson extrapolation formula

146

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

f(x  2h)  8f(x  h)  8f(x  h)  f(x  2h)


f' (x) 
12h
So

f (1.0  2(0.5))  8f (1.0  0.5)  8f (1.0  0.5)  f (1.0  2(0.5))


f ' (1.0) 
12(0.5)

f (0)  8f (0.5)  8f (1.5)  f (2)



6

0  8(3.65 )  8(9.90 )  12.15



6
 6.3083

Warm up exercise

Consider the f(x)  3x 2  4x. Find the first derivative of f(x) at x =2 with
h = 0.1 using:
(i) the two -point method
(ii) the three-point central difference method.
(iii) the Richardson extrapolation
Discuss your answers and compare it with the exact solution. So which is
better?

9.3 Error Analysis


Theorem
Assume that f  C3 [a, b] and x  2h , x  h x  [a, b] with h > 0. Then
f ( x  2h)  8f ( x  h)  8f ( x  h)  f ( x  2h)
f ' ( x)   D1(h) (1)
12h
Furthermore, c  [a, b] such that

f ( x  2h)  8f ( x  h)  8f ( x  h)  f ( x  2h)
f ' ( x)   E2 ( f, h) (2)
12h

147

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

(2)

 h 4 f ( 5 ) (c )
where E2 ( f, h)   O(h 4 ) .
30

Example 5
Determine the error if Richardson formula is used to approximate the first
derivative of f(x) = cos x in [0.9, 1.3] with
a) h = 0.1 b) h = 0.01

Solution

 h 4 f ( 5 ) (c )
Given | e | while
30

f ( x )  cos x f ' ' ' ( x )  sin x


f ' ( x )   sin x f 4 ( x )  cos x
f ' ' ( x )   cos x f 5 ( x )   sin x

For 0.9  x  1.3 then 0.7833  sin x  0.9636


a)

(0.1) 4 (0.9636 )
| e |
30

 3.212 x10  6

b)

(0.01) 4 (0.9636 )
| e |
30

 3.212 x10 10

148

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

Warm up exercise

Determine the error if Richarson formula is used to approximate the


first derivative of f(x) = 2 sin x in [0.9, 1.1] with
(i) h = 0.1 (ii) h = 0.01

Exercise 9

1. Use Richardson extrapolation to evaluate f’(x) and calculate the error bound for
the following functions.
a) f(x) = cos(x) at x = π/4 with h = 0.01, h = 0.005
b) f(x) = ln(1 + x) at x = 1 with h = 0.01, h = 0.005
c) f(x) = tan−1 x at x = 2 with h = 0.01, h = 0.005

d) f (x)  ex at x = 1.15 with h = 0.01, h = 0.001

1
e) f (x)  at x = 1 with h = 0.1, h = 0.01
x

f) f ( x )  e  x sin x at x = 1

g) f ( x )  xe x at x = 2 with h = 0.2

149

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

2. Use Richarson extrapolation to evaluate f’(x) and calculate the error bound for
the following functions.

a) f (x)  ex at x = 1.15 with h = 0.01, h = 0.001

1
b) f ( x )  at x = 1 with h = 0.1, h = 0.01
x

1
f (x) 
x
f ( x  2h )  8 f ( x  h )  8 f ( x  h )  f ( x  2h )
f'( x) 
2h
h = 0.1
f ( 0.8 )  8 f ( 0.9 )  8 f ( 1.1)  f ( 1.2 )
f ' ( 1) 
0.2
 -0.999579125

 h 4 f ( 5 ) (c )
| e |
30

1
f'( x) 
x2
2
f '' ( x ) 
x3
6
f ''' ( x ) 
x4
24
f '''' ( x ) 
x5
 120
f ''''' ( x ) 
x6
0.8  x  1.2
40.1877572  f 5 ( x )  457 .7636719

( 0.1)4 ( 457 .7636719 )


e
30
 1.5259  10  3
 0.1526  10  2

150

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)


lOMoARcPSD|12841845

Part 5 NUMERICAL DIFFERENTIATION MAT 575

f ( x )  x sin x
f ' ( x )  sin x  x cos x
f ' ' ( x )  cos x  cos x  x sin x
 2 cos x  x sin x
f ' ' ' ( x )  2 sin x  sin x  x cos x
 3 sin x  x cos x
f ' ' ' ' ( x )  3 cos x  cos x  x sin x
 4 cos x  x sin x
f ' ' ' ' ' ( x )  5 sin x  x cos x

http://www.math.dartmouth.edu/~calcsite/video1.html#406
Source: 1999 Addison Wesley Longman, Inc.
http://www.mathcs.emory.edu/ccs/ccs215/integral/node3.html

151

Downloaded by RAJA FARHATUL AIESYA RAJA AZHAR (2020859442@student.uitm.edu.my)

You might also like