A website made the statement $P(n) = \sum\_{i=0}^n i^2 = \frac{1}{6}n(n+1)(2n+1)$.

If I want to know the value at the 3rd position in the sequence is, I just plug $3$ into the equation:

$$P(3) = \sum\_{n=0}^3 = i^2 = \frac{1}{6}3(3+1)(2(3)+1)$$

And the result is $\frac{84}{6} = 14$. Why is it not 4, which is the third integer generated by the summation: $0, 1, 4, 9, 16...$?