Euclid's Algorithm and Computation of Polynomial GCD' s
481
variate or multivariate polynomials. By viewing multivariate polynomials as poly-
nomials in one variable, hereafter called the
main variable,
with coefficients in the
domain of polynomials in the other variables, hereafter called the
auxiliary variables,
we may confine our attention without loss of generality to the univariate case.
2.2
THE RATIONAL ALGORITHM. For univariate polynomials F1 and F2 over a
field, division yields a unique quotient Q and remainder R such that
F1
=
QF2 + R,
O (R)
< O (F2),
(3)
where 0 (F) denotes the degree of F, and 0 (0) = - ~. Thus Euclid's algorithm, as
presented in Section 1.4, is directly applicable. As an example [1, pp. 370-371], if
Fi(x) = x s+ x 6-
3x 4-
3x 3"4- 8x 2 +
2x-- 5,
(4)
F2(x)
-~
3x 6 +
5x 4 --
4x 2
--
9x
+
21
are viewed as polynomials with rational coefficients, then the following sequence
occurs (for brevity, we write only the coefficients):
1, 0, 1, 0, --3, --3, 8, 2, --5
3, 0, 5, 0, --4, --9, 21
-~, o, ~, o, -~
117
-9, ~-
233150
102500.
"-~591
, ---'~97
1988744821
(5)
- 543589
~-~5-'"
It follows that F1 and F2 are relatively prime.
To improve this procedure, we make each polynomial monic as soon as it is ob-
tained, thereby simplifying the coefficients somewhat. In our example, we obtain
the sequence
1,0,1,0,-3,-3,8,2,-5
1, 0, ~, 0, -~, -3,7
1,0, -], 0, ~
1, 95
49
1,
615o
-- T~-6--,gj
1.
(6)
Although this sequence minimizes the growth of coefficients, it requires integer
GCD computations at each step in order to reduce the fractions to lowest terms.
In general, if the coefficient domain is not a field, we could embed it in its field of
quotients and then use the algorithm of Section 1.4, but we shall see that it is more
efficient not to do so.
2.3
POLYNOMIAL REMAINDER SEQUENCES. Let 9 be a unique factorization do-
main in which there is some way of finding GCD's, and let 9[x] denote the domain of"
polynomials in x with coefficients in 9. Assuming that the terms of a polynomial
F C 9[x] are arranged in the order of decreasing exponents, the first term is called
the
leading term,
and its coefficient lc (F) is called the
leading coe~cient.