Ekuation

purpose

Divisor Calculator

Find all divisors of an integer, count them (d(n)), and compute their sum (\u03C3(n)).

Back to Prime Factorization Calculator
Your figures

Enter a positive integer greater than 1

Display the step-by-step trial division process

Find the Prime Factorization

Enter an integer greater than 1 to see its prime factorization, factor tree, and divisors.

The plate is drawn once you enter your figures.

Try an Example

Pick a scenario to see how the calculator works, then adjust the values

  1. Highly Composite Number

    Factor 360, a highly composite number with many divisors.

    Key values: 360 = 2^3 x 3^2 x 5 · 24 divisors · phi(360) = 96

  2. Large Prime

    Check if 7919 is prime (it is -- the 1000th prime number).

    Key values: 7919 is prime · 2 divisors · phi(7919) = 7918

  3. GCD and LCM

    Compute the GCD and LCM of 84 and 120.

    Key values: 84 = 2^2 x 3 x 7 · 120 = 2^3 x 3 x 5 · GCD = 12, LCM = 840

Documentation

Counting Divisors

Given the prime factorization n=p1a1×p2a2×⋯n = p_1^{a_1} \times p_2^{a_2} \times \cdots, the number of divisors is:

d(n)=∏i(ai+1)d(n) = \prod_{i} (a_i + 1)

Each divisor is formed by choosing an exponent from 0 to aia_i for each prime factor. The product of all these choices gives the total count.

Example: 60=22×3×560 = 2^2 \times 3 \times 5, so d(60)=(2+1)(1+1)(1+1)=12d(60) = (2+1)(1+1)(1+1) = 12 divisors.


Sum of Divisors

σ(n)=∏ipiai+1−1pi−1\sigma(n) = \prod_{i} \frac{p_i^{a_i+1} - 1}{p_i - 1}

This uses the geometric series formula for each prime power component.

Example: σ(60)=23−12−1×32−13−1×52−15−1=7×4×6=168\sigma(60) = \frac{2^3-1}{2-1} \times \frac{3^2-1}{3-1} \times \frac{5^2-1}{5-1} = 7 \times 4 \times 6 = 168.


Perfect Numbers

A perfect number satisfies σ(n)=2n\sigma(n) = 2n — the sum of its proper divisors equals the number itself.

  • 6=1+2+36 = 1 + 2 + 3
  • 28=1+2+4+7+1428 = 1 + 2 + 4 + 7 + 14
  • 496=1+2+4+8+16+31+62+124+248496 = 1 + 2 + 4 + 8 + 16 + 31 + 62 + 124 + 248

Euclid-Euler theorem: Every even perfect number has the form 2p−1(2p−1)2^{p-1}(2^p - 1) where 2p−12^p - 1 is a Mersenne prime. Whether odd perfect numbers exist is one of the oldest unsolved problems in mathematics.


Frequently Asked Questions

How do I count the number of divisors of a number?

Find the prime factorization n=p1a1×p2a2×…n = p_1^{a_1} \times p_2^{a_2} \times \ldots, then compute d(n)=(a1+1)(a2+1)…d(n) = (a_1 + 1)(a_2 + 1)\ldots. For example, 60=22×3×560 = 2^2 \times 3 \times 5 has d(60)=(2+1)(1+1)(1+1)=12d(60) = (2+1)(1+1)(1+1) = 12 divisors.

How do I find the sum of all divisors?

Use the formula σ(n)=∏(piai+1−1)/(pi−1)\sigma(n) = \prod (p_i^{a_i+1} - 1)/(p_i - 1) for each prime power in the factorization. For 60=22×3×560 = 2^2 \times 3 \times 5, σ(60)=(23−1)/(2−1)×(32−1)/(3−1)×(52−1)/(5−1)=7×4×6=168\sigma(60) = (2^3 - 1)/(2 - 1) \times (3^2 - 1)/(3 - 1) \times (5^2 - 1)/(5 - 1) = 7 \times 4 \times 6 = 168.

What is a perfect number?

A perfect number is a positive integer that equals the sum of its proper divisors, which means σ(n)=2n\sigma(n) = 2n. The first three perfect numbers are 6 (= 1+2+3), 28 (= 1+2+4+7+14), and 496. By the Euclid-Euler theorem, every even perfect number has the form 2p−1(2p−1)2^{p-1}(2^p - 1) where 2p−12^p - 1 is a Mersenne prime.

What numbers have the most divisors relative to their size?

Highly composite numbers have more divisors than any smaller positive integer. They tend to be products of the smallest primes with descending exponents, like 12=22×312 = 2^2 \times 3 (6 divisors), 60=22×3×560 = 2^2 \times 3 \times 5 (12 divisors), and 120=23×3×5120 = 2^3 \times 3 \times 5 (16 divisors).

Why is the divisor function multiplicative?

The divisor function d(n)d(n) is multiplicative, meaning d(a×b)=d(a)×d(b)d(a \times b) = d(a) \times d(b) whenever gcd⁡(a,b)=1\gcd(a, b) = 1. This follows from the fact that each divisor of a×ba \times b uniquely corresponds to a pair of divisors, one from aa and one from bb, when aa and bb share no common prime factor.

Plate

Related purpose calculators

Other purpose variations of this calculator

Further plates

More Math calculators

Explore the category

Calculator Search

Search and find calculators