Calculators
Prime Factorization Calculator
Find the prime factors of a whole number.
Prime factorization
2^3 × 3^2 × 5
Expanded factors: 2 × 2 × 2 × 3 × 3 × 5
About This Tool
Prime factorization writes an integer as a product of prime numbers. Because every integer greater than 1 has one unique prime factorization apart from factor order, the result is a useful building block for simplifying fractions, finding common factors and multiples, and studying divisibility. Enter one whole number to see both compact exponent notation and the repeated factors.
How To Use It
- Enter a whole number of 2 or greater.
- Read the compact prime factorization, where repeated prime factors use exponents.
- Use the expanded factor list to see every repeated prime separately, or copy the compact result.
Examples
Prime factorization of 360
360 = 2^3 × 3^2 × 5, or 2 × 2 × 2 × 3 × 3 × 5 in expanded form.
Prime factorization of 97
97 is already prime, so its prime factorization is simply 97.
Prime factorization of 1024
1024 is a power of two: 2^10.
Useful Notes
What makes a factor prime?
A prime number is an integer greater than 1 whose only positive divisors are 1 and itself. Prime factorization keeps dividing by prime divisors until no composite factor remains.
How this calculator factorizes numbers
The calculation removes factors of 2 first, then tests odd divisors. Once a possible divisor is larger than the remaining value divided by that divisor, the remaining value—if greater than 1—must itself be prime.
Exponent and expanded notation
Repeated factors can be shortened with exponents. For example, 72 = 2 × 2 × 2 × 3 × 3 = 2^3 × 3^2. Both forms represent exactly the same product.
Input limits
The tool accepts integers from 2 through JavaScript's maximum safe integer. Trial division is exact for supported inputs, but very large prime or nearly-prime values can take longer than ordinary classroom-sized numbers.
FAQ
Is 1 a prime number?
No. A prime number has exactly two positive divisors, 1 and itself. The number 1 has only one positive divisor, so prime factorization starts at 2.
Does every number have a unique prime factorization?
Every integer greater than 1 can be expressed as a product of primes uniquely apart from the order of those factors. This is the fundamental theorem of arithmetic.
How does prime factorization help with GCD and LCM?
For GCD, take shared prime factors using the smaller exponents. For LCM, take every prime appearing in either number using the larger exponents. Hanakash's GCD & LCM Calculator can calculate those values directly.
Can this calculator factor negative numbers?
This page focuses on the standard prime factorization of positive integers greater than 1. A negative integer can be written as -1 times the prime factorization of its absolute value, but -1 is not prime.
Related Tools
GCD & LCM Calculator
Calculate GCD and LCM for two whole numbers.
Basic Calculator
PopularA simple arithmetic calculator for quick results.
Number Base Converter
Convert integers between binary, octal, decimal, and hexadecimal.
Roman Numeral Converter
Convert between decimal numbers and standard Roman numerals.