# Math Help - Approximate Integration - Trapezoidal Rule

1. ## Approximate Integration - Trapezoidal Rule

42) Use the trapezoidal rule with n = 10 to approximate Integral (from 0 to 20) of cos(Pi*x)dx. Compare your result to the actual value. Can you explain the discrepancy?

When I use the Trap Rule, I get Delta(x) = 20/10 = 2.

So, 1(f(2) + 2f(4) + 2f(6) + 2f(8) + 2f(10) + 2f(12) + 2f(14) + 2f(16) + 2f(18) + f(20)) = 20.

However, when I calculate the integral I get (1/Pi)*(Sin(Pi*x)) from 0 to 20, or just 0.

I don't really know how to explain the discrepancy -- I only learned what trap. rule was yesterday!

Any help? Am I right in the calculations?

2. Originally Posted by Sprintz
42) Use the trapezoidal rule with n = 10 to approximate Integral (from 0 to 20) of cos(Pi*x)dx. Compare your result to the actual value. Can you explain the discrepancy?

When I use the Trap Rule, I get Delta(x) = 20/10 = 2.

So, 1(f(2) + 2f(4) + 2f(6) + 2f(8) + 2f(10) + 2f(12) + 2f(14) + 2f(16) + 2f(18) + f(20)) = 20.

However, when I calculate the integral I get (1/Pi)*(Sin(Pi*x)) from 0 to 20, or just 0.

I don't really know how to explain the discrepancy -- I only learned what trap. rule was yesterday!

Any help? Am I right in the calculations?
Draw a graph of the function and indicate the positions of the knots (the points used in your calculation). Do you notice anything?

Now try using the trap rule again with n=20.

CB