Divisor Function Calculator
Solve divisor function problems step-by-step with our free calculator. See formulas, worked examples, and clear explanations.
Formula
sigma_k(n) = Sum of d^k for all divisors d of n
The divisor function sigma_k(n) sums the kth powers of all positive divisors of n. When k=0, it counts the number of divisors. When k=1, it gives the sum of divisors. The function is multiplicative: for coprime m and n, sigma_k(mn) = sigma_k(m) * sigma_k(n).
Worked Examples
Example 1: Divisor Function Values for n = 60
Problem: Compute sigma_0(60), sigma_1(60), and sigma_2(60).
Solution: 60 = 2^2 * 3 * 5, divisors: {1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60}\nsigma_0(60) = 12 (count of divisors)\nsigma_1(60) = 1+2+3+4+5+6+10+12+15+20+30+60 = 168\nsigma_2(60) = 1+4+9+16+25+36+100+144+225+400+900+3600 = 5460\n\nFrom factorization:\nsigma_0 = (2+1)(1+1)(1+1) = 12\nsigma_1 = (7)(4)(6) = 168
Result: sigma_0(60) = 12 | sigma_1(60) = 168 | sigma_2(60) = 5460 | 60 is abundant (aliquot sum = 108 > 60)
Example 2: Checking if 28 is a Perfect Number
Problem: Verify that 28 is a perfect number using the divisor function.
Solution: 28 = 2^2 * 7\nDivisors: {1, 2, 4, 7, 14, 28}\nProper divisors: {1, 2, 4, 7, 14}\nAliquot sum = 1 + 2 + 4 + 7 + 14 = 28\n\nsigma_1(28) = 1+2+4+7+14+28 = 56 = 2*28\n\n28 = 2^(3-1) * (2^3 - 1) = 4 * 7, and 7 is a Mersenne prime (2^3 - 1).
Result: 28 is PERFECT | sigma_1(28) = 56 = 2*28 | Proper divisors sum to exactly 28
Frequently Asked Questions
What is the divisor function and what does sigma notation mean?
The divisor function, denoted sigma_k(n) or sometimes d_k(n), is a function from number theory that sums the kth powers of all positive divisors of n. For k=0, sigma_0(n) counts the total number of divisors (often written d(n) or tau(n)). For k=1, sigma_1(n) gives the sum of all divisors. For k=2, sigma_2(n) gives the sum of squares of divisors. The general formula is sigma_k(n) = sum of d^k for all positive divisors d of n. For example, for n=12 with divisors {1,2,3,4,6,12}: sigma_0(12) = 6 (six divisors), sigma_1(12) = 28 (sum = 1+2+3+4+6+12), and sigma_2(12) = 210 (sum of squares). The divisor function is multiplicative, meaning sigma_k(mn) = sigma_k(m)*sigma_k(n) when gcd(m,n) = 1. This multiplicative property allows efficient computation from prime factorizations.
How do you compute the divisor function from a prime factorization?
The multiplicative property of the divisor function makes prime factorization the most efficient computation method. If n = p1^a1 * p2^a2 * ... * pr^ar, then sigma_k(n) = product of sigma_k(pi^ai) for each prime factor. For each prime power, sigma_0(p^a) = a+1 (counting divisors: 1, p, p^2, ..., p^a). For k > 0, sigma_k(p^a) = (p^(k*(a+1)) - 1) / (p^k - 1), which is a geometric series sum. For sigma_1, this simplifies to sigma_1(p^a) = (p^(a+1) - 1) / (p - 1). For example, 60 = 2^2 * 3 * 5, so sigma_0(60) = (2+1)(1+1)(1+1) = 12, and sigma_1(60) = (2^3-1)/(2-1) * (3^2-1)/(3-1) * (5^2-1)/(5-1) = 7 * 4 * 6 = 168. This factorization approach converts a problem requiring finding all divisors into simple arithmetic on prime powers, dramatically reducing computation time for large numbers.
What is a highly composite number and how does it relate to the divisor function?
A highly composite number is a positive integer with more divisors than any smaller positive integer. In other words, n is highly composite if sigma_0(n) > sigma_0(m) for all m < n. The sequence of highly composite numbers begins 1, 2, 4, 6, 12, 24, 36, 48, 60, 120, 180, 240, 360, 720, 1260, 2520, and was extensively studied by Ramanujan in his 1915 paper. These numbers have specific structural properties: their prime factorization uses consecutive primes starting from 2, and the exponents are non-increasing. For example, 360 = 2^3 * 3^2 * 5 has exponents 3, 2, 1 using primes 2, 3, 5 consecutively. Highly composite numbers are practical in everyday life: 12 (a dozen), 24 (hours), 60 (minutes, seconds), and 360 (degrees in a circle) are all highly composite, chosen historically because they have many divisors, making division into equal parts easy. Anti-prime is another name for these numbers.
How does the divisor function connect to the Riemann zeta function?
The divisor function has a deep connection to the Riemann zeta function through Dirichlet series. The generating Dirichlet series for sigma_k(n) is sum of sigma_k(n)/n^s = zeta(s) * zeta(s-k), where zeta(s) = sum of 1/n^s is the Riemann zeta function. For k=0, this gives sum of d(n)/n^s = zeta(s)^2, showing that the number-of-divisors function is related to the square of the zeta function. This connection means that properties of the zeta function (including the famous unsolved Riemann Hypothesis) have implications for the average behavior and distribution of divisor function values. The average order of d(n) is ln(n), meaning (1/N) * sum of d(n) for n=1 to N approaches ln(N) as N grows. The average order of sigma_1(n)/n is pi^2/6, which equals zeta(2). These averages encode deep information about the distribution of prime numbers and are central to analytic number theory.
How is the divisor function used in modular forms and elliptic curves?
The divisor function plays a starring role in the theory of modular forms, which are complex analytic functions with specific symmetry properties. The Eisenstein series G_k(tau) = sum of sigma_{k-1}(n) * q^n (where q = e^{2*pi*i*tau}) are fundamental examples of modular forms. The normalized Eisenstein series E_4 and E_6 generate the ring of modular forms and appear in the theory of elliptic curves. The Ramanujan tau function, defined through the discriminant modular form Delta = (E_4^3 - E_6^2) / 1728, has Fourier coefficients related to divisor function values. The sum of divisors function sigma_1 appears directly in the q-expansion of the Eisenstein series E_2, which is a quasi-modular form. These connections link the elementary number-theoretic divisor function to some of the deepest structures in modern mathematics, including the proof of Fermats Last Theorem by Andrew Wiles, which fundamentally used the theory of modular forms and elliptic curves.
What are multiplicative functions and why is the divisor function multiplicative?
A multiplicative function f satisfies f(mn) = f(m)*f(n) whenever gcd(m,n) = 1 (m and n are coprime), with f(1) = 1. The divisor function sigma_k is multiplicative because divisors of a product mn (when gcd(m,n)=1) correspond bijectively to pairs (d_m, d_n) where d_m divides m and d_n divides n, with d = d_m * d_n. Since d^k = d_m^k * d_n^k, the sum factors: sigma_k(mn) = sigma_k(m) * sigma_k(n). This is proven rigorously using the Chinese Remainder Theorem. The multiplicative property means computing sigma_k for any n reduces to computing it for prime powers. Other important multiplicative functions include Eulers totient function phi(n), the Mobius function mu(n), and the Liouville function lambda(n). The Dirichlet convolution of two multiplicative functions is also multiplicative, creating a rich algebraic structure. Multiplicative functions form a group under Dirichlet convolution, with the identity being the function that is 1 at n=1 and 0 elsewhere.