0

I have been trying to solve a question that arose in my mind a couple of days ago.

What is the sum of:

$1+4+9+16+25+\cdots +n^2$?

It is the sum of squares of each numbers starting from $1$ to $n$.

Can there be any formula for this sum?

Kenta S
  • 16,151
  • 15
  • 26
  • 53
user24225
  • 101

1 Answers1

2

$$1^2+2^2+...+n^2=\frac{n(n+1)(2n+1)}{6}.$$ We can get it by the following way.

$$(n+1)^3-1=\sum_{k=1}^n((k+1)^3-k^3)=\sum_{k=1}^n(3k^2+3k+1)=$$ $$=3\sum_{k=1}^nk^2+3\cdot\frac{n(n+1)}{2}+n$$ and the rest is smooth.