Unique Factorization Domains
Why does every integer factor uniquely into primes? Yet in the ring , the number factors as both and . There is no way to reconcile these. This single question — does unique factorization survive when we leave — sits at the heart of algebraic number theory. It drove much of nineteenth-century ring theory. The failure of unique factorization in rings of integers was exactly the obstruction that stalled early attempts to prove Fermat's Last Theorem. Understanding it forced mathematicians to isolate the precise structural property that makes factorization work. The key realization is this. "Prime" and "irreducible" — indivisible in the naive sense — are two logically distinct notions in a general integral domain. Unique factorization holds exactly when they coincide appropriately. A Unique Factorization Domain (UFD) is defined by axiomatizing the behavior we take for granted in . Every nonzero nonunit factors into irreducibles, and that factorization is unique up to order and units. This article develops the definition carefully. It separates irreducibility from primality. It proves the fundamental structural theorem that every Principal Ideal Domain is a UFD. This explains why , , and for a field all enjoy unique factorization automatically. The big picture is a hierarchy of increasingly special integral domains: Fields Euclidean Domains PIDs UFDs Integral Domains. Each containment is strict. Understanding where a ring sits in this hierarchy tells you what algebraic tools are available. Unique factorization licenses arguments by "comparing prime factorizations." These are second nature in but require justification everywhere else. This article gives the precise definitions of irreducible and prime elements. It proves that primes are always irreducible, while the converse can fail. It states and proves the UFD axioms carefully. It proves the central implication that PIDs are UFDs, using the ascending chain condition on principal ideals. It closes by pointing toward Gauss's Lemma and polynomial factorization over UFDs, where this machinery becomes indispensable.
- In a general integral domain, irreducible (cannot be factored nontrivially) and prime (generates a prime ideal) are different properties; prime always implies irreducible, but not conversely.
- A UFD is an integral domain where every nonzero nonunit is a product of irreducibles, uniquely up to order and associates.
- In a UFD, irreducible and prime elements coincide — this equivalence is itself a theorem, not part of the definition.
- Every PID is a UFD: the proof uses the ascending chain condition on principal ideals (from Noetherian-ness of PIDs) to guarantee factorization exists, then uses primality of irreducibles in a PID to force uniqueness.
- is a standard example of an integral domain that is not a UFD, showing the PID UFD implication is not reversible in spirit (there exist UFDs that are not PIDs, e.g. ).
- Key idea: unique factorization is equivalent to every irreducible element being prime, and this coincidence is guaranteed automatically once ideals are principal.
Where this lives today
Unique factorization domains are the algebraic backbone of several major areas. In algebraic number theory, the failure of unique factorization in rings of integers of number fields is measured by the class group, and Dedekind's theorem that ideals do factor uniquely into prime ideals (even when elements do not) is the modern repair of Kummer's original insight — this is one of the deepest classical results building directly on the distinction between prime and irreducible elements developed here. In polynomial algebra and computer algebra systems, the fact that is a UFD (as a Euclidean domain, hence a PID, hence a UFD by this theorem) underlies polynomial factorization algorithms used in symbolic computation software, and Gauss's Lemma extends unique factorization from down from back to whenever itself is a UFD — this is exactly how one proves is a UFD despite not being a PID. In cryptography, factorization-based hardness assumptions (RSA, and Gaussian-integer variants of primality testing) rely on unique factorization in and to guarantee well-defined notions of "prime" moduli. In coding theory, factorizations of polynomials over finite fields (a UFD) determine cyclic code structure. In algebraic geometry, whether a coordinate ring is a UFD governs whether every codimension-one subvariety is cut out by a single equation — a geometric shadow of the algebraic uniqueness property proved here.
:::quiz[In , why does fail to be prime even though it is irreducible?]
- is not irreducible in , so the question is moot
- divides but divides neither factor ✓
- has no units other than , blocking primality
- has norm , matching neither factor's norm
:::faq[Why doesn't the existence-of-factorization argument work verbatim in ?] It actually does work: does satisfy ACC on principal ideals (it is Noetherian, being a finitely generated -module as a ring), so every nonzero nonunit does factor into irreducibles there. What fails is uniqueness, because Part I of the PID proof — "irreducible implies prime" — depended crucially on writing as a single principal ideal , which is only guaranteed when every ideal of the ring is principal. In some ideals, like , are not principal, so that step of the argument breaks down, and indeed irreducibles like turn out not to be prime.
Ask the tutor: Can you show me why is a UFD even though it isn't a PID, using Gauss's Lemma?
Let be an integral domain (a commutative ring with and no zero divisors).
Units and associates. An element is a unit if for some . Two elements are associates if for some unit .
Irreducible. A nonzero nonunit is irreducible if whenever with , at least one of or is a unit. Equivalently, cannot be written as a product of two nonunits.
Prime. A nonzero nonunit is prime if whenever for , then or . Equivalently, is prime if and only if the principal ideal is a nonzero Prime Ideal.
Unique Factorization Domain (UFD). An integral domain is a unique factorization domain if: 1. (Existence) Every nonzero nonunit can be written as a product of irreducibles:
2. (Uniqueness) This factorization is unique up to order and associates: if
are two factorizations into irreducibles, then and, after reindexing, and are associates for each .
Intuition
Think of an integral domain as a universe of "numbers" where multiplication behaves, but the notion of "divides evenly" may be looser than in . Irreducibility is a syntactic condition: an element resists being split into two nontrivial factors. Primality is a semantic condition about how the element interacts with products: it can only divide a product by dividing one of the pieces. In these two ideas trace out the same set of elements — that fusion is so automatic we rarely distinguish them. The whole subtlety of unique factorization theory is that this fusion is a theorem, true in nice rings like PIDs, and false in general. The picture to keep in mind: primes are the "well-behaved" atoms that never cause ambiguity when they divide a product, while irreducibles are merely atoms with respect to the multiplication operation, with no promise about how they interact with divisibility of products. The diagram below shows the containment of classes of rings, and where the logical implication proven in this article — PID UFD — sits.
Worked examples appear after the theorem, once the containment PID UFD is proven rigorously.
Let be an integral domain and let be prime. Then is irreducible.
Since is prime, by definition is a nonzero nonunit. Suppose for some . We must show or is a unit. Since , we have (trivially, as ). Because is prime, or . Without loss of generality suppose , so for some . Substituting into gives , so . Since is an integral domain and , we conclude , i.e. . Hence is a unit. This shows that in any factorization , one of the two factors is a unit, so is irreducible by definition.
∎Let be a Principal Ideal Domain (an integral domain in which every ideal is principal). Then is a Unique Factorization Domain: every nonzero nonunit of factors into irreducibles, and this factorization is unique up to order and associates.
We break the proof into three parts: (I) irreducibles are prime in a PID, (II) every nonzero nonunit has some factorization into irreducibles (existence), and (III) uniqueness follows from (I). The proof technique for existence is a Noetherian induction / ascending chain argument, and for uniqueness a primality induction argument, mirroring Euclid's classical proof for .
Part I: In a PID, every irreducible element is prime. Let be irreducible. We show is a prime ideal. Since is a nonzero nonunit, is a proper nonzero ideal. Suppose for ; we must show or . Consider the ideal . Since is a PID, for some . Since , we have ; because is irreducible, is either a unit or an associate of . Case 1: is a unit. Then , so for some . Multiplying by :
Since , write . Then , so . Case 2: is an associate of , i.e. for a unit . Then , so , meaning . In either case or , so is prime. This proves Part I.
Part II: Existence of factorizations. We first show satisfies the ascending chain condition (ACC) on principal ideals: there is no infinite strictly increasing chain
Suppose such a chain existed. Let . This is an ideal: if then , for some , and taking , both lie in , so ; closure under multiplication by is immediate since each is an ideal. Since is a PID, for some . Since , we have for some . Then
forcing , contradicting strictness of the chain at stage . Hence no such infinite chain exists: satisfies ACC on principal ideals. Now suppose, for contradiction, that some nonzero nonunit has no factorization into irreducibles. Then in particular itself is not irreducible (else is its own one-term factorization), so with both nonunits. At least one of must also fail to have a factorization into irreducibles — otherwise multiplying their factorizations gives one for . Say has no factorization; note , strictly, because is not a unit (if then for some , giving , so , making a unit, a contradiction). Repeating this argument on produces with no factorization and , and so on, yielding an infinite strictly increasing chain
contradicting the ACC on principal ideals just established. Hence every nonzero nonunit has a factorization into irreducibles. This proves Part II (existence).
Part III: Uniqueness of factorization. Suppose is a nonzero nonunit with two factorizations into irreducibles:
We induct on , the length of the first factorization. Base case : Then . Since is irreducible and has factors none of which is a unit, if we could write as a product of two nonunits, contradicting irreducibility of . So and ; they are trivially associates (with unit ). Inductive step: Suppose the uniqueness claim holds for all nonzero nonunits admitting an irreducible factorization of length less than . Since is irreducible, by Part I it is prime. From
and primality of , divides one of the ; reindex so . Write for some . Since is irreducible and is not a unit, must be a unit (else would be a factorization of into two nonunits). Thus and are associates. Cancel from both sides of
using that is an integral domain (so nonzero elements are cancellable): and
Absorb the unit into , replacing by (still irreducible, since associates of irreducibles are irreducible — if then , forcing or to be a unit exactly when the same held for ). Now
is an equation between two irreducible factorizations of a nonzero nonunit, and the left side has length . By the inductive hypothesis, (so ) and, after reindexing, is an associate of for (with replaced by its associate , whose associate class is the same as 's). Combined with from above, this completes the induction. By induction, uniqueness holds for all nonzero nonunits of . Combined with Part II (existence), is a UFD.
∎If is a UFD, then an element is irreducible if and only if it is prime.
Prime implies irreducible holds in any integral domain, giving one direction. For the converse, suppose is irreducible in the UFD and with . Factor (or note if any is zero or a unit the claim is easy) into irreducibles and use uniqueness of the factorization of : the irreducible appearing on the right must appear, up to associates, among the irreducible factors of or of on the left, since both sides are factorizations of the same element into irreducibles (after refining units). Hence divides or divides . (This argument specializes the proof of Part I of the PID implies UFD theorem, replacing the ideal-theoretic argument with a direct comparison of factorizations, which is available precisely because is a UFD.)
∎Worked examples
Example 1: Factoring in , the Gaussian integers, a PID. Let , which is known to be a Euclidean domain via the norm , hence a PID, hence by our theorem a UFD. Consider the element
We factor into irreducibles two different-looking ways and confirm they agree up to units and reordering — units in are . Route A. Factor out the obvious real integer content: . Now (check: , and ), and since . Both and are irreducible in because their norms ( and respectively) are primes in , and a Gaussian integer of prime norm must be irreducible (if it factored as a product of two nonunits, the norms — which are multiplicative — would give a nontrivial factorization of the prime norm in , impossible). So:
Route B. Directly test divisibility: requires . So . Continue factoring and exactly as before, arriving at the same multiset of irreducibles:
up to the unit , confirming uniqueness as guaranteed by the theorem, regardless of the order in which factors were extracted.
Example 2: The non-example is not a UFD — sanity-checking why the PID hypothesis matters. Let , with norm , multiplicative: . Consider . We exhibit two genuinely different factorizations into irreducibles:
Check: . Good. We must verify each of is irreducible, and no two of them are associates. Compute norms: , , , . Irreducibility of : if with nonunits, then with (norm forces a unit, since only for , giving units ), so . But has no integer solutions (checking gives , impossible; already exceeds ). So is irreducible. Irreducibility of : similarly forces , and has no solution. So is irreducible. Irreducibility of : a nontrivial factorization would force norm factors with both , i.e. ; but we just showed no element has norm or norm . So are irreducible. No two are associates: the only units are (norm ), so associates of are , of are , and have norm , so they cannot be associates of or ; and is not . Hence has two factorizations into irreducibles, and , that are not related by reordering and units. So is not a UFD — and by our theorem (contrapositive), it cannot be a PID either. Indeed, one can show the ideal is not principal, consistent with this.
The theorem requires to be a PID. If we only assume is an integral domain — dropping the hypothesis that every ideal is principal — factorization into irreducibles can fail to exist at all, not merely fail to be unique. Consider functions expressible via the ring of algebraic integers in a number field with infinitely many prime factors available, or more simply: , the ring of all algebraic integers (algebraic numbers satisfying a monic polynomial with integer coefficients). This is an integral domain (subring of ), but it has no irreducible elements whatsoever: given any nonzero nonunit , one can always write , and is again an algebraic integer (it satisfies shifted appropriately) and is not a unit whenever is not, since norms strictly decrease. Iterating, factors forever into nonunits, so can never be written as a finite product of irreducibles — existence of factorization fails completely. This shows the ACC on principal ideals (which we derived from the PID hypothesis and used crucially in Part II of the proof) is not a free lunch: is very far from Noetherian, and without some finiteness hypothesis like ACC, factorizations need not exist, so the UFD property collapses at the most basic level.
Scope, edge cases & common traps
| Situation | What holds | What can fail |
|---|---|---|
| a field | Vacuously a UFD (no nonzero nonunits to factor) | N/A |
| a PID | UFD, by the theorem above | — |
| a UFD | Irreducible prime | need not be a PID (e.g. is a UFD, not a PID) |
| merely an integral domain | Irreducibles may exist | Factorizations may not exist, or may not be unique |
| non-Noetherian domain | — | Existence of factorization can fail entirely (e.g. , algebraic integers) |
The mathematician behind it
Origins · 1 minErnst Eduard Kummer and how this was discovered
Kummer's investigations into Fermat's Last Theorem in the 1840s led him to work in rings of cyclotomic integers , where he discovered that unique factorization into ordinary elements could fail, mirroring the phenomenon later exhibited concretely in . To repair this, he introduced "ideal numbers," a precursor to Dedekind's theory of ideals, restoring unique factorization at the level of ideals even when it fails at the level of elements. This work — connecting failure of the UFD property directly to deep number-theoretic questions — is the historical origin of the entire theory formalized in this article.
Are "prime" and "irreducible" ever literally the same definition?
No — they are defined differently even though they coincide in many familiar rings. Irreducible is defined purely multiplicatively: cannot be split into two nonunit factors. Prime is defined via divisibility of products: or , equivalently is a nonzero prime ideal. The lemma proved in this article shows prime always implies irreducible in any integral domain, but the converse requires extra structure — it holds in UFDs (by definition, essentially, once uniqueness is available) and hence in PIDs, but fails in general domains like .
Why does the definition of UFD require uniqueness "up to order and associates" rather than exact uniqueness?
Because factorization can never be exactly unique in any ring with more than one unit. For instance in , , and reordering is also unavoidable. The phrase "up to order and associates" precisely quotients out these harmless ambiguities — swapping the order of multiplication (which is always commutative) and multiplying factors by units (which doesn't change what they generate as ideals) — while still capturing the meaningful uniqueness: the multiset of associate-classes of irreducible factors is an invariant of the element.
Is every Euclidean domain automatically a UFD?
Yes, but through an intermediate step: every Euclidean domain is a PID (the standard proof uses the division algorithm to show any ideal is generated by an element of minimal norm), and this article's theorem then shows every PID is a UFD. So Euclidean domain PID UFD, but not every UFD is Euclidean or even a PID — again being the standard example of a UFD sitting strictly outside the PID class.
Does UFD imply Noetherian, or is that a separate assumption?
UFDs need not be Noetherian in general — the existence part of the UFD axiom only requires that finite factorizations into irreducibles exist and are unique, which is a weaker condition than ACC on all ideals. However, every UFD does satisfy ACC on principal ideals (essentially by the same infinite-descent argument used in Part II of the PID proof, run in reverse), because otherwise factorization existence itself would fail. Full Noetherian-ness (ACC on all ideals, not just principal ones) is a strictly stronger hypothesis than being a UFD.
How does this connect to Gauss's Lemma and polynomial factorization?
If is a UFD, one can ask whether the polynomial ring is also a UFD — this is not automatic from our PID theorem, since is typically not a PID even when is (e.g. ). Gauss's Lemma supplies exactly the missing tool: it shows that a polynomial in that is irreducible in remains irreducible in (and controls the reverse direction too), letting one transfer the UFD property of the PID back down to . This is how one proves and are UFDs despite not being PIDs, directly building on the definitions and the prime/irreducible distinction established here.
Can an element be neither prime nor irreducible, and does that matter for the definition?
Yes — units and zero are neither prime nor irreducible by definition (both notions are defined only for nonzero nonunits), and this exclusion is deliberate. If units were allowed to be "irreducible," factorizations would never be unique, since you could always insert extra unit factors; excluding avoids degenerate statements like " divides every product." The UFD definition is carefully scoped to nonzero nonunits precisely so that the existence and uniqueness clauses are meaningful and the coincidence with primality (proved in the corollary) is a clean, checkable statement.