Introduction
For a general field $F$ there is no simple way to determine if an arbitrary polynomial in $F[T]$ is irreducible. Here we will focus on the case $F=\mathrm{Q}$ and describe two useful irreducibility tests in $\mathbf{Q}[T]$ for monic polynomials in $\mathbf{Z}[T]$. Let
$$
f(T)=T^{n}+a_{n-1} T^{n-1}+\cdots+a_{1} T+a_{0} \in \mathbf{Z}[T]
$$
The two tests are
- Reduction mod $p$ : for a prime $p$, reducing coefficients of $f(T)$ modulo $p$ leads to
$$
\bar{f}(T)=T^{n}+\bar{a}{n-1} T^{n-1}+\cdots+\bar{a}{0} \in(\mathbf{Z} / p \mathbf{Z})[T]
$$
If $\bar{f}(T)$ is irreducible in $(\mathbf{Z} / p \mathbf{Z})[T]$ for some $p$, then $f$ is irreducible in $\mathbf{Q}[T]$. Eisenstein criterion: call $f(T)$ Eisenstein at $p$ if $p \mid a_{i}$ for all $i$ and $p^{2} \nmid a_{0}$. If $f$ is Eisenstein for some $p$, then $f$ is irreducible in $\mathbf{Q}[T]$.
These tests each depend on a choice of a prime number, but they use the prime number in different ways.
The polynomial $T^{3}+T+1$ is irreducible in $(\mathbf{Z} / 2 \mathbf{Z})[T]$, so every monic cubic in $\mathbf{Z}[T]$ that reduces modulo 2 to $T^{3}+T+1$ is irreducible in $\mathbf{Q}[T]$, such as $T^{3}-4 T^{2}+3 T+1$.
The polynomial $T^{6}+T+1$ is irreducible in $\mathbf{Q}[T]$ because it is irreducible in $(\mathbf{Z} / 2 \mathbf{Z})[T] .$ To show irreducibility in $(\mathbf{Z} / 2 \mathbf{Z})[T]$, we just have to check it is not divisible by any irreducibles of degree 1,2 , or 3 in $(\mathbf{Z} / 2 \mathbf{Z})[T]:$ there are two irreducibles of degree 1 $(T$ and $T+1)$, one irreducible of degree $2\left(T^{2}+T+1\right)$, and two irreducibles of degree 3 $\left(T^{3}+T+1\right.$ and $\left.T^{3}+T^{2}+1\right)$. This leaves us with a finite amount of computation, which you should go through yourself.
Let $f(T)=T^{3}-2$. Then
$$
\begin{aligned}
f(T) & \equiv T^{3} \bmod 2 \
f(T) & \equiv T^{3}+1 \bmod 3 \
& \equiv(T+1)\left(T^{2}-T+1\right) \bmod 3 \
f(T) & \equiv(T-3)\left(T^{2}+3 T+9\right) \bmod 5,
\end{aligned}
$$
so $f$ is reducible mod $p$ for $p=2,3,5$. However $f(T) \bmod 7$ is irreducible since $f \bmod 7$ has degree 3 in $(\mathbf{Z} / 7 \mathbf{Z})[T]$ and has no root in $\mathbf{Z} / 7 \mathrm{Z}$ : that is a finite check since $\mathbf{Z} / 7 \mathbf{Z}$ is finite. By the reduction mod $p$ test at $p=7, T^{3}-2$ is irreducible in $\mathbf{Q}[T]$.
There are monic polynomials in $\mathbf{Z}[T]$ that are irreducible in $\mathbf{Q}[T]$ but are reducible mod $p$ for all $p$, e.g., $T^{4}-10 T^{2}+1$. So the reduction mod $p$ test does not always apply.
$T^{3}-2$ is Eisenstein at 2 , so it’s irreducible in $\mathbf{Q}[T]$. This is a much easier method for $T^{3}-2$ than reduction mod $p$ (Example 1.3).
The usefulness of the Eisenstein criterion is that it lets us create irreducibles in $\mathbf{Q}[T]$ of any degree we wish. (Note $T-2$ is Eisenstein at 2 : the test could be used in degree 1 , but it is not necessary since all linear polynomials over a field are irreducible.)
$T^{n}-2$ is Eisenstein at 2 for any $n \geq 1$, so it is irreducible in $\mathrm{Q}[T]$.
An Eisenstein polynomial at 3 is $T^{19}+6 T^{10}-9 T^{4}+75$.
Gauss’ Lemma
To prove the reduction mod $p$ test and the Eisenstein criterion, we will prove the polynomial in each test can’t be decomposed into lower-degree factors in $\mathbf{Z}[T] .$ How come that implies irreducibility in $\mathrm{Q}[T] ?$ For comparison, $T^{2}+1$ is irreducible in $\mathbf{R}[T]$ but if we enlarge $\mathbf{R}$ to $\mathbf{C}$ then $T^{2}+1=(T+i)(T-i)$ in $\mathbf{C}[T]$ and the polynomial becomes reducible. Passing from $\mathbf{Z}[T]$ to $\mathbf{Q}[T]$ never turns irreducibility into reducibility. This is traditionally called Gauss’ lemma.
Theorem $2.1$ (Gauss). If $f(T) \in \mathbf{Z}[T]$ is monic and $f(T)=g(T) h(T)$ in $\mathbf{Q}[T]$ where $\operatorname{deg} g<\operatorname{deg} f$ and $\operatorname{deg} h<\operatorname{deg} f$ then we can write $f(T)=g_{1}(T) h_{1}(T)$ in $\mathbf{Z}[T]$, where $g_{1}(T)$
and $h_{1}(T)$ are scalar multiples of $g(T)$ and $h(T)$, respectively; in particular, deg $g_{1}(T)=$ $\operatorname{deg} g(T)<\operatorname{deg} f(T)$ and $\operatorname{deg} h_{1}(T)=\operatorname{deg} h(T)<\operatorname{deg} f(T)$
Therefore if a monic polynomial in $\mathrm{Z}[T]$ can’t be written as a product of lower-degree polynomials in $\mathbf{Z}[T]$, it is irreducible in $\mathbf{Q}[T] .$
As an example, $T^{2}-1$ in $\mathbf{Q}[T]$ is $((4 / 3) T-4 / 3)((3 / 4) T+3 / 4)$, having linear factors, and in $\mathbf{Z}[T]$ it is $(T+1)(T-1)$, also having linear factors.
Step 1: Use common denominators to factor a scalar multiple of $f(T)$ in $\mathbf{Z}[T]$. Let $d$ and $e$ be common denominators of the coefficients of $g(T)$ and $h(T)$, respectively,
so $g(T)=g_{0}(T) / d$ and $h(T)=h_{0}(T) / e$ where $g_{0}(T)$ and $h_{0}(T)$ are both in $\mathrm{Z}[T]$. Thus
$$
f(T)=g(T) h(T)=\frac{g_{0}(T)}{d} \frac{h_{0}(T)}{e} \Longrightarrow \operatorname{def}(T)=g_{0}(T) h_{0}(T)
$$
This last equation takes place in $\mathrm{Z}[T]$.
Step 2: Use greatest common divisors to get factors of $f(T)$ whose coefficients are relatively prime.
Factor out the greatest common divisor of the coefficients of $g_{0}(T)$ and of the coefficients of $h_{0}(T): g_{0}(T)=a g_{1}(T)$ and $h_{0}(T)=b h_{1}(T)$ where $a, b \in \mathbf{Z}^{+}$, the coefficients of $g_{1}(T)$ are relatively prime, and the coefficients of $h_{1}(T)$ are relatively prime. Then
$$
\operatorname{def}(T)=g_{0}(T) h_{0}(T)=\operatorname{abg}{1}(T) h{1}(T)
$$
Step 3: Obtain a factorization of $f(T)$ in $\mathbf{Z}[T]$. We will show de $=a b$, so canceling this (nonzero) factor from both sides gives us $f(T)=$ $g_{1}(T) h_{1}(T)$ in $\mathbf{Z}[T]$ where $g_{1}(T)=g_{0}(T) / a=(d / a) g(T)$ and $h_{1}(T)=h_{0}(T) / b=(e / b) h(T)$
are scalar multiples of $g(T)$ and $h(T)$. Since $f(T)$ is monic, looking at the leading coefficient on both sides of $(1)$ we get
$$
d e=a b\left(\text { lead } g_{1}\right)\left(\text { lead } h_{1}\right) \quad \text { in } \mathbf{Z}
so $a b \mid$ de. Let $c=d e / a b \in \mathbf{Z}^{+}$, so $c \geq 1$ and $(1)$ implies
$(2)$
$$
c f(T)=g_{1}(T) h_{1}(T) .
$$
If $c>1$ then it has a prime factor, say $p$. Reduce both sides of $(2.2)$ modulo $p$ : this turns $(2.2)$ into $0=\overline{g_{1}}(T) \overline{h_{1}}(T)$ in $(\mathbf{Z} / p \mathbf{Z})[T]$. Since $(\mathbf{Z} / p \mathbf{Z})[T]$ is an integral domain, one of $\overline{g_{1}}(T)$
or $\overline{h_{1}}(T)$ is 0, which is another way of saying all the coefficients of $g_{1}(T)$ are divisible by $p$ or all the coefficients of $h_{1}(T)$ are divisible by $p$. Neither is possible, since the coefficients of $g_{1}(T)$ are relatively prime and the coefficients of $h_{1}(T)$ are relatively prime. Therefore $c$ has no prime factor, so $c=1$ and $f(T)=g_{1}(T) h_{1}(T)$ is a factorization of $f(T)$ in $\mathbf{Z}[T]$ where the factors $g_{1}(T)$ and $h_{1}(T)$ are scalar multiples of $g(T)$ and $h(T)$.
$$
A good way to think about the later part of this proof is that we applied the reduction $\bmod p$ homomorphism to turn an equation in $\mathbf{Z}[T]$ into an equation in $(\mathbf{Z} / p \mathbf{Z})[T]$ for a suitably chosen prime $p$. We will apply this same idea in the proofs of both the reduction $\bmod p$ test and the Eisenstein criterion.
Reduction mod p
Theorem 3.1. If $f(T) \in \mathbf{Z}[T]$ is monic and there is a prime p such that $\bar{f}(T)$ is irreducible in $(\mathbf{Z} / p \mathbf{Z})[T]$ then $f(T)$ is irreducible in $\mathbf{Q}[T]$.
Proof. By Gauss’ lemma, to prove $f(T)$ is irreducible in $\mathbf{Q}[T]$ it suffices to show we can’t write $f(T)$ as a product of lower-degree factors in $\mathbf{Z}[T]$. Assume $f=g h$ for some $g, h \in \mathbf{Z}[T]$ with $\operatorname{deg} g<\operatorname{deg} f$ and $\operatorname{deg} h<\operatorname{deg} f .$ We will get
a contradiction from this. Looking at the leading coefficients on both sides of $f=g h$ we have $1=($ lead $g)($ lead $h)$ in $\mathrm{Z}$, so $g$ and $h$ both have leading coefficient 1 or both have leading coefficient $-1$. Therefore, after changing the signs on $g$ and $h$ if necessary, we can assume $g$ and $h$ are both monic in $\mathbf{Z}[T]$. Reduction mod $p$ is a ring homomorphism $\mathbf{Z}[T] \rightarrow(\mathbf{Z} / p \mathbf{Z})[T]$, so it turns the equation $f=g h$ in $\mathbf{Z}[T]$ into $\bar{f}=\bar{g} \bar{h}$ in $(\mathbf{Z} / p \mathbf{Z})[T] .$ Since $\bar{f}$ is irreducible, one of $\bar{g}$ or $\bar{h}$ has degree 0 and the other has degree equal to that of $\bar{f}$. Because $f, g$ and $h$ are all monic,
$$
\begin{aligned}
\operatorname{deg} \bar{f} &=\operatorname{deg} f \
\operatorname{deg} \bar{g} &=\operatorname{deg} g \
\operatorname{deg} \bar{h} &=\operatorname{deg} h
\end{aligned}
$$
Therefore one of $g$ or $h$ has degree equal to the degree of $f$, but this contradicts $g$ and $h$ both having degree less than $\operatorname{deg} f$.