Simpson's 3/8 Rule
Calling Sequence
Parameters
Description
Examples
ApproximateInt(f(x), x = a..b, method = simpson[3/8], opts)
ApproximateInt(f(x), a..b, method = simpson[3/8], opts)
ApproximateInt(Int(f(x), x = a..b), method = simpson[3/8], opts)
f(x)
-
algebraic expression in variable 'x'
x
name; specify the independent variable
a, b
algebraic expressions; specify the interval
opts
equation(s) of the form option=value where option is one of boxoptions, functionoptions, iterations, method, outline, output, partition, pointoptions, refinement, showarea, showfunction, showpoints, subpartition, view, or Student plot options; specify output options
The ApproximateInt(f(x), x = a..b, method = simpson[3/8], opts) command approximates the integral of f(x) from a to b by using Simpson's 3/8 rule. This rule is also known as Newton's 3/8 rule. The first two arguments (function expression and range) can be replaced by a definite integral.
If the independent variable can be uniquely determined from the expression, the parameter x need not be included in the calling sequence.
Given a partition P=a=x0,x1,...,xN=b of the interval a,b, Simpson's 3/8 rule approximates the integral on each subinterval xi−1,xi by integrating the cubic function that interpolates the four points xi−1,f⁡xi−1, 2⁢xi−13+xi3,f⁡2⁢xi−13+xi3, xi−13+2⁢xi3,f⁡xi−13+2⁢xi3, and xi,f⁡xi. This value is
xi−xi−1⁢f⁡xi−1+3⁢f⁡2⁢xi−13+xi3+3⁢f⁡xi−13+2⁢xi3+f⁡xi8
In the case that the widths of the subintervals are equal, the approximation can be written as
b−a⁢f⁡x0+3⁢f⁡2⁢x03+x13+3⁢f⁡x03+2⁢x13+2⁢f⁡x1+3⁢f⁡2⁢x13+x23+3⁢f⁡x13+2⁢x23+2⁢f⁡x2+...+f⁡xN−13+2⁢xN3+f⁡xN8⁢N
Traditionally, Simpson's 3/8 rule is written as: given N, where N is a positive multiple of 3, and given equally spaced points a=x0,x1,x2,...,xN=b, an approximation to the integral ∫abf⁡xⅆx is
3⁢b−a⁢f⁡x0+3⁢f⁡x1+3⁢f⁡x2+2⁢f⁡x3+3⁢f⁡x4+3⁢f⁡x5+2⁢f⁡x6+3⁢f⁡x7+...+3⁢f⁡xN−1+f⁡xN8⁢N
By default, the interval is divided into 10 equal-sized subintervals.
For the options opts, see the ApproximateInt help page.
This rule can be applied interactively, through the ApproximateInt Tutor.
polynomial≔CurveFittingPolynomialInterpolation⁡x0,2⁢x0+x13,x0+2⁢x13,x1,f⁡0,f⁡13,f⁡23,f⁡1,z:
integrated≔int⁡polynomial,z=x0..x1:
factor⁡integrated
−x0−x1⁢f⁡0+f⁡1+3⁢f⁡13+3⁢f⁡238
with⁡StudentCalculus1:
ApproximateInt⁡sin⁡x,x=0..5,method=simpson38
3⁢sin⁡14316+3⁢sin⁡29616+sin⁡516+sin⁡728+3⁢sin⁡11316+3⁢sin⁡23616+sin⁡48+3⁢sin⁡25616+3⁢sin⁡13316+sin⁡928+3⁢sin⁡7316+sin⁡528+3⁢sin⁡8316+3⁢sin⁡17616+sin⁡38+3⁢sin⁡19616+3⁢sin⁡10316+3⁢sin⁡7616+3⁢sin⁡4316+sin⁡328+3⁢sin⁡5316+3⁢sin⁡11616+sin⁡28+3⁢sin⁡13616+3⁢sin⁡1616+3⁢sin⁡1316+sin⁡128+3⁢sin⁡2316+3⁢sin⁡5616+sin⁡18
ApproximateInt⁡x⁢x−2⁢x−3,x=0..5,method=simpson38,output=plot
ApproximateInt⁡tan⁡x−2⁢x,x=−1..1,method=simpson38,output=plot,partition=50
To play the following animation in this help page, right-click (Control-click, on Mac) the plot to display the context menu. Select Animation > Play.
ApproximateInt⁡ln⁡x,1..100,method=simpson38,output=animation
See Also
Boole's Rules
Newton-Cotes Rules
plot/options
Simpson's Rule
Student
Student plot options
Student[Calculus1]
Student[Calculus1][ApproximateInt]
Student[Calculus1][ApproximateIntTutor]
Student[Calculus1][RiemannSum]
Student[Calculus1][VisualizationOverview]
Trapezoidal Rule
Download Help Document