MCS 471 Practice Problems 4: Numerical Integration

Hand Calculator and Maple Calculations

Do NOT Hand In: Practice Problems ONLY!



Background Reading:


Practice Problems Topics:


CAUTION: These problems are just for practice and are not to be handed in. Some of these old exam problems and answers may not be relevant to your current course. The capital letter "S" is used for an integral sign in the problems below. Caveat Usor!

Practice Problems:

In following computational questions, use 4 Digit Exam Precision: Round to 4 significant decimal digits only when you record an intermediate or final answer in your exam booklet; and continue calculations with these rounded, recorded numbers.
  1. Use an efficient, composite, 5-point Trapezoidal Rule to numerically approximate the integral of a piecewise function given by
    
        0.5                         { (x2+3)/4, if 0.5<x<1.0
       S     f(x) dx,  where f(x) = {                                             
        1.5                         { (x+4)/(x2+4), if 1.0<x<1.5    
    
    

    minimizing the number of floating point operations and function evaluations. Also, tabulate

      i   0   1   2   3   4 
     xi           
     f i           
    for all values used. {Caution: You must treat f(x) as one continuous function.}



    (S99a)

  2. Use a composite, 1-point Gaussian Quadrature (3×G1; i.e., 3 points total) to numerically approximate the integral given by
          b            0.75 
         S  f(x) dx = S     (exp(2x)/(x+8)) dx ,
          a            0     
    
    minimizing the number of floating point operations and function evaluations. Also, tabulate

      i   1   2   3 
     ti       
     xi       
     Fi       
    for all values used, where Fi=F(ti).

    (S99a)

Old Practice Problems using Chopping:

In computational problems, use "EXAM PRECISION": Chop to 4 significant (4C) digits only when you write an intermediate or final answer down and continue calculations with those numbers recorded.

Caution: These old problems may have different answers due to different methods and chopping truncation used, so do not worry if your answers are a few least significant digits different.


  1. In parts (a) to (d), approximate
                                        1
                                       S  f(x) dx,
                                        0
    
    where
                 {  (1+x)  on  (0,0.5)
          f(x) = {                        ,
                 {  (2-x)   on  (0.5,1.0)
    
    according to the following simple rules:
  2. In parts (a) to (e), approximate
                                        +1
                                       S  ln(1+x2) dx,
                                        -1
    
    for the following rules:
  3. Approximate the integral:
                                    3 
                                   S  exp(x)*sqrt(x) dx 
                                    0 
    
    using 7 points and Simpson's composite rule. Minimize the number of function evaluations, multiplications and additions. (Ans.: 27.45 or 27.43 with extra chops)
  4. Estimate how many function evaluations (i.e., points used) are needed for an efficient, composite Simpson's Rule, so that the absolute value of the global approximation error is <= 0.5e-3. The interval of integration is (-3,2), -2^p/p! <= (d/dx)^p*f(x) <= 2^(-p)/p! for all x and p; and the chopping error is assumed to be negligible. (Final Ans.: 15 function evaluations.)
  5. Approximate the integral:
                                         4 
                                   I =  S  (sqrt(x)/exp(x))  dx  
                                         1 
    
    using a 7 point Simpson's rule. Minimize the number of function evaluations and multiplications in calculating the composite rule.
    (Ans.:  
          x =      (1.000  1.500  2.000  2.500  3.000     3.500     4.000)
       f(x) =(4ch) (0.3678 0.2732 0.1913 0.1297 0.8623e-1 0.5645e-1 0.3663e-1),
    I =(4ch) (0.3678+4*(0.2732+0.1297+0.5649e-1)+2*(0.1913+0.8623e-1)+0.3663e-1)/6.
      =(4ch) (0.4661,0.4660,0.4663), depending on the chopping sequence.)
    


Web Source: http://www.math.uic.edu/~hanson/mcs471/pp4.html

Email Comments or Questions to hanson A T math uic edu

Click Here For Current Class HomePage