# Are zero and one relatively prime?

The definition of relative primality that I was taught was that:

Two numbers are relatively prime if the only common positive factor
of the two numbers is one.


Every integer (except zero) divides zero and the only positive factor of one is one. Thus, the only common positive factor of zero and one is one.

Thus, it would seem that zero and one are relatively prime by the definition above. By convention is this not the case? i.e. zero is defined as not being relatively prime with any integer?

• Yes, $0$ and $1$ are relatively prime. Your argument shows that they are. – André Nicolas Feb 19 '15 at 23:06
• $1$ is relatively prime to every integer. Even to itself. – ajotatxe Feb 19 '15 at 23:07
• I'm curious as to what brought this up. – Akiva Weinberger Feb 20 '15 at 1:13
• I wanted to know if a pairwise relatively prime set could contain zeroes. – terminex9 Feb 20 '15 at 3:58

$\gcd(0,n)=n$ for all $n\in\mathbb{N}$. For $n=1$ it turns out to be $1$, so if you insist, $0$ and $1$ are relatively prime. Zero is not defined to be not relatively prime with any integer. It just so happens that it is divisible by any integer.
Every integer divides zero. The only integers that divide $1$ are $1$ and $-1$. The greatest common divisor of $0$ and $1$ is thus $1$. That makes them relatively prime.