Presentation is loading. Please wait.

Presentation is loading. Please wait.

The purpose of Chapter 5 is to develop the basic principles of numerical integration Usefule Words integrate, integral 积分(的), integration 积分(法), quadrature.

Similar presentations


Presentation on theme: "The purpose of Chapter 5 is to develop the basic principles of numerical integration Usefule Words integrate, integral 积分(的), integration 积分(法), quadrature."— Presentation transcript:

1

2 The purpose of Chapter 5 is to develop the basic principles of numerical integration Usefule Words integrate, integral 积分(的), integration 积分(法), quadrature 求积分, integrand 被积函数 definite integral 定积分, indefinite integral 不定积分, trapezoidal 梯形(的), composite trapezoidal quadrature 复合求积公式 algebraic accuracy 代数精度

3 The solution can not be found directly. A Real Problem Find the length of the curve from to.

4 Definition Suppose that. A formula with the property that is called a numerical integration or a quadrature formula. This definition implies that a quadrature formula is dependent on the choice of and. Question arises: (1) How to choose and ? (2) How to evaluate a quadrature formula? 5.1 Introduction to quadrature

5 Degree of Precision ( accuracy of formula) Definition The degree of precision of a quadratrue formula is a positive integer such that for all polynomials of degree but for some polynomials of degree. If the degree of precision of a quadratrue formula is n, then (1) The formula produces exact results for all with. (2) The error term is of the form where k is a suitable constant and c is dependent on x. Example Prove that the degree of precision of the formula is only one. Example Find constants and so that the formula has the highest possible degree of precision. Determine the the degree n. (See Ex. 5.4 (P209))

6 Suppose that and are in [a,b], and and Two useful theorems Weighted Mean value Theorem for Integrals Suppose the Riemann integral of g exists on [a,b], and g(x) does not change sign on [a,b]. Then there exists a number c in (a,b) with are positive constants. Then a number exists between and with Derivation of Quadrature formulas

7 Let are M+1 equidistant nodes on the interval and is the Mth Lagrange interpolating polynomial for. with truncation error M=1 Trapezoidal Rule M=2 Simpson’s rule That is Then See Th.5.1 and Cor.5.1, page 204 (Newton--Cotes formulas)

8 M=1 Trapezoidal Rule

9 M=2 Simpson’s rule Integrating P 2 (x) on [x 0, x 2 ] directly provides only an error term involving f (3). By approaching the problem in another way, a higher-order term involving f ( 4) can be derived. Expand f(x) about x 1 in the third Taylor polynomial.

10 Integrating f(x) on [x 0, x 2 ] gives Then(Simpson’s rule) Differentiating f(x) and evaluating f(x 0 ) give the forward-difference formula Interpolating f(x) with nodes x 0 and x 1 Expand f(x) in the 3rd Taylor polynomial about x 1, evaluate f(x 0 ) and f(x 2 ), and then add them. and

11 Example Use quadrature formulas (5.4) to (5.7) to approximate the integral Solution Let The result of using the trapezoidal rule with h=1 is Using Simpson’s rule with h=1/2, we have For Simpson’s 3/8 rule with h=1/3, we obtain The result of using the Boole’s rule with h=1/4 is

12 Composite Quadratrue Formulas

13 5.2 Composite Trapezoidal and Simpson’s Rule Then the composite trapezoidal rule is expressed as follows: Then the composite Simpson’s rule is expressed as follows:

14 Example2 Approximate using the given entries. a.Use the Composite Trapezoidal rule. b.Use the Composite Simpson’s rule. 0.84147091 0.87719257/8 0.90885163/4 0.93615565/8 0.95885101/2 0.97672673/8 0.98961581/4 0.99739781/8 1.00000000 f(x)=sinx/xx Solution

15 Example3 Determine the values M and h such that the truncation error E s (f, h) is less than when the composite Simpson’s rule is used to approximate Solution Let The first four derivatives of f are According to we have So h 112.95. In consideration of M being a positive integer, the result is M= 113 and h=1/2M.

16 5.3 Recursive Rules and Romberg Integration Recursive Quadrature Rules Recursive Trapezoidal Rules LetThen,

17 Example1 Approximate using ln 5≈1.6094379124

18 Recursive Simpson Rules Recursive Boole Rules Richardson’s Improvement

19 Example1 Approximate using ln 5≈1.6094379124 The results are as follows: kT(J)S(J)B(J) 0 2.4 1 1.8666661.688888 2 1.6833331.6222221.617778 3 1.6289681.610846 1.610088

20 Example then If Subtract (2) from 4×(1) (i.e 4(1)-2): Thus, Recursive Simpson Rule That is, Similarly, if we obtain Recursive Boole Rule (Richardson’s Improvement)

21 for all Theorem Ifthen Define Theorem Then and First improvement Second improvement Third improvement

22 Give preliminary approximations using the Composite Trapezoidal rule firstly and then improve them by Richardson’s extrapolation process Richardson’s Improvement Suppose that. (1) Then That is Subtract (2) from 4×(1). Then K=1 K=2 K=3

23 Romberg Integration Tabuleau

24 Example2 Approximate using Romberg integration. 2.400000 1.8666671.688888 1.6833341.6222221.617778 1.6289681.6108461.6100881.609490 R(J,0)R(J,1)R(J,2)R(J,3) Solution We use J=3. The Romberg table is given as follows: Where and ln 5≈1.6094379124

25 Example2 Approximate using R(5,5). Solution Compute R(J,k) where J=0,1,2,3,4,5 and k=0,1,2,3,4,5. The results are listed in the following table. 00 11.570796332.09439511 21.896118902.004559761.99857073 31.974231602.000269171.999983132.00000555 41.993570342.000016591.999999752.000000011.99999999 51.998393362.000001032.00000000 JR(J,0)R(J,1)R(J,2)R(J,3)R(J,4)R(J,5) Therefore,

26 5.4 Gauss-Legendre Integration Gaussian quadrature choose the points for evaluation in an optimal, rather than equally spaced way. Definition Choose the parameters of the quadrature formula properly such that it is likely of degree of precision 2N-1. This formula is called Gaussian formula.

27 Gaussian nodes is likely of degree of precision 2N-1.

28 are the zeros of the Nth Legendre polynomial. Theorem Suppose that are the roots of the Nth Legendre polynomial. For each, the numbers are defined by If is any polynomial of degree less than 2N, then

29 has the degree of precision 1. Midpoint Rule two-point Gaussian formula Three-point Gaussian formula has the degree of precision 3.

30 Truncation errors for Gaussian formulas Example LetWe have For See Table 5.8, P240 Let We have Change of variables

31 Example Approximate the integral using Gaussian quadrature with n=2 and n=3.


Download ppt "The purpose of Chapter 5 is to develop the basic principles of numerical integration Usefule Words integrate, integral 积分(的), integration 积分(法), quadrature."

Similar presentations


Ads by Google