Factor Calculator
List every positive and negative factor of a whole number, along with its prime or composite classification.
How It's Calculated
Formula
d \mid n \iff n \bmod d = 0A factor (or divisor) of a whole number n is any integer that divides n evenly, with no remainder. Every nonzero whole number has both positive and negative factors: if d is a positive factor of n, then -d is also a factor, since n divided by -d also produces a whole number. This calculator finds every factor of a number by checking divisor candidates only up to the square root of its magnitude, pairing each divisor d it finds with its partner n/d — a much faster approach than checking every integer up to n itself. Factors are different from prime factors: the factors of 12 are every number that divides it (1, 2, 3, 4, 6, 12), while the prime factors of 12 are only the prime numbers it's built from (2 and 3, since 12 = 2 x 2 x 3). A number with exactly two positive factors (1 and itself) is prime; a number with more than two is composite; the number 1 is a special case classified as neither.
Worked Examples
Find every factor of 12
- Check divisors up to sqrt(12) ~= 3.46, so d = 1, 2, 3
- d=1: 12/1=12, pair (1, 12)
- d=2: 12/2=6, pair (2, 6)
- d=3: 12/3=4, pair (3, 4)
- Positive factors: 1, 2, 3, 4, 6, 12
- Negative factors: -1, -2, -3, -4, -6, -12
Find every factor of a prime number: 13
- Check divisors up to sqrt(13) ~= 3.6, so d = 1, 2, 3
- Only d=1 divides evenly: 13/1=13, pair (1, 13)
- Positive factors: 1, 13 — exactly two, so 13 is prime
Frequently Asked Questions
How are factors different from prime factors?
A factor is any integer that divides a number evenly — 12's factors include 1, 2, 3, 4, 6, and 12. A prime factor is a factor that is also a prime number — of those, only 2 and 3 are prime, and 12 = 2 x 2 x 3 shows how they combine. This calculator lists every factor, not just the prime ones; for prime decomposition, see the Prime Factorization Calculator.
Why does zero have no factor list?
Every nonzero integer divides 0 evenly (0 divided by any nonzero number is 0 with no remainder), so 0 has infinitely many factors. There's no finite list to display, which is why this calculator rejects a zero input rather than trying to show one.
Why does a negative input still show negative factors?
This calculator factors the magnitude (absolute value) of the input, then reports both the positive factor set and its corresponding negative factor set, since every factor relationship that holds for a positive number also holds for its negation.
What makes a number prime, composite, or neither?
A number with exactly two positive factors (1 and itself) is prime. A number with more than two positive factors is composite. The number 1 is a special case: it has only one positive factor (itself), so it's classified as neither prime nor composite by mathematical convention.