Proving Legendre's Sum of 3 Squares Theorem via Geometry of Numbers

Every positive integer can be written as the sum of 4 squares $n = a_1^2 + a_2^2 + a_3^2 + a_4^2$ however, if we only allow sum of 3 squares some numbers have to be left out:

$n = a^2 + b^2 + c^2$ $\longleftrightarrow$ $n \equiv 4^a (8k+7)$

Excuse me for using the same letter twice to mean different things...

I am trying trying to find a proof of this result from within Cassels' Rational Quadratic Forms, but it's not always the easiest to read. In that book Legendre's Theorem is stated in a very general way:

Let $g(x) = \color{lightgry}{a}_1 \,x_1^2 + a_2\, x_2^2 + a_3\, x_3^2$ with $a_1, a_2, a_3 \in \mathbb{Z}$ and $a_1 a_2 a_3$ is squarefree...

• blah
• blah
• blah

Then where are $b_1, b_2, b_3 \in \mathbb{Z}$ not all of them zero with $a_1 \,b_1^2 + a_2\, b_2^2 + a_3\, b_3^2 = 0$

From what I gather, this Legendre theorem is strong form of the Hasse Principle and it can be proven using the geometry of numbers - which is the style I am endorsing today.

By the middle of Chapter 9 - Section 5 to be exact - we get the claim that proof of this theorem is complete. Because $x_1^2 + x_2^2 + x_3^2$ is the only quadratic form in it's genus. And that in indeed rested on the Hasse principle.

Come to think of it there is a rather serious question here. Mis-using the Hasse principle slightly we could way:

The only obstruction to having representation as sum of three squares $n = a^2 + b^2 + c^2$ happens in the 2-adic numbers $\mathbb{Q}_2$.

How could a statement like this possible be proven geometrically? Minkowski's geometry of numbers is decidedly a Euclidean result and so the only possible completion that should be useful is $\mathbb{R}$.

In the case of sum of 2-squares the role of the Hasse principle is even more obvious since we can use multiplication identities like:

\begin{eqnarray} (a+bi)(c+id) &=& (ac-bd) + i(ad+bc) \\ (a^2 + b^2)(c^2 + d^2)&=& (ac-bd)^2 + (ad+bc)^2 \end{eqnarray} and check each time that $n = x_1^2 + x_2^2 \mod p$ and multiply the result. By Minkowski theorem this only works when $p = 4k+1$.

I am going to keep reading, but does anyone know what polyhedron or oval or other geometric shape leads to a proof of the sum of 3 squares theorem?

• Have you seen this recent arXiv preprint? arxiv.org/abs/1509.02590 Nov 18 '15 at 16:56
• @so-calledfriendDon there must be tons of places I haven't looked but I can't go on forever so I am putting it on here. Also found this math.uga.edu/~pete/geometryofnumbers.pdf Nov 18 '15 at 16:58

• @johnmangual, you give a link to a Pete L. Clark writeup in comment above. In that, he discusses a very pretty approach, which is also in Serre's little book: the sum of three squares is one of Pete's ADC forms, named after Aubry and Davenport-Cassels, and means that, if $x^2 + y^2 + z^2$ represents an integer with rational values for $x,y,z,$ then it also does so with integral values. Pete and I found all positive forms for which this holds, published an article. Turned out we were confirming (and slightly correcting) an existing list by G. Nebe. Nov 18 '15 at 22:29
• I notice Dirichlet's Theorem on prime numbers in arithmetic progressions is an input. So for example there are infinitely many prime numbers among $1,4,7,10,\dots$. And Quadratic Reciprocity of Legendre Symbols that $\left(\frac{p}{q}\right)\left(\frac{q}{p}\right) = (-1)^{\frac{p-1}{2}\frac{q-1}{2}}$ is also an input. Nov 18 '15 at 21:40