hide long namesshow long names
hide short namesshow short names
Integer type:  int32  int64  nag_int  show int32  show int32  show int64  show int64  show nag_int  show nag_int

PDF version (NAG web site, 64-bit version, 64-bit version)
Chapter Contents
Chapter Introduction
NAG Toolbox

NAG Toolbox: nag_ode_ivp_stiff_sparjac_diag (d02nx)

Purpose

nag_ode_ivp_stiff_sparjac_diag (d02nx) is an optional output function which you may call, on exit from an integrator in sub-chapter D02M–N, if sparse matrix linear algebra has been selected.

Syntax

[liwreq, liwusd, lrwreq, lrwusd, nlu, nnz, ngp, isplit, igrow, nblock] = d02nx(icall, lblock, inform)
[liwreq, liwusd, lrwreq, lrwusd, nlu, nnz, ngp, isplit, igrow, nblock] = nag_ode_ivp_stiff_sparjac_diag(icall, lblock, inform)

Description

nag_ode_ivp_stiff_sparjac_diag (d02nx) permits you to examine the various outputs from the sparse linear algebra functions called by the integrator.

References

See the D02M–N sub-chapter Introduction.

Parameters

Compulsory Input Parameters

1:     icall – int64int32nag_int scalar
Indicates whether or not all output parameters have been set during the call to the integrator. If so, that is, if the integrator returned with ifail = 0ifail=0 or 1212, then icall must be set to 00. Otherwise icall must be set to 11, indicating that integration did not take place due to lack of space in arrays wkjac and jacpvt, and only liwreq, liwusd, lrwreq, lrwusd have been set.
2:     lblock – logical scalar
The value used for the parameter lblock when calling nag_ode_ivp_stiff_sparjac_setup (d02nu).
3:     inform(2323) – int64int32nag_int array
Contains information supplied by the integrator.

Optional Input Parameters

None.

Input Parameters Omitted from the MATLAB Interface

None.

Output Parameters

1:     liwreq – int64int32nag_int scalar
The length of the integer workspace jacpvt reserved for the sparse matrix functions.
2:     liwusd – int64int32nag_int scalar
The length of the integer workspace jacpvt actually used by the sparse matrix functions.
3:     lrwreq – int64int32nag_int scalar
The length of the double workspace wkjac reserved for the sparse matrix functions.
4:     lrwusd – int64int32nag_int scalar
The length of the double workspace wkjac actually used by the sparse matrix functions.
5:     nlu – int64int32nag_int scalar
The number of LULU decompositions done during the integration.
6:     nnz – int64int32nag_int scalar
The number of nonzeros in the Jacobian.
7:     ngp – int64int32nag_int scalar
The number of fcn or resid calls needed to form the Jacobian.
8:     isplit – int64int32nag_int scalar
An appropriate value for the parameter isplit when calling nag_ode_ivp_stiff_sparjac_setup (d02nu) for subsequent runs of similar problems.
9:     igrow – int64int32nag_int scalar
An estimate of the growth of the elements encountered during the last LULU decomposition performed. If the actual estimate exceeds the largest possible integer value for the machine being used (see nag_machine_integer_max (x02bb)) igrow is set to the value returned by nag_machine_integer_max (x02bb).
10:   nblock – int64int32nag_int scalar
If lblock = truelblock=true, nblock contains the number of diagonal blocks in the Jacobian matrix permuted to block lower triangular form. If nblock = 1nblock=1 then on subsequent runs of a similar problem lblock should be set to false in the call to nag_ode_ivp_stiff_sparjac_setup (d02nu).
If lblock = falselblock=false, nblock = 1nblock=1.

Error Indicators and Warnings

None.

Accuracy

Not applicable.

Further Comments

The output from nag_ode_ivp_stiff_sparjac_diag (d02nx), in particular the values of liwreq, liwusd, lrwreq, lrwusd, isplit and igrow, should be used to determine appropriate values for the parameters of the setup function nag_ode_ivp_stiff_sparjac_setup (d02nu) on further calls to the integrator for the same or similar problems.

Example

function nag_ode_ivp_stiff_sparjac_diag_example
icall = int64(0);
lblock = true;
inform = [int64(55);136;16;4;4;78;8264206;3;8;100;150;29;71;16;7;3;73;1108;1;448693;8090947;8183732;8185508];
[liwreq, liwusd, lrwreq, lrwusd, nlu, nz, ngp, isplit, igrow, nblock] = ...
    nag_ode_ivp_stiff_sparjac_diag(icall, lblock, inform)
 

liwreq =

                  100


liwusd =

                  150


lrwreq =

                   29


lrwusd =

                   71


nlu =

                   16


nz =

                    7


ngp =

                    3


isplit =

                   73


igrow =

                 1108


nblock =

                    1


function d02nx_example
icall = int64(0);
lblock = true;
inform = [int64(55);136;16;4;4;78;8264206;3;8;100;150;29;71;16;7;...
          3;73;1108;1;448693;8090947;8183732;8185508];
[liwreq, liwusd, lrwreq, lrwusd, nlu, nz, ngp, isplit, igrow, nblock] = ...
          d02nx(icall, lblock, inform)
 

liwreq =

                  100


liwusd =

                  150


lrwreq =

                   29


lrwusd =

                   71


nlu =

                   16


nz =

                    7


ngp =

                    3


isplit =

                   73


igrow =

                 1108


nblock =

                    1



PDF version (NAG web site, 64-bit version, 64-bit version)
Chapter Contents
Chapter Introduction
NAG Toolbox

© The Numerical Algorithms Group Ltd, Oxford, UK. 2009–2013