Updates:
Summary: leading_monom is incorrect
Comment #1 on issue 1647 by smichr: leading_monom is incorrect
http://code.google.com/p/sympy/issues/detail?id=1647
It appears that the problem comes when the new polynomial is made by adding:
p: Poly(y**4 + 11*y**2 - 6*y, y, x, order='grevlex')
p leading monom: (4, 0)
q: Poly(-6*y**3, y, x, order='grevlex')
q leading monom: (3, 0)
p+q: Poly(-6*y**3 + y**4 + 11*y**2 - 6*y, y, x, order='grevlex')
p+q leading monom: (3, 0)
That's right (if the ordering is right) but the ordering is wrong so the
answer is
wrong. If we construct the polynomial without addition then we get the
right answer:
>>> Poly(-6*y**3 + y**4 + 11*y**2 - 6*y, y, x, order='grevlex')
Poly(y**4 - 6*y**3 + 11*y**2 - 6*y, y, x, order='grevlex')
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sympy-issues" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sympy-issues?hl=en
-~----------~----~----~----~------~----~------~--~---