M. Dumbser 1 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser Lecture on Numerical.

Slides:



Advertisements
Similar presentations
Lecture on Numerical Analysis Dr.-Ing. Michael Dumbser
Advertisements

M. Dumbser 1 / 23 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser Lecture on Numerical.
Lecture on Numerical Analysis Dr.-Ing. Michael Dumbser
Chapter 0 Review of Algebra.
Aim: How do we solve polynomial equations using factoring?
Lecture on Numerical Analysis Dr.-Ing. Michael Dumbser
0 - 0.
MULTIPLYING MONOMIALS TIMES POLYNOMIALS (DISTRIBUTIVE PROPERTY)
10-6 Solving Quadratic Equations by Factoring
A POLYNOMIAL is a monomial or a sum of monomials.
Numerical Integration
Computational Methods in Physics PHYS 3437
By S Ziaei-Rad Mechanical Engineering Department, IUT.
Chapter 7 Numerical Differentiation and Integration
Numerical Integration
MATH 685/ CSI 700/ OR 682 Lecture Notes
ECIV 720 A Advanced Structural Mechanics and Analysis
Newton-Cotes Integration Formula
MANE 4240 & CIVL 4240 Introduction to Finite Elements Numerical Integration in 1D Prof. Suvranu De.
Numerical Integration
MA/CS 375 Fall MA/CS 375 Fall 2002 Lecture 32.
ON MULTIVARIATE POLYNOMIAL INTERPOLATION
2010/3/11 計算機在工程上的應用 Page 1 Gaussian quadrature Advisor: J. T. Chen Reporter: Jia-Wei Lee Date: Mar., 11, 2010.
CISE301_Topic7KFUPM1 SE301: Numerical Methods Topic 7 Numerical Integration Lecture KFUPM Read Chapter 21, Section 1 Read Chapter 22, Sections 2-3.
CISE301_Topic71 SE301: Numerical Methods Topic 7 Numerical Integration Lecture KFUPM (Term 101) Section 04 Read Chapter 21, Section 1 Read Chapter.
Quadrature Greg Beckham. Quadrature Numerical Integration Goal is to obtain the integral with as few computations of the integrand as possible.
19.5 Numeric Integration and Differentiation
Integration. Problem: An experiment has measured the number of particles entering a counter per unit time dN(t)/dt, as a function of time. The problem.
The Islamic University of Gaza Faculty of Engineering Civil Engineering Department Numerical Analysis ECIV 3306 Chapter 21 Newton-Cotes Integration Formula.
Chapter 4, Integration of Functions. Open and Closed Formulas x 1 =a x 2 x 3 x 4 x 5 =b Closed formula uses end points, e.g., Open formulas - use interior.
Chapter 4 Numerical Differentiation and Integration 1/16 Given x 0, approximate f ’(x 0 ). h xfhxf xf h )()( lim)('    x0x0 x1x1 h x1x1 x0x0.
1 NUMERICAL INTEGRATION Motivation: Most such integrals cannot be evaluated explicitly. Many others it is often faster to integrate them numerically rather.
1 Chapter 5 Numerical Integration. 2 A Review of the Definite Integral.
3. Numerical integration (Numerical quadrature) .
Lecture 19 - Numerical Integration CVEN 302 July 22, 2002.
1 Chapter 7 NUMERICAL INTEGRATION. 2 PRELIMINARIES We use numerical integration when the function f(x) may not be integrable in closed form or even in.
1 Numerical Analysis Lecture 12 Numerical Integration Dr. Nader Okasha.
Chapters 5 and 6: Numerical Integration
CSE 330 : Numerical Methods
Wicomico High School Mrs. J. A. Austin AP Calculus 1 AB Third Marking Term.
MA2213 Lecture 4 Numerical Integration. Introduction Definition is the limit of Riemann sums I(f)
MA2213 Lecture 3 Approximation.
1. Interpolating polynomials Polynomial of degree n,, is a linear combination of Definitions: (interval, continuous function, abscissas, and polynomial)
6. Introduction to Spectral method. Finite difference method – approximate a function locally using lower order interpolating polynomials. Spectral method.
Differential Equations MTH 242 Lecture # 13 Dr. Manshoor Ahmed.
5. Integration 2.Quadrature as Box Counting 3.Algorithm: Trapezoid Rule 4.Algorithm: Simpson’s Rule 5.Integration Error 6.Algorithm: Gaussian Quadrature.
Numerical Differentiation and Quadrature (Integration)
CHAPTER 3 NUMERICAL METHODS
Lecture 16 - Approximation Methods CVEN 302 July 15, 2002.
The Limit of a Function. Home Calculating Limits Using the Limit Laws.
1/7  4.6 Adaptive Quadrature Methods Chapter 4 Numerical Differentiation and Integration -- Adaptive Quadrature Methods   /2  /4  /8 Predict the.
The purpose of Chapter 5 is to develop the basic principles of numerical integration Usefule Words integrate, integral 积分(的), integration 积分(法), quadrature.
ECE 530 – Analysis Techniques for Large-Scale Electrical Systems Prof. Hao Zhu Dept. of Electrical and Computer Engineering University of Illinois at Urbana-Champaign.
SE301_Topic 6Al-Amer20051 SE301:Numerical Methods Topic 6 Numerical Integration Dr. Samir Al-Amer Term 053.
Runge Kutta schemes Taylor series method Numeric solutions of ordinary differential equations.
Answers for Review Questions for Lectures 1-4. Review Lectures 1-4 Problems Question 2. Derive a closed form for the estimate of the solution of the equation.
CHAPTER 3 NUMERICAL METHODS
Chapter 4, Integration of Functions
NUMERICAL DIFFERENTIATION Forward Difference Formula
Chapter 7 Numerical Differentiation and Integration
MATH 2140 Numerical Methods
4.3 Elements of Numerical Integration
Numerical Analysis Lecture 23.
Elements of Numerical Integration
Numerical Computation and Optimization
SKTN 2393 Numerical Methods for Nuclear Engineers
Numerical Integration
Chapter 4, Integration of Functions
Elements of Numerical Integration
Presentation transcript:

M. Dumbser 1 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser Lecture on Numerical Analysis Dr.-Ing. Michael Dumbser 24 / 09 / 2008

M. Dumbser 2 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser Numerical Integration (Quadrature) of Functions - Motivation ab x f h Task: compute approximately Solution strategy: Divide interval [a;b] into n smaller subintervals Approximate f(x) by interpolation polynomials on the subintervals, e.g. using Lagrange interpolation Integrate these polynomials exactly on each subinterval and sum up So-called Newton-Cotes formulae

M. Dumbser 3 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser Transformation of the Integration Interval The computation of numerical quadrature formulae for each sub-interval can be technically considerably simplified using the following variable substitution: Therefore, it is sufficient, without the loss of generality, to consider from now on the case of numerical integration in the reference interval [0;1].

M. Dumbser 4 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Newton-Cotes Formulae The integral of f(x) is approximated in the following steps: 1.First, the function f(x) is interpolated by a polynomial of degree k inside each sub-interval. The interpolation points are distributed in an equidistant manner in each sub-interval. 2.Second, the interpolation polynomial is integrated analytically. 3.Steps 1 and 2 produce an approximation of the integral of f(x) in terms of the function values f i at the interpolation points and the step size h.

M. Dumbser 5 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Trapezium or Trapezoid Rule a b f h Use linear interpolation polynomials, i.e. polynomials of degree one in the subintervals [x i ;x i+1 ] [0;1]: x

M. Dumbser 6 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Simpson Rule (Originally Discovered by Johannes Kepler in 1615) a b f h Use quadratic interpolation polynomials, i.e. polynomials of degree two: x

M. Dumbser 7 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The 3/8 Rule Use cubic interpolation polynomials, i.e. polynomials of degree three:

M. Dumbser 8 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser Isaac Newton Sir Isaac Newton - (* 4. January 1643 in Woolsthorpe; 31. March 1727 in Kensington) Physicist, Mathematician, Astronomer and Philosopher Together with Leibniz, Newton is one of the inventors of infinitesimal calculus (differentiation and integration) 1667: Fellow of Trinity College, Cambridge 1687: Philosophiae Naturalis Principia Mathematica. Newton discovered the universal law of gravitation and the laws of motion of classical mechanics 1704: Opticks. A corpuscular theory of light. From 1703 president of the Royal Society Buried in Westminster abbey in London

M. Dumbser 9 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae The previously derived formulae were all of the form and were very easy to obtain since an equidistant spacing of the nodes was imposed and only the weights j had to be computed. The aim of the Gaussian quadrature formulae is now to obtain an optimal quadrature formula with a given number of points by making also the nodes an unknown in the derivation procedure of the quadrature formula and to come up with an optimal set of nodes x j and weights w j. An explicit construction strategy for Gaussian integration formulae: (1) Using M quadrature points, we have M unknowns for the positions and also M unknowns for the weights, i.e. a total of 2M unknowns. (2) We need 2M equations to determine uniquely the 2M unknowns. (3) The equations are obtained by requiring that the integration formula is exact for polynomials from degree 0 up to degree 2M-1 !

M. Dumbser 10 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae This means we have 2M equations of the form to solve for j and j. For P i ( ), any polynomial of degree i can be used, in particular also the monomial i. Example 1: One integration point, i.e. M = 1, leading to the two equations:

M. Dumbser 11 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae Example 2: Two integration points, i.e. M = 2, leading to the 4 equations:

M. Dumbser 12 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae A more efficient and more general way of obtaining the Gaussian quadrature formulae makes use of so-called orthogonal polynomials L i ( ), which are the so-called Legendre polynomials. The set of polynomials L i ( ) is called orthogonal, if it satisfies the relation First, we define the scalar-product of two functions f and g as follows: With this scalar product available, we can define the L 2 norm of a function f as

M. Dumbser 13 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae The polynomials L i ( ) can be constructed via Gram-Schmidt orthogonalization from the monomials M 0 = 1, M 1 = 2, M 3 = 3, … M n = n as follows: We first use the analogy of the scalar product of two functions with the scalar product already known for vectors: The Gram-Schmidt orthogonalization then proceeds as follows:

M. Dumbser 14 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae Instead of performing orthogonalization of vectors, we now perform the orthogonalization of functions as follows:

M. Dumbser 15 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae Using the orthogonality property of the Legendre polynomials, we find that The Gaussian quadrature formulae are written as If we now apply formula (2) to the integrals given in (1), we obtain the following linear equation system for the weights j, if we suppose the positions j to be known: (1) (2) (3)

M. Dumbser 16 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae Theorem: If the n positions j are given be the n roots of the polynomial L n ( L n ( j ) = 0 ), and the weights are given by the solution of system (3), then the Gaussian quadrature rules are exact for polynomials up to degree 2n-1, i.e. Proof: Suppose p( ) is an arbitrary polynomial of the space of polynomials of degree 2n-1, i.e. Then we can write the polynomial p( ) as

M. Dumbser 17 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser The Gaussian Quadrature Formulae Proof (continued): We have We also have This finishes the proof. QED

M. Dumbser 18 / 18 Analisi Numerica Università degli Studi di Trento Dipartimento dIngegneria Civile ed Ambientale Dr.-Ing. Michael Dumbser Integration of Improper Integrals If the integration interval goes to infinity, it can be very useful to change the integration variables use the following substitution: Example: If the integrand is singular at a known position c, than it is usually useful to split the integral as: Note: Gaussian quadrature formulae never use the interval endpoints, which makes them very useful for the computation of improper integrals!