# Does $x$ irreducible in ring $R$ imply $(x)$ maximal ideal of $R$?

I was studying for my final exam of abstract algebra and, after seeing that $$p$$ prime element of a ring $$R$$ is equivalent as saying the ideal $$(p)\unlhd R$$ is prime, I came up with the assumption that something similar might happend with the irreducible elements and the maximal ideals, but this is not said anywhere in my course book so I may be wrong. So my question is, is this statement true?

Being $$R$$ a commutative unital ring, and $$0\neq x\in\mathbb{R\setminus R^\times}$$, then: $$x \text{ irreducible in R} \Longleftrightarrow (x) \text{ is maximal ideal of R}$$

Maybe this is only verified under certain extra conditions of $$R$$ (for example, being PID or UFD or some kind of special ring). Is my assumption true in general? If not, could you give me a counter example? It would be nice to have a proof if it's true. Any help will be appreciated, thanks in advance.

• Not in general, I think. Take $R = k[x,y]$ and let $x$ be, well, $x$. Commented Jan 28, 2021 at 9:32
• Also, take $x$ that is irreducible but not prime. Then $(x)$ is not prime and, a fortiori, not maximal.
– user239203
Commented Jan 28, 2021 at 9:33
• @Gae.S. So would it be true inside rings where primes and irreducibles are the same? (Fields, Euclidean Domains, Principal Ideal Domains and Unique Factorisation Domains) Commented Jan 28, 2021 at 9:35
• @AlejandroBergasaAlonso As Jeroen has shown, not in UFDs. In fields this is vacuously true. In PIDs which aren't fields it's true, because in general $x$ is irreducible if and only if $(x)$ is a maximal element of the family of proper non-zero principal ideals.
– user239203
Commented Jan 28, 2021 at 9:39

$$x \in R$$ is irreducible if and only if the ideal $$(x)$$ is maximal among proper principal ideals. The proof is straightforward.
Thus if there exist proper ideals in $$R$$ which are not principal, then there will exist irreducible elements whose principal ideals are not maximal ideals.
• $x\Bbb{Q}$ is not principal in $(\Bbb{Z}+x\Bbb{Q}[x])/x^2\Bbb{Q}[x]$, the irreducibles $p+ax$ are maximal ideals. Commented Jan 28, 2021 at 10:11
The simplest counterexample is $$R=\mathbb Z[x]$$. Then $$(x) \subset (2,x)$$ is not maximal.