Status: Accepted
Owner: smi...@gmail.com
Labels: Type-Defect Priority-Medium NeedsReview smichr
New issue 2218 by smi...@gmail.com: Derivative issues
http://code.google.com/p/sympy/issues/detail?id=2218
There are a few issues with derivatives.
1) if something doesn't have the variable of differentiation, it shouldn't
need a _eval_derivative action to be able to return 0.
master
h[2] >>> RootOf(Poly(x**6+x+1,x),1).diff(y)
D(RootOf(x**6 + x + 1, x, domain='ZZ', index=1), y)
https://github.com/sympy/sympy/pull/134
h[1] >>> RootOf(Poly(x**6+x+1,x),1).diff(y)
0
2) there is insufficient checking of Derivative input allowing errors
to "pass silently"
Master
h[1] >>> D=Derivative
h[1] >>> D(x,2,x) # bad input
D(x, x)
h[2] >>> D(y,x,2,x) # misinterpreted input (should have x,x,x)
D(y, x, x)
https://github.com/sympy/sympy/pull/134
h[1] >>> D(x,2,x)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "sympy\core\function.py", line 521, in __new__
raise ValueError('Derivative expects Symbol [, Integer] args but
got %s, %s'
% (s, count))
ValueError: Derivative expects Symbol [, Integer] args but got 2, x
h[1] >>> D(y,x,2,x)
D(y, x, x, x)
These can be reviewed for commiting at
[ https://github.com/sympy/sympy/pull/134 ]
--
You received this message because you are subscribed to the Google Groups
"sympy-patches" group.
To post to this group, send email to sympy-patches@googlegroups.com.
To unsubscribe from this group, send email to
sympy-patches+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/sympy-patches?hl=en.