ode: numeric and power series



Sam Steingold wrote:
> Raymond Toy wrote:
>> Sam Steingold wrote:
>>> how do I solve an 1st order ODE IVP on maxima numerically?
>>
>> load(dynamics);
>>
>> There's an rk function for solving odes.  I've never used it.  "?? rk"
>> gives some info.  Looking in dynamics.mac gives an example:
>>
>>
>> results: rk(t-x^2,x,1,[t,0,8,0.1])$
>> plot2d([discrete, results]));
>>
>> Don't know if that's right or not.
> 
> runge-kutta sounds good but it has been running on my amd64 ws for 20+
> minutes now... (maxima/sbcl):
> 
> rk(dy/dx=cos(x*y),y,0,[x,0,5,0.1]);

I've never actually used rk before, but I think you should have written

rk(cos(x*y),y,0,[x,0,5,0.1]);

This runs pretty fast and seems close to the Lisp code you gave.

Ray