# HG changeset patch # User Jay Belanger # Date 1227667119 0 # Node ID 2a48557d7247efbd8d643c105eb4653c4e5d2348 # Parent ba6d5a7083212e2b2d21108e1d36ba6667fd54c5 (calcFunc-collect): Normalize the coefficients of the polynomial rather than the whole polynomial. diff -r ba6d5a708321 -r 2a48557d7247 lisp/calc/calc-alg.el --- a/lisp/calc/calc-alg.el Tue Nov 25 22:58:14 2008 +0000 +++ b/lisp/calc/calc-alg.el Wed Nov 26 02:38:39 2008 +0000 @@ -1598,8 +1598,7 @@ (defun calcFunc-collect (expr base) (let ((p (math-is-polynomial expr base 50 t))) (if (cdr p) - (math-normalize ; fix selection bug - (math-build-polynomial-expr p base)) + (math-build-polynomial-expr (mapcar 'math-normalize p) base) (car p)))) ;;; If expr is of the form "a + bx + cx^2 + ...", return the list (a b c ...),