Gauss’s first proof of quadratic reciprocity

The law of quadratic reciprocity compares two questions that appear unrelated: is p a square modulo q , and is q a square modulo p ? Here p and q are distinct odd primes. It predicts that the answers agree unless both primes are 3\pmod4 , in which case they are opposite. Using the usual residue symbol, the assertion is

\displaystyle \left(\frac pq\right)\left(\frac qp\right)=(-1)^{\frac{p-1}{2}\frac{q-1}{2}}.

What would an inductive proof have to do? Suppose we understand pairs of smaller primes and already know whether p is a square modulo the larger prime q . How can we use that knowledge to calculate the reverse test \left(\frac qp\right) ? We therefore need to manufacture some integer smaller than q , whose residue character can be related to q . Gauss’s idea is that a square congruence itself manufactures such an integer. The argument becomes much less mysterious if we calculate with one before introducing general notation.

Take p=7 and q=19 . The number 7 is a square modulo 19 , since 8^2\equiv7\pmod{19} . Instead of stopping at that congruence, write the actual equality

\displaystyle 8^2=7+19\cdot3.

The remainder 3 is smaller than 19 . Reduce this equality modulo 7 . Because the left side is a square, 19\cdot3 must be a square modulo 7 . Thus

\displaystyle \left(\frac{19}{7}\right)=\left(\frac{3}{7}\right)=-1.

We have translated the unknown residue test involving 19 into a test involving 3 . And \left(\frac37\right) is accessible by the induction hypothesis: interchange 3 and 7 , paying the minus sign because they are both 3\pmod4 . Notice that the coefficient 3 was not chosen in advance; it appeared as the quotient (8^2-7)/19 . This is the essential discovery. A square modulo the large prime produces a small remainder through ordinary integer division.

Descent

For general primes p<q , suppose \left(\frac pq\right)=1 . Choose a square root x of p modulo q , and take the even one of x and q-x . Thus 0<x<q , and for some odd integer t we have

\displaystyle x^2=p+qt,\qquad |t|<q.

The size bound follows because 0<x^2<q^2 and 0<p<q . The parity of t follows because x is even while p,q are odd. We choose x even for a further reason: its square is divisible by 4 , so

\displaystyle p+qt\equiv0\pmod4.

This tiny congruence will supply exactly the sign in quadratic reciprocity. Thus the three features of the choice : an actual equality, a small quotient, and an even square roo, each have a separate job.

Assume for the moment that \gcd(p,t)=1 . Modulo p , the equality x^2=p+qt says qt is a nonzero square. Since the quadratic character is multiplicative,

\displaystyle \left(\frac qp\right)=\left(\frac tp\right).

Modulo |t| , the same equality says p is a square. More precisely \left(\frac p{t}\right)=1 , where for a negative odd denominator we use the prime factors of its absolute value. The induction hypothesis may now be used to reverse the smaller pair p,t . For an odd integer n , let \epsilon(n) be 0 or 1 according as n\equiv1 or 3\pmod4 . The reciprocity law for smaller prime factors, multiplied together, gives

\displaystyle \left(\frac qp\right)=\left(\frac tp\right)=(-1)^{\epsilon(p)\epsilon(t)}\left(\frac pt\right)=(-1)^{\epsilon(p)\epsilon(t)}.

Why is this the right sign? The congruence p+qt\equiv0\pmod4 settles it without another residue calculation. When q\equiv1\pmod4 , we have t\equiv-p\pmod4 , so p and t cannot both be 3\pmod4 ; the exponent vanishes. When q\equiv3\pmod4 , we have t\equiv p\pmod4 , so the exponent equals \epsilon(p) . In both cases

\displaystyle \epsilon(p)\epsilon(t)\equiv\epsilon(p)\epsilon(q)\pmod2.

This proves reciprocity whenever p is a square modulo q and the remainder t is coprime to p . The calculation reveals the mechanism: one congruence moves q into the smaller numerator t , a second congruence makes the reverse symbol equal to 1 , and the choice of an even root determines the sign. The theorem is a consequence of two reductions of the same integer equality.

For p=3 and q=11 , the even square root gives 6^2=3+11\cdot3 . Here t=3 shares a factor with p . Reducing modulo 3 gives 0\equiv0 , not a residue test: the argument above has lost all its information. But the equation contains extra divisibility. Since 3 divides the right side, it divides 6 ; dividing the equality by 3 gives

\displaystyle 3\cdot2^2=1+11.

Now reduction modulo 3 is informative again: 11\equiv-1\pmod3 , so \left(\frac{11}{3}\right)=-1 . The problem was not that the descent failed, but that a common square factor in the original equality had to be removed first. Gauss’s induction requires a systematic version of precisely this repair.

There is another reason to extend the elementary computation. In the difficult case we shall multiply p by an auxiliary prime; the quantity represented by a square modulo q will then be a product of two primes, rather than a single prime. So we need one descent that works with an odd squarefree integer a , possibly negative, all of whose prime factors are smaller than q .

Suppose a is one of p , -p , or p\ell , with \ell a different odd prime smaller than q , and suppose \left(\frac aq\right)=1 . Choose an even root x and write

\displaystyle x^2=a+qt,\qquad 0<x<q,\qquad 0<|t|<q.

These bounds hold because |a|<q^2 . The Jacobi symbol \left(\frac uv\right) for an odd, possibly composite denominator v means the product of Legendre symbols over the prime factors of |v| . It is only a convenient abbreviation for the separate residue tests. Put d=\gcd(|a|,|t|) . The squarefreeness of a forces d\mid x , so writing a=du , t=dv , x=dy turns the original equation into

\displaystyle dy^2=u+qv.

The numbers d,u,v are pairwise coprime. Indeed, d is squarefree and therefore coprime to u ; the definition of d makes u and v coprime; and any prime dividing both d and v would, by the displayed equation, also divide u . Because d is odd and x even, y is still even. Also |v|<q . We have retained both features needed for the induction: smaller prime factors and a square divisible by 4 .

We now repeat the two reductions, but do so separately modulo u and d . From dy^2=u+qv we obtain

\displaystyle \left(\frac qu\right)=\left(\frac{dv}{u}\right),\qquad \left(\frac qd\right)=\left(\frac{-uv}{d}\right).

Multiplying, and remembering a=du , gives

\displaystyle \left(\frac qa\right)=\left(\frac{-u}{d}\right)\left(\frac d{u}\right)\left(\frac va\right).

Reduction modulo |v| gives a third relation: dy^2\equiv u\pmod v , so \left(\frac uv\right)=\left(\frac dv\right) . Consequently \left(\frac av\right)=\left(\frac{du}{v}\right)=1 . The preceding formula is therefore a relation between two reciprocity products:

\displaystyle \underbrace{\left(\frac aq\right)\left(\frac qa\right)}_{\text{pair }a,q}\;=\;\underbrace{\left(\frac{-u}{d}\right)\left(\frac d{-u}\right)}_{\text{pair }-u,d}\;\underbrace{\left(\frac av\right)\left(\frac va\right)}_{\text{pair }a,v}.

The first factor on the left is 1 by construction. On the right, every prime factor in the two pairs is smaller than q . We are therefore allowed to invoke the previously proved reciprocity statements, even though a or u may be composite. The only remaining question is whether their signs combine correctly.

The sign check is short when we retain its source. For odd n , write \epsilon(n)=0 for n\equiv1\pmod4 and \epsilon(n)=1 for n\equiv3\pmod4 , including negative n . We know by induction that the right side is (-1)^E , where

\displaystyle E=\epsilon(-u)\epsilon(d)+\epsilon(a)\epsilon(v)\pmod2.

Because y is even, u+qv\equiv0\pmod4 . If q\equiv1\pmod4 , then u\equiv-v\pmod4 ; substituting \epsilon(-u)=\epsilon(v) and \epsilon(a)=\epsilon(d)+1+\epsilon(v)\pmod2 gives E=0 . If q\equiv3\pmod4 , then u\equiv v\pmod4 ; substituting \epsilon(-u)=1+\epsilon(v) and \epsilon(a)=\epsilon(d)+\epsilon(v)\pmod2 gives E=\epsilon(a) . Hence in both cases E=\epsilon(a)\epsilon(q) . We have established the usable form of the descent:

\displaystyle \boxed{\left(\frac aq\right)=1\quad\Longrightarrow\quad \left(\frac aq\right)\left(\frac qa\right)=(-1)^{\epsilon(a)\epsilon(q)}.}

The same derivation covers d=1 , d=p , d=\ell , or d=p\ell . Nothing has been hidden in a case distinction; the common divisor is divided out and the remaining symbols are all genuinely smaller. Notice that the source of the final sign is still the elementary fact that an even square is 0\pmod4 .

For an example where the quotient shares both prime factors, 120^2=3\cdot5+137\cdot105 has d=15 . After dividing, the equality becomes 15\cdot8^2=1+137\cdot7 ; the new remainder 7 is coprime to 15 , so the same symbol calculation applies. Thus the common-divisor problem is an issue of normalization.

Auxiliary Prime

Return to a prime p<q . If p is a square modulo q , the preceding descent with a=p finishes the problem. If p is not a square and q\equiv3\pmod4 , then (-1/q)=-1 , so (-p/q)=1 . We may apply the same descent to a=-p . Since \epsilon(-p)=1+\epsilon(p)\pmod2 and \left(\frac{-1}q\right)=-1 , removing the minus sign gives the desired reciprocity law for p,q . Thus the sign change already solves every case with q\equiv3\pmod4 .

What remains is a very specific obstruction: q\equiv1\pmod4 and p is a nonsquare modulo q . Then (-1/q)=1 , so changing p to -p does not help. To manufacture a square we would like to multiply p by another nonsquare \ell modulo q . Such a prime certainly exists below q — factor any nonsquare integer between 1 and q — but an arbitrary choice is not enough. We also need to know how to compare \left(\frac q\ell\right) and \left(\frac\ell q\right) without already assuming the theorem for this pair. The cleverer target is therefore a small prime \ell for which the reverse test \left(\frac q\ell\right)=-1 is known directly. Once such a prime is found, the argument is almost natural. If \ell were a square modulo q , the square case already proved at this same q would imply \left(\frac q\ell\right)=1 , contradicting its selection. Thus \ell is a nonsquare modulo q . The product p\ell is a square modulo q ; our established descent applies to it. The only genuinely new work is to prove that the desired auxiliary prime exists without invoking reciprocity.

Assume q\equiv1\pmod4 . We want an odd prime \ell<q with \left(\frac q\ell\right)=-1 . First suppose q\equiv5\pmod8 . Then q-2\equiv3\pmod8 . At least one prime factor \ell of q-2 is 3 or 5\pmod8 ; otherwise all factors would be 1 or 7\pmod8 and their product could not be 3\pmod8 . But q\equiv2\pmod\ell , and the elementary supplementary rule for 2 gives

\displaystyle \left(\frac q\ell\right)=\left(\frac2\ell\right)=-1\qquad(\ell\equiv3\text{ or }5\pmod8).

It remains to consider q\equiv1\pmod8 . Suppose for contradiction that q is a square modulo every odd prime at most 2k+1 , where k=\lfloor\sqrt q\rfloor . Our aim is not to find a particular prime by inspection. Instead, we will show that so many local square roots are arithmetically impossible.

Every square root modulo an odd prime r can be lifted to a root modulo r^j for every j . Indeed, if z^2\equiv q\pmod{r^j} , then changing z to z+c r^j changes its square, modulo r^{j+1} , by 2zc r^j ; since r\nmid 2z , choose c to correct the remaining residue modulo r . For powers of 2 , the hypothesis q\equiv1\pmod8 likewise supplies roots modulo 2^j for all j\ge3 (from a root modulo 2^j , add 2^{j-1} when necessary to obtain the needed correction at the next level). The Chinese remainder theorem therefore supplies a single integer z such that

\displaystyle z^2\equiv q\pmod{(2k+1)!}.

Why introduce a factorial? Because any 2k+1 consecutive integers have a product divisible by (2k+1)! . Apply this to the integers from z-k to z+k . Grouping opposite factors gives

\displaystyle (2k+1)!\mid z\prod_{j=1}^{k}(z^2-j^2).

Replacing z^2 by q in each factor yields divisibility of z\prod_{j=1}^k(q-j^2) by the same factorial. Also z is coprime to the factorial: a common prime divisor would divide z^2 and hence q , but every prime in (2k+1)! is below q . We can cancel z and deduce

\displaystyle (2k+1)!\mid\prod_{j=1}^{k}(q-j^2).

Now comes the contradiction. We have k^2<q<(k+1)^2 , and all q-j^2 are positive for 1\le j\le k . Hence

\displaystyle 0<\prod_{j=1}^{k}(q-j^2)<\prod_{j=1}^{k}((k+1)^2-j^2)=\frac{(2k+1)!}{k+1}<(2k+1)!.

A positive integer smaller than (2k+1)! cannot be divisible by it. Thus our supposition was impossible: some odd prime \ell\le2k+1<q must satisfy \left(\frac q\ell\right)=-1 . For q=17 , for example, the allegedly divisible positive product would be (17-1)(17-4)(17-9)(17-16)=1664 , whereas 9!=362880 . The special feature of the factorial construction is now visible: the local assumption forces divisibility by a large integer, while the proximity of q to the square k^2 forces the resulting product to be smaller than that integer.

Finishing Induction

Fix q , and assume reciprocity for all pairs of odd primes smaller than q . First prove it at this q for every p<q that is a square modulo q , using the descent above. The treatment of a=-p then handles every remaining p when q\equiv3\pmod4 . Finally suppose q\equiv1\pmod4 and \left(\frac pq\right)=-1 . The auxiliary-prime argument gives \ell<q with \left(\frac q\ell\right)=-1 ; by the already-established square case, \left(\frac\ell q\right)=-1 as well. If \ell=p we are finished. Otherwise \left(\frac{p\ell}q\right)=1 , and the descent for a=p\ell gives

\displaystyle \left(\frac{p\ell}{q}\right)\left(\frac q{p\ell}\right)=1.

We now know that \left(\frac\ell q\right)=\left(\frac q\ell\right)=-1 , so their product is 1 . Divide the displayed equality into the two factors corresponding to p and \ell . The latter factor is 1 ; hence

\displaystyle \left(\frac pq\right)\left(\frac qp\right)=1\qquad(q\equiv1\pmod4).

Thus all pairs with largest prime q are settled, and the induction advances to the next prime. The apparent circularity disappears because the proof at fixed q is carefully ordered: first solve the square cases, then use those cases to recognize an auxiliary nonsquare, then make a product that is a square.

Consider p=11 and q=13 . Neither 11 nor 5 is a square modulo 13 , but \left(\frac{13}{5}\right)=\left(\frac35\right)=-1 is immediately known. We may choose \ell=5 . Their product is a square modulo 13 , and the corresponding integer equality is

\displaystyle 4^2=11\cdot5-13\cdot3.

There is no common factor here. Reduction modulo 55 gives 13(-3)\equiv4^2\pmod{55} , and reduction modulo 3 says 55\equiv1 is a square. The induction therefore yields equality of the two residue tests for 55 and 13 . Since 5 is a nonsquare modulo 13 and 13 is a nonsquare modulo 5 , its two negative signs cancel, leaving equality for 11 and 13 . Directly, \left(\frac{11}{13}\right)=-1 and \left(\frac{13}{11}\right)=\left(\frac2{11}\right)=-1 . The auxiliary prime has not solved the original problem by itself; it has produced the square congruence needed to run the already understood descent.

This is the organizing idea of the first proof of Gauss. To compare two residue tests, arrange one square equation with the two primes in it. Read the equation modulo its smaller factors. If those factors collide, divide them out. If the desired square does not exist, change the number being tested by a smaller prime whose character is already controlled. Every move is motivated by the same goal: replace a question involving the largest prime by questions involving smaller prime factors, without losing the sign.

Leave a Reply