[SciPy-User] integrate.ode sets t0 values outside of my data range

Daπid davidmenhur at gmail.com
Thu Aug 7 07:13:25 EDT 2014


On 7 August 2014 11:05, Camille <camillechambon at yahoo.fr> wrote:

> Thanks for your answer. Actually, data(t) is a sinusoidal function. Thus I
> can not extend the interpolation data linearly. I edited my question on
> StackOverflow accordingly.


Note that you are evaluating it very close to the boundary, so the
interpolation effects will not be so bad. You can check the sensibility
comparing the results with a purposefully "wrong" interpolation, like the
same linear interpolation but with the opposite slope; but I bet the
differences are going to be slim.

If you know your data is sinusoidal, you can use that to make an even
better estimation of the next value. Essentially, you need to provide the
ODE solver with a way to estimate the derivatives of your function at any
point.


/David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.scipy.org/pipermail/scipy-user/attachments/20140807/739b263e/attachment.html>


More information about the SciPy-User mailing list