Proof

We split the interval into [Maple Math] subintervals and apply Simpson's Rule on each pair of consecutive intervals:

> int1:=(h/3)*(f(a)+4*f(a+h)+f(a+2*h))+err(xi[1]);

[Maple Math]

> int2:=(h/3)*(f(a+2*h)+4*f(a+3*h)+f(a+4*h))+err(xi[2]);

[Maple Math]

> int3:=(h/3)*(f(a+4*h)+4*f(a+5*h)+f(a+6*h))+err(xi[3]);

[Maple Math]

and so on until

> intm:=(h/3)*(f(a+(n-2)*h)+4*f(a+(n-1)*h)+f(b))+err(xi[m]);

[Maple Math]

where each of the error term is of the form

> err(xi[i])=-h^5*(D@@4)(f)(xi[i])/90;

[Maple Math]

Adding all the integrals together yields:

> inttot:=int1+int2+int3+intm;

[Maple Math]
[Maple Math]

which can be rewritten as

[Maple Math]

>

This yields the composite formula. The error term can be simplified by considering that for all values of [Maple Math] ,

[Maple Math] ,

with [Maple Math] the minimal value of the fourth derivative over the interval [Maple Math] . Then

[Maple Math] , or

[Maple Math] .

Similarly, for the maximum over [Maple Math] :

[Maple Math] ,

[Maple Math] , or

[Maple Math] .

Using the Mean Value Theorem, we can then say that there must exist a value [Maple Math] in the interval [Maple Math] so that

[Maple Math]

The error term then becomes:

[Maple Math]

or

[Maple Math]

which, with [Maple Math] can finally be written as

[Maple Math]

>