15.11.2014 Views

MATLAB Mathematics - SERC - Index of

MATLAB Mathematics - SERC - Index of

MATLAB Mathematics - SERC - Index of

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Initial Value Problems for ODEs and DAEs<br />

There are four solvers designed for stiff problems:<br />

ode15s<br />

ode23s<br />

ode23t<br />

Variable-order solver based on the numerical differentiation<br />

formulas (NDFs). Optionally it uses the backward differentiation<br />

formulas, BDFs, (also known as Gear’s method). Like ode113,<br />

ode15s is a multistep solver. If you suspect that a problem is stiff or<br />

if ode45 failed or was very inefficient, try ode15s.<br />

Based on a modified Rosenbrock formula <strong>of</strong> order 2. Because it is a<br />

one-step solver, it may be more efficient than ode15s at crude<br />

tolerances. It can solve some kinds <strong>of</strong> stiff problems for which<br />

ode15s is not effective.<br />

An implementation <strong>of</strong> the trapezoidal rule using a “free”<br />

interpolant. Use this solver if the problem is only moderately stiff<br />

and you need a solution without numerical damping.<br />

ode23tb An implementation <strong>of</strong> TR-BDF2, an implicit Runge-Kutta formula<br />

with a first stage that is a trapezoidal rule step and a second stage<br />

that is a backward differentiation formula <strong>of</strong> order 2. Like ode23s,<br />

this solver may be more efficient than ode15s at crude tolerances.<br />

Basic ODE Solver Syntax<br />

All <strong>of</strong> the ODE solver functions, except for ode15i, share a syntax that makes<br />

it easy to try any <strong>of</strong> the different numerical methods, if it is not apparent which<br />

is the most appropriate. To apply a different method to the same problem,<br />

simply change the ODE solver function name. The simplest syntax, common to<br />

all the solver functions, is<br />

[t,y] = solver(odefun,tspan,y0,options)<br />

where solver is one <strong>of</strong> the ODE solver functions listed previously.<br />

5-7

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!