Numeric Integration  Simpson's Rule
� Maplesoft, a division of Waterloo Maple Inc., 2007
Introduction
This application is one of a collection of examples teaching Calculus with Maple. These applications use Clickable Calculus� methods to solve problems interactively. Steps are given at every stage of the solution, and many are illustrated using short video clips. Click on the buttons to watch the videos.
Problem Statement
Evaluate numerically the definite integral of on the interval . Compare the results of Maple's builtin integrator with that produced by Simpson's rule. Use Maple to investigate the derivation of Simpson's rule.
Solution
Step

Result

Enter the expression for , then use the context menu to construct the definite integral and evaluate it with Maple's builtin integrator.
Rightclick on the expression and select Constructions/Definite Integral/ and insert the limits of integration in the ensuing dialog box.
Rightclick on the definite integral and select Approximations and the number of digits desired.


(1) 

To access Maple's builtin Simpson's rule, load the Student Calculus 1 package.
Tools>Load package>Student Calculus 1.

Loading
Student:Calculus1

Use Maple's Approximate Integration Tutor to explore the numerical evaluation of the integral via Simpson's rule.
Use the equation label to obtain a copy of the integrand.
Right click on the integrand to access the Approximate Integration Tutor.
Select Tutors>CalculusSingle Variable>Approximate Integration. Enter the limits of integration. Set n to the desired number of partitions. Select "Simpson's Rule" for the method of approximation, select "Normal" for the Partition type and click Display, (see Figure 1below). Click Close to display the plot in the worksheet.


(2) 


Figure 1 Simpson's rule applied to via the Approximate Integration Tutor.


Derivation of the Simpson's Rule
Step

Result

Form a list of the three points .
Interpolate these three points with a polynomial quadratic in .
Navigate to the task template Tools/Tasks: Browse/Curve Fitting/Polynomial Interpolation. Insert Minimal Content, and delete the default list of points. Reference the relevant list of points by equation label, and execute the PolynomialInterpolation command.


(3) 
> 


Integrate the interpolation polynomial over the interval , and simplify the result.
Using the definite integral icon in the Expression palette, construct the definite integral of the interpolating polynomial. Press [Enter] to evaluate the integral.
Rightclick on the result and select Simplify. Rightclick and select Assign to a Name. (For example, use the name "q".)


Add the areas under three contiguous "double panels" and factor the sum. The result can be generalized to
where the first sum is over evenindexed nodes; the second, over odd; and . Of course, in this formulation of Simpson's rule, must be an even integer.
Using the evaluation icon from the Expression palette, reference the area contained in the representative "double panel" and set the index to 0, 2, and 4. Add the resulting expressions. Rightclick and select Factor.


(6) 

(7) 

Legal Notice: The copyright for this application is owned by Maplesoft. The application is intended to demonstrate the use of Maple to solve a particular problem. It has been made available for product evaluation purposes only and may not be used in any other context without the express permission of Maplesoft.