In this chapter is a very short introduction to modules and rings leading to canonical forms. The only rings considered here will be commutative rings. It all applies to the ring of polynomials F
Definition 9.1.1 A commutative ring R is called an integral domain if in addition, whenever x≠0 and y≠0, it follows that xy≠0. A subset I of a commutative ring R is called an ideal if whenever r ∈ R and a ∈ I,ra ∈ I and if whenever a,b ∈ I, so is a + b and if a ∈ I, so is −a. (I is a subgroup of the additive group of R) Informally, RI = I. A principal ideal is an ideal of the form
Note that Ra =
The example we have in mind is the following, although you can also see that the integers ℤ is also a principal ideal domain. The following theorem was partly done in Lemma 1.12.8 but here is a different proof.
Theorem 9.1.2 Let F be a field and consider F
Proof: It is obvious that F

and suppose both p

The only nonzero terms in the sum involve i ≥ r and j ≥ s. However, i + j = r + s and so there is only one nonzero term in the sum and it is a_{r}b_{s} which must be zero, a contradiction to a_{r},b_{s} both nonzero. Therefore, one of p
Next consider the question whether it is a principal ideal domain. Let I be an ideal. Suppose that it is not the zero ideal which is obviously a principal ideal but uninteresting. Then let g

where r

The right side is in I because it is a sum of two things in I. Now this is a contradiction if r
Note that the first part of the proof works if the coefficients of polynomials are only known to be in an integral domain. However, when we do division, we like to have coefficients in a field, but you might consider whether one could generalize to the situation in which the coefficients are only in an integral domain for the second part also.
In what follows the symbol ∕ indicates “divides”. Thus a∕b means b = ax for some x.
Observation 9.1.3 Note that, just as with matrices, if xy = yx = 1 and xz = zx = 1, then y = z so the inverse, if it exists, is unique. However, this is easier here because multiplication is commutative. In case D = F

but the degrees add and so the degree of both a
Definition 9.1.4 Let D be an integral domain. Then p ∈ D is said to be prime if it is not zero and divided only by invertible elements of D and elements of the form xp where x is invertible. If a,b ∈ D then a greatest common divisor d denoted g.c.d.satisfies d∕a,d∕b and if c∕a,c∕b, then c∕d. If Da + Db = D1 = D, then we say that a,b are relatively prime.
Note that invertible elements are prime and also if p is prime, so is xp where x is invertible. Here is why: If y∕xp where x invertible and p prime, then xp = yk and so p = x^{−1}yk showing that x^{−1}y∕p and so, since p is prime, either x^{−1}y = p or x^{−1}y = zp where z is invertible. In the second case, y = xzp and so y is an invertible times p. In the first case, y = xp so still, y is an invertible times p. Thus xp is prime. As to invertibles being primes, if x is invertible, then if y∕x, then x = yz and so 1 = yx^{−1}z showing that y is invertible. Thus if y∕x, then y is invertible. Thus the only divisors of x are invertibles times x or invertibles. Thus x qualifies to be called prime.
When p = xq for x invertible, p,q are said to be associates or associated.
Lemma 9.1.5 In a p.i.d. every pair of nonzero a,b has a greatest common divisor d and it can be written in the form

for some s,t ∈ D. Also a,b are relatively prime if and only if there exists s,t such that

Proof: Consider the set Da + Db, all linear combinations of a,b. This is clearly an ideal and since this is a principal ideal domain, there exists d such that Dd = Da + Db. Thus there exists s,t such that d = sa + tb. Also, there exists k such that kd = 1a + 0b which shows that d∕a. Similarly d∕b. Now suppose c∕a and c∕b so cx = a,cy = b. Then d = sxc + tyc =
Next suppose a,b are relatively prime. This means Da + Db = D. In particular, you can get s,t such that sa + tb = 1 since 1 ∈ D. Conversely, if for some s,t you have 1 = sx + ty, then it is obvious that D = Da + Db. ■
Here is a proposition which gives a condition for a,b to be relatively prime.
Proposition 9.1.6 In a p.i.d. a,b are relatively prime if and only if the only divisors of a,b are the invertible elements of D.
Proof: If a,b are relatively prime, then

for some s,t ∈ D. If d divides both a,b, then a = dx,b = dy for some x,y and so

and so d^{−1} =
Conversely suppose the only divisors are invertible. Consider the ideal Da + Db. It equals Dd for some d because this is a p.i.d. As above, d∕a,d∕b. By assumption, d^{−1} exists and so Dd = D. Hence there exists s,t such that 1 = sa + tb and so a,b are relatively prime by Lemma 9.1.5. ■
Corollary 9.1.7 Let p be a prime in a principal ideal domain D. If p∕ab then p∕a or p∕b.
Proof: Say p∕ab. Suppose that p does not divide a. Since p is prime, this means that if k∕p then k is an invertible or an invertible times p. It follows that the only things from D which divide both p and a are invertibles times p or invertibles. However, the former does not occur because it is assumed that p does not divide a. Thus p,a are relatively prime because the only element of D dividing them both is an invertible. This implies the greatest common divisor is invertible. Hence there are s,t ∈ D such that

which implies

Now we use that p∕ab to write ab = pz. Then

showing that p∕b. ■
What are examples of prime elements of our favorite integral domain F
Definition 9.1.8 In F
As mentioned above, in F
The above definition just gives the content of the following lemma. It is just a restatement of the above definition of what it means to be prime.
As discussed much earlier, every polynomial in F
Lemma 9.1.10 Let D be a p.i.d. (principal ideal domain). Also let I_{1} ⊆ I_{2} ⊆ I_{3} ⊆
Proof: Let I = ∪_{i}I_{i}. This is a subgroup of the additive group of D because if a ∈ I, then eventually a ∈ I_{n} and so −a ∈ I_{n} ⊆ I. Similarly, if a,b ∈ I, then for large enough n, both are in I_{n} and so their sum is in I_{n} ⊆ I. If d ∈ D and a ∈ I, then a ∈ I_{m} for some m and so da ∈ I_{m} ⊆ I. So yes, I is an ideal. Therefore, I = Da =
Recall again the definition of a prime. p ∈ D is said to be prime if it is divided only by invertible elements of D and elements of the form xp where x is invertible.
What follows is the prime factorization theorem analogous to the fundamental theorem of arithmetic. Note the following example in ℚ

both on the right are irreducible over ℚ and so you can’t expect uniqueness in such a prime factorization for a p.i.d. What you can expect is uniqueness up to associates.
Theorem 9.1.11 Let D be a p.i.d. and let a ∈ D,a≠0 and a is not invertible^{1} . Then there are primes p_{1},
Proof: Say a is not invertible and suppose it has no prime factorization. Then a is itself not prime. Thus a has a divisor a_{1} which is not invertible and also is not an invertible multiple of a. Thus a = a_{1}b_{1}. If b_{1} were invertible, then a_{1} = b_{1}^{−1}a and this violates what is known about a_{1} that it is not an invertible times a. Therefore, b_{1} is not invertible. If b_{1} = xa, then you would have a = a_{1}xa and so, a
If these each had a prime factorization consisting of non invertible primes, then so would a ≡ a_{0}. Let a_{1} be the one which does not have such a prime factorization. Then repeating the above argument for a_{1}, it follows that a_{1} = a_{2}b_{2} where neither factor is invertible nor an invertible multiple of a_{1} and as just explained, one fails to have a prime factorization. Let a_{2} be the one which does not have the prime factorization consisting of non invertible primes. Then continuing this way, you get a sequence

where a_{n} is a non invertible multiple of a_{n+1}. It follows that the ideals
To see why these are strictly increasing, note first that
If a^{−1} were to exist, this argument would fail because you would have 1 = a_{0}^{−1}a_{0} ∈ Da_{0} and so this ideal would be all of D and there would be no contradiction because the ideals would all be the same.
This takes care of the existence of the factorization.
Now suppose ∏ _{i=1}^{m}p_{i} = a. If m = 1, then a is a prime and so if a = p = q_{1}

and cancelling p, it follows that p is invertible which it is not. The error occured in assuming there was more than one factor in the q_{i}. Hence in this case that m = 1, the second claim about uniqueness follows. Assume this claim is true for m − 1,m > 1 that if one of k,l is no larger than m − 1, and if

then k = l and there is a permutation such that q_{ji} = p_{i}x for some invertible x.
Then if ∏ _{i=1}^{m}p_{i} = ∏ _{j=1}^{n}q_{j} where the primes are not invertible, we can assume n > m− 1 because if not, the induction hypothesis would apply to draw the desired conclusion. Then q_{n} divides some p_{i}. Assume it divides p_{m} for the sake of simplicity. Then q_{n} is not invertible and so it must be of the form q_{n} = xp_{m} where x is invertible. Thus

Thus, p_{m}

and now by induction, m− 1 = n− 1 and there is a permutation of the q_{j} such that q_{ji} = x_{i}p_{i} where x_{i} is invertible. Recall that if q is prime, so is xq for x an invertible. ■
The next proposition is like Corollary 1.12.10.
Proposition 9.1.12 Let a∕b where b = ∏ _{i=1}^{n}p_{i}^{ki} is not invertible. Then a is either invertible or a = x∏ _{i=1}^{n}p_{i}^{mi} where x is an invertible and m_{i} ≤ k_{i}, the p_{i} being distinct noninvertible primes.
Proof: We have b = ak. Then by Theorem 9.1.11, assuming that a is not invertible,

where the q are noninvertible primes and by collecting the q,