Divisor Calculator

Enter a positive whole number to list all of its divisors, the divisor count, the sum of divisors, and whether it's prime, perfect, abundant, or deficient.

Quick Facts

Divisor test
d divides N when N mod d = 0
Divisors always come in pairs: d and N ÷ d.
Divisor count formula
τ(N) = (a1+1)(a2+1)···(ak+1)
From the prime factorization N = p1^a1 × p2^a2 × ... × pk^ak.
Perfect number rule
Proper divisors of N sum to N
Example: 6 = 1 + 2 + 3, so 6 is perfect.

Your Results

Calculated
Divisors (filtered)
-
Matches your divisor filter, low to high
Total Divisor Count
-
τ(N): count of all positive divisors
Sum of Divisors
-
σ(N): sum of all positive divisors
Classification
-
Prime, perfect, abundant, or deficient

Ready

Enter a positive whole number and press Calculate.

How the Divisor Calculator Works

A positive integer d is a divisor (or factor) of a whole number N if N can be divided by d with no remainder — that is, N mod d = 0, or equivalently N = d × k for some whole number k. Every positive integer has at least two divisors, 1 and itself; numbers with exactly those two are the prime numbers. This calculator takes a whole number N, finds every one of its positive divisors, counts them (τ(N)), sums them (σ(N)), and classifies N as prime, perfect, abundant, or deficient based on how that sum compares to N.

Formula and method

Divisors always come in matched pairs: if d divides N, then so does N ÷ d, and d × (N ÷ d) = N. That means you only need to test integers d from 1 up to √N — for every d that divides N evenly, both d and N ÷ d are divisors (they are the same value only when d = √N exactly, so that case is counted once). This trial-division method is what the calculator uses, and it is dramatically faster than checking every integer up to N.

If you know N's prime factorization, N = p1^a1 × p2^a2 × ... × pk^ak, two closed-form results follow directly. The divisor count function is τ(N) = (a1+1)(a2+1)···(ak+1), and the sum-of-divisors function is σ(N) = Π [(pᵢ^(aᵢ+1) − 1) ÷ (pᵢ − 1)]. For example, 60 = 2² × 3¹ × 5¹, so τ(60) = 3 × 2 × 2 = 12 and σ(60) = (2³−1)/(2−1) × (3²−1)/(3−1) × (5²−1)/(5−1) = 7 × 4 × 6 = 168.

Common sources of error

  • Forgetting 1 and N: both 1 and N itself always count as divisors of N, even though they are easy to overlook when listing "the factors."
  • Divisors vs. prime factors: the divisors of 12 are 1, 2, 3, 4, 6, and 12, but its prime factors are only 2 and 3 — prime factors are the subset of divisors that are themselves prime.
  • Perfect squares: when N is a perfect square (like 36), √N divides N and pairs with itself, so it should only be counted once, giving an odd total divisor count.

Checking your result

A few quick sanity checks catch most mistakes: the divisor count τ(N) should be odd only when N is a perfect square, and even otherwise (divisors pair up). The sum σ(N) should always be at least N + 1 for N > 1, since 1 and N are both included. And every value in the divisor list should divide N with zero remainder — spot-check one or two by hand if the list looks off.

Applications

Divisor calculations show up whenever a quantity needs to be split into equal whole groups — scheduling shifts, arranging items into even rows and columns, or simplifying a fraction to lowest terms (which relies on the greatest common divisor of the numerator and denominator). The count of divisors is also a quick way to test primality: exactly two divisors means N is prime. Perfect, abundant, and deficient numbers are a classic topic in number theory, and prime factorization itself underlies cryptographic methods like RSA, which rely on large numbers being hard to factor.

Frequently Asked Questions

What is a divisor of a number?
A divisor of N is any positive integer that divides N exactly, with no remainder. For example, the divisors of 12 are 1, 2, 3, 4, 6, and 12, because each one divides 12 evenly.
How many divisors does a number have?
Write N as a product of prime powers, N = p1^a1 × p2^a2 × ... × pk^ak. The divisor count is τ(N) = (a1+1)(a2+1)...(ak+1). For example, 60 = 2² × 3 × 5, so τ(60) = (2+1)(1+1)(1+1) = 12, matching the 12 divisors 1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60.
What makes a number a perfect, abundant, or deficient number?
Compare the sum of a number's proper divisors (all divisors except itself) to the number itself. If they are equal, N is perfect (e.g., 6 = 1+2+3). If the proper divisors sum to more than N, it is abundant (e.g., 12, whose proper divisors 1+2+3+4+6 = 16). If they sum to less than N, it is deficient (true of most numbers, including every prime).
What is the difference between divisors and prime factors?
Divisors are every positive integer that divides N evenly. Prime factors are only the prime numbers among those divisors, the building blocks that multiply together (with repetition) to form N. For 12, the divisors are 1, 2, 3, 4, 6, and 12, but the prime factors are just 2 and 3, since 12 = 2² × 3.