1 Part I: Riemann Sums
Total Page:16
File Type:pdf, Size:1020Kb
Math 242 Lab Riemann Sums & Numerical Integration 1 Part I: Riemann Sums 1.1 Sigma notation One strategy for calculating the area of a region is to cut the region into simple shapes, calculate the area of each simple shape, and then add these smaller areas together to get the area of the whole region. We will use that approach, but it is useful to have a notation for adding a lot of values together: the sigma !" notation. The function to the right of the sigma is called the summand, and the numbers below and above the sigma are called the lower and upper limits of the summation. Summation $ way to read Sigma notation the sigma notation notation 2 2 2 2 2 5 2 % &' &( &) &* the sum ofk s+uared k=1 k fork equals % tok equals * 1 1 1 1 1 �7 1 3 & 4 & 5 & 6 & 7 the sum of % overk k=3 k− fork equals ( tok equals , 0 1 2 3 4 5 � 5 j ' &' &' &' &' &' the sum of ' to thej-th power j=0 ' forj equals . toj equals * �7 a2 &a 3 &a 4 &a 5 &a 6 &a 7 the sum ofa subi i=2 ai fori equals ' toi equals , � The variable typicallyi,j, ork" used in the summation is called the counter or index variable. Problem 1: Write the summation denoted by each of the following: 5 3 (a) k=1 k / � b" 7 %"j 1 / j=2 − j � 4 c) m=0 'm&%"/ � % Math 242 Lab Riemann Sums & Numerical Integration x f x" g x" h x" % ' ) ( ' ( % ( ( % -' ( ) . ( ( * ( * ( 0igure %: #able for 1xample 1. In practice, the sigma notation is fre+uently used with the standard function notation: 3 f k&'"/f % & '" &f ' & '" &f ( & '" /f (" &f )" &f *" �k=1 and 4 f x i"/f x 1"&f x 2"&f x 3"&f x 4". �k=1 5 5 Example%. Use the values in #able % to evaluate k=2 'f k" and j=3 * &f j '"". 5 − 5 Solution: k=2 'f k"/'f '"&'f ("&'f )"&'f *"� / ' ("&' %"&'� ."&' (" / 14. j=3 *&f j '"" / *&f ( '""& *&f ) '""& *&f * '"" / *&f %""& *&f '""& *&f ("" / *&'"& *&("& *&%"− / 21. − � − − � Problem 2: Use the values off,g andh in #able % to evaluate the following: 5 (a) k=2 g k"/ � b" 5 4f i %"&h i"5 / i=3 − � Since the sigma notation is simply a notation for addition, it has all of the familiar properties of addition. Theorem 1. (Summation Properties) Sum of Constants: n C/C&C&C& &C(n terms)/nC. • k=1 ··· Addition: n a �&b "/ n a & n b . • k=1 k k k=1 k k=1 k Subtraction:� n a b "/� n a � n b . • k=1 k − k k=1 k − k=1 k Constant Multiple:� n Ca /�C n a�. • k=1 k k=1 k Preserves positivity:� ifb a for� allk then n b n a . In particular ifa . • k ≥ k k=1 k ≥ k=1 k k ≥ for allk then n a .. k=1 k ≥ � � Additivity of ranges:� if% m n then m a & n a / n a . • ≤ ≤ k=1 k k=m+1 k k=1 k � � � ' Math 242 Lab Riemann Sums & Numerical Integration 1.2 Sums of areas of rectangles Later, we will appro2imate the areas under curves by building rectangles as high as the curve, calculating the area of each rectangle, and then adding the rectangular areas together. Example'. 1valuate the sum of the rectangular areas in 0igure ' and write the sum using the sigma notation. Solution: sum of the rectangular areas / sum of base" height) for each rectangle / %" %/(" & %"× %/)" & %" %/*" / ),/7.. Using the sigma notation, 5 % %" %/(" & %" %/)" & %" %/*" / . k k�=3 Problem 3: 1valuate the sum of the rectangular areas in 0igure ( and write the sum using the sigma notation. Solution: ( Math 242 Lab Riemann Sums & Numerical Integration Example(. Write the sum of the areas of the rectangles in 0igure * using the sigma notation. Solution: The area of each rectangle is base" height). × rectangle base height area % x x f x " x x "f x " 1 − 0 1 1 − 0 1 ' x2 x 1 f x 2" x2 x 1"f x 2" ( x −x f x " x −x "f x " 3 − 2 3 3 − 2 3 The area of thek-th rectangle is x k x k 1"f x k", and the total area of the rectangles is the sum 3 − − xk x k 1"f x k). k=1 − − � 1.3 Area under a curve by Riemann sums Suppose we want to calculate the area between the graph of a positive functionf and the interval 4a, b5 on thex–axis 0ig. ,". The Riemann Sum method is to build several rectangles withy/f x" bases on the interval 4a, b5 and sides that reach up to the graph off 0ig. 9". #hen the areas of the rectangles can be calculated and added together to get a number called a Riemann sum off on4a, b5. The area of the region formed by the rectangles is an approximation of the area we want. Example). Appro2imate the area in 0igure ' a) between the graph off and the interval 4', *5 on thex–axis by summing the areas of the rectangles in 0igure ' b). Solution: The total area of rectangles is '" (" & %" *" / %% s+uare units. 0igure ': Illustration for 12ample 4. In order to effectively describe this process, some new vocabulary is helpful: a “partition< of an interval and the mesh of the partition. $ partitionP of a closed interval 4a,b5 inton subintervals is a set ofn & % points x 0 / a, x1, x2, x3, ..., xn 1, xn /b in increasing order,a/x 0 < x1 < x2 < { − } x3 < ... < xn /b. $ partition is a collection of points on the axis and it does not depend on the function in any way." The points of the partitionP divide the interval inton subintervals 0igure (): 4x 0, x15, 4x1, x2], 4x2, x35, . , and 4xn 1, xn5 with lengths =x1 /x 1 x 0, =x2 /x 2 x 1, . , =xn /x n x n 1. The − − − − − pointsx k of the partitionP are the locations of the vertical lines for the sides of the rectangles, ) Math 242 Lab Riemann Sums & Numerical Integration and the bases of the rectangles have lengths =xk fork/%,',(, ..., n. The mesh or norm of the partition is the length of the longest of the subintervals 4xk 1, xk5, or, equivalently, the maximum − of the =xk fork/%,',(, ..., n. 0igure (: >artition of the interval 4a, b]. $ function, a partition, and a point in each subinterval determine a Riemann sum. Supposef is a positive function on the interval 4a, b],P/ x 0 / a, x1, x2, x3, ..., xn 1, xn /b is a partition { − } of 4a, b5, andc k is anx-value in thek-th subinterval 4x k 1, xk5 :x k 1 c k x k. Then the area of − − ≤ ≤ thek-th rectangle isf c k" x k x k 1"/f c k"=xk. 0igure )" · − − 0igure ): >art of a Riemann sum. n efinition 1. $ summation of the form k=1 f c k"=xk is called a Riemann sum off for the partitionP. � This Riemann sum is the total of the areas of the rectangular regions and is an appro2imation of the area between the graph off and thex–axis. Example*. 0ind the Riemann sum forf x"/%/x and the partition %,),* using valuesc / ' andc / 5. { } 1 2 Solution: The two subintervals are 4%, )5 and 4), *5 so =x1 / ( and =x2 / 1. Then the Riemann sum for this partition is n % % f c "=x /f c "=x &f c "=x /f '" (" &f *" %" / (" & %" / %.,. k k 1 1 2 2 ' * k�=1 Problem 4: Calculate the Riemann sum forf x"/%/x on the partition %,),* using the values { } c1 / 3,c 2 / 4. Answer: * Math 242 Lab Riemann Sums & Numerical Integration Problem 5: What is the smallest value a Riemann sum forf x"/%/x and the partition %,),* { } can have@ Aou will need to select values forc 1 andc 2." What is the largest value a Riemann sum can have for this function and partition@ Braw a picture if necessary." Answers: 0inally, it is important to note that iff is a continuous function on 4a, b], then by taking more and more skinnier and sCinnier" rectangles, our choice of locations for the pointsc i in the interval 4xi 1, xi5 becomes unimportant. − Theorem 2. Iff is a continuous function on4a, b5 (or has finitely many #ump discontinuities) then n lim Sn / lim f c i"=x n n →∞ →∞ �i=1 exists and is the same value no matter what choice ofc i we make. As we will see later, when the functionf is continuous, the limit in the theorem above approaches b the value of the integral a f x"dx, which is the area under the curve. #hus, no matter what method we use for choosing the pointsc , if we take enough rectangles, we can expect the Riemann sum to � i provide a good appro2imation to the area under the curve. 7.