Hi,
Next time, please provide an example code so that people can do their own
experiments.
I guess you did something like:
>>> from math import sqrt
>>> from sympy.abc import *
>>> sqrt(x)
Traceback (most recent call last):
File "", line 1, in
File
When passing symbolic variables through the function i get the error
message "can't convert expression to float"
This does not happen if I pass numerical values through the function.
Any suggestions?
On Wed, 5 Jun 2019 at 06:07, Aaron Meurer wrote:
> Yes, you should replace 'math' and
Yes, you should replace 'math' and 'numpy' with 'sympy', so that the
symbolic functions are used. I also recommend using sympy.Matrix for
the symbolic expressions.
Then, if you want a numeric expression you can use with numpy, use
lambdify() to convert the SymPy expression into a numeric
I have a function that I have written, attached file, and would like to
pass theta, thetad, phi and phid through it as symbolic variables.
Therefore hoping for an output in terms of these variables that I can then
integrate. Is this possible??
--
You received this message because you are