Added lcm for polynomials.