Simpson's 3/8 Rule - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Education : Student Package : Calculus 1 : Visualization : Integration : Student/Calculus1/Simpson38

Simpson's 3/8 Rule

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

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)

Parameters

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

Description

• 

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 xi1,xi by integrating the cubic function that interpolates the four points xi1,fxi1, 23xi1+13xi,f23xi1+13xi, 13xi1+23xi,f13xi1+23xi, and xi,fxi.  This value is

18xixi1fxi1+3f23xi1+13xi+3f13xi1+23xi+fxi

• 

In the case that the widths of the subintervals are equal, the approximation can be written as

18bafx0+3f23x0+13x1+3f13x0+23x1+2fx1+3f23x1+13x2+3f13x1+23x2+2fx2+...+f13xN1+23xN+fxNN

  

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 ∫abfxⅆx is

38bafx0+3fx1+3fx2+2fx3+3fx4+3fx5+2fx6+3fx7+...+3fxN1+fxNN

• 

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.

Examples

polynomialCurveFitting[PolynomialInterpolation]x0,2x0+x13,x0+2x13,x1,f0,f13,f23,f1,z:

integrated∫x0x1polynomialⅆz:

factorintegrated

18x0x1f1+3f23+3f13+f0

(1)

withStudent[Calculus1]:

ApproximateIntsinx,x=0..5,method=simpson38

18sin4+316sin256+316sin133+18sin92+316sin143+316sin296+116sin5+18sin3+316sin196+316sin103+18sin72+316sin113+316sin236+316sin116+18sin2+316sin136+316sin73+18sin52+316sin83+316sin176+316sin56+316sin76+316sin43+18sin32+316sin53+316sin13+18sin12+316sin23+316sin16+18sin1

(2)

ApproximateIntxx2x3,x=0..5,method=simpson38,output=plot

ApproximateInttanx2x,x=1..1,method=simpson38,output=plot,partition=50

To play the following animation in this help page, right-click (Control-click, on Macintosh) the plot to display the context menu.  Select Animation > Play.

ApproximateIntlnx,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

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam