113
$\begingroup$

Why is $1$ not considered a prime number?

Or, why is the definition of prime numbers given for integers greater than $1$?

$\endgroup$
  • 19
    $\begingroup$ Given how often "let p be an odd prime" shows up in theorems, sometimes I wonder if we'd be better off defining 2 as non-prime too ;) $\endgroup$ – user7530 Oct 4 '11 at 20:12
  • 3
    $\begingroup$ Note the uniqueness of factorisation argument is not wholly compelling on its own because $-2\times -3=6$ - only when Ideals are in question does the issue become more acute. $\endgroup$ – Mark Bennet Jun 19 '14 at 18:15
  • 1
    $\begingroup$ @user7530 But still $2$ has a lot more in common with the odd primes than $1$ does: an irrational square root, a non-integer reciprocal, two distinct divisors in $\mathbb{Z}^+$, etc. $\endgroup$ – user153918 Dec 16 '14 at 17:59
  • 1
    $\begingroup$ $1$ is the power of other primes. $1=2^0=3^0=5^0$… no other prime is the power of another prime. Perhaps this isn't super-important, though… $\endgroup$ – Akiva Weinberger Apr 15 '15 at 16:08
  • 3
    $\begingroup$ The non-primality of 1 is the most elementary example of a general principle in mathematics: a trivial object is too simple to be simple $\endgroup$ – Eric Stucky May 7 '15 at 6:31

14 Answers 14

109
$\begingroup$

One of the whole "points" of defining primes is to be able to uniquely and finitely prime factorize every natural number.

If 1 was prime, then this would be more or less impossible.

$\endgroup$
  • 6
    $\begingroup$ In the same way, it's often convenient for a variety of reasons not to consider hte unit ideal as prime (e.g. for unique factorization in Dedekind domains). $\endgroup$ – Akhil Mathew Jul 20 '10 at 21:15
  • 2
    $\begingroup$ That's a good way of looking at it, but I wouldn't call it a proof. We simply define 1 as a prime, there is no proof of that fact; it's a definition. $\endgroup$ – Edan Maor Jul 20 '10 at 22:48
  • 5
    $\begingroup$ @Stacked let's say I wanted to prime factorize 6. It is 2*3, but it's also 2*3*1. It is also 2*3*1*1, and 2*3*1*1*1; that is, 6 no longer has a unique prime factorization $\endgroup$ – Justin L. Aug 10 '10 at 23:06
  • 15
    $\begingroup$ @Stacked: “Isn’t it now impossible to factorize 1?” Good question… it’s not impossible; it takes lateral thinking. 1 is the product of the empty list of factors (just as 0 is the sum of an empty list). See the answers to math.stackexchange.com/questions/6832/… for discussion of this! $\endgroup$ – Peter LeFanu Lumsdaine Nov 21 '10 at 8:57
  • 4
    $\begingroup$ @user36712 A factor is not the same as a prime factor. $\endgroup$ – user50229 Apr 8 '13 at 10:02
64
$\begingroup$

It's important to understand that this is not something that can be proved: it's a definition. We choose not to regard 1 as a prime number, simply because it makes writing lots of theorems much easier.

Noah gives the best example in his answer: Euclid's theorem that every positive integer can be written uniquely as a product of primes. If 1 is defined to be a prime number, then we'd have to change that theorem to: "every positive integer can be written uniquely as a product of primes, except for infinite multiplications by 1". So we choose to go with the easier path of defining 1 to not be a prime.

$\endgroup$
41
$\begingroup$

The main point of talking about prime numbers is Euclid's theorem that every positive integer can be written uniquely as a product of primes. As Justin remarks, this would break horribly if $1$ were considered prime, for example we could factor $2$ as $2\times1\times1\times1\times1\times1$. Instead we say that $1$ is not a prime, but it is the product of zero primes (see Why is $x^0 = 1$ except when $x = 0$? to understand why any prime multiplied by itself $0$ times is $1$) so Euclid's theorem works out nicely!

$\endgroup$
  • 2
    $\begingroup$ Euclid's theorem could easily be modified to work with 1 as a prime. The reason why 1 isn't a prime is either because it makes a whole lot of different results nicer, or an accident of history, not because of one specific theorem $\endgroup$ – Casebash Jul 20 '10 at 23:25
  • 1
    $\begingroup$ I take it by "Euclid's theorem" you don't mean "Euclid's theorem" in the sense that we have more prime numbers than any assignable magnitude, but rather mean "the fundamental theorem of arithmetic" which did first get proven by Euclid, but isn't quite the same as what say wkipedia calls Euclid's theorem en.wikipedia.org/wiki/Euclid%27s_theorem $\endgroup$ – Doug Spoonwood Aug 22 '11 at 21:16
  • 5
    $\begingroup$ Hence the sentence "Euclid's theorem that every positive integer can be written uniquely as a product of primes" and then referring back to it later. $\endgroup$ – Noah Snyder Aug 23 '11 at 0:33
  • $\begingroup$ I have a problem with statement product of zero primes, since 0 is not natural number. Is such factorization even unique? :) $\endgroup$ – mykhal Apr 24 '17 at 22:01
39
$\begingroup$

actually 1 was considered a prime number until the beginning of 20th century. Unique factorization was a driving force beneath its changing of status, since it's formulation is quickier if 1 is not considered a prime; but I think that group theory was the other force. Indeed I prefer to describe numbers as primes, composites and unities, that is numbers whose inverse exists (so if we take the set of integer numbers Z, we have that 1 and -1 are unities and we still have unique factorization up to unities).

We can always amend the defition of a prime number and say it is a number with exactly two divisors: in this way 1 is not a prime by definition :-)

$\endgroup$
  • $\begingroup$ oeis.org/A008578 $\endgroup$ – Charles Oct 4 '11 at 14:44
  • 8
    $\begingroup$ In the classical Greek system, 1 was not even called a "number", and "prime" was a subclassification of "odd", so both 1 and 2 were excluded then. $\endgroup$ – GEdgar Oct 4 '11 at 15:05
  • 1
    $\begingroup$ If you're talking about the integers, you're missing one. Every integer is prime, composite, a unit, or zero. $\endgroup$ – Tanner Swett Mar 7 '12 at 0:33
  • $\begingroup$ Euler definitely did not consider 1 a prime number. $\endgroup$ – bof Nov 15 '14 at 7:50
  • 1
    $\begingroup$ @TannerSwett I would call $0$ a composite number. In fact, it's the MOST composite in that $k\mid 0$ for all $k$. But it depends on your definition of composite number, I guess. $\endgroup$ – user137731 Dec 13 '14 at 22:48
28
$\begingroup$

It's worth emphasizing that, in addition to unique factorization, there are also somewhat deeper structural reasons underlying the convention that $\:1\:$ is neither prime nor a prime ideal, but $\:0\:$ is. Below I discuss the motivations for these differing conventions.

One important motivation for including the zero ideal as prime is that this facilitates powerful reductions. For example, in many ring theoretic problems involving an ideal $\rm\; I\;$, one can reduce to the case $\rm\;I = P\;$ prime, and then reduce to $\rm\;R/P\;$, therefore reducing to the case when the ring is a domain. In this case one simply says that one can factor out $\rm\; P\;$, so wlog assume $\rm\; P = 0\;$ is prime, hence the ring is a domain. For example, at the end of this post is an excerpt from Kaplansky's classic textbook "Commutative Rings", section 1-3: G-Ideals, Hilbert Rings, and the Nullstellensatz, where I've explicitly highlighted a few prototypical examples of such reductions - cf. reduce to...

Thus we have solid evidence for the utility of the convention that the zero ideal is prime. So why don't we adopt the same convention for the unit ideal $1$ or, equivalently, why don't we permit the zero ring as a domain? There are a number of reasons. First, in domains and fields it often proves very convenient to assume that one has a nonzero element available. This permits proofs by contradiction to conclude by deducing $1 = 0\:$. More importantly, it implies that the unit group is nonempty, so unit groups always exist. It'd be very inconvenient to have to always add the proviso (except if $\;\rm R = 0)$ to the ubiquitous arguments involving units and unit groups. More generally it's worth emphasizing that the usual rules for equational logic are not complete for empty structures. That is why groups and other algebraic structures are always axiomatized to prevent nonempty structures (see this thread for further details).

Below is the mentioned Kaplansky excerpt on reduction to domains by factoring out prime ideals.

Let $\rm\; I\;$ be any ideal in a ring $\rm\; R\;$. We write $\rm\: R^{*}\:$ for the quotient ring $\rm\; R/I\;$. In the polynomial ring $\rm\; R[x]\;$ there is a smallest extension $\rm\; IR[x]\;$ of $\rm\; I\;$. The quotient ring $\rm\; R[x]/IR[x]\;$ is in a natural way isomorphic to $\rm\; R^*[x].\;$ In treating many problems, we can in this way reduce to the case $\rm\; I = 0\;$, and we shall often do so.

THEOREM 28. $\;$ Let $\rm\; M\;$ be a maximal ideal in $\rm\; R[x]\;$ and suppose that the contraction $\rm\; M \cap R\ =\ N\;$ is maximal in $\rm\; R\;.\ $ Then $\rm\; M\;$ can be generated by $\rm\; N\;$ and one more element $\rm\; f\:.\ $ We can select $\rm\; f\;$ to be a monic polynomial which maps mod $\rm\; N\;$ into an irreducible polynomial over the field $\rm\; R/N\;$.

Proof. $\;$ We can reduce to the case $\rm\; N = 0,\;$ i. e., $\rm\; R\;$ a field, and then the statement is immediate.

THEOREM 31. $\;$ A commutative ring $\rm\; R\;\;$ is a Hilbert ring if and only if the polynomial ring $\rm\; R[x] \;\;$ is a Hilbert ring.

Proof. $\;$ If $\rm\; \;\rm R[x]\;$ is a Hilbert ring, so is its homomorphic image $\rm\; R\;$. Conversely, assume that $\rm\; R\;$ is a Hilbert ring. Take a G-ideal $\rm\: Q\:$ in $\rm\; R[x]\;$; we must prove that $\rm\: Q\:$ is maximal. Let $\rm\: P = Q \cap R\:$; we can reduce the problem to the case $\rm\ P = 0\:,\ $ which, incidentally, makes $\rm\ R\ $ a domain. Let $\rm\; u\;$ be the image of $\rm\; x\;$ in the natural homomorphism $\rm\ R[x] \ \to\ R[x]/Q\ .\ \ $ Then $\rm\; R[u]\;$ is a G-domain. $\ $ By Theorem 23, $\rm\ u\ $ is algebraic over $\rm\ R\ $ and $\rm\ R\ $ is a G-domain. Since $\rm\:R\:$ is both a G-domain and a Hilbert ring, $\rm\ R\ $ is a field. $\ $ But this makes $\rm\ R[u] = R[x]/Q\ $ a field, $\ $ proving $\rm\ Q\ $ to be maximal.

$\endgroup$
  • $\begingroup$ This answer almost leads one to ask: Why is 0 not a prime number? (thread from 2010 Aug 31). $\endgroup$ – Jeppe Stig Nielsen Apr 15 '15 at 20:59
  • $\begingroup$ In a (unitary) ring the unit group always exists (is non-empty) since it contains $1$. What fails when $R=0$ is that $0$ is a non-unit. $\endgroup$ – Marc van Leeuwen May 6 '16 at 4:18
  • $\begingroup$ @Marc Not necessarily (it depends on definitions). There was prior discussion of this and related matters here but I cannot find it. See also here. $\endgroup$ – Bill Dubuque May 6 '16 at 13:53
  • $\begingroup$ Great answer! $\;$ $\endgroup$ – Arrow Oct 17 '18 at 21:37
14
$\begingroup$

As this question has been just bumped up, might as well mention this great article by Chris Caldwell (who maintains The Prime Pages) and Yeng Xiong:

The abstract:

What is the first prime? It seems that the number two should be the obvious answer, and today it is, but it was not always so. There were times when and mathematicians for whom the numbers one and three were acceptable answers. To find the first prime, we must also know what the first positive integer is. Surprisingly, with the definitions used at various times throughout history, one was often not the first positive integer (some started with two, and a few with three). In this article, we survey the history of the primality of one, from the ancient Greeks to modern times. We will discuss some of the reasons definitions changed, and provide several examples. We will also discuss the last significant mathematicians to list the number one as prime.

It shows that "There does not appear to be any period of time during which most mathematicians deemed one to be a prime" (to a large extent because "For much of history it did not even make sense to ask if the number one was a prime", as 1 was not considered a number). But just as a teaser, here are a couple more quotes (I've removed the references to make this readable):

Others who listed one as prime in this period are […] Wallis (1685), J. Prestet (1689), C. Goldbach (1742), J. H. Lambert (1770), A. Felkel (1776) and E. Waring (1782). [...]
Even after Gauss' pivotal text, many continued to write that unity was prime. Among these are: A. M. Legendre (1830), E. Hinkley (1853), M. Glaisher (1876), K. Weierstrass (1876), R. Frick & F. Klein (1897), A. Cayley (1890), L. Kronecker (1901), G. Chrystal (1904) and D. N. Lehmer (1914). [...]
G. H. Hardy listed one as a prime in several editions of his text A Course of Pure Mathematics.

Read the article; it's really interesting! They also have a "The history of the primality of one—a selection of sources".

$\endgroup$
10
$\begingroup$

Prime numbers are the multiplicative building blocks of the natural numbers in the sense that every natural number is either a prime or a product of primes (the empty product gives 1). Multiplicatively 1 does not contribute anything and so it is not a building block.

$\endgroup$
6
$\begingroup$

Choose some random composite integer $n$ that is a multiple of some prime $p$, other than $-1, 0,$ or $1$. Let's pull together the set of multiples of $n$ and call it $\mathfrak{n}$ (I'm a demon, so I like to make things confusing by using the same letter for different things). Clearly this set is infinite, but it does not contain all integers: $$\mathfrak{n} = \{\ldots, -2n, -n, 0, n, 2n, \ldots\}$$

For starters, it does not contain $p$, since $n$ is a multiple of $p$, not the other way around. Now let's pull together the set of multiples of $p$ and call it $\mathfrak{p}$. It's obvious that $p \in \mathfrak{p}$ and $n \in \mathfrak{p}$. In fact, we can say more than that: $\mathfrak{n} \subset \mathfrak{p}$.

But $\mathfrak{p}$ still does not contain all integers. If $n$ and $p$ are both positive, then $n > p$, but you could say that $\mathfrak{p}$ is larger than $\mathfrak{n}$.

Now let's see what happens if $p = 1$. It's still true that $\mathfrak{n} \subset \mathfrak{p}$. But now $\mathfrak{p}$ consists of all integers. This is a very different thing than what happens if $p$ is a number like $-7$ or $43$.

Let's also shoot down the notion that $0$ could be prime while we're at it. Pull together the set of all multiples of $0$. It turns out there is only one number in that set: $0$ itself!

$-1, 0, 1$ are very different from the prime numbers and from the composite numbers. Clearly these numbers are neither prime nor composite.

The reason that $1$ is not considered a prime number is because it is not a prime number.

I have invoked the concept of principal ideals, which is a concept some humans would like you to think is far too advanced for most other humans to comprehend.

$\endgroup$
6
$\begingroup$

No, 1 is not a prime number, and you can knock it off the list of primes without any hand-wringing over the fundamental theorem of arithmetic. Nor do you need to invoke algebraic number theory, though that is certainly way more appealing than whining about how horrendously complicated the FTA would be if 1 is considered prime.

In my opinion, the most convincing way to show that 1 is not prime is by examining what properties 2 and the higher odd primes have in common and then seeing if 1 also has these properties. So, for starters:

  • $\sqrt[k]{p} \not\in \mathbb{Q}$ for all integers $k > 1$, yet $\sqrt[k]{1} = 1$ for any integer $k$ whatsoever.
  • For some squarefree $d > 1$, the equation $x^2 - dy^2 = p$ has no solutions, but $x^2 - dy^2 = 1$ has solutions for all squarefree $d > 1$. (This gets a little bit into ANT, but you can still prove it by elementary methods).
  • $\sigma(p) = p + 1$ and $\phi(p) = p - 1$, yet $\sigma(1) = \phi(1) = 1$.
$\endgroup$
  • $\begingroup$ Your first paragraph is a trifle aggressive. $\endgroup$ – PJTraill Jan 2 '17 at 16:16
  • $\begingroup$ @PJTraill Well, I find that hand-wringing very irksome, and also quite arrogant, come to think of it. The numbers exist whether we do or not. The fundamental theorem of arithmetic is man's understanding of the properties of numbers. A mild inconvenience in stating our ephemeral understanding of eternal numbers should never be seen as determining their properties. $\endgroup$ – Robert Soupe Jan 3 '17 at 3:45
6
$\begingroup$

1 isn't a prime number for the same reason 0 isn't a basis vector.

Positive integers can be written as "almost a linear algebra" of the vector space $\mathbb{Z}_{>0}$ over the scalar field $\mathbb{Z_{\ge0}}$ (okay, this is not really a field -- it's a semiring, do what you want with it, but the idea is the same) with:

  • Primes as the "unit basis vectors"
  • Multiplication as "vector addition"
  • Exponentiation as "scalar multiplication" (e.g. $p^k$ represents the scalar $k$ multiplied by the vector $p$)
  • 1 as the vector 0
  • 1 as the scalar 1
  • 0 is the scalar 0

One may check this obeys all the axioms of linear algebra, except the existence of negatives (of vectors).

The reason you don't call the zero vector a basis vector is that it doesn't really add anything to the formalism if you consider "$0 + e_1 + e_2$" to be the same representation as "$e_1+e_2$", and if you consider it to be a different representation, you're violating the idea of each vector having a unique representation in a basis. Instead, 0 is just what you have when you haven't added anything, similarly 1 is just the empty product.

Note that this formalism has a lot of other interesting analogies -- for an example, co-primeness is "orthogonality". You could also extend the formalism to rationals $\mathbb{Q}$ over the scalar field $\mathbb{Z}$ -- then it would satisfy the existence of negativeness -- although co-primeness would be more complicated (e.g. 18 would be co-prime to 3/4).

$\endgroup$
4
$\begingroup$

Prime numbers are the building blocks of numbers; every integer has one unique representation as the product of prime numbers.

Ex: $54 = 2 \times 3 \times 3 \times 3$.

Here $2$ and $3$ are the prime number building blocks. $2 \times 3 \times 3 \times 3$ is the only way to represent $54$ as the product of prime numbers. If one was a prime number, then there would be an infinite number of representations of $54$.

Ex: $(2 \times3 \times 3 \times 3 \times 1)$ or $(2 \times 3 \times 3 \times 3 \times 1 \times 1 \times 1)$.

This is one of the reasons mathematicians don't consider one to be a prime number.

$\endgroup$
3
$\begingroup$

$1$ is not a prime number, but it's important to understand that the ancient Greeks saw numbers mainly as geometric constructs, whereas we see them as algebraic constructs. We must also remember that the Greeks thought of the primes as "first numbers," and that survives in our terminology.

For example, let's say you have $n > 0$ square tiles all the same size. You can always arrange these tiles into a quadrilateral, but if you require each side of the quadrilateral to be at least $2$, then $n$ must be composite. If $n = 1$ or if $n$ is a prime, then it can be the side of a quadrilateral but it can't be the total area of a quadrilateral required to have sides greater than $2$.

But now we are more concerned with solving an equation like the one in Fermat's last theorem than we are with arranging tiles into quadrilaterals. In algebraic number theory, an important kind of number emerges: units. We see that $1$ doesn't fit in quite so well with the prime numbers, and it certainly isn't composite, but it's right at home with the units. It still has many unique properties that distinguish it even among the units, but definitely the units are where $1$ belongs.

$\endgroup$
3
$\begingroup$

No, $1$ is not a prime number, though human mathematicians were slow to recognize this fact. The most important reason that $1$ is not prime (or composite, for that matter) is that it is its own inverse; just the fact that it has an inverse in $\mathbb{Z}$ speaks volumes.

$\endgroup$
  • 3
    $\begingroup$ I don't see why an integer having an integer inverse should indicate that it is not prime. $\endgroup$ – Michael Albanese Nov 4 '15 at 22:11
  • $\begingroup$ @Michael I believe I said that 1 "is its own inverse." In that way it's different from the primes and the composites. $\endgroup$ – The Short One Nov 4 '15 at 22:29
  • 1
    $\begingroup$ I don't understand the connection either -- how does this difference matter? $\endgroup$ – Abhimanyu Pallavi Sudhir May 14 '18 at 4:57
2
$\begingroup$

(Not dissimilar to other answers; I'd rather put it as a comment if I could.)

The line of reasoning can be as follows:

  1. A composite (e.g. 6, 10) can be written as a product of primes. We don't dispute this, it's just a matter of definition to set it straight.

  2. One could say if a prime appears in a number, and if it does, how many times it appears. It's easier then to say simply how many times it appears, with the possibility of 0.

  3. Now what if all the primes appears zero times in a number? That number must be 1. (If you are writing code to compute it, you know to set initial value to be 1.) So 1 is a composite in a weird way.

Euler's product says the same thing with a formula:

$$\sum_{n=1}^\infty \frac{1}{n} = \prod_p \frac{1}{1-p^{-1}} $$

(and there goes another proof of infinitude to primes).

It seems that 1 is demoted from being a prime at the same time that 0 is promoted to be a natural number. Perhaps with the prevalence of programming languages such as Python we may finally teach the latter fact to school kids.

$\endgroup$

protected by Nate Eldredge Jul 28 '12 at 13:10

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.