information:classification
Quadratic reciprocity

Gauss's third proof of quadratic reciprocity, as modified by Eisenstein, has two basic steps.

Let p and q be distinct positive odd prime numbers, and let m = 1 2 (p − 1), {\displaystyle m={\tfrac {1}{2}}(p-1),} n = 1 2 (q − 1). {\displaystyle n={\tfrac {1}{2}}(q-1).}

First, Gauss's lemma is used to show that the Legendre symbols are given by

The second step is to use a geometric argument to show that

Combining these formulas gives quadratic reciprocity in the form

There are formulas that use floor to express the quadratic character of small numbers mod odd primes p: