lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On 16 February 2011 22:14, T T <t34www@googlemail.com> wrote:
> If you are serious about writing RK (explicit) ODE integrator with
> auto time step control, then the Dormand–Prince method with embedded
> RK 4/5 pair is the one to go for:
>
> http://en.wikipedia.org/wiki/Dormand–Prince_method
>
> See also:
>
> "A survey of the MATLAB ODE suite"
> http://www.osaka-kyoiku.ac.jp/~ashino/pdf/2651.pdf
>
> Double time step error control is not exactly the state-of-the-art any more.
>
> Cheers,
>
> Tomek
>
>

I got bored... See attached for a lua Dormand–Prince integrator...
Pretty much a verbatim copy of http://adorio-research.org/wordpress/?p=6565

Strangely, for the given parameters in the example, we get the same
result, but with only 7 iterations as oppose to 994...

Daurn.

Attachment: ode45.lua
Description: Binary data