TOPICS
Search

Divisor


A divisor, also called a factor, of a number n is a number d which divides n (written d|n). For integers, only positive divisors are usually considered, though obviously the negative of any positive divisor is itself a divisor. In the formulas below, n is a positive integer and all divisors are positive. A list of these divisors may be returned by the Wolfram Language function Divisors[n].

Sums and products are commonly taken over only some subset of values that are the divisors of a given number. Such a sum would then be denoted, for example,

 sum_(d|n)f(d).
(1)

Such sums are implemented in the Wolfram Language as DivisorSum[n, form, cond].

The following tables lists the divisors of the first few positive integers (OEIS A027750).

ndivisors
11
21, 2
31, 3
41, 2, 4
51, 5
61, 2, 3, 6
71, 7
81, 2, 4, 8
91, 3, 9
101, 2, 5, 10
111, 11
121, 2, 3, 4, 6, 12
131, 13
141, 2, 7, 14
151, 3, 5, 15

The total number of divisors for a given number n (variously written d(n), sigma_0(n), or nu(n)) can be found as follows. Write a number in terms of its prime factorization

 n=p_1^(alpha_1)p_2^(alpha_2)...p_r^(alpha_r).
(2)

For any divisor d of n, n=dd^' where

 d=p_1^(delta_1)p_2^(delta_2)...p_r^(delta_r),
(3)

so

 d^'=p_1^(alpha_1-delta_1)p_2^(alpha_2-delta_2)...p_r^(alpha_r-delta_r).
(4)

Now, delta_1=0,1,...,alpha_1, so there are alpha_1+1 possible values. Similarly, for delta_n, there are alpha_n+1 possible values, so the total number of divisors d(n) of n is given by

 d(n)=product_(i=1)^r(alpha_i+1).
(5)

The product of divisors can be found by writing the number n in terms of all possible products

 n={d^((1))d^('(1)); |; d^((nu))d^('(nu)),
(6)

so

n^(nu(n))=[d^((1))...d^((nu))][d^('(1))...d^('(nu))]
(7)
=product_(i=1)^(nu)d_iproduct_(i=1)^(nu)d_i^'
(8)
=(productd)^2,
(9)

and

 productd=n^(nu(n)/2).
(10)

The geometric mean of divisors is

G=(productd)^(1/nu(n))
(11)
=[n^(nu(n)/2)]^(1/nu(n))
(12)
=sqrt(n).
(13)

The arithmetic mean is

 A(n)=(sigma(n))/(nu(n)).
(14)

The harmonic mean is

 1/H=1/(nu(n))(sum1/d).
(15)

But n=dd^', so 1/d=d^'/n and

sum1/d=1/nsumd^'
(16)
=1/nsumd
(17)
=(sigma(n))/n,
(18)

and we have

 1/(H(n))=1/(nu(n))(sigma(n))/n=(A(n))/n
(19)
 n=A(n)H(n).
(20)

For three integers chosen independently and uniformly from 1, 2, ..., X, the probability that their greatest common divisor is 1 tends, as X->infty, to

 [zeta(3)]^(-1) approx 1.20206^(-1) approx 0.831907,
(21)

where zeta(3) is Apéry's constant.

The smallest numbers having exactly 0, 1, 2, ... divisors (other than 1) are 1, 2, 4, 6, 16, 12, 64, 24, 36, ... (OEIS A005179; Minin 1883-84; Grost 1968; Roberts 1992, p. 86; Dickson 2005, pp. 51-52). Fontené (1902) and Chalde (1903) showed that if p_1^(alpha_1)p_2^(alpha_2)...p_(r-1)^(alpha_(r-1))p_r^(alpha_r) is the prime factorization of the least number with a given number of divisors, with the primes in increasing order and the exponents in decreasing order, then (1) alpha_r+1 is prime, and (2), for r>=2, alpha_(r-1)+1 is prime except for the number 2^3·3, which has 8 divisors (Dickson 2005, p. 52).

Let f(n) be the number of elements in the greatest subset of [1,n] such that none of its elements are divisible by two others. For n sufficiently large,

 0.6725...<=(f(n))/n<=0.673...
(22)

(Le Lionnais 1983, Lebensold 1976/1977).

Coprimality can also be imposed when matching the divisors of an integer to an arithmetic progression. Let n be a positive integer, let D(n) be its positive divisors, let N=tau(n) be their number, and let P={a+bt:t=0,1,...,N-1} for integers a and b>0. Alekseyev (2026) proved that there is a bijection f:D(n)->P with gcd(d,f(d))=1 for every d in D(n) iff, for every prime p dividing n,

 |{x in P:p|x}|<=N/(nu_p(n)+1),
(23)

where nu_p(n) is the exponent of p in the prime factorization of n. Alekseyev (2026) reports AI assistance with developing and checking the proof.


See also

Divisor Function, Infinitary Divisor, Unitary Divisor Explore this topic in the MathWorld classroom

Related Wolfram sites

https://functions.wolfram.com/NumberTheoryFunctions/Divisors/

Explore with Wolfram|Alpha

References

Alekseyev, M. A. "Coprime Matchings of Divisor Sets." 27 Oct 2026. https://arxiv.org/abs/2610.37512.Chalde. Nouv. Ann. Math. 3, 471-473, 1903.Dickson, L. E. History of the Theory of Numbers, Vol. 1: Divisibility and Primality. New York: Dover, 2005.Fontené, G. Nouv. Ann. Math. 2, 288, 1902.Grost, M. E. "The Smallest Number with a Given Number of Divisors." Amer. Math. Monthly 75, 725-729, 1968.Guy, R. K. "Solutions of d(n)=d(n+1)." §B18 in Unsolved Problems in Number Theory, 2nd ed. New York: Springer-Verlag, pp. 73-75, 1994.Le Lionnais, F. Les nombres remarquables. Paris, France: Hermann, p. 43, 1983.Lebensold, K. "A Divisibility Problem." Studies Appl. Math. 56, 291-294, 1976/1977.Minin, A. P. Math. Soc. Moscow 11, 632, 1883-84.Nagell, T. "Divisors." §1 in Introduction to Number Theory. New York: Wiley, pp. 11-12, 1951.Roberts, J. The Lure of the Integers. Washington, DC: Math. Assoc. Amer., 1992.Sloane, N. J. A. Sequences A005179/M1026 and A027750 in "The On-Line Encyclopedia of Integer Sequences."

Referenced on Wolfram|Alpha

Divisor

Cite this as:

Weisstein, Eric W. "Divisor." From MathWorld--A Wolfram Resource. https://mathworld.wolfram.com/Divisor.html

Subject classifications