# Is 0 a prime number?

Is 0 a prime or composite number?

**Why some people say it's prime:** Its divisors are 1 and itself.

**Why some people say it's composite:** It divides by 2, 3, 5 and so on

**Why some people say it’s neither:**It doesn’t divide by itself

0 is\( \color{red}{\textbf{neither}}\) prime nor composite.

Proof:The definition of a prime number is a positive integer that hasexactlytwo positive divisors. Therefore, the simplest reason why \(0\) is not prime is that \(0\) is not a positive integer.Moreover, \(0\) also doesn't have exactly two positive divisors. A positive, integer divisor \((D)\) of any number \((N)\) is a positive, whole number which divides \(N\) evenly, such that \(\frac{N}{D}\) has a remainder of \(0.\) By this definition, we can prove that \(0\) does not have exactly two factors.

Firstly, however, \(0\) is not a divisor of itself because \(\frac{0}{0}\) is undefined. \(1\) is a divisor of \(0\) since \(\frac{0}{1} = 0\), which has remainder \(0.\) Therefore, \(1\) is a divisor of \(0.\) However, \(1\) is not \(0\)'s only positive divisor. In fact, all positive integers are divisors of \(0.\) For example, by the same reasoning that \(1\) is a divisor of \(0,\) \(2\) is a divisor of \(0\) since \(\frac{0}{2} = 0\), which has remainder \(0.\) Similarly, all positive integers are divisors of \(0\) and, yes, this also implies that \(0\) is a multiple of all positive integers.

In summary, \(0\) is not positive and it has infinitely many positive divisors, so, no matter how you look at it, \(0\) is not prime. \(\square\) However, 0 is not composite. It is not a positive integer and does not satisfy the fundermental theorem of arithmetic(you can’t write it as the product of primes;0 is not prime) and it doesn’t divide by itself. In conclusion, 0 is like 1 in the fact that it is neither prime nor composite.

Rebuttal: This is crazy. We need to come up with new definitions if the ones that we have imply that \(0\) has infinitely many factors and is a multiple ofeverything.

Reply: While, in the proofs above, we only thought about this issue from the logical perspective of verifying the accepted definition of a prime number, it's also important to realize that the definitions are worded as they are to create a system which is as sensible and usable as possible. Including 0 as part of every set of multiples is actually very natural. For example, consider the visual representations of multiples of \(N\) pictured below. It's clear that including 0 in the set of multiples for each number completes the pattern, whereas omitting 0 would create a strange exception/irregularity in each set.

Acknowledging and preserving this kind of pattern creates symmetry in the mathematics and makes it more likely that the theorems and proofs which use these definitions can be simply stated, without many exceptions and special cases. For example, consider the theorem, "The sum of any two multiples of a number is also a multiple of that number." If \(0\) were not a multiple of every number, this elegant theorem would have to be revised to, "The sum of any two multiples of a number is either 0 or a multiple of that number, and the sum of 0 and any multiple of a number is also a multiple of that number."

This entire page is just a matter of definition. Mathematicians love to define things; they decide that \(0\) shouldn't be prime, because they can do so. But, of course, mathematicians also have reasons when defining things, and are not just making this decision at whim.

Rebuttal: I disagree that \(\frac{0}{0}\) is undefined. \(\frac{0}{0} = 1,\) since any number divided by itself is equal to 1.

Reply: \(\frac{0}{0}\) is undefined for good reason. Check out the wiki page What is 0 divided by 0? for a full explanation.

Want to make sure you've got this concept down? Try these problems:

What are the integral divisors of 0?

\(\)

**Clarification:** Given two integers \(N\) and \(M,\) \(N\) is an "integral divisor" of \(M\) if \(F = \frac{M}{N}\) is an integer.

**See Also**