Generated by GPT-5-mini| Wilson's theorem | |
|---|---|
| Name | Wilson's theorem |
| Field | Number theory |
| Statement | For a prime number p, (p−1)! ≡ −1 (mod p) |
| Contributors | John Wilson; Joseph-Louis Lagrange |
| Year | 1770s–1820s |
Wilson's theorem is a result in Number theory characterizing prime integers via a factorial congruence. It asserts that for a positive integer p>1, (p−1)! is congruent to −1 modulo p exactly when p is prime, linking combinatorial factorials with modular arithmetic. The theorem connects to work by figures such as John Wilson (mathematician), Edward Waring, Joseph-Louis Lagrange, and later developments by Carl Friedrich Gauss, Srinivasa Ramanujan, and Évariste Galois in related fields.
The theorem states: for an integer p>1, (p−1)! ≡ −1 (mod p) if and only if p is prime. This gives a necessary and sufficient criterion involving factorials for primes, situated in the context of Modular arithmetic studied by Pierre de Fermat, Leonhard Euler, and Adrien-Marie Legendre. The criterion is algebraic and exact, contrasting with analytic criteria developed in the work of Bernhard Riemann and Dirichlet.
Elementary proofs use pairings of residues: for a prime p, every nonzero residue modulo p has a unique multiplicative inverse, leading to cancellation in (p−1)! except for self-inverse residues 1 and p−1; this argument appears in expositions by Joseph-Louis Lagrange and Carl Friedrich Gauss. Group-theoretic proofs place the statement within the structure of the multiplicative group (Z/pZ)^×, invoking results about element orders as in texts by Évariste Galois and Camille Jordan. Analytic or combinatorial proofs connect to binomial coefficients and use congruences derived from work by Pierre-Simon Laplace and Adrien-Marie Legendre. Historical attributions and proofs are discussed in writings of Edward Waring and formalized by Lagrange in his treatment of permutation groups and residues. More modern expositions relate the theorem to Wilson primes studied by D. H. Lehmer and computational verifications by researchers in computational number theory at institutions such as Bell Labs and Princeton University.
The statement was recorded by Edward Waring in the 1770s, attributing it to his student John Wilson (mathematician), though no surviving proof from Wilson exists; the first published proof was given by Joseph-Louis Lagrange in 1771. Subsequent treatment by Carl Friedrich Gauss placed the theorem in the emergent theory of congruences in his Disquisitiones Arithmeticae, influencing later work by Adrien-Marie Legendre and Sophie Germain. The theorem links to the legacy of Pierre de Fermat through shared interest in primality tests, and to developments by Leonhard Euler who advanced multiplicative residue theory. In the 19th and 20th centuries, mathematicians such as Évariste Galois and Arthur Cayley integrated ideas around finite groups, while computational investigations into Wilson primes engaged D. H. Lehmer and modern computational projects at Cambridge University and Harvard University.
Generalizations include extensions to factorial-like products in quadratic and cyclotomic fields, studied in the frameworks of Algebraic number theory by Richard Dedekind and Ernst Eduard Kummer. The concept inspires criteria for prime powers and composite testing similar to results by Leonhard Euler and Sophie Germain, and ties to Wilson primes — primes p such that (p−1)! ≡ −1 (mod p^2) — investigated by D. H. Lehmer and more recent computational researchers at University of Illinois Urbana-Champaign and Max Planck Institute. Group-theoretic consequences connect to properties of the symmetric group examined by Augustin-Louis Cauchy and Camille Jordan, while relationships with factorial congruences appear in studies by Srinivasa Ramanujan and G. H. Hardy. In algebraic extensions, one finds analogues in Dedekind domains and in the study of ideal class groups as in the work of Emil Artin and Helmut Hasse.
As a primality criterion, the theorem is mostly of theoretical interest; practical primality testing relies on algorithms developed by Agrawal–Kayal–Saxena researchers and computational number theorists at Massachusetts Institute of Technology and Bell Labs. Example computations show that for p=5, 4! = 24 ≡ −1 (mod 5), illustrating the criterion; for composite n=6, 5! = 120 ≡ 0 (mod 6), demonstrating failure. Wilson primes such as 5, 13, and 563 are rare examples highlighted in computational surveys by D. H. Lehmer and projects at University of Cambridge. The theorem appears in pedagogical contexts across curricula at institutions like University of Oxford, Princeton University, and Harvard University and features in recreational mathematics collections associated with Martin Gardner.
Category:theorems in number theory