## The Sum of the squares of the first n natural numbers

Why do you love math or why do you love apples? Share with us!

### The Sum of the squares of the first n natural numbers

Here the solution is more-tricky, because we need a more complex idea how to solve it.
We know that:
\begin{equation}
(x+1)^3 = x^3 + 3x^2 + 3x +1
\end{equation}
So Let’s write down the this equation for values of x=1 to x=n :
\begin{equation}
2^3 = 1^3 + 3.1^2 + 3.1 +1\\
3^3 = 2^3 + 3.2^2 + 3.2 +1\\
4^3 = 3^3 + 3.3^2 + 3.3 +1\\
5^3 = 4^3 + 3.4^2 + 3.4 +1\\
………\\
(n+1)^3 = n^3 + 3.n^2 + 3.n +1\\
\end{equation}
Let’s add all the rows and see what we get.
Left side will be 2^3 + 3^3 + 4^3 + … + (n+1)^3
Right side will be:
\begin{equation}
1^3 + 2^3 + 3^3 + .. + n^3 + 3\sum_{i=1}^{n}i^2\ + 3\sum_{i=1}^{n}i\ + n
\end{equation}
As you can see there are many elements in the left and right side which are the same. We can destroy 2^3 from both sides, as well as 3^3, as well as 4^3, etc. This process will continue to n^3 - the max element the both sides of equation shares.
So at the end we will deduct the equation to this equation:
\begin{equation}
(n+1)^3 = 1^3 + 3\sum_{i=1}^{n}i^2\ + 3\sum_{i=1}^{n}i\ + n
\end{equation}
We already calculate this sum in a previous topic:
\begin{equation}
\sum_{i=1}^{n}i\
\end{equation}
This in fact is the sum of all the natural numbers from 1 to n. You can see the detailed proof here:
Sum of first n natural numbers proof
So we know that it is equal to n*(n+1) / 2
The other sum we have in the equation is:
\begin{equation}
\sum_{i=1}^{n}i^2\
\end{equation}
Which in fact is the sum we are looking for. That’s why we did all this, in order to extract this sum.
So let’s continue the calculations.
\begin{equation}
n^3 + 3.n^2 + 3.n + 1 = 1 + 3\sum_{i=1}^{n}i^2\ + 3 \frac {n(n+1)} {2}\ + n\\
n^3 + 3.n^2 + 3.n = 3\sum_{i=1}^{n}i^2\ + 3 \frac {n(n+1)} {2}\ + n\\
n^3 + 3.n^2 + 2.n = 3\sum_{i=1}^{n}i^2\ + 3 \frac {n(n+1)} {2}\\
n^3 + 3.n^2 + 2.n - 3 \frac {n(n+1)} {2}\ = 3\sum_{i=1}^{n}i^2\\
n(n^2 + 3n + 2) - 3 \frac {n(n+1)} {2}\ = 3\sum_{i=1}^{n}i^2\\
n(n+1)(n+2) - 3 \frac {n(n+1)} {2}\ = 3\sum_{i=1}^{n}i^2\\
n(n+1)(n+2 -\frac{3}{2}) = 3\sum_{i=1}^{n}i^2\\
\frac {n(n+1)(2n +1)} {6} = \sum_{i=1}^{n}i^2\\
\end{equation}
Eureka!
You can share your solutions too, I will be happy to discuss them. showmyiq

Posts: 390
Joined: Sat Sep 15, 2012 9:45 pm

### Re: The Sum of the squares of the first n natural numbers

I have just been thinking that if you take the square root of the sum of the first n natural numbers you will find the length of the space diagonal of an n-dimensional rectangular parallelogram! It is just a fact I find amusing, so I decided to share it.
DArk0n3

Posts: 76
Joined: Sat Oct 06, 2012 4:20 pm 