When I try using both mpmath and PyDSTool in my code, I got the following error:
Traceback (most recent call last):
File "case1_PyDSTool.py", line 137, in <module>
y0 = zeros(2,1)
TypeError: data type not understood
This also happens everywhere when an array is initiated. I am using both findroot and Radau integrator for my program :
from mpmath import sqrt,mpf,,mp,linspace,zeros,exp,log,findroot
from PyDSTool import *
I noticed that the error would disappear when PyDSTool was commented out. I am very new to Python so please help me out. Also, thank you Robert for all of your responses in the previous topic.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Looks like a problem in SymPy. It's not an error from PyDSTool. Are you sure you mean to use mpmath to generate your arrays? I think you'd want to use numpy. Zeros probably requires a tuple as an argument, i.e. zeros((2,1)), but try it in numpy unless you mean to have symbolic arrays.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
When I try using both mpmath and PyDSTool in my code, I got the following error:
Traceback (most recent call last):
File "case1_PyDSTool.py", line 137, in <module>
y0 = zeros(2,1)
TypeError: data type not understood
This also happens everywhere when an array is initiated. I am using both findroot and Radau integrator for my program :
from mpmath import sqrt,mpf,,mp,linspace,zeros,exp,log,findroot
from PyDSTool import *
I noticed that the error would disappear when PyDSTool was commented out. I am very new to Python so please help me out. Also, thank you Robert for all of your responses in the previous topic.
Looks like a problem in SymPy. It's not an error from PyDSTool. Are you sure you mean to use mpmath to generate your arrays? I think you'd want to use numpy. Zeros probably requires a tuple as an argument, i.e. zeros((2,1)), but try it in numpy unless you mean to have symbolic arrays.