Factor Calculator
Find all factors of any positive whole number. Enter a number to get every divisor in order, every factor pair, the full prime factorization in both expanded and exponential form, the sum of all divisors, and whether the number is prime, a perfect square, or a perfect cube.
Formula
Worked example
For 60: sqrt(60) = 7.75, so test 1 through 7. Divisors found: 1, 2, 3, 4, 5, 6. Their pairs: 60, 30, 20, 15, 12, 10. All 12 factors in order: 1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60. Sum = 168. Prime factorization = 2^2 x 3 x 5. Classification: composite.
What a factor is and why factor pairs matter
A factor (also called a divisor) of a positive integer n is any whole number that divides n exactly, leaving no remainder. Every number has at least two factors: 1 and itself. Factors always occur in pairs, where both members of each pair multiply to produce the original number. For example, since 4 divides 60 evenly (60 / 4 = 15), the pair (4, 15) is a factor pair of 60. Factor pairs make it easy to visualize how a number can be arranged into equal rectangles: 60 tiles can be laid out as a 4 x 15 grid, a 5 x 12 grid, and so on. The only exception to strict pairing is a perfect square, where the square root sits in the middle and pairs with itself, counted once.
How trial division finds every factor
Rather than testing every integer from 1 all the way to n, this calculator uses trial division up to the square root of n. The key insight is that if d is a factor of n and d is at or below the square root, then n / d is a factor at or above the square root. So every divisor below the square root automatically reveals its partner above it for free. For n = 1,000,000 that means testing only 1,000 candidates instead of a million, making the computation fast. Each candidate i is accepted when n mod i = 0 (the remainder is zero), then stored as the pair (i, n / i).
Prime factorization and the sigma function
Every integer greater than 1 can be written as a unique product of prime numbers, a result known as the Fundamental Theorem of Arithmetic. This calculator shows that product in two forms: expanded (2 x 2 x 3 x 5 for 60) and exponential (2^2 x 3 x 5), which is the standard compact notation. The sum of all divisors, denoted sigma(n) in number theory, has practical uses: if sigma(n) = 2n, the number is a perfect number (6 and 28 are the two smallest). The calculator also flags perfect squares (where the square root is an integer) and perfect cubes (where the cube root is an integer).
Common factors and the GCF
When you enter a second number, the calculator lists every factor that both numbers share. The largest of these shared factors is the Greatest Common Factor (GCF), also called the Greatest Common Divisor (GCD). The GCF is essential for simplifying fractions: to reduce 36/60, find GCF(36, 60) = 12 and divide both the numerator and denominator by 12 to get 3/5. It also determines whether two numbers are coprime, if the only shared factor is 1, the numbers share no common divisors and their GCF is 1.
Divisibility rules quick reference
| Divisor | Rule | Example |
|---|---|---|
| 2 | Last digit is even (0, 2, 4, 6, 8) | 128: last digit 8 - yes |
| 3 | Sum of digits is divisible by 3 | 123: 1+2+3=6 - yes |
| 4 | Last two digits form a number divisible by 4 | 312: 12/4=3 - yes |
| 5 | Last digit is 0 or 5 | 85: last digit 5 - yes |
| 6 | Divisible by both 2 and 3 | 18: even and digit-sum 9 - yes |
| 7 | Double the last digit, subtract from rest; repeat | 203: 20-6=14 - yes |
| 8 | Last three digits divisible by 8 | 1,024: 024/8=3 - yes |
| 9 | Sum of digits divisible by 9 | 729: 7+2+9=18 - yes |
| 10 | Last digit is 0 | 340: last digit 0 - yes |
Use these shortcuts to spot factors instantly without dividing.
Frequently asked questions
What is the difference between a factor and a multiple?
A factor divides into a number evenly, while a multiple is the result of multiplying a number by an integer. 6 is a factor of 12, while 12, 18, and 24 are multiples of 6. Factors are always less than or equal to the number; multiples are greater than or equal to it.
Why does the calculator only test divisors up to the square root?
Factors come in pairs that multiply to the original number. In every pair, one factor is at or below the square root and the other is at or above it. Finding the smaller one automatically reveals the larger, so checking past the square root would only repeat work already done. This halves the computation for large numbers.
What is prime factorization and why does it matter?
Prime factorization breaks a number into a product of prime numbers (numbers divisible only by 1 and themselves). By the Fundamental Theorem of Arithmetic, every integer greater than 1 has exactly one such representation. It is used to find the GCF and LCM of two numbers, simplify fractions, and solve many algebra and number theory problems.
What is the sum of factors (sigma function)?
The sigma function sigma(n) adds up all positive divisors of n, including 1 and n itself. For 12, sigma(12) = 1+2+3+4+6+12 = 28. When sigma(n) = 2n, the number is called a perfect number: 6 (sigma = 12) and 28 (sigma = 56) are the two smallest examples known.
How do I use the common factors feature?
Enter your first number in the top field and your second number in the optional second field. The calculator finds every factor shared by both numbers and identifies the largest one as the GCF (Greatest Common Factor). This is useful for simplifying fractions: divide numerator and denominator by their GCF.
Are negative numbers and zero supported?
This tool works with positive whole numbers from 1 to 1,000,000. Zero is divisible by every integer and has infinitely many factors. Negative factors are simply the positive factors with a minus sign, so by convention this calculator lists positive divisors only.