Arithmetic & Numbers
Prime Factorization Calculator
Enter a whole number to see it divided by successive primes until only 1 remains. If nothing but the number itself divides it, the calculator tells you it is prime.
- Divisors: 12
- Sum of divisors: 224
Step-by-step working 3 steps
- 1Divide by the smallest prime that fits, again and again
84 ÷ 2 = 42 42 ÷ 2 = 21 21 ÷ 3 = 7 7 ÷ 7 = 1
Stop when the quotient reaches 1.
- 2Collect the primes
84 = 2 × 2 × 3 × 7 84 = 2² × 3 × 7
- 3Count the divisors
(3 × 2 × 2) = 12 divisors
Add 1 to each exponent and multiply.
How to use the prime factorization calculator
- Enter a whole number of 2 or more.
- The calculator divides by the smallest prime that fits, repeatedly.
- Primes are collected and written with exponents.
- The divisor count comes from adding 1 to each exponent and multiplying.
Divisors from the factorization
n = p₁^a × p₂^b × … Number of divisors = (a+1)(b+1)… Sum of divisors = Π (p^(e+1) − 1)/(p − 1)
Every whole number above 1 has exactly one prime factorization (the fundamental theorem of arithmetic).
Worked examples
Each example below is generated by the same calculator you used above, so the working always matches the answer.
84
- Divisors: 12
- Sum of divisors: 224
Step-by-step working 3 steps
- 1Divide by the smallest prime that fits, again and again
84 ÷ 2 = 42 42 ÷ 2 = 21 21 ÷ 3 = 7 7 ÷ 7 = 1
Stop when the quotient reaches 1.
- 2Collect the primes
84 = 2 × 2 × 3 × 7 84 = 2² × 3 × 7
- 3Count the divisors
(3 × 2 × 2) = 12 divisors
Add 1 to each exponent and multiply.
360
- Divisors: 24
- Sum of divisors: 1170
Step-by-step working 3 steps
- 1Divide by the smallest prime that fits, again and again
360 ÷ 2 = 180 180 ÷ 2 = 90 90 ÷ 2 = 45 45 ÷ 3 = 15 15 ÷ 3 = 5 5 ÷ 5 = 1
Stop when the quotient reaches 1.
- 2Collect the primes
360 = 2 × 2 × 2 × 3 × 3 × 5 360 = 2³ × 3² × 5
- 3Count the divisors
(4 × 3 × 2) = 24 divisors
Add 1 to each exponent and multiply.
97 (prime)
- Divisors: 2
- Sum of divisors: 98
Step-by-step working 3 steps
- 1Divide by the smallest prime that fits, again and again
97 ÷ 97 = 1
Stop when the quotient reaches 1.
- 2Check
Only 97 itself divides 97 without a remainder (besides 1), so 97 is prime.
- 3Count the divisors
(2) = 2 divisors
Add 1 to each exponent and multiply.
1001
- Divisors: 8
- Sum of divisors: 1344
Step-by-step working 3 steps
- 1Divide by the smallest prime that fits, again and again
1001 ÷ 7 = 143 143 ÷ 11 = 13 13 ÷ 13 = 1
Stop when the quotient reaches 1.
- 2Collect the primes
1001 = 7 × 11 × 13
- 3Count the divisors
(2 × 2 × 2) = 8 divisors
Add 1 to each exponent and multiply.
Where you will use this
- Simplifying radicals and fractions in Algebra 1
- Finding all the factors of a number for a number-theory unit
- Understanding the idea behind public-key encryption
Common mistakes to avoid
Treating 1 as prime
1 has only one divisor, and primes need exactly two. That is why factorization starts at 2.
Stopping at a composite factor
If a factor like 6 is left, keep going: 6 = 2 × 3. Only primes belong in the final list.
Forgetting that 2 is prime
2 is the only even prime, and it is often the first factor to check.
Frequently asked questions
How can I tell quickly whether a number is prime?
Test divisibility by primes up to its square root. If none divide it, it is prime. The calculator does exactly this.
Why is the limit one trillion?
Trial division up to the square root is instant at that size. Much larger numbers need specialist algorithms.
Related calculators
LCM & GCF Calculator
LCM and GCF of any numbers, by prime factorization.
Simplify Fractions Calculator
Reduce any fraction to lowest terms with the GCF shown.
Fraction Calculator
Add, subtract, multiply and divide with simplified steps.
Percentage Calculator
% of a number, what percent, original value and % change.
Percentage Change Calculator
Percent increase or decrease between two values.
Times Tables Generator
Any multiplication table, up to 30 lines.
Browse everything in Arithmetic & Numbers or the full calculator list.