Prime Factorization Tree Calculator
Break any whole number into its prime factors in exponent form, with the count of prime factors and distinct primes.
How it works
Every integer > 1 = p₁^e₁ × p₂^e₂ × … (unique set of primes, by the Fundamental Theorem of Arithmetic)
Prime factorization expresses a number as a product of primes — the building blocks that cannot themselves be divided further. By the Fundamental Theorem of Arithmetic, every integer above 1 has exactly one such factorization (ignoring order), which is why it underpins finding greatest common divisors, simplifying fractions and modern cryptography. Trial division peels off the smallest prime repeatedly until only 1 remains.
Worked example
360 divides by 2 three times (giving 45), then by 3 twice (giving 5), and 5 is prime. So 360 = 2³ × 3² × 5 — six prime factors in total, across three distinct primes.
Frequently asked questions
What does the exponent notation mean?
2^3 means 2 multiplied by itself three times (2 × 2 × 2 = 8). Writing 360 as 2³ × 3² × 5 is just a compact way of saying 2 × 2 × 2 × 3 × 3 × 5.
What if the number is already prime?
Then its factorization is just the number itself — a prime has no smaller prime factors. The tool flags this case for you.
Why is there an upper limit?
Factorization uses trial division up to the square root of the number. Capping the input at one trillion keeps that under about a million steps so results are instant.
Related calculators
This calculator is for educational purposes. Double-check important results before acting on them.