Euler's criterion states, for an odd prime ,Apply it to . The integer is when and when . Since those signs are distinct modulo an odd prime, the modular congruence determines the actual Legendre symbol:This is the first supplementary law for quadratic reciprocity.
Choose any pair from part (i), and put . The divisibilities of the exponents makepositive integers. Their powers areThus , with all three powers nonzero and distinct. For example, take , for every nonnegative integer . Then strictly increases, giving infinitely many distinct solutions. The construction uses modular congruences to turn the elementary identity into three prescribed perfect powers.
The Chinese remainder theorem says that for pairwise coprime positive moduli and arbitrary integers , the simultaneous modular congruenceshave a solution, unique modulo .
Choose distinct prime numbers . Their prime powers are pairwise coprime. Apply the Chinese remainder theorem toFor the resulting integer , each is divisible by , the required power of an integer greater than one. Adding a sufficiently large multiple of makes positive without changing any modular congruence. Thus such a positive exists, indeed infinitely many do. This is the general construction of consecutive integers divisible by prescribed prime powers.
The Sylow theorems give and . Among the divisors , only satisfies the modular congruence. HenceUniqueness and the conjugacy assertion of the Sylow theorems make a normal subgroup.
Complete the square to obtain the equivalent quadratic congruenceHere : the Euclidean algorithm has successive nonzero remainders . If this modular congruence had a solution, the Jacobi symbol would be , since a square coprime to an odd modulus has Legendre symbol at every prime factor. Calculate instead, using Jacobi reciprocity and reduction of numerators,Therefore there is no solution. This obstruction does not require a separate primality test for ; the Jacobi symbol suffices.
Pépin's test 2026-10-14
For , Pépin's test says that the Fermat number is a prime number exactly when the displayed modular congruence holds. Modular exponentiation evaluates it by exponentiation by squaring without constructing the enormous ordinary power. The index restriction excludes , where the base itself is divisible by the candidate.[ref]
For a proof outline of sufficiency, any prime factor of a passing candidate gives multiplicative order exactly , a power of two: its half-power is , rather than . Fermat's little theorem forces , so , and hence . Conversely, for a prime candidate, ; quadratic reciprocity and Euler's criterion give the required half-power. At , the check is .
Prime divisor of a Fermat number Created 2026-10-07 Updated 2026-10-14
For a prime number , the exact criterion iswhere must be different from two and is the multiplicative order of two modulo . If , then : the order divides but not , so it is exactly . Conversely, that order makes a square root of unity different from one in the prime field ; it must be , because has no other roots in a field.
Exact modular powers distinguish Fermat divisors from the prime thirteen, whose multiplicative order is twelve
. Details. For example, modulo seventeen the powers of two are . Their first return to one occurs after eight steps. The half-way value is , proving that . Likewise, identifies as a prime factor of . These are statements about divisibility, not evidence that the entire Fermat number is prime.
The multiplicative order always divides , by Fermat's little theorem, so . In particular, for every prime divisor of a Fermat number is one modulo four. That weaker modular congruence is insufficient: thirteen is one modulo four, but , which is not a power of two. It divides no Fermat number at any index. The exact order criterion explains the whole family, instead of testing finitely many terms.
Prime-power contraction under pth powers Created 2026-10-07 Updated 2026-10-25
For a prime and , write . The binomial theorem shows is divisible by : the linear term contains the extra factor and every higher term contains at least . Iteration gives the displayed modular congruence for every , including . Applied to Fermat's little theorem, it yields .
Quadratic congruence 2026-10-25
A quadratic congruence is a modular congruence defined by a degree-two polynomial, with solutions sought among residue classes. For odd and invertible modulo , completing the square gives . A Jacobi symbol of for a coprime proposed square rules out solutions, whereas a Jacobi symbol of alone does not establish solubility for a composite modulus.
Quadratic residue Created 2026-09-24 Updated 2026-10-18
For an odd prime , a nonzero congruence class is a quadratic residue when for some integer . Here "quadratic residue" excludes zero: zero is a square of a number, but is neither a quadratic residue nor a quadratic nonresidue under this convention. Some treatments include zero among quadratic residues; the distinction matters when counting them or discussing their subgroup.[ref]
Quadratic Residue Patterns Modulo a Prime by Keith Conrad. Keith Conrad, Quadratic Residue Patterns Modulo a Prime, §1, p. 1: nonzero convention and equal counts
Modulo seven, squaring the six nonzero congruence classes givesThus the set of quadratic residues is , and the quadratic nonresidues are . In particular, has exactly the two solutions : and . Modulo eleven the quadratic residues are instead . Two is therefore a quadratic residue modulo seven and a quadratic nonresidue modulo eleven: being a quadratic residue depends on the modulus.
Why do the square roots come in pairs? If , the prime number divides , so it divides one factor: or . For nonzero these are distinct, because is an odd prime. Every nonempty nonzero fiber of a function of therefore contains exactly two inputs. Pairing the nonzero congruence classes gives exactly quadratic residues and quadratic nonresidues. Including zero gives different squares, with one rather than two square roots for zero.
The quadratic residues form a subgroup of the multiplicative group of a finite field , with index of a subgroup two. Indeed, one is a square, , and ; the inverses exist because the inputs are nonzero in the prime field. Equivalently, the squaring group homomorphism has kernel of a group homomorphism and image of a function . The apparent loss of a sign in squaring becomes a precise division of the nonzero arithmetic into two equal parts.
This structure turns a search for square roots into a yes-or-no test: Euler's criterion detects quadratic residues through modular exponentiation, and the Legendre symbol records the result as a sign. For a general integer modulus, the modular congruence still makes sense, but the two-root count and the prime field argument need not survive. For example, has four solutions ; the Chinese remainder theorem separates the sign choices modulo three and five.
Weight-sixteen Eisenstein congruence 2026-10-14
The weight-sixteen cusp form space is spanned by . Its leading coefficient and the Fourier expansion of a normalized Eisenstein series give . The coefficient multiplier is congruent to modulo , and is invertible there. Coefficient comparison gives the displayed modular congruence. Integrality of follows from the modular discriminant product.

