# Infinite riemann sums discrepancy

1. Aug 28, 2011

### computerex

Hello. I have to solve some integrals using both the standard theorem of calculus and infinite Riemann sums.

$\int_{1}^{7} (x^2-4x+2) dx = \lim_{n \to \infty } \sum f(x_i)\Delta x_i = \lim_{n \to \infty } \sum (x_i^2 - 4x_i + 2)6/n$

Evaluating the definite integral results in an answer of 30 units.. But it seems I have done something wrong in trying to do it with infinite Riemann sums:

Taking the limit results in 42, not 30. Note I may have prematurely omitted some terms that will evaluate to 0 after taking the limit to save space.. Can someone tell me what I am doing wrong?

Last edited: Aug 28, 2011
2. Aug 28, 2011

### Screwdriver

Why exactly did you sub in $1+\frac{6i}{n}$ for $x^2$, but not for $x$?

3. Aug 28, 2011

### computerex

I caught that minutes after posting.. But I still am not getting the right answer. Can someone please calculate the integral so that I can compare it with my work to see where I went wrong?

4. Aug 28, 2011

### Screwdriver

5. Aug 28, 2011

### computerex

Thank you for the reply.. But
I already know how to evaluate definite integrals, I need to know where my mistake is in computing the sum, which is tedious and error prone.. I already know how to set everything, it is an error in simplification. I would highly appreciate it if someone could post the solution.

6. Aug 28, 2011

### Screwdriver

I'd love to, but that's not the way it works around here. The best I (or anyone else) is allowed to do is guide you towards the solution as per the forum rules. You should post the method you used to compute the sum, or perhaps some steps from your simplification, and then we can probably spot the error for you.

7. Aug 28, 2011

### computerex

$$\lim_{n \to \infty }\sum_{1}^{n}\frac{6}{n}(1+\frac{12i}{n} + \frac{36i^2}{n^2} - 4 - \frac{24i}{n}+2)$$

$$\lim_{n \to \infty }\sum_{1}^{n}[\frac{6}{n} + \frac{72i}{n^2} + \frac{216i^2}{n^3} - \frac{24}{n} - \frac{144i}{n^2} + \frac{12}{n}] = 0 + 72+432-0-144+0=360$$

8. Aug 28, 2011

### computerex

Do you see the error? Since we are taking limit to infinity I don't bother evaluating everything, I just get the coefficients..

9. Aug 28, 2011

### Screwdriver

Okay, wait a minute. You're expanding this:

$$\sum_{i=0}^{n} \frac{6}{n}[(1 + \frac{6i}{n})^2 - 4 (1 + \frac{6i}{n}) + 2]$$

It should give you this:

$$\sum_{i=0}^{n} [\frac{216 i^2}{n^3} - \frac{72 i}{n^2} - \frac{6}{n}]$$

You have to find this sum first before taking the limit. To do this, split it up and factor out constants to get this:

$$\frac{216 }{n^3} \sum_{i=0}^{n} [i^2] - \frac{72 }{n^2} \sum_{i=0}^{n} - \frac{6}{n} \sum_{i=0}^{n} [1]$$

Do you know how to find these sums?

10. Aug 28, 2011

### computerex

Sorry for the delayed response, but does this seem right?
$$\frac{216 }{n^3} \sum_{i=0}^{n} [i^2] - \frac{72 }{n^2} \sum_{i=0}^{n} - \frac{6}{n} \sum_{i=0}^{n} [1] = \frac{216(n)(n+1)(2n+1)}{6n^3} - \frac{72(n)(n+1)}{2n^2} - 6$$

11. Aug 28, 2011

### Dick

Yes, now take the limit n->infinity.

12. Aug 28, 2011

### computerex

Yep. Through out the entire day I have been subtracting from 432 as opposed to 432/6... Thank you all for helping me :)

And this is a testament to why I hate these stupid problems. Conceptual understanding is nice.. But my calc teacher who has been teaching the subject since before I was born (1970) also made numerous mistakes in doing examples of these problems in front of the class.. No reason as to why we should resort to first principles just to torture the students.

I think being able to set up the problem is good enough.