Divisor Function σ(n)
Statement
The divisor function (or sum-of-divisors function) is defined for positive integers by
More generally, ; the case is the most classical.
Key property: is multiplicative — for coprime :
A number is perfect if (equivalently, the sum of proper divisors equals ).
Visualization
Values of for to . Perfect numbers () are starred:
| Divisors of | Note | ||
|---|---|---|---|
| 1 | 1 | 1 | |
| 2 | 1, 2 | 3 | |
| 3 | 1, 3 | 4 | |
| 4 | 1, 2, 4 | 7 | |
| 5 | 1, 5 | 6 | |
| 6 | 1, 2, 3, 6 | 12 | perfect |
| 7 | 1, 7 | 8 | |
| 8 | 1, 2, 4, 8 | 15 | |
| 9 | 1, 3, 9 | 13 | |
| 10 | 1, 2, 5, 10 | 18 | |
| 11 | 1, 11 | 12 | |
| 12 | 1, 2, 3, 4, 6, 12 | 28 | |
| 13 | 1, 13 | 14 | |
| 14 | 1, 2, 7, 14 | 24 | |
| 15 | 1, 3, 5, 15 | 24 | |
| 16 | 1, 2, 4, 8, 16 | 31 | |
| 17 | 1, 17 | 18 | |
| 18 | 1, 2, 3, 6, 9, 18 | 39 | |
| 19 | 1, 19 | 20 | |
| 20 | 1, 2, 4, 5, 10, 20 | 42 | |
| 28 | 1, 2, 4, 7, 14, 28 | 56 | perfect |
Multiplicativity check: , , .
Proof Sketch
- Multiplicativity. For coprime , every divisor of factors uniquely as with , . Hence .
- Prime powers. .
- General formula. By multiplicativity, for : .
- Perfect numbers. Even perfect numbers have the form where is a Mersenne prime (Euler's theorem).
Connections
is the canonical example of a multiplicative functionMultiplicative FunctionsArithmetic functions that split over coprime inputs: f(mn) = f(m)f(n) when gcd(m,n) = 1Read more →. The Möbius InversionMöbius InversionIf g equals the Dirichlet convolution of f with the constant 1, then f recovers via the Möbius functionRead more → formula expresses as a Dirichlet convolution , connecting it to the theory of Euler's Totient FunctionEuler's Totient Functionφ(n) counts integers up to n coprime to n, and governs modular exponentiationRead more →.
Lean4 Proof
import Mathlib.NumberTheory.ArithmeticFunction.Misc
open ArithmeticFunction in
/-- σ is multiplicative: isMultiplicative_sigma from Mathlib. -/
theorem sigma_multiplicative {k : ℕ} :
IsMultiplicative (σ k) :=
isMultiplicative_sigma
open ArithmeticFunction in
/-- σ₁(6) = 12: sum of divisors of 6 is 1+2+3+6 = 12.
We verify via the explicit divisor set and sigma_one_apply. -/
theorem sigma_6 : σ 1 6 = 12 := by
rw [sigma_one_apply]
decide
open ArithmeticFunction in
/-- 6 is perfect: σ₁(6) = 2·6. -/
theorem six_is_perfect : σ 1 6 = 2 * 6 := by
rw [sigma_one_apply]
decide