
lcm - least common multiple of polynomials

Calling sequence:
lcm(poly ...)
lcm(expr ...)

Parameter:
poly   --  polynomial
expr   --  expression

Overloading:

all

Summary:

lcm calculates the least common multiple of any number of polynomials. The
polynomials may either have the rationals, a residue class ring IntMod(p)
with a prime number p or a domain as their coefficient ring. If the coefficient
ring is a domain then the same conditions as with the function gcd apply.

The arguments of lcm may be either polynomials or expressions. Expressions
are converted into polynomials (see function poly). lcm returns FAIL if it is
not possible to convert an expression into a polynomial.

>>  lcm(x^3 - y^3, x^2 - y^2);

      -x^4 - x^3*y + x*y^3 + y^4

>>  a:= poly(x^2 - y^2, [x,y], IntMod(17)):
    b:= poly(x^2 - 2*x*y + y^2, [x,y], IntMod(17)):
    lcm(a, b);

      poly(x^3 - x^2*y - x*y^2 + y^3, [x, y], IntMod(17))

See also:  content , gcd, ilcm, poly

