# A number which can be expressed as the sum of the squares of 6 odd integers

Which one of the numbers below can be expressed as the sum of the squares of 6 odd integers?

$${1998,1996,2000,2002,2004}$$ I first started this by saying if $m$ is odd then $m = 2k+1$ so $$m^2 = 4k^2+4k+1$$ so $$m^2-1 = 4k(k+1)$$ I'm stuck now and any help will be appreciated.

-
You can add $2006=35^2+25^2+7^2+1^2+9^2+5^2$, too. – Dietrich Burde Apr 23 '14 at 14:47

$$m^2=4k(k+1)+1$$
If $k$ is even, $k+1$ is odd and vice-versa. So the square of an odd number is $1$ more than a multiple of $8$, otherwise written as $m^2\equiv1\pmod8$. The sum of $6$ odd squares would therefore be $6$ more than a multiple of $8$ (or $2$ less than one). Assuming any of those answers are correct, this leaves only $1$ possibility.
An odd integer is congruent $1$ mod $4$. Hence the sum of six odd integers is congruent $2$ mod $4$. This leaves only $1998$ and $2002$. Also it must be congruent $2$ mod $8$.This leaves only $1998$. And indeed, we have $1998=43^2+11^2+3^2+3^2+3^2+1^2$.
You left out "the square of" a couple places, and could just use the $\pmod 8$ test. – Ross Millikan Apr 24 '14 at 17:37