Principles and methods of algebraic computations
2.3 Methods for the computation of the GCD of polynomialsof polynomials
2.3.1 The Matrix Pencil method
The Matrix Pencil method (MP) is a direct matrix-based method which relies on the characterisation of the GCD of a set Pm,n of m > 2 polynomials of maximum degree n > 1 as the output decoupling zero polynomial of a linear system S( ˆA, ˆC) that may be associated with Pm,n. The theoretical basis of the Matrix Pencil methodology derives from the system properties of zeros [44, 55], where the GCD characterisation is reduced to. The computation of the GCD is reduced to finding the finite zeros of the pencil T (s) = s W − ˆA W , where W is a basis matrix of the unobservable subspace W of S( ˆA, ˆC). If k = dim{W}, the GCD is determined as any nonzero entry of the kth compound Ck(s W − ˆA W ). The method defines the exact degree of GCD, works satisfactorily with any number of polynomials, and evaluates successfully approximate solutions.
The algorithm of the MP method uses stable algebraic processes, such as SVD for computing the right Nr and left Nl nullspaces of appropriate matrices. The main target of the MP algorithm is to form the GCD pencil T (s) and specify any minor of maximal order, which gives the required GCD. This specification can be done symbolically. The MP method has been presented and analysed in [45]. An earlier comparison of the MP method with other existing methods can be found in [59] and a new approach to its numerical implementation has been given in [49, 72].
◮ The standard Matrix Pencil method
For a given polynomial setPh+1,n, let Ph+1 be the basis matrix of the set formed directly from the coefficients of the polynomials of the set. The following theorem underlie the Matrix Pencil method.
Theorem 2.9 ([45]). Let the set of univariate polynomials Ph+1,n, Ph+1 a basis matrix with rank(Ph+1) = ρ < n + 1, M ∈ R(n+1)×µ with µ = n− ρ + 1 a basis matrix for the right nullspace Nr(Ph+1) of Ph+1, and M1 ∈ Rn×µ the submatrix of M obtained by deleting the last row of M . If p(s)∈ Ph+1,n is any monic polynomial of degree n, ˆA∈ Rn×n is the associated companion matrix, and ˆC ∈ R(ρ−1)×n with rank( ˆC) = ρ− 1 is such that ˆCM1 = 0, then the unobservable modes of the system S( ˆA, ˆC) : ˙x = ˆAx, y = ˆCx (2.22) with multiplicities included define the roots of the GCD of Ph+1,n. Then S( ˆA, ˆC) will be called the associated system of Ph+1,n and the observability matrix
Q( ˆA, ˆC) =h
Cˆt, ˆAtCˆt, . . . , ( ˆAt)n−1Cˆtit
∈ Rn(ρ−1)×n (2.23)
will be referred to as a reduced resultant of Ph+1,n.
REMARK 2.3. If Nr(Ph+1) ={0}, then the set Ph+1,n is coprime. Equivalently, if S( ˆA, ˆC) is observable,Ph+1,n is coprime.
Let now Q( ˆA, ˆC) be the corresponding reduced resultant, rank(Q( ˆA, ˆC)) < n and W , Nr(Q( ˆA, ˆC))6= {0}, k = dim{W} and W a basis matrix for W. The pencil T (s) = s W− ˆA W characterizes the setPh+1,n and it is called the associated pencil of the set. The following result forms a basis for the numerical computation of the GCD :
Corollary 2.2([59]). Let T (s) = s W− ˆA W ∈ Rn×k[s] be the associated pencil of Ph+1,n. If v(s) is the GCD of Ph+1,n and Ck(·) denotes the kth compound matrix, then
Ck(T (s)) = v(s)· Ck(W )
The essence of the numerical implementation of the Matrix Pencil algorithm is the determination of the null spaceNr(Q( ˆA, ˆC)) and its nullity n(Q( ˆA, ˆC)) = dim{Nr(Q( ˆA, ˆC))}. The computation of the approximate null space of a matrix is more important here, since we care about approximate solutions. The following result suggests one method for calculating the numerical ε-nullity of a matrix from its singular values.
Theorem 2.10 ([18]). For a matrix A ∈ Rm×n and a specified tolerance ε, the numerical ε-nullity of A is nε(A) ={number of singular values of A ≤ ε}.
The SVD can also provide a basis for the right null space. In the Matrix Pencil method the numerical ε-nullity defines the ε-GCD degree. More specifically, if k = nε(Q( ˆA, ˆC)), it can be proved [45] that, if k = 0, the set of polynomials is coprime. Otherwise, if T (s) = s W − ˆA W = s W − fW is the associated pencil and s Wa− fWa, a∈ Qk,n is any minor of maximal order such that det(Wa)6= 0, then the determinant det(s Wa− fWa) suggests an ε-GCD of degree k.
The above technique often involves the computation of many minors. Each one of these may lead to different polynomials of degree k, which form the kth compound matrix Ck(T (s)). Suppose that B is the matrix, which is formed by the coefficients of the polynomials of Ck(T (s)). Then, it can be proved [45] that, if B = Λ S Jt is the singular value decomposition of B, the polynomial, which derives from the first row of J, is the best representative of all the polynomial rows of Ck(T (s)). This polynomial can be accepted as an approximate ε-GCD of the original set, obtained by the Matrix Pencil algorithm for the specified tolerance ε.
ALGORITHM 2.1. The standard MP Algorithm.
Step 1 : Form the initial basis matrix P := Ph+1 ∈ R(h+1)×(n+1). Step 2 : Compute a base M ∈ R(n+1)×(n−ρ+1) for the right null space
of P and form M1 :={M without the last row}.
Step 3 : Compute a base ˆC ∈ R(ρ−1)×n for the left null space of M1. If rank( ˆC) > 2 then
let P := ˆC and repeat Step 1.
end if
Step 4 : Form the companion matrix ˆA and construct the observability matrix: Q( ˆA, ˆC) =h
Cˆt, ˆAtCˆt, . . . , ( ˆAt)n−1Cˆtit
∈ Rn(ρ−1)×n Step 5 : Compute the SVD of Q( ˆA, ˆC) = V Σ Wt.
Select a tolerance ε according to the singular values of Q( ˆA, ˆC).
Step 6 : Let k := nε(Q( ˆA, ˆC)) If k = 0 then
gcd = 1 quit else
Form W ∈ Rn×k from the first k columns of W . Form T (s) := sW − ˆAW ∈ Rn×k[s]
Step 7 : Compute the kth compound matrix Ck(T (s)).
Form B from the polynomial rows of Ck(T (s)).
Compute the SVD of B = Λ S Jt.
Step 8 : Select the approximate GCD vector from the first column of J.
end if
Regarding the computational complexity of the algorithm, the SVD procedure generally requires O(hn2+ 6n3) flops for the computation of the singular values and the right null space of an h× n matrix [27]. The multiplication of an n × n companion matrix with another n× q matrix demands O(nq) flops. Thus, the construction of the observability matrix Q( ˆA, ˆC) requires about O(n2ρ) flops.
Since, the computation of the kth compound matrix Ck(T (s)) may involve the evaluation of the determinant of too many minors, practically we accept the approximate solution given by anyone of them and this computation requires O(k3) flops for a k× k matrix. An optimization method can also be employed to refine the obtained solution.
In terms of numerical stability, the MP method requires two SVD calls and the construction of the observability matrix. Since the matrix ( ˆA)(k) is computed, the computation of the product ( ˆAt)(k)Cˆt = ( ˆC( ˆA)(k))t is stable because the matrix ˆC is orthonormal. For the last matrix multiplication it holds [49] :
f l( ˆC( ˆA)(k)) = ˆC( ˆA)(k)+ E, with kEk2 ≤ d2u1k ˆCk2k ˆAkk2 = d2u1k ˆAkk2
where f l(·) denotes the computed floating point number and u1 is of order of unit round off. A more detailed analysis for the numerical stability of each step of the above algorithm is presented in [45, 49, 59].
◮ The Modified Resultant Matrix Pencil method
The Modified Resultant Matrix Pencil method (MRMP) [49, 72] is an improved version of the standard MP method. The MRMP algorithm is a variation of the standard MP algorithm which is based on the modified Sylvester matrix S∗ [72] in order to construct a different GCD pencil Z(s) and specify any minor of maximal order, which gives the required GCD. This process is done symbolically by using symbolic-numeric computations. The exploitation of the properties of the modified Sylvester matrix results in the formulation of a faster and more effective algorithm based on the Matrix Pencil methodology.
ALGORITHM 2.2. The MRMP Algorithm
Step 1 : Define a basis fM for the right nullspace of the modified Sylvester matrix S∗.
Step 2 : Define the Matrix Pencil Z(s) = s fM1− fM2 for the Resultant set, where fM1 and fM2 are the matrices obtained from fM by deleting the last and the first row of fM respectively.
Step 3 : Compute any non-zero minor determinant d(s) of Z(s) and thus gcd := d(s).
The MRMP method requires [49, 72] :
O
(n + p)3
2 log2(n)− 1 3
+ (n + p)2(2m log2n + p) + 12k(n + p)2
flops, where k is the number of the calls of the SVD step. The computed GCD is the exact GCD of a slightly perturbed set of the initial polynomials. The final error is E = E1+ E2, [49, 72] with
kE1kF ≤ ϕ(n) u kSkF and kE2kF ≤
ϕ(n) + c(h, n) + c(h, n) ϕ(n) u
ukSkF
where u is the unit round off error, ϕ(n) is a slowly growing function of n [18] and c(h, n) is a constant depending on h, n.