How to determine order and time step size of ode15i

3 visualizaciones (últimos 30 días)
Gautam
Gautam el 30 de Sept. de 2014
Respondida: Mike Hosea el 1 de Oct. de 2014
Hi,
I'm solving a DAE using ode15i. I'm wondering if it is possible to extract the time step size and the order of the BDF formula that the ode15i used to integrate the DAE.
Thanks, -Gautam.

Respuestas (1)

Mike Hosea
Mike Hosea el 1 de Oct. de 2014
ODE15i is variable-step and variable-order, so "the" step size and "the" order used would each be sequences as long as the number of steps. You can supply an output function to be called after each time step. It could store the previous step's t value as a persistent and calculate the step size. Or you can make the TSPAN a two-element vector (in which case the first output t will be the t-values at each time step, so the step size diff(t)). Off-hand I can't think how to get at the sequence of orders used.

Categorías

Más información sobre Ordinary Differential Equations en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by