>>> from sympy import *
>>> x,y=symbols('x y')
>>> f=lambdify(x,y*cos(x))
>>> f(1)
0.54030230586814*y
works fine, but interchanging x and y:
>>> f=lambdify(x,x*cos(y))
>>> f(1)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<string>", line 1, in <lambda>
File "/Users/krol/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/sympy/core/expr.py", line 225, in __float__
raise TypeError("can't convert expression to float")
TypeError: can't convert expression to float
gives me a headache,
Does someone know a solution to this?
kind Regards,
Quirine
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/788a5592-1021-4082-85bb-4d71c907fb8d%40googlegroups.com.--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
To post to this group, send email to sy...@googlegroups.com.
Visit this group at http://groups.google.com/group/sympy.