Comment #7 on issue 1305 by [email protected]: sympy.roots not working for
slightly more complicated polynomials
http://code.google.com/p/sympy/issues/detail?id=1305
not sure how we should check for exact result, as the output formula is
really
unreadable ...
and check the result by subtituing and equaling to zero:
In [6]: r = roots( x**2*(a + b*(c-d)*a) + x*a*b*c/(b*d-d) + (a*d-c/d), x)
In [7]: ( x**2*(a + b*(c-d)*a) + x*a*b*c/(b*d-d) + (a*d-c/d)).subs(x,
r.values()[0])
Out[7]:
c a⋅b⋅c
a + a⋅d + a⋅b⋅(c - d) - ─ + ────────
d -d + b⋅d
but this is not an identity:
In [8]: _.expand().subs(a,1).subs(b,0).subs(c,0).subs(d,1)
Out[23]: 2
Maybe i'm doing something wrong. Maybe I've encountered a bug.
--
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
-~----------~----~----~----~------~----~------~--~---