NAG Library Function Document

nag_complex_sparse_eigensystem_monit (f12asc)

Note: this function uses optional parameters to define choices in the problem specification. If you wish to use default settings for all of the optional parameters, then the option setting function nag_complex_sparse_eigensystem_option (f12arc) need not be called. If, however, you wish to reset some or all of the settings please refer to Section 11 in nag_complex_sparse_eigensystem_option (f12arc) for a detailed description of the specification of the optional parameters.

1Purpose

nag_complex_sparse_eigensystem_monit (f12asc) can be used to return additional monitoring information during computation. It is in a suite of functions consisting of nag_complex_sparse_eigensystem_init (f12anc), nag_complex_sparse_eigensystem_iter (f12apc), nag_complex_sparse_eigensystem_sol (f12aqc), nag_complex_sparse_eigensystem_option (f12arc) and nag_complex_sparse_eigensystem_monit (f12asc).

2Specification

 #include #include
 void nag_complex_sparse_eigensystem_monit (Integer *niter, Integer *nconv, Complex ritz[], Complex rzest[], const Integer icomm[], const Complex comm[])

3Description

The suite of functions is designed to calculate some of the eigenvalues, $\lambda$, (and optionally the corresponding eigenvectors, $x$) of a standard complex eigenvalue problem $Ax=\lambda x$, or of a generalized complex eigenvalue problem $Ax=\lambda Bx$ of order $n$, where $n$ is large and the coefficient matrices $A$ and $B$ are sparse and complex. The suite can also be used to find selected eigenvalues/eigenvectors of smaller scale dense complex problems.
On an intermediate exit from nag_complex_sparse_eigensystem_iter (f12apc) with ${\mathbf{irevcm}}=4$, nag_complex_sparse_eigensystem_monit (f12asc) may be called to return monitoring information on the progress of the Arnoldi iterative process. The information returned by nag_complex_sparse_eigensystem_monit (f12asc) is:
 – the number of the current Arnoldi iteration; – the number of converged eigenvalues at this point; – the converged eigenvalues; – the error bounds on the converged eigenvalues.
nag_complex_sparse_eigensystem_monit (f12asc) does not have an equivalent function from the ARPACK package which prints various levels of detail of monitoring information through an output channel controlled via an argument value (see Lehoucq et al. (1998) for details of ARPACK routines). nag_complex_sparse_eigensystem_monit (f12asc) should not be called at any time other than immediately following an ${\mathbf{irevcm}}=4$ return from nag_complex_sparse_eigensystem_iter (f12apc).
Lehoucq R B (2001) Implicitly restarted Arnoldi methods and subspace iteration SIAM Journal on Matrix Analysis and Applications 23 551–562
Lehoucq R B and Scott J A (1996) An evaluation of software for computing eigenvalues of sparse nonsymmetric matrices Preprint MCS-P547-1195 Argonne National Laboratory
Lehoucq R B and Sorensen D C (1996) Deflation techniques for an implicitly restarted Arnoldi iteration SIAM Journal on Matrix Analysis and Applications 17 789–821
Lehoucq R B, Sorensen D C and Yang C (1998) ARPACK Users' Guide: Solution of Large-scale Eigenvalue Problems with Implicitly Restarted Arnoldi Methods SIAM, Philidelphia

5Arguments

1:    $\mathbf{niter}$Integer *Output
On exit: the number of the current Arnoldi iteration.
2:    $\mathbf{nconv}$Integer *Output
On exit: the number of converged eigenvalues so far.
3:    $\mathbf{ritz}\left[\mathit{dim}\right]$ComplexOutput
Note: the dimension, dim, of the array ritz must be at least ${\mathbf{ncv}}$ (see nag_complex_sparse_eigensystem_init (f12anc)).
On exit: the first nconv locations of the array ritz contain the converged approximate eigenvalues.
4:    $\mathbf{rzest}\left[\mathit{dim}\right]$ComplexOutput
Note: the dimension, dim, of the array rzest must be at least ${\mathbf{ncv}}$ (see nag_complex_sparse_eigensystem_init (f12anc)).
On exit: the first nconv locations of the array rzest contain the complex Ritz estimates on the converged approximate eigenvalues.
5:    $\mathbf{icomm}\left[\mathit{dim}\right]$const IntegerCommunication Array
Note: the dimension, dim, of the array icomm must be at least $\mathrm{max}\phantom{\rule{0.125em}{0ex}}\left(1,{\mathbf{licomm}}\right)$, where licomm is passed to the setup function  (see nag_complex_sparse_eigensystem_init (f12anc)).
On entry: the array icomm output by the preceding call to nag_complex_sparse_eigensystem_iter (f12apc).
6:    $\mathbf{comm}\left[\mathit{dim}\right]$const ComplexCommunication Array
Note: the dimension, dim, of the array comm must be at least $\mathrm{max}\phantom{\rule{0.125em}{0ex}}\left(1,{\mathbf{lcomm}}\right)$, where lcomm is passed to the setup function  (see nag_complex_sparse_eigensystem_init (f12anc)).
On entry: the array comm output by the preceding call to nag_complex_sparse_eigensystem_iter (f12apc).

None.

7Accuracy

A Ritz value, $\lambda$, is deemed to have converged if the magnitude of its Ritz estimate $\le {\mathbf{Tolerance}}×\left|\lambda \right|$. The default ${\mathbf{Tolerance}}$ used is the machine precision given by nag_machine_precision (X02AJC).

8Parallelism and Performance

nag_complex_sparse_eigensystem_monit (f12asc) is not threaded in any implementation.

None.

10Example

This example solves $Ax=\lambda Bx$ in shifted-inverse mode, where $A$ and $B$ are obtained from the standard central difference discretization of the one-dimensional convection-diffusion operator $\frac{{d}^{2}u}{d{x}^{2}}+\rho \frac{du}{dx}$ on $\left[0,1\right]$, with zero Dirichlet boundary conditions. The shift, $\sigma$, is a complex number, and the operator used in the shifted-inverse iterative process is $\mathrm{OP}=\text{inv}\left(A-\sigma B\right)×B$.

10.1Program Text

Program Text (f12asce.c)

10.2Program Data

Program Data (f12asce.d)

10.3Program Results

Program Results (f12asce.r)

© The Numerical Algorithms Group Ltd, Oxford, UK. 2017