⠀㐀ⴀ尩 Numerical Differentiation

Post on 12-May-2022

16 views 0 download

Transcript of ⠀㐀ⴀ尩 Numerical Differentiation

Numerical Differentiation and Integration

(4-1) Numerical Differentiation

MaSc 352 - PNU(4-1) Numerical Differentiation

(4-1) Numerical Differentiation

1

Forward and Backward Difference Formulas:

MaSc 352 - PNU(4-1) Numerical Differentiation2

MaSc 352 - PNU(4-1) Numerical Differentiation3

Example (1)

MaSc 352 - PNU(4-1) Numerical Differentiation4

Obtaining General Derivative Approximation Formula:

108

MaSc 352 - PNU(4-1) Numerical Differentiation5

MaSc 352 - PNU(4-1) Numerical Differentiation6

Three-Point Formula:

Since

MaSc 352 - PNU(4-1) Numerical Differentiation7

From Eq. (4-3) we get:

Three-Point Formula (When nodes are equally spaced):

MaSc 352 - PNU(4-1) Numerical Differentiation8

MaSc 352 - PNU(4-1) Numerical Differentiation9

MaSc 352 - PNU(4-1) Numerical Differentiation10

Five-Point Formula (nodes are equally spaced):

MaSc 352 - PNU(4-1) Numerical Differentiation11

Example (2) [Exercise 9 Page 177]:

2.62.52.42.32.22.1

-0.6-0.75-0.92-1.12-1.37-1.7

x

)( xf

)1.2(.1 f ′3-Point Endpoint

MaSc 352 - PNU(4-1) Numerical Differentiation

5-Point Endpoint

12

)3.2(.2 f ′3-Point Endpoint

3-Point Midpoint

MaSc 352 - PNU(4-1) Numerical Differentiation

5-Point Midpoint

13

Example (3) [Exercise 11 Page 177]:

2. The error bound of using 3-Point Midpoint formula

1. Absolute error:)2.2(f ′

MaSc 352 - PNU(4-1) Numerical Differentiation

2. The error bound of using 3-Point Midpoint formula

14

The error bound of using 3-Point Endpoint formula

MaSc 352 - PNU(4-1) Numerical Differentiation15

High Derivative Formula:

Second Derivative Midpoint Formula:

MaSc 352 - PNU(4-1) Numerical Differentiation16

MaSc 352 - PNU(4-1) Numerical Differentiation17

Example (4):

2.22.12.01.91.8

19.8617.1514.7812.710.89

x

)( xf

1. h=

Use The second derivative formula (4.9) to approximate using the following data:

)2(f ′′

MaSc 352 - PNU(4-1) Numerical Differentiation18

2. h=

Round-Off Error Instability:

MaSc 352 - PNU(4-1) Numerical Differentiation19

Example (5):Consider using the values in Table 4.3 to approximate where

Compute the error and the optimal choice of h to reduce the error.

)9.0(f ′ xxf sin)( =

MaSc 352 - PNU(4-1) Numerical Differentiation

We can notice that the best approximations are at:

20

Optimal Choice of h:

MaSc 352 - PNU(4-1) Numerical Differentiation21

Homework:

1 (b) +3 (b)

Exercise Set (4-1)

MaSc 352 - PNU(4-1) Numerical Differentiation

5 ( + ) +7 ( + )

9 ( + )

20

22

)2.1(f ′ )4.1(f ′ )2.1(f ′ )4.1(f ′

)4.2(f ′ )6.2(f ′