[英]SymPy diff function on cosec(x) is returning Derivative(cosec(x),x)
Here is the code that I wrote:这是我写的代码:
print(diff("cosec(x)","x"))
The output I got is: Derivative(cosec(x), x)
我得到的 output 是: Derivative(cosec(x), x)
What is up with this and how do I actually get the derivative of cosec(x)?这是怎么回事,我如何实际得到 cosec(x) 的导数?
You should define the symbol x
:您应该定义符号x
:
x = Symbol('x')
then you can obtain the derivative as那么你可以获得导数为
diff(csc(x),x)
As you can see the name of cosecant function is csc
如您所见,余割 function 的名称是csc
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.