SUBROUTINE ZGGEVX( BALANC, JOBVL, JOBVR, SENSE, N, A, LDA, B, LDB, * ALPHA, BETA, VL, LDVL, VR, LDVR, ILO, IHI, LSCALE, RSCALE, ABNRM, * BBNRM, RCONDE, RCONDV, WORK, LWORK, RWORK, IWORK, BWORK, INFO) CHARACTER * 1 BALANC, JOBVL, JOBVR, SENSE DOUBLE COMPLEX A(LDA,*), B(LDB,*), ALPHA(*), BETA(*), VL(LDVL,*), VR(LDVR,*), WORK(*) INTEGER N, LDA, LDB, LDVL, LDVR, ILO, IHI, LWORK, INFO INTEGER IWORK(*) LOGICAL BWORK(*) DOUBLE PRECISION ABNRM, BBNRM DOUBLE PRECISION LSCALE(*), RSCALE(*), RCONDE(*), RCONDV(*), RWORK(*) SUBROUTINE ZGGEVX_64( BALANC, JOBVL, JOBVR, SENSE, N, A, LDA, B, * LDB, ALPHA, BETA, VL, LDVL, VR, LDVR, ILO, IHI, LSCALE, RSCALE, * ABNRM, BBNRM, RCONDE, RCONDV, WORK, LWORK, RWORK, IWORK, BWORK, * INFO) CHARACTER * 1 BALANC, JOBVL, JOBVR, SENSE DOUBLE COMPLEX A(LDA,*), B(LDB,*), ALPHA(*), BETA(*), VL(LDVL,*), VR(LDVR,*), WORK(*) INTEGER*8 N, LDA, LDB, LDVL, LDVR, ILO, IHI, LWORK, INFO INTEGER*8 IWORK(*) LOGICAL*8 BWORK(*) DOUBLE PRECISION ABNRM, BBNRM DOUBLE PRECISION LSCALE(*), RSCALE(*), RCONDE(*), RCONDV(*), RWORK(*)
SUBROUTINE GGEVX( BALANC, JOBVL, JOBVR, SENSE, [N], A, [LDA], B, * [LDB], ALPHA, BETA, VL, [LDVL], VR, [LDVR], ILO, IHI, LSCALE, * RSCALE, ABNRM, BBNRM, RCONDE, RCONDV, [WORK], [LWORK], [RWORK], * [IWORK], [BWORK], [INFO]) CHARACTER(LEN=1) :: BALANC, JOBVL, JOBVR, SENSE COMPLEX(8), DIMENSION(:) :: ALPHA, BETA, WORK COMPLEX(8), DIMENSION(:,:) :: A, B, VL, VR INTEGER :: N, LDA, LDB, LDVL, LDVR, ILO, IHI, LWORK, INFO INTEGER, DIMENSION(:) :: IWORK LOGICAL, DIMENSION(:) :: BWORK REAL(8) :: ABNRM, BBNRM REAL(8), DIMENSION(:) :: LSCALE, RSCALE, RCONDE, RCONDV, RWORK SUBROUTINE GGEVX_64( BALANC, JOBVL, JOBVR, SENSE, [N], A, [LDA], B, * [LDB], ALPHA, BETA, VL, [LDVL], VR, [LDVR], ILO, IHI, LSCALE, * RSCALE, ABNRM, BBNRM, RCONDE, RCONDV, [WORK], [LWORK], [RWORK], * [IWORK], [BWORK], [INFO]) CHARACTER(LEN=1) :: BALANC, JOBVL, JOBVR, SENSE COMPLEX(8), DIMENSION(:) :: ALPHA, BETA, WORK COMPLEX(8), DIMENSION(:,:) :: A, B, VL, VR INTEGER(8) :: N, LDA, LDB, LDVL, LDVR, ILO, IHI, LWORK, INFO INTEGER(8), DIMENSION(:) :: IWORK LOGICAL(8), DIMENSION(:) :: BWORK REAL(8) :: ABNRM, BBNRM REAL(8), DIMENSION(:) :: LSCALE, RSCALE, RCONDE, RCONDV, RWORK
void zggevx(char balanc, char jobvl, char jobvr, char sense, int n, doublecomplex *a, int lda, doublecomplex *b, int ldb, doublecomplex *alpha, doublecomplex *beta, doublecomplex *vl, int ldvl, doublecomplex *vr, int ldvr, int *ilo, int *ihi, double *lscale, double *rscale, double *abnrm, double *bbnrm, double *rconde, double *rcondv, int *info);
void zggevx_64(char balanc, char jobvl, char jobvr, char sense, long n, doublecomplex *a, long lda, doublecomplex *b, long ldb, doublecomplex *alpha, doublecomplex *beta, doublecomplex *vl, long ldvl, doublecomplex *vr, long ldvr, long *ilo, long *ihi, double *lscale, double *rscale, double *abnrm, double *bbnrm, double *rconde, double *rcondv, long *info);
Optionally, it also computes a balancing transformation to improve the conditioning of the eigenvalues and eigenvectors (ILO, IHI, LSCALE, RSCALE, ABNRM, and BBNRM), reciprocal condition numbers for the eigenvalues (RCONDE), and reciprocal condition numbers for the right eigenvectors (RCONDV).
A generalized eigenvalue for a pair of matrices (A,B) is a scalar lambda or a ratio alpha/beta = lambda, such that A - lambda*B is singular. It is usually represented as the pair (alpha,beta), as there is a reasonable interpretation for beta=0, and even for both being zero.
The right eigenvector v(j) corresponding to the eigenvalue lambda(j) of (A,B) satisfies
A * v(j) = lambda(j) * B * v(j) .
The left eigenvector u(j) corresponding to the eigenvalue lambda(j) of (A,B) satisfies
u(j)**H * A = lambda(j) * u(j)**H * B.
where u(j)**H is the conjugate-transpose of u(j).
Note: the quotient ALPHA(j)/BETA(j) ) may easily over- or underflow, and BETA(j) may even be zero. Thus, the user should avoid naively computing the ratio ALPHA/BETA. However, ALPHA will be always less than and usually comparable with norm(A) in magnitude, and BETA always less than and usually comparable with norm(B).
If LWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.