Numerical Integration Lecture (I)1

Slides:



Advertisements
Similar presentations
Numerical Integration
Advertisements

ES 240: Scientific and Engineering Computation. Chapter 17: Numerical IntegrationIntegration  Definition –Total area within a region –In mathematical.
NUMERICAL DIFFERENTIATION AND INTEGRATION
Numerical Integration Lecture (II)1
Dr. Jie Zou PHY Chapter 9 Ordinary Differential Equations: Initial-Value Problems Lecture (I) 1 1 Besides the main textbook, also see Ref.: “Applied.
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 30 Numerical Integration & Differentiation.
Dr. Jie Zou PHY Chapter 2 Solution of Nonlinear Equations: Lecture (III)
Newton-Cotes Integration Formula
Curve Fitting and Interpolation: Lecture (IV)
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 29 Numerical Integration.
Dr. Jie Zou PHY Chapter 3 Solution of Simultaneous Linear Algebraic Equations: Lecture (II) Note: Besides the main textbook, also see Ref: Applied.
Dr. Jie Zou PHY Chapter 9 Ordinary Differential Equations: Initial-Value Problems Lecture (II) 1 1 Besides the main textbook, also see Ref.: “Applied.
Solution of Nonlinear Equations: Lecture (I)
Curve Fitting and Interpolation: Lecture (II)
Chapter 17 Numerical Integration Formulas. Graphical Representation of Integral Integral = area under the curve Use of a grid to approximate an integral.
ECIV 301 Programming & Graphics Numerical Methods for Engineers REVIEW III.
Dr. Jie Zou PHY Chapter 3 Solution of Simultaneous Linear Algebraic Equations: Lecture (III) Note: Besides the main textbook, also see Ref: Applied.
Dr. Jie Zou PHY Chapter 7 Numerical Differentiation: 1 Lecture (I) 1 Ref: “Applied Numerical Methods with MATLAB for Engineers and Scientists”, Steven.
Dr. Jie Zou PHY Welcome to PHY 3320 Computational Methods in Physics and Engineering.
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 21 CURVE FITTING Chapter 18 Function Interpolation and Approximation.
Numerical Differentiation:1* Lecture (II)
Integration of Equations
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Numerical Differentiation and Integration Standing.
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 27 Numerical Integration & Differentiation.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 ~ Numerical Differentiation and Integration ~ Newton-Cotes.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Numerical Differentiation and Integration Standing.
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.
Numerical Integration Formulas
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Numerical Differentiation and Integration Part 6 Calculus.
The Islamic University of Gaza Faculty of Engineering Civil Engineering Department Numerical Analysis ECIV 3306 Chapter 21 Newton-Cotes Integration Formula.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Applied Numerical Methods With MATLAB ® for Engineers.
Today’s class Numerical Integration Newton-Cotes Numerical Methods
MECN 3500 Inter - Bayamon Lecture Numerical Methods for Engineering MECN 3500 Professor: Dr. Omar E. Meza Castillo
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.
Numerical Differential & Integration. Introduction If a function f(x) is defined as an expression, its derivative or integral is determined using analytical.
9/14/ Trapezoidal Rule of Integration Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker
1 Trapezoidal Rule of Integration. What is Integration Integration: The process of measuring the area under a function.
Curve Fitting and Interpolation: Lecture (I)
EE3561_Unit 7Al-Dhaifallah EE 3561 : Computational Methods Unit 7 Numerical Integration Dr. Mujahed AlDhaifallah ( Term 342)
Trapezoidal Rule of Integration
12/1/ Trapezoidal Rule of Integration Civil Engineering Majors Authors: Autar Kaw, Charlie Barker
CSE 330 : Numerical Methods Lecture 15: Numerical Integration - Trapezoidal Rule Dr. S. M. Lutful Kabir Visiting Professor, BRAC University & Professor.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 6 - Chapter 21.
Numerical Integration
Dr. Jie Zou PHY Chapter 2 Solution of Nonlinear Equations: Lecture (II)
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 5 Integration and Differentiation.
3/12/ Trapezoidal Rule of Integration Computer Engineering Majors Authors: Autar Kaw, Charlie Barker
SE301_Topic 6Al-Amer20051 SE301:Numerical Methods Topic 6 Numerical Integration Dr. Samir Al-Amer Term 053.
3/20/ Trapezoidal Rule of Integration Chemical Engineering Majors Authors: Autar Kaw, Charlie Barker
Quadrature – Concepts (numerical integration) Don Allen.
Trapezoidal Rule of Integration
Applied Numerical Methods
Part 6 - Chapter 21.
Chapter 7 Numerical Differentiation and Integration
Numerical Integration Formulas
NUMERICAL DIFFERENTIATION AND INTEGRATION
NUMERICAL DIFFERENTIATION AND INTEGRATION
Trapezoidal Rule of Integration
MATH 2140 Numerical Methods
Romberg Rule of Integration
SKTN 2393 Numerical Methods for Nuclear Engineers
Romberg Rule of Integration
Numerical Computation and Optimization
Romberg Rule of Integration
Numerical Computation and Optimization
Romberg Rule of Integration
MATH 2140 Numerical Methods
Numerical Integration
Presentation transcript:

Numerical Integration Lecture (I)1 Chapter 8 Numerical Integration Lecture (I)1 1 Ref.: “Applied Numerical Methods with MATLAB for Engineers and Scientists”, Steven Chapra, 2nd ed., Ch. 17, McGraw Hill, 2008. Dr. Jie Zou PHY3320

Outline Introduction What is integration? When do we need numerical integration? Applications of integration in engineering and science Newton-cotes formulas (1) The trapezoidal rule Error of the Trapezoidal rule The composite trapezoidal rule Implementation in MATLAB Dr. Jie Zou PHY3320

Introduction What is integration? Mathematically: A definite integration is represented by . It means: The total value, or summation, of f(x)dx over the range x = a to b. Graphical representation: For functions lying above the x axis, the integral corresponds to the area under the curve of f(x) between x = a and b. When do we need numerical integration (also referred to as quadrature)? Functions that are difficult to or cannot be integrated analytically. Only a table of discrete data are available. Ref. Fig. 17.1 Graphical representation of the integral Dr. Jie Zou PHY3320

Applications of integration in engineering and science Examples related to “the integral as the area under a curve”: Examples related to the analogy between integration and summation: An example: To determine the mean of a continuous function Ref. Fig. 17.3

Newton-cotes formulas Basic strategy: Replacing a complicated function or tabulated data with a polynomial that is easy to integrate. fn(x) = a0 + a1x + … + an-1xn-1+anxn n: The order of the polynomial. Ref. Fig. 17.4 The approx. of an integral by the area under (a) a straight line and (b) a parabola Ref. Fig. 17.5 The approx. of an integral by the area under three straight-line segments Dr. Jie Zou PHY3320

Newton-cotes formulas: (1) The trapezoidal rule Basic idea: Replacing the complicated function or tabulated data with a polynomial or a series of polynomials of the first order (linear). Single and Composite applications Single application formula: Composite application formula: Ref. Fig. 17.7 Single application Ref. Fig. 17.9 Composite application

Error of the trapezoidal rule For single applications, an estimate for the error: If the function being integrated is linear, Et = 0; otherwise, Et  0. For composite applications, an estimate for the error: If the number of segments is doubled, Et is approximately quartered. Here, Ref. Fig. 17.8 Truncation error for a single application of the trapezoidal rule

Example: Composite application of the trapezoidal rule Example 17.2 (Ref.): Use the two-segment trapezoidal rule to estimate the integral of f(x) = 0.2 + 25x – 200x2 + 675x3 – 900x4 + 400x5 from a = 0 to b = 0.8. Also, find the true error Et and the approximate error, Ea. (1) By hand. (2) Implement on a computer-write an M-file. x0 = a x1 x2 = b Two segments n = 2; Dr. Jie Zou PHY3320

Results n h I t (%) 2 0.4 1.0688 34.9 3 0.2667 1.3695 16.5 4 0.2 1.4848 9.5 5 0.16 1.5399 6.1 6 0.1333 1.5703 4.3 7 0.1143 1.5887 3.2 8 0.1 1.6008 2.4 9 0.0889 1.6091 1.9 10 0.08 1.6150 1.6 Dr. Jie Zou PHY3320

Implementation of composite trapezoidal rule on a computer Write an M-file called My_Trapezoidal_Rule.m to do Example 17.2. A copy of the code will be handed out later. Dr. Jie Zou PHY3320