Divisor Count Calculator
Count the positive divisors of an integer from its prime exponents, and see how many are proper divisors.
What it does
Every positive integer has a fixed number of positive divisors. The count is written d(n) or tau(n). For 12 it is six, because 1, 2, 3, 4, 6 and 12 all divide evenly. Knowing the count matters when simplifying expressions, comparing factor structures, or deciding whether a number has an even or odd number of factors.
Counting by listing divisors works for small numbers but becomes tedious as values grow. The exponent shortcut is much quicker. If n factors as p^a times q^b times r^c, then each divisor chooses an exponent from 0 up to a for p, from 0 up to b for q, and so on. That gives a + 1 choices for the first prime, b + 1 for the second, and the total is the product of those counts.
This rule explains why primes have two divisors and why squares behave differently. For a square every exponent is even, so each a + 1 is odd and the product is odd. For any other number at least one exponent is odd, making an even factor appear in the product and the whole count even.
The page factors n, multiplies the incremented exponents, and reports both the full count and the count of proper divisors. The proper count is simply one less, since only n itself is removed from the list.
Results are exact integers for every input up to one trillion. The tool does not list the divisors themselves, so for the actual divisor values you would use a factorization or divisor sum page.
How to use
- Enter a whole number n of at least 1.
- Read the number of divisors as the main result.
- Check the proper divisor count beside it.
- Look at the factorization to see the exponents used.
- Try 36 to see an odd count from a square number.
- Try a prime such as 17 to confirm the count is 2.
Formula
- n
- The positive integer whose divisors are counted.
- p^e
- A prime power in the factorization of n, with exponent e.
- d(n)
- The total number of positive divisors, also written tau(n).
For 12 the factorization is 2^2 x 3, so the exponents are 2 and 1 and d(12) = (2 + 1)(1 + 1) = 6. For 36 the factorization is 2^2 x 3^2 and d(36) = 3 x 3 = 9. Because 36 is a square, the count is odd. The input 1 has no prime factors and gives a count of 1.
Worked example
Example: d(12)
Use n = 12, which is already set in the input.
- Factor 12 into 2^2 x 3^1.
- Add one to the exponent of 2: 2 + 1 = 3.
- Add one to the exponent of 3: 1 + 1 = 2.
- Multiply the choices: 3 x 2 = 6.
- The tool reports 6 divisors, 5 proper divisors, and factorization 2^2 x 3.
- Check by listing 1, 2, 3, 4, 6 and 12, which is six values.
Reference table
| n | Prime factorization | d(n) | Proper divisors |
|---|---|---|---|
| 6 | 2 x 3 | 4 | 3 |
| 12 | 2^2 x 3 | 6 | 5 |
| 17 | 17 | 2 | 1 |
| 28 | 2^2 x 7 | 6 | 5 |
| 36 | 2^2 x 3^2 | 9 | 8 |
Limits
- The count includes 1 and n, and proper divisors exclude only n.
- Negative divisors are outside the count.
- Inputs above one trillion are rejected to keep factoring responsive.
- The tool does not display the divisor list, only how many there are.
Common mistakes
- Multiplying the exponents instead of adding one to each before multiplying.
- Counting repeated primes more than once when reading the factorization.
- Assuming an even number always has an even number of divisors.
- Forgetting that 1 has a single divisor, itself.
- Reporting the proper count as the full count.
Try it yourself
Quick checks. Answers sit tucked under each question.
How many divisors does 36 have?
36 = 2^2 x 3^2, so d(36) = (2 + 1)(2 + 1) = 9, with 8 proper divisors.
How many divisors does the prime 17 have?
A prime has exponent 1, so d(17) = 2 and there is 1 proper divisor.
How many divisors does 28 have?
28 = 2^2 x 7, so d(28) = 3 x 2 = 6.
Questions
What is another name for the divisor count?
It is often called tau(n) or the divisor function of order zero.
Why do squares have an odd count?
Every exponent is even, so each exponent plus one is odd, and a product of odd numbers is odd.
What is the smallest number with three divisors?
Four, since 4 = 2^2 gives (2 + 1) = 3 divisors: 1, 2 and 4.
Does the order of primes matter?
No. Multiplication of the incremented exponents gives the same total in any order.
How does this differ from the divisor sum?
The count tells how many divisors exist, while the sum adds their values.
What is the maximum input?
Any whole number up to 1,000,000,000,000. Larger values return a readable error.