naginterfaces.library.matop.real_​gen_​matrix_​actexp_​rcomm

naginterfaces.library.matop.real_gen_matrix_actexp_rcomm(irevcm, b, t, b2, x, y, p, r, z, comm, tr=0.0)[source]

real_gen_matrix_actexp_rcomm computes the action of the matrix exponential , on the matrix , where is a real matrix, is a real matrix and is a real scalar. It uses reverse communication for evaluating matrix products, so that the matrix is not accessed explicitly.

For full information please refer to the NAG Library document for f01gb

https://support.nag.com/numeric/nl/nagdoc_30.3/flhtml/f01/f01gbf.html

Parameters
irevcmint

On initial entry: must be set to .

bfloat, ndarray, shape , modified in place

On initial entry: the matrix .

On intermediate exit: if , contains the matrix .

On intermediate entry: must not be changed.

On final exit: the matrix .

tfloat

The scalar .

b2float, ndarray, shape , modified in place

On initial entry: need not be set.

On intermediate entry: if , must contain .

On final exit: the array is undefined.

xfloat, ndarray, shape , modified in place

On initial entry: need not be set.

On intermediate exit: if , contains the current matrix .

On intermediate entry: if , must contain .

On final exit: the array is undefined.

yfloat, ndarray, shape , modified in place

On initial entry: need not be set.

On intermediate exit: if , contains the current matrix .

On intermediate entry: if , must contain .

On final exit: the array is undefined.

pfloat, ndarray, shape , modified in place

On initial entry: need not be set.

On intermediate entry: if , must contain .

On final exit: the array is undefined.

rfloat, ndarray, shape , modified in place

On initial entry: need not be set.

On intermediate entry: if , must contain .

On final exit: the array is undefined.

zfloat, ndarray, shape , modified in place

On initial entry: need not be set.

On intermediate exit: if or , contains the vector .

On intermediate entry: must not be changed.

On final exit: the array is undefined.

commdict, communication object, modified in place

Communication structure.

On initial entry: need not be set.

trfloat, optional

The trace of . If this is not available then any number can be supplied ( is a reasonable default); however, in the trivial case, , the result is immediately returned in the first row of . See Further Comments.

Returns
irevcmint

On intermediate exit: , , , or . The calling program must:

  1. if : evaluate , where is an matrix, and store the result in ;

    if : evaluate , where and are matrices, and store the result in ;

    if : evaluate and store the result in ;

    if : evaluate and store the result in ;

    if : evaluate and store the result in .

  2. call real_gen_matrix_actexp_rcomm again with all other parameters unchanged.

On final exit: .

Raises
NagValueError
(errno )

On initial entry, .

Constraint: .

(errno )

On initial entry, .

Constraint: .

(errno )

On intermediate re-entry, .

Constraint: , , , or .

(errno )

On initial entry, .

Constraint: .

Warns
NagAlgorithmicWarning
(errno )

has been computed using an IEEE double precision Taylor series, although the arithmetic precision is higher than IEEE double precision.

Notes

is computed using the algorithm described in Al–Mohy and Higham (2011) which uses a truncated Taylor series to compute the without explicitly forming .

The algorithm does not explicity need to access the elements of ; it only requires the result of matrix multiplications of the form or . A reverse communication interface is used, in which control is returned to the calling program whenever a matrix product is required.

References

Al–Mohy, A H and Higham, N J, 2011, Computing the action of the matrix exponential, with an application to exponential integrators, SIAM J. Sci. Statist. Comput. (33(2)), 488-511

Higham, N J, 2008, Functions of Matrices: Theory and Computation, SIAM, Philadelphia, PA, USA