# Could someone prove the rule that the sum of n squares is given by : [n(n + 1)(2n + 1)]/6

We have to prove the sum of the squares of the first n numbers is given by n(n+1)(n+2)/6

We know that (x+1)^3 = x^3 + 3x^2 + 3x + 1, now if we write the cubes of the numbers 1 to n+1, we get

1^3 = (0+1) ^3 = 0^3...

Start your 48-hour free trial to unlock this answer and thousands more. Enjoy eNotes ad-free and cancel anytime.

We have to prove the sum of the squares of the first n numbers is given by n(n+1)(n+2)/6

We know that (x+1)^3 = x^3 + 3x^2 + 3x + 1, now if we write the cubes of the numbers 1 to n+1, we get

1^3 = (0+1) ^3 = 0^3 + 3(0^2) + 3 (0) + 1

2^3 = (1+1) ^3 = 1^3 + 3(1^2) + 3 (1) + 1

3^3 = (2+1) ^3 = 2^3 + 3(2^2) + 3 (2) + 1

n^3 = (n-1+1) ^3 = (n-1) ^3 + 3(n-1) ^2 + 3(n-1) + 1

(n+1)^3 = n^3 + 3n^2 + 3n + 1

We see that for all the cubes above other than (n+1)^3 there are equal terms on the right hand side as well as the left hand side. So we cancel them and we are left with:

(n+1)^3 = 3*sum of squares from 1 to n + 3*(sum of numbers from 1 to n) + n + 1

Denote the sum of the squares which we are finding by S

=> n^3 + 3n^2 + 3n + 1 = 3*S + 3*[sum of numbers from 1 to n] + n+1

As we are trying to find the sum of the squares I assume the relation for the sum of the numbers from 1 to n is known, which is n*(n+1)/2

So n^3 + 3n^2 + 3n + 1 = 3*S + 3*n(n+1)/2 + n+1

=> n^3 + 3n^2 + 3n + 1 = 3*S + 3*(n^2 + n)/2 + n+1

=> 3*S = n^3 + 3n^2 + 3n + 1 - 3*(n^2 + n)/2 – n-1

=> 3*S = n^3 + 3n^2 + 3n + 1 – (3*n^2 -3n)/2 – n – 1

=> 3*S = n^3 + 3n^2/2 + n/2

=> S = (1/6)( 2n^3 + 3n^2 + n)

=> S = (1/6)*n*(2n^2 + 3n +1)

=> S = (1/6)*n*(2n^2 + 2n + n +1)

=> S = (1/6)*n*(2n(n+1)+1(n+1))

=> S = (1/6)*n*(n+1)(2n+1)

Therefore we prove that the sum of the squares of the numbers from 1 to n is given by (1/6)*n*(n+1)(2n+1)

Approved by eNotes Editorial Team