.TH "TESTING/EIG/zdrgvx.f" 3 "Version 3.12.0" "LAPACK" \" -*- nroff -*- .ad l .nh .SH NAME TESTING/EIG/zdrgvx.f .SH SYNOPSIS .br .PP .SS "Functions/Subroutines" .in +1c .ti -1c .RI "subroutine \fBzdrgvx\fP (nsize, thresh, nin, nout, a, lda, b, ai, bi, alpha, beta, vl, vr, ilo, ihi, lscale, rscale, s, dtru, dif, diftru, work, lwork, rwork, iwork, liwork, result, bwork, info)" .br .RI "\fBZDRGVX\fP " .in -1c .SH "Function/Subroutine Documentation" .PP .SS "subroutine zdrgvx (integer nsize, double precision thresh, integer nin, integer nout, complex*16, dimension( lda, * ) a, integer lda, complex*16, dimension( lda, * ) b, complex*16, dimension( lda, * ) ai, complex*16, dimension( lda, * ) bi, complex*16, dimension( * ) alpha, complex*16, dimension( * ) beta, complex*16, dimension( lda, * ) vl, complex*16, dimension( lda, * ) vr, integer ilo, integer ihi, double precision, dimension( * ) lscale, double precision, dimension( * ) rscale, double precision, dimension( * ) s, double precision, dimension( * ) dtru, double precision, dimension( * ) dif, double precision, dimension( * ) diftru, complex*16, dimension( * ) work, integer lwork, double precision, dimension( * ) rwork, integer, dimension( * ) iwork, integer liwork, double precision, dimension( 4 ) result, logical, dimension( * ) bwork, integer info)" .PP \fBZDRGVX\fP .PP \fBPurpose:\fP .RS 4 .PP .nf ZDRGVX checks the nonsymmetric generalized eigenvalue problem expert driver ZGGEVX\&. ZGGEVX computes the generalized eigenvalues, (optionally) the left and/or right eigenvectors, (optionally) computes a balancing transformation to improve the conditioning, and (optionally) reciprocal condition numbers for the eigenvalues and eigenvectors\&. When ZDRGVX is called with NSIZE > 0, two types of test matrix pairs are generated by the subroutine DLATM6 and test the driver ZGGEVX\&. The test matrices have the known exact condition numbers for eigenvalues\&. For the condition numbers of the eigenvectors corresponding the first and last eigenvalues are also know ``exactly'' (see ZLATM6)\&. For each matrix pair, the following tests will be performed and compared with the threshold THRESH\&. (1) max over all left eigenvalue/-vector pairs (beta/alpha,l) of | l**H * (beta A - alpha B) | / ( ulp max( |beta A|, |alpha B| ) ) where l**H is the conjugate transpose of l\&. (2) max over all right eigenvalue/-vector pairs (beta/alpha,r) of | (beta A - alpha B) r | / ( ulp max( |beta A|, |alpha B| ) ) (3) The condition number S(i) of eigenvalues computed by ZGGEVX differs less than a factor THRESH from the exact S(i) (see ZLATM6)\&. (4) DIF(i) computed by ZTGSNA differs less than a factor 10*THRESH from the exact value (for the 1st and 5th vectors only)\&. Test Matrices ============= Two kinds of test matrix pairs (A, B) = inverse(YH) * (Da, Db) * inverse(X) are used in the tests: 1: Da = 1+a 0 0 0 0 Db = 1 0 0 0 0 0 2+a 0 0 0 0 1 0 0 0 0 0 3+a 0 0 0 0 1 0 0 0 0 0 4+a 0 0 0 0 1 0 0 0 0 0 5+a , 0 0 0 0 1 , and 2: Da = 1 -1 0 0 0 Db = 1 0 0 0 0 1 1 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 1+a 1+b 0 0 0 1 0 0 0 0 -1-b 1+a , 0 0 0 0 1 \&. In both cases the same inverse(YH) and inverse(X) are used to compute (A, B), giving the exact eigenvectors to (A,B) as (YH, X): YH: = 1 0 -y y -y X = 1 0 -x -x x 0 1 -y y -y 0 1 x -x -x 0 0 1 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 1, 0 0 0 0 1 , where a, b, x and y will have all values independently of each other from { sqrt(sqrt(ULP)), 0\&.1, 1, 10, 1/sqrt(sqrt(ULP)) }\&. .fi .PP .RE .PP \fBParameters\fP .RS 4 \fINSIZE\fP .PP .nf NSIZE is INTEGER The number of sizes of matrices to use\&. NSIZE must be at least zero\&. If it is zero, no randomly generated matrices are tested, but any test matrices read from NIN will be tested\&. If it is not zero, then N = 5\&. .fi .PP .br \fITHRESH\fP .PP .nf THRESH is DOUBLE PRECISION A test will count as 'failed' if the 'error', computed as described above, exceeds THRESH\&. Note that the error is scaled to be O(1), so THRESH should be a reasonably small multiple of 1, e\&.g\&., 10 or 100\&. In particular, it should not depend on the precision (single vs\&. double) or the size of the matrix\&. It must be at least zero\&. .fi .PP .br \fININ\fP .PP .nf NIN is INTEGER The FORTRAN unit number for reading in the data file of problems to solve\&. .fi .PP .br \fINOUT\fP .PP .nf NOUT is INTEGER The FORTRAN unit number for printing out error messages (e\&.g\&., if a routine returns IINFO not equal to 0\&.) .fi .PP .br \fIA\fP .PP .nf A is COMPLEX*16 array, dimension (LDA, NSIZE) Used to hold the matrix whose eigenvalues are to be computed\&. On exit, A contains the last matrix actually used\&. .fi .PP .br \fILDA\fP .PP .nf LDA is INTEGER The leading dimension of A, B, AI, BI, Ao, and Bo\&. It must be at least 1 and at least NSIZE\&. .fi .PP .br \fIB\fP .PP .nf B is COMPLEX*16 array, dimension (LDA, NSIZE) Used to hold the matrix whose eigenvalues are to be computed\&. On exit, B contains the last matrix actually used\&. .fi .PP .br \fIAI\fP .PP .nf AI is COMPLEX*16 array, dimension (LDA, NSIZE) Copy of A, modified by ZGGEVX\&. .fi .PP .br \fIBI\fP .PP .nf BI is COMPLEX*16 array, dimension (LDA, NSIZE) Copy of B, modified by ZGGEVX\&. .fi .PP .br \fIALPHA\fP .PP .nf ALPHA is COMPLEX*16 array, dimension (NSIZE) .fi .PP .br \fIBETA\fP .PP .nf BETA is COMPLEX*16 array, dimension (NSIZE) On exit, ALPHA/BETA are the eigenvalues\&. .fi .PP .br \fIVL\fP .PP .nf VL is COMPLEX*16 array, dimension (LDA, NSIZE) VL holds the left eigenvectors computed by ZGGEVX\&. .fi .PP .br \fIVR\fP .PP .nf VR is COMPLEX*16 array, dimension (LDA, NSIZE) VR holds the right eigenvectors computed by ZGGEVX\&. .fi .PP .br \fIILO\fP .PP .nf ILO is INTEGER .fi .PP .br \fIIHI\fP .PP .nf IHI is INTEGER .fi .PP .br \fILSCALE\fP .PP .nf LSCALE is DOUBLE PRECISION array, dimension (N) .fi .PP .br \fIRSCALE\fP .PP .nf RSCALE is DOUBLE PRECISION array, dimension (N) .fi .PP .br \fIS\fP .PP .nf S is DOUBLE PRECISION array, dimension (N) .fi .PP .br \fIDTRU\fP .PP .nf DTRU is DOUBLE PRECISION array, dimension (N) .fi .PP .br \fIDIF\fP .PP .nf DIF is DOUBLE PRECISION array, dimension (N) .fi .PP .br \fIDIFTRU\fP .PP .nf DIFTRU is DOUBLE PRECISION array, dimension (N) .fi .PP .br \fIWORK\fP .PP .nf WORK is COMPLEX*16 array, dimension (LWORK) .fi .PP .br \fILWORK\fP .PP .nf LWORK is INTEGER Leading dimension of WORK\&. LWORK >= 2*N*N + 2*N .fi .PP .br \fIRWORK\fP .PP .nf RWORK is DOUBLE PRECISION array, dimension (6*N) .fi .PP .br \fIIWORK\fP .PP .nf IWORK is INTEGER array, dimension (LIWORK) .fi .PP .br \fILIWORK\fP .PP .nf LIWORK is INTEGER Leading dimension of IWORK\&. LIWORK >= N+2\&. .fi .PP .br \fIRESULT\fP .PP .nf RESULT is DOUBLE PRECISION array, dimension (4) .fi .PP .br \fIBWORK\fP .PP .nf BWORK is LOGICAL array, dimension (N) .fi .PP .br \fIINFO\fP .PP .nf INFO is INTEGER = 0: successful exit < 0: if INFO = -i, the i-th argument had an illegal value\&. > 0: A routine returned an error code\&. .fi .PP .RE .PP \fBAuthor\fP .RS 4 Univ\&. of Tennessee .PP Univ\&. of California Berkeley .PP Univ\&. of Colorado Denver .PP NAG Ltd\&. .RE .PP .PP Definition at line \fB293\fP of file \fBzdrgvx\&.f\fP\&. .SH "Author" .PP Generated automatically by Doxygen for LAPACK from the source code\&.