|
Calling Sequence
|
|
GCD(F, G, vars)
GCD(F, G, vars, options)
|
|
Parameters
|
|
F
|
-
|
polynom({numeric,complex(numeric)})
|
G
|
-
|
polynom({numeric,complex(numeric)})
|
vars
|
-
|
a set or list of variables
|
|
|
|
|
Options
|
|
|
if provided, the command returns where d is the gcd, and u and v are the cofactors such that and .
|
|
if provided, exact gcd computation will not be attempted
|
|
if given then a post-processing step is done on the output, using Optimization[NLPSolve] to return an approximate gcd with smaller backward error. Optionally, it can be given as optimize=list with a list of extra options to be passed to optimization.
|
|
|
Description
|
|
•
|
After some basic preprocessing to handle exact cases, the numerical gcd of F and G is computed by projecting to the univariate case to determine the degree of the approximate GCD, then the GCD cofactors are computed from the low rank approximation of the generalized SylvesterMatrix. Finally, the GCD is computed with a least-squares polynomial division.
|
•
|
This command will work on univariate polynomials, but there are several other options for the univariate case in the SNAP package.
|
|
|
Examples
|
|
>
|
|
>
|
|
| (1) |
| (2) |
>
|
|
| (3) |
>
|
|
| (4) |
>
|
|
GCD: approximate GCD inputs of total degrees 5 and 5 in [x, y]
GCD: approximate GCD determined with an error of 7.484964e-10
| |
| (5) |
>
|
|
| (6) |
>
|
|
>
|
|
GCD: approximate GCD inputs of total degrees 5 and 5 in [x, y]
GCD: approximate GCD determined with an error of 1.258109e-04
| |
| (8) |
>
|
|
| (9) |
>
|
|
|
|
References
|
|
|
Gao, S.; Kaltofen, E.; May, J.; Yang, Z.; and Zhi, L. "Approximate factorization of multivariate polynomials via differential equations." Proceedings of the 2004 International Symposium on Symbolic and Algebraic Computation (ISSAC 2004), pp. 167-174. Ed. J. Guitierrez. ACM Press, 2004.
|
|
|
Compatibility
|
|
•
|
The PolynomialTools:-Approximate:-GCD command was introduced in Maple 2021.
|
|
|
|