Factorizing

polynomials with

rational coefficients
can be difficult and Gauss's Lemma is a helpful tool for this problem.
It is used implicitly in

computer algebra packages.

**Theorem** A polynomial with integer coefficients that is
irreducible in **Z**[x] is irreducible in
**Q**[x]

Here's an example to illustrate the theorem. Consider
*f(x)=x*^{3} - x^{2} - x - 1.
We are going to show that this polynomial is irreducible
in **Q**[x]. Suppose that *f(x)*
factorizes nontrivially in **Z**[x]. Since the highest
common factor of its coefficients is 1 such a factorization has to
be as *g(x)h(x)* where *g* and *h* both have degree <3.
Thus

*
x*^{3} - x^{2} - x - 1 = (ax + b)(cx^{2} + dx + e).
Equating coefficients of
*x*^{3} and *x*^{0}
we get *ac=1* and *be=-1* so we see that
*a* and *b* both have to be 1 or -1. It follows that
*f(x)* has 1 or -1 as a zero but *f(1)* and *f(-1)*
are both nonzero.

This contradiction shows that *f(x)* is irreducible in
**Z**[x] and hence in **Q**[x]

Another application of the theorem is Eisenstein's irreducibility criterion.

We will prove a more general result than the theorem. First we need some
definitions. We work with *R[x]* the polynomial ring
over a unique factorization domain (UFD). Let *f(x)* in
*R[x]*, then we can find a highest common factor
*c*, say, of the coefficients of *f(x)*. Thus
*f=cg* where *g* is in *R[x]* and is such that
the highest common factor of its coefficient is 1. Such a polynomial
is called **primitive**. The constant *c* is called the
**content** of *f*. Note that *c* is only unique
up to associates (so should really be called a content).

**Gauss's Lemma** Let *R* be a UFD and let
*f,g* in *R[x]* be primitive. Then so
is *fg*.

**Proof**
Say *f=f*_{0}+f_{1}x+...+f_{n}x^{n}
and *g=g*_{0}+g_{1}x+...+g_{m}x^{m}.
Write *fg=ch* with *h* primitive and *c* the content
of *h*. Suppose that *p* is a prime in *R* that divides
*c*. Since *f* is primitive *p* cannot divide all its
coefficients so choose *f*_{i} to be the first one
not divisible by *p*. Likewise choose *g*_{j} to
be the first coefficient of *g* not divisible by *p*.
Now consider the coefficient of *x*^{i+j} in
*fg=ch*. We have

*ch*_{i+j} = (f_{0}g_{i+j} + ... + f_{i}g_{j} +...+ f_{i+j}g_{0}).

Now because of the way *f*_{i} and *g*_{j}
were chosen all the terms on the right hand side except
*f*_{i}g_{j} are divisible by *p*. But *p*
divides the right hand side by assumption. So we deduce that
*p|f*_{i}g_{j}. This contradicts the primeness of
*p*. We deduce that there is no such *p* and *c* is
a unit. In other words, *fg* is primitive.

**Corollary**
Let *R* be a UFD and let *f,g* in *R[x]*. Then
content(*fg*)=content(*f*).content(*g*).

**Proof:** Write *f=cf*_{1} and *g=dg*_{1}
where *c,d* are, respectively, the contents of *f,g*.
Thus, *fg=cdf*_{1}g_{1}. Since
*f*_{1}g_{1} is primitive, by the Gauss Lemma,
we are done.

Now for our UFD *R* let *k=* be the field of fractions
of *R*. For example, if *R=***Z** then *k=***Q**.
The next result has the very first theorem we stated as the special case
when *R=***Z**.

**Theorem** Let *R* be a UFD with field of fractions
*k*.
Let *f* be a polynomial in *R[x]*.
Then *f* is primitive and irreducible in *k[x]*
iff it is irreducible in *R[x]*.

**Proof:** One direction is trivial. If *f* is primitive
and irreducible in *k[x]* then how could it factorize
over *R[x]*? By primitivity a factorization *ch*
where *c* is a nonunit of *R* is impossible. By irreduciblity
in *k[x]* such a factorization where both *g,h* have
smaller degree than *f* is impossible.

So let's prove the other implications. Suppose that *f* is irreducible
in *R[x]* (hence clearly primitive). Suppose that
*f=gh* where *g,h* in *k[x]* have degree <
deg *f*. clearing denominators we can rewrite this as

*af=bg*_{1}h_{1} (*)

where
*a,b* are in *R* and *g*_{1},h_{1}
are in *R[x]*. Taking contents and using the corollary
we get that
*a*=*b*.content(*g*_{1}).content(*h*_{1}).
Subsituting in (*) we have a nontrivial factorization of *f* in
*R[x]*, a contradiction.