python - Evaluation of sympy.function containing a NumPy function -


my problem following code doesn't evaluate function f

class f(sympy.function):     @staticmethod     def _imp_(x):         return numpy.sin(x)  # shows f(0.1)          # return sympy.sin(x)  # shows 0.0998334166468282  print f(0.1) 

numerically when use inside _imp_ function numpy procedures. works when use sympy only. wrong @ here?

there nothing wrong.

the precision due floating point numbers.

check here , here ,where can set precision.


Comments

Popular posts from this blog

java - Incorrect order of records in M-M relationship in hibernate -

command line - Use qwinsta in PowerShell ISE -

php - I want to create a website for polls/survey like this http://www.poll-maker.com/ -