Research Article

On Degrees of Modular Common Divisors and the Big Prime Algorithm

Algorithm 4

Big prime modular gcd algorithm with a preliminary estimate on divisor degree.
Input: non-zero polynomials .
Calculate their greatest common divisor  .
(01) Calculate , in the Euclidean domain , choose their signs
    so that and .
(02) Set and .
(03) Calculate in the Euclidean domain by (25).
(04) Set and (they are positive by our selection of signs
    for and ).
(05) Calculate the positive in the Euclidean domain .
(06) Set .
(07) Choose a prime number .
(08) Apply the reduction to calculate the modular images .
(09) Calculate in the Euclidean domain .
(10) Set .
(11) Calculate by (40) using the value of .
(12) Choose a new prime number .
(13) Apply the reduction to calculate the modular images .
(14) Calculate in the Euclidean domain .
(15) If
(16)  go to step (12).
(17) else
(18)  choose a such that the ;
(19)  call Algorithm 1 to calculate the preimage of ;
(20)  calculate in the Euclidean domain ;
(21)  set ;
(22)    if and
(23)      go to step (27);
(24)     else
(25)      set ;
(26)      go to step (12).
(27) Output the result: .