[summary: An irreducible element of a ring is one which cannot be written as a nontrivial product of two other elements of the ring.]

[summary(Technical): Let $~$(R, +, \times)$~$ be a ring which is an integral domain. We say $~$x \in R$~$ is *irreducible* if, whenever we write $~$r = a \times b$~$, it is the case that (at least) one of $~$a$~$ or $~$b$~$ is a unit (that is, has a multiplicative inverse).]

Ring theory can be viewed as the art of taking the integers [48l $~$\mathbb{Z}$~$] and extracting or identifying its essential properties, seeing where they lead.
In that light, we might ask what the abstracted notion of "prime" should be.
Confusingly, we call this property *irreducibility* rather than "primality"; "prime" in ring theory corresponds to something closely related but not the same.

In a ring $~$R$~$ which is an Integral domain, we say that an element $~$x \in R$~$ is *irreducible* if, whenever we write $~$r = a \times b$~$, it is the case that (at least) one of $~$a$~$ or $~$b$~$ is a unit (that is, has a multiplicative inverse).

# Why do we require $~$R$~$ to be an integral domain?

[todo: this]

# Examples

[todo: lots]

# Relationship with primality in the ring-theoretic sense

It is always the case that primes are irreducible in any integral domain. %%hidden(Show proof): If $~$p$~$ is prime, then $~$p \mid ab$~$ implies $~$p \mid a$~$ or $~$p \mid b$~$ by definition. We wish to show that if $~$p=ab$~$ then one of $~$a$~$ or $~$b$~$ is invertible.

Suppose $~$p = ab$~$. Then in particular $~$p \mid ab$~$ so $~$p \mid a$~$ or $~$p \mid b$~$. Assume without loss of generality that $~$p \mid a$~$; so there is some $~$c$~$ such that $~$a = cp$~$.

Therefore $~$p = ab = cpb$~$; we are working in a commutative ring, so $~$p(1-bc) = 0$~$. Since the ring is an integral domain and $~$p$~$ is prime (so is nonzero), we must have $~$1-bc = 0$~$ and hence $~$bc = 1$~$. That is, $~$b$~$ is invertible. %%

However, the converse does not hold (though it may in certain rings).

- In $~$\mathbb{Z}$~$, it is a fact that irreducibles are prime. Indeed, it is a consequence of Bézout's theorem that if $~$p$~$ is "prime" in the usual $~$\mathbb{Z}$~$-sense (that is, irreducible in the rings sense) %%note:I'm sorry about the notation. It's just what we're stuck with. It is very confusing.%%, then $~$p$~$ is "prime" in the rings sense. (Proof.)
- In the ring $~$\mathbb{Z}[\sqrt{-3}]$~$ of complex numbers of the form $~$a+b \sqrt{-3}$~$ where $~$a, b$~$ are integers, the number $~$2$~$ is irreducible but we may express $~$4 = 2 \times 2 = (1+\sqrt{-3})(1-\sqrt{-3})$~$. That is, we have $~$2 \mid (1+\sqrt{-3})(1-\sqrt{-3})$~$ but $~$2$~$ doesn't divide either of those factors. Hence $~$2$~$ is not prime.

%%hidden(Proof that $~$2$~$ is irreducible in $\mathbb{Z}[\sqrt{-3}]): A slick way to do this goes via the [norm_complex_number norm] $~$N(2)$~$ of the complex number $~$2$~$; namely $~$4$~$.

If $~$2 = ab$~$ then $~$N(2) = N(a)N(b)$~$ because [norm_of_complex_number_is_multiplicative the norm is a multiplicative function], and so $~$N(a) N(b) = 4$~$. But $~$N(x + y \sqrt{-3}) = x^2 + 3 y^2$~$ is an integer for any element of the ring, and so we have just two distinct options: $~$N(a) = 1, N(b) = 4$~$ or $~$N(a) = 2 = N(b)$~$. (The other cases follow by interchanging $~$a$~$ and $~$b$~$.)

The first case: $~$N(x+y \sqrt{3}) = 1$~$ is only possible if $~$x= \pm 1, y = \pm 0$~$. Hence the first case arises only from $~$a=\pm1, b=\pm2$~$; this has not led to any new factorisation of $~$2$~$.

The second case: $~$N(x+y \sqrt{3}) = 2$~$ is never possible at all, since if $~$y \not = 0$~$ then the norm is too big, while if $~$y = 0$~$ then we are reduced to finding $~$x \in \mathbb{Z}$~$ such that $~$x^2 = 2$~$.

Hence if we write $~$2$~$ as a product, then one of the factors must be invertible (indeed, must be $~$\pm 1$~$). %%

In fact, in a Principal ideal domain, "prime" and "irreducible" are equivalent. (Proof.)

# Relationship with unique factorisation domains

It is a fact that an integral domain $~$R$~$ is a UFD if and only if it has "all irreducibles are prime (in the sense of ring theory)" and "every $~$r \in R$~$ may be written as a product of irreducibles". ([alternative_condition_for_ufd Proof.]) This is a slightly easier condition to check than our original definition of a UFD, which instead of "all irreducibles are prime" had "products are unique up to reordering and multiplying by invertible elements".

Therefore the relationship between irreducibles and primes is at the heart of the nature of a unique factorisation domain. Since $~$\mathbb{Z}$~$ is a UFD, in some sense the Fundamental Theorem of Arithmetic holds precisely because of the fact that "prime" is the same as "irreducible" in $~$\mathbb{Z}$~$.