Prime Factorisation Calculator

Break a number into its prime powers and read off how many divisors it has.

Prime factors with repetition
Adjust the inputs

Your result updates live as you type.

Every whole number above one is a product of primes in exactly one way, ignoring the order. That is the fundamental theorem of arithmetic, and it is why the factorisation is worth having rather than just a list of factors: it is the number's fingerprint. Written in index form, 360 becomes 2³ × 3² × 5.

The index form does more work than it first appears. Add one to each exponent and multiply, and you have the exact count of divisors — 360 has (3+1)(2+1)(1+1) = 24 of them, without listing any. The same exponents give the sum of the divisors through a product of geometric series. Trial division up to the square root is enough to find the factorisation, because any factor above the square root must pair with one below it.

The formula

n = p1a × p2b × …  ·  d(n) = (a + 1)(b + 1)…
n
The number being factorised
p<sub>i</sub>
Each distinct prime that divides it
a, b, …
How many times each prime appears
d(n)
The count of divisors, from the exponents plus one multiplied together

How it works, step by step

  1. Enter a whole number greater than one.
  2. The gauge shows how many prime factors it has counted with repetition.
  3. The index form appears below, together with the divisor count.
  4. A square-free number has every exponent equal to one.

Worked examples

360 in index form

360 = 2³ × 3² × 5, which is 6 prime factors counted with repetition. The divisor count is (3+1)(2+1)(1+1) = 24, and those divisors sum to 1170.

Why 2,310 is different

2,310 = 2 × 3 × 5 × 7 × 11, five distinct primes each appearing once. That makes it square-free, and the divisor count is 2⁵ = 32 despite the number being much larger than 360, which has 24.

How to read your score

0–2Prime or nearly soOne or two prime factors — the number is close to irreducible.
2–5ModestA typical factorisation for an everyday number.
5–9RichPlenty of small primes, so the number has many divisors.
9–—Highly compositeDominated by repeated small primes, as powers of two are.

Frequently asked questions

Why stop trial division at the square root?

Because factors come in pairs whose product is the number. If neither member of a pair were below the square root, their product would exceed the number, so testing that far is enough.

How does the exponent trick count divisors?

Any divisor picks an exponent for each prime, from zero up to the one in the factorisation. That gives a + 1 choices per prime, and the choices multiply. For 2³ × 3² × 5 that is 4 × 3 × 2 = 24.

What does square-free mean?

That no prime appears more than once, so no perfect square above one divides the number. 2,310 is square-free; 360 is not, because 4 and 9 both divide it.

Is one a prime number?

No. Treating one as prime would break the uniqueness of factorisation, since you could insert any number of ones. It is called a unit instead.

Factorisations and divisor counts

Index form and what it implies
NumberIndex formDistinct primesDivisorsSum of divisors
642<sup>6</sup>17127
97971298
1002<sup>2</sup> × 5<sup>2</sup>29217
3602<sup>3</sup> × 3<sup>2</sup> × 53241,170
5122<sup>9</sup>1101,023
1,0242<sup>10</sup>1112,047
2,3102 × 3 × 5 × 7 × 115326,912

97 is prime, so its index form is itself and it has exactly two divisors.

Related calculators