Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

In a trapezoidal rule problem I got following question:

"Evaluate the above integral using trapezoidal rule with five points."

My confusion is here what we take for the value of $n$ is it $5$ or $4$. I'm thinking like suppose if you take $5$ points $1,2,3,4,5$ then there would be $4$ sections/intervals so that's why $n$ should be $4$. Can anyone help me in it that what would be $n$'s value and why? Please provide explanation too if possible. Thanks!

Note: $h=\frac{b-a}{n}$ where $b$ and $a$ are limits.

share|improve this question
    
@Julian Thanks for the edit ! –  shashi kant Dec 14 '12 at 13:29
    
Thanks should go to @levap. I just approved his edit (and did some minor improvements). –  Julian Kuelshammer Dec 14 '12 at 13:45
    
Oh then @levap Thank you too friend :) –  shashi kant Dec 14 '12 at 14:03
    
But I've one more confusion that In Trapezoidal or Simpson rule Do we need to integrate the function first or we can directly apply the values to the respective function equation to get the approximation? –  shashi kant Dec 14 '12 at 14:04

3 Answers 3

It seems like your $n$ equals $4$. As you say in your question, you consider $h = \frac{b-a}n$, that gives you the evaluation points $x_i = a + ih$, $0 \le i \le n$ (such that $x_0 = a$ and $x_n = b$), so altogether five points, as you correctly say.

share|improve this answer
    
Shouldn't that be an $h = \frac{b-a}n$? That is, an $n$ in the denominator? –  Amzoti Dec 14 '12 at 12:47
    
@Amzoti Thanks. –  martini Dec 14 '12 at 12:54
    
@martini thanks for the reply ! –  shashi kant Dec 14 '12 at 13:31

There is some ambiguity, texts usually say something like "with $n=8$." But $5$ points is $5$ points, and it would be unreasonable not to count the endpoints. So here $n=4$.

If we are integrating $f(x)$ from $a$ to $b$, we would use $$\frac{\Delta x}{2}\left(f(x_0)+2f(x_1)+2f(x_2)+2f(x_3)+f(x_4)\right),$$ where $\Delta x=\dfrac{b-a}{4}$ and $x_i=a+(\Delta x)i$.

share|improve this answer
    
Hey Andre Thanks for reply! –  shashi kant Dec 14 '12 at 13:30

When you have 5 integration points you will divide you integration interval in 4 sub-intervals, and by definition $n$ is the number of sub-intervals, which is 4 in this case.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.