$\displaystyle \sum_{i=1}^{n} (n + i)^2 = (\sum_{i=1}^{n - 1} (n - 1 + i)^2) + (2n - 1)^2 + (2n)^2 - n^2$

Proof:

$\displaystyle \sum_{i=1}^{n} (n + i)^2 = (n + 1)^2 + (n + 2)^2 + \ldots + (2n - 3)^2 + (2n - 2)^2 + (2n - 1)^2 + (2n)^2 = n^2 + (n + 1)^2 + (n + 2)^2 + \ldots + (2n - 3)^2 + (2n - 2)^2 + (2n - 1)^2 + (2n)^2 - n^2$

$\displaystyle \sum_{i=1}^{n - 1} (n - 1 + i)^2 = n^2 + (n + 1)^2 + \ldots + (2n - 3)^2 + (2n - 2)^2$

So, $\displaystyle \sum_{i=1}^{n} (n + i)^2 = \sum_{i=1}^{n - 1} (n - 1 + i)^2 + (2n - 1)^2 + (2n)^2 - n^2$