1
$\begingroup$

I am a class 9th student. Sorry if my problem is silly.

I am trying to find the sum of squares from 1 to 10. For this I tried summation, and it was fine. But now I came to know that Integration can be also used for summation.

But the problem is I am not able to get correct answer. The sum of squares from 1 to 10 is $$\sum_{n=1}^{10} n^2 = 385$$ but after doing integration answer is $$\int_1^{10} x^2 \, dx= \left[\frac{x^3}{3}\right]_1^{10} = 333$$ which is quite less than the actual answer.

What is the correct way of calculating squares from 1 to 10 via integration? Am I mistaken something?

$\endgroup$
1
  • $\begingroup$ Do you similarly think the area of a triangle with a particular base and height is the same as the area of a rectangle with that same base and height? Same error. $\endgroup$
    – JMoravitz
    Commented Nov 30, 2023 at 0:22

3 Answers 3

2
$\begingroup$

Using integration as a substitute for the summation is an interesting but problematic idea.

Your integration captures the area under the curve of the continuous function $~f(x)=x^2,~$ as opposed to the area under the step function : $~g(x)~$ defined by

  • $g(x)=1 ~: ~1 \leq x < 2$
  • $g(x)=4 ~: ~2 \leq x < 3$
  • $\cdots$
  • $g(x)=100 ~: ~10 \leq x < 11$

As a separate issue, your integration specifies an interval of [1,10]. Analogizing the summation to the area under the step function $~g(x),~$ this overlooks the area under the interval [10,11].

As expected, if you instead change the integration to $~\displaystyle \int_1^{11} x^2 ~dx ~$ then you get $~\displaystyle \left[\frac{x^3}{3}\right]_1^{11} > 385.~$ That is, with the intervals aligned, you would expect the area under the continuous function to be greater than the area under the step function.

$\endgroup$
1
$\begingroup$

When it comes to making asymptotic estimates, integration and summation behave in similar (not equal, but similar) ways when looking at their growth rate, when they diverge. As an example, when $k$ is a nonnegative integer, $$ \sum_{n=1}^N n^k \sim \int_1^N x^k\,dx = \frac{N^{k+1}}{k+1} - \frac{1}{k+1} \sim \frac{N^{k+1}}{k+1} $$ when $N \to \infty$

To compare a sum and related integral when you have concrete bounds (not variable upper bounds), look up the Euler Maclaurin summation formula.

$\endgroup$
0
$\begingroup$

As @KCd suggested, Euler-McLaurin summation is very interesting to use for this kind of problem.

For your case, $$S_p=\sum_{n=1}^p {n^2}$$ depending on the level of expansion, you would obtain $$S_p=\frac{p^3}{3}+\frac{p^2}{2}+\frac{p}{6}+O\left(\frac{1}{p^2}\right)$$ which gives the exact result.

If you do the same for $$T_p=\sum_{n=1}^p {n^k}$$ it would give $$T_p =\frac{p^{k+1}-1}{k+1}+\frac{1}{2} \left(p^k+1\right)$$ Notice that making $k=2$, you would obtain $383.5$ which is not exact.

Use it for $k=\pi$ and $p=20$. The approximate result would be $65156.6$ while the exact value is $65316.4$ (relative error of $0.25$%).

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .