Menu

#4658 factor should check that second argument is irreducible

None
open
nobody
factor (12)
5
2026-01-07
2026-01-07
No

(thanks to Barton for the example)

factor(x^3-1,x-1) => 
     factor: second argument must be a nonlinear, univariate polynomial
factor(a^2*g+a*g-a^2 , g^3-1) => division by zero
factor(a^2*g+a*g-a^2 , second(factor(g^3-1)))
     => (a*(-g+3*a+1)*(g-1))/3

factor should not only check that the second argument is nonlinear and univariate, but that it is irreducible

Tested in 5.48.1 SBCL 2.5.7

Discussion


Log in to post a comment.