[SciPy-User] _dop.error: failed in processing argument list for call-back fcn.

SHIHUI GUO sguo@bournemouth.ac...
Tue Feb 26 04:09:06 CST 2013

HI all,

I want to use scipy to implement an oscillator, ie. solving a secod-order
ordinary differential equation, my code is:
from scipy.integrate import ode

y0,t0 = [0, 1], 0

def fun(t, y, params):
    rou = 1
    omega = 10
    sigma = 1
    # convergence rate, ie, lambda
    conrate = 10
    temp = -conrate*((y[0]^2+y[1]^2)/rou^2-sigma)
    dy = temp*y[0] - omega*y[1]
    ddy = omega*y[0] + temp*y[1]
    return [dy, ddy]

test = ode(fun).set_integrator('dopri5')
test.set_initial_value(y0, t0)
t1 = 10
dt = 0.1

while test.successful() and test.t<t1:
    print test.t, test.yy

The error says:
_dop.error: failed in processing argument list for call-back fcn.
File "/home/shepherd/python/research/testode.py", line 23, in <module>
line 333, in integrate
  self.f_params, self.jac_params)
line 827, in run
  tuple(self.call_args) + (f_params,)))

Previously I use the ubuntu default python, and scipy is 0.9.0. Some thread
says it is a bug and has been fixed in 0.10.0, so I switched to enthought,
now the scipy is newest version, but the error remains.

Thanks for any help.



National Center for Computer Animation
Bournemouth University
United Kingdom

BU is a Disability Two Ticks Employer and has signed up to the Mindful Employer charter. Information about the accessibility of University buildings can be found on the BU DisabledGo webpages [ http://www.disabledgo.com/en/org/bournemouth-university ]
This email is intended only for the person to whom it is addressed and may contain confidential information. If you have received this email in error, please notify the sender and delete this email, which must not be copied, distributed or disclosed to any other person.
Any views or opinions presented are solely those of the author and do not necessarily represent those of Bournemouth University or its subsidiary companies. Nor can any contract be formed on behalf of the University or its subsidiary companies via email.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-user/attachments/20130226/781204ed/attachment.html 

More information about the SciPy-User mailing list