13.01.2013 Views

sundialsTB, a Matlab Interface to SUNDIALS - Site Index Page ...

sundialsTB, a Matlab Interface to SUNDIALS - Site Index Page ...

sundialsTB, a Matlab Interface to SUNDIALS - Site Index Page ...

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.

If quadratures were computed (see CVodeSetOptions), CVode will return their<br />

values at T in the vec<strong>to</strong>r YQ.<br />

If sensitivity calculations were enabled (see CVodeSetOptions), CVode will<br />

return their values at T in the matrix YS.<br />

On return, STATUS is one of the following:<br />

0: CVode succeeded and no roots were found.<br />

1: CVode succeded and returned at ts<strong>to</strong>p.<br />

2: CVode succeeded, and found one or more roots.<br />

-1: Illegal attempt <strong>to</strong> call before CVodeMalloc<br />

-2: One of the inputs <strong>to</strong> CVode is illegal. This includes the situation<br />

when a component of the error weight vec<strong>to</strong>rs becomes &lt; 0 during internal<br />

time-stepping.<br />

-4: The solver <strong>to</strong>ok mxstep internal steps but could not reach TOUT. The<br />

default value for mxstep is 500.<br />

-5: The solver could not satisfy the accuracy demanded by the user for some<br />

internal step.<br />

-6: Error test failures occurred <strong>to</strong>o many times (MXNEF = 7) during one internal<br />

time step<br />

or occurred with |h| = hmin.<br />

-7: Convergence test failures occurred <strong>to</strong>o many times (MXNCF = 10) during one<br />

internal time step or occurred with |h| = hmin.<br />

-9: The linear solver’s setup routine failed in an unrecoverable manner.<br />

-10: The linear solver’s solve routine failed in an unrecoverable manner.<br />

See also CVodeSetOptions, CVodeGetstats<br />

Purpose<br />

CVodeB integrates the backward ODE.<br />

Synopsis<br />

CVodeB<br />

function [status,t,yB,varargout] = CVodeB(<strong>to</strong>ut,itask)<br />

Description<br />

CVodeB integrates the backward ODE.<br />

Usage: [STATUS, T, YB] = CVodeB ( TOUT, ITASK )<br />

[STATUS, T, YB, YQB] = CVodeB ( TOUT, ITASK )<br />

If ITASK is ’Normal’, then the solver integrates from its current internal<br />

T value <strong>to</strong> a point at or beyond TOUT, then interpolates <strong>to</strong> T = TOUT and returns<br />

YB(TOUT). If ITASK is ’OneStep’, then the solver takes one internal time step<br />

and returns in YB the solution at the new internal time. In this case, TOUT<br />

is used only during the first call <strong>to</strong> CVodeB <strong>to</strong> determine the direction of<br />

integration and the rough scale of the problem. In either case, the time<br />

reached by the solver is returned in T.<br />

11

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

Saved successfully!

Ooh no, something went wrong!