Mathematics1 Mathematics 1 Applied Informatics Štefan BEREŽNÝ.

Slides:



Advertisements
Similar presentations
Numerical Integration
Advertisements

6. 4 Integration with tables and computer algebra systems 6
Mathematics1 Mathematics 1 Applied Informatics Štefan BEREŽNÝ.
Applied Informatics Štefan BEREŽNÝ
Mathematics1 Mathematics 1 Applied Informatics Štefan BEREŽNÝ.
Riemann sums, the definite integral, integral as area
1 Chapter 5 Numerical Integration. 2 A Review of the Definite Integral.
A Riemann sum is a method for approximating the total area underneath a curve on a graph. This method is also known as taking an integral. There are 3.
Section 5.7 Numerical Integration. Approximations for integrals: Riemann Sums, Trapezoidal Rule, Simpson's Rule Riemann Sum: Trapezoidal Rule: Simpson’s.
Chapter 7 Numerical Differentiation and Integration
8 TECHNIQUES OF INTEGRATION. There are two situations in which it is impossible to find the exact value of a definite integral. TECHNIQUES OF INTEGRATION.
Mathematics1 Mathematics 1 Applied Informatics Štefan BEREŽNÝ.
1 Example 2 Estimate by the six Rectangle Rules using the regular partition P of the interval [0,  ] into 6 subintervals. Solution Observe that the function.
NUMERICAL DIFFERENTIATION The derivative of f (x) at x 0 is: An approximation to this is: for small values of h. Forward Difference Formula.
1 Example 1 (a) Estimate by the Midpoint, Trapezoid and Simpson's Rules using the regular partition P of the interval [0,2] into 6 subintervals. (b) Find.
Index FAQ Numerical Approximations of Definite Integrals Riemann Sums Numerical Approximation of Definite Integrals Formulae for Approximations Properties.
5.2 Definite Integrals Greg Kelly, Hanford High School, Richland, Washington.
5.2 Definite Integrals Quick Review Quick Review Solutions.
Riemann Sums and the Definite Integral Lesson 5.3.
Numerical Integration In general, a numerical integration is the approximation of a definite integration by a “weighted” sum of function values at discretized.
Integrals 5.
1 Chapter 5 Numerical Integration. 2 A Review of the Definite Integral.
MAT 1235 Calculus II Section 7.7 Approximate (Numerical) Integration
4.6 Numerical Integration -Trapezoidal Rule -Simpson’s Rule
Introduction to Numerical Analysis I
4.6 Numerical Integration Trapezoid and Simpson’s Rules.
4.6 Numerical Integration. The Trapezoidal Rule One method to approximate a definite integral is to use n trapezoids.
1 Numerical Integration Section Why Numerical Integration? Let’s say we want to evaluate the following definite integral:
MA2213 Lecture 4 Numerical Integration. Introduction Definition is the limit of Riemann sums I(f)
Homework questions thus far??? Section 4.10? 5.1? 5.2?
Lets take a trip back in time…to geometry. Can you find the area of the following? If so, why?
EE3561_Unit 7Al-Dhaifallah EE 3561 : Computational Methods Unit 7 Numerical Integration Dr. Mujahed AlDhaifallah ( Term 342)
Integration Copyright © Cengage Learning. All rights reserved.
5.2 Definite Integrals. Subintervals are often denoted by  x because they represent the change in x …but you all know this at least from chemistry class,
Section 4.3 – Riemann Sums and Definite Integrals
Numerical Approximations of Definite Integrals Mika Seppälä.
Section 5.9 Approximate Integration Practice HW from Stewart Textbook (not to hand in) p. 421 # 3 – 15 odd.
Definite Integrals Riemann Sums and Trapezoidal Rule.
CHAPTER 3 NUMERICAL METHODS
Section 5.1/5.2: Areas and Distances – the Definite Integral Practice HW from Stewart Textbook (not to hand in) p. 352 # 3, 5, 9 p. 364 # 1, 3, 9-15 odd,
Chapter 15 – Multiple Integrals 15.1 Double Integrals over Rectangles 1 Objectives:  Use double integrals to find volumes  Use double integrals to find.
Sigma Notations Example This tells us to start with k=1 This tells us to end with k=100 This tells us to add. Formula.
1 Example 1 Estimate by the six Rectangle Rules using the regular partition P of the interval [0,1] into 4 subintervals. Solution This definite integral.
Estimating area under a curve
Warm up 10/16 (glue in). Be seated before the bell rings DESK homework Warm-up (in your notes) Agenda : go over hw Finish Notes lesson 4.5 Start 4.6.
Section 5.6: Approximating Sums Suppose we want to compute the signed area of a region bounded by the graph of a function from x = a to x = b.
“In the fall of 1972 President Nixon announced that the rate of increase of inflation was decreasing. This was the first time a sitting president used.
Riemann Sum. When we find the area under a curve by adding rectangles, the answer is called a Rieman sum. subinterval partition The width of a rectangle.
Riemann Sum. Formula Step 1 Step 2 Step 3 Riemann Sum.
Approximating Antiderivatives. Can we integrate all continuous functions? Most of the functions that we have been dealing with are what are called elementary.
Numerical Integration using Trapezoidal Rule
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.
Numerical Integration
CHAPTER 3 NUMERICAL METHODS
NUMERICAL DIFFERENTIATION Forward Difference Formula
Lecture 19 – Numerical Integration
Midpoint and Trapezoidal Rules
NUMERICAL INTEGRATION
MTH1170 Numeric Integration
5.2 Definite Integrals Greg Kelly, Hanford High School, Richland, Washington.
TECHNIQUES OF INTEGRATION
Copyright © Cengage Learning. All rights reserved.
Composite Numerical Integration
Numerical Integration:
Copyright © Cengage Learning. All rights reserved.
5.1 Area.
Numerical Integration
Objectives Approximate a definite integral using the Trapezoidal Rule.
Numerical Integration
Presentation transcript:

Mathematics1 Mathematics 1 Applied Informatics Štefan BEREŽNÝ

5 th lecture

MATHEMATICS 1 Applied Informatics 3 Štefan BEREŽNÝ Contents Numerical integration Rectangular Rule Trapezoidal Rule Simpson’s Rule:

MATHEMATICS 1 Applied Informatics 4 Štefan BEREŽNÝ Numerical integration Definition: The partition D =  x 0, x 1, …, x n  of interval  a, b  is given by a = x 0  x 1  …  x n-1  x n = b. We will get n sub-intervals  x 0, x 1 ,  x 1, x 2 ,  x 2, x 3 , …,  x n-2, x n-1 ,  x n-1, x n  of the same length h, where x k = a + k  h for k = 1, 2, 3, …, n and

MATHEMATICS 1 Applied Informatics 5 Štefan BEREŽNÝ Numerical integration Notation: We shall denote y k = for k = 1, 2, 3, …, n.

MATHEMATICS 1 Applied Informatics 6 Štefan BEREŽNÝ Rectangular Rule We approximate function f by a constant function on each sub-interval  x k-1, x k . The constant function is uniquely determined by the one point. Then the considered constant function is: y = y k on interval  x k  1, x k . Its integral I k in the interval  x k  1, x k  represents the area of the rectangle and so I k = h  y k.

MATHEMATICS 1 Applied Informatics 7 Štefan BEREŽNÝ Rectangular Rule If we add all the numbers I 1, I 2, …., I n, we obtain:

MATHEMATICS 1 Applied Informatics 8 Štefan BEREŽNÝ Rectangular Rule S n is the approximate value of the Riemann integral of function f on the interval  a, b . It is the sum of the areas of n rectangles constructed on the intervals  x 0, x 1 ,  x 1, x 2 ,  x 2, x 3 , …,  x n-2, x n-1 ,  x n-1, x n . The accuracy of the approximation should increase with increasing n.

MATHEMATICS 1 Applied Informatics 9 Štefan BEREŽNÝ Trapezoidal Rule We shall denote y k = f ( x k ). We approximate function f by a linear function on each sub-interval  x k-1, x k . The linear function is uniquely determined by the requirement that its graph (a straight line) passes through two chosen points. Let us choose the points  x k  1, y k  1  and  x k, y k . Then the considered linear function is: y = y k  1 + (( y k  y k  1 )  ( x  x k  1 ))/ h. Its integral I k in the interval  x k  1, x k  represents the area of the trapezoid and so I k = ( h  ( y k  1, y k ))/2.

MATHEMATICS 1 Applied Informatics 10 Štefan BEREŽNÝ Trapezoidal Rule If we add all the numbers I 1, I 2, …., I n, we obtain:

MATHEMATICS 1 Applied Informatics 11 Štefan BEREŽNÝ Trapezoidal Rule S n is the approximate value of the Riemann integral of function f on the interval  a, b . It is the sum of the areas of n trapezoids constructed on the intervals  x 0, x 1 ,  x 1, x 2 ,  x 2, x 3 , …,  x n-2, x n-1 ,  x n-1, x n . It can naturally be expected that the finer the partition of the interval  a, b , the better is the approximation of the Riemann integral.

MATHEMATICS 1 Applied Informatics 12 Štefan BEREŽNÝ Trapezoidal Rule In other words, the accuracy of the approximation should increase with increasing n and with decreasing h. This expectation is correct. It can be proved that if function f has a continuous second derivative f  in interval  a, b  and M 2 is the maximum of  f  in  a, b  then the following error estimate holds:

MATHEMATICS 1 Applied Informatics 13 Štefan BEREŽNÝ Simpson’s Rule Let us now choose an integer n that it is even and let us approximate function f by a quadratic polynomial on each of the sub-intervals  x 0, x 2 ,  x 2, x 4 ,  x 4, x 6 , …,  x n-4, x n-2 ,  x n-2, x n . The quadratic polynomial on the sub-interval  x k  2, x k  for k = 2, 4, 6, …, n is uniquely determined if we require that its graph (a parabola) passes trough three chosen points. Let the three chosen points be  x k  2, y k  2 ,  x k  1, y k  1  and  x k, y k .

MATHEMATICS 1 Applied Informatics 14 Štefan BEREŽNÝ Simpson’s Rule The coefficients and the integral of such a quadratic polynomial in the interval  x k  2, x k  can be relatively easily evaluated - you can verify for yourself that the integral I k = h  ( y k   y k  1 + y k )/3. Summing all the numbers I 2, I 4, …., I n, we obtain:

MATHEMATICS 1 Applied Informatics 15 Štefan BEREŽNÝ Simpson’s Rule S n is the approximate value of the Riemann integral of function f on the interval  a, b . It can be proved that if the fourth derivative f (4) of function f is continuous in  a, b  and M 4 is the maximum of  f (4)  in  a, b  then the following error estimate holds:

MATHEMATICS 1 Applied Informatics 16 Štefan BEREŽNÝ Thank you for your attention.