How does the trapezoidal rule work?

1 Answer
Oct 17, 2014

Let us approximate the definite integral

int_a^b f(x)dx

by Trapezoid Rule T_n.

First, split the interval [a,b] into n equal subintervals:

[x_0,x_1], [x_1,x_2],[x_2,x_3],...,[x_{n-1},x_{n}],

where a=x_0 < x_1 < x_2< cdots < x_n=b.

Trapezoid Rule T_n can be found by

T_n=[f(x_0)+2f(x_1)+2f(x_2)+cdots+2f(x_{n-1})+f(x_n)]{b-a}/{2n}.


I hope that this was helpful.