gges(3)
π NAME π
gges β that's gges: Schur form, unblocked, bestie. That's the whole name, no notes. It's the umbrella for the four routines below and honestly the whole family ate. π
β¨ SYNOPSIS β¨
πΈ Functions
cggesπ¦
subroutine cgges (jobvsl, jobvsr, sort, selctg, n, a, lda, b, ldb, sdim,
alpha, beta, vsl, ldvsl, vsr, ldvsr, work, lwork, rwork, bwork,
info)
so CGGES is the one computing the eigenvalues, the Schur form, and β if you asked nicely β the matrix of Schur vectors, all of it for GE matrices. periodt.
dggesπ
subroutine dgges (jobvsl, jobvsr, sort, selctg, n, a, lda, b, ldb, sdim,
alphar, alphai, beta, vsl, ldvsl, vsr, ldvsr, work, lwork, bwork,
info)
same energy as above but DGGES: eigenvalues, Schur form, and optionally the matrix of Schur vectors for GE matrices. π
sggesβ
subroutine sgges (jobvsl, jobvsr, sort, selctg, n, a, lda, b, ldb, sdim,
alphar, alphai, beta, vsl, ldvsl, vsr, ldvsr, work, lwork, bwork,
info)
yup, SGGES β eigenvalues, Schur form, optionally the matrix of Schur vectors, GE matrices, you know the drill by now. β¨
zggesπ
subroutine zgges (jobvsl, jobvsr, sort, selctg, n, a, lda, b, ldb, sdim,
alpha, beta, vsl, ldvsl, vsr, ldvsr, work, lwork, rwork, bwork,
info)
and ZGGES, the last sibling: eigenvalues, Schur form, and β say it with me β optionally the matrix of Schur vectors for GE matrices. π
π«Ά Detailed Description π«Ά
bestie there is literally nothing here. like, the section exists and the content does not. it's giving "I said what I said". moving on π
π Function Documentation π
π subroutine cgges
here's the full declaration in all its glory, character for character, do not touch:
subroutine cgges (character jobvsl, character jobvsr, character sort,
external selctg, integer n, complex, dimension( lda, * ) a, integer lda,
complex, dimension( ldb, * ) b, integer ldb, integer sdim, complex,
dimension( * ) alpha, complex, dimension( * ) beta, complex, dimension(
ldvsl, * ) vsl, integer ldvsl, complex, dimension( ldvsr, * ) vsr,
integer ldvsr, complex, dimension( * ) work, integer lwork, real,
dimension( * ) rwork, logical, dimension( * ) bwork, integer info)
CGGES computes the eigenvalues, the Schur form, and, optionally, the matrix of Schur vectors for GE matrices β yes that's the tagline, and yes it goes hard. π₯
π« Purpose:
ok so, deep breath, here's what CGGES actually does:
CGGES computes, for a pair of N-by-N complex nonsymmetric matrices (A,B), the generalized eigenvalues, the generalized complex Schur form (S, T), and optionally the left and/or right Schur vectors (VSL and VSR). the way it hands you the generalized Schur factorization:
(A,B) = ( (VSL)*S*(VSR)**H, (VSL)*T*(VSR)**H )
where (VSR)**H is the conjugate-transpose of VSR. conjugate-transpose bestie, not just transpose, do not come for me. π
optionally it also orders the eigenvalues so that a selected cluster of eigenvalues appears in the leading diagonal blocks of the upper triangular matrix S and the upper triangular matrix T. the leading columns of VSL and VSR then form an unitary basis for the corresponding left and right eigenspaces (deflating subspaces). cute, right? π¦
if you only need the generalized eigenvalues, use the driver CGGEV instead β it's faster. no cap.
a generalized eigenvalue for a pair of matrices (A,B) is a scalar w or a ratio alpha/beta = w, such that A - w*B is singular. it's usually represented as the pair (alpha,beta), because there's a reasonable interpretation for beta=0, and even for both being zero. π
a pair of matrices (S,T) is in generalized complex Schur form if S and T are upper triangular and, in addition, the diagonal elements of T are non-negative real numbers. that's the whole vibe check. β
πΈ Parameters
JOBVSLβJOBVSLisCHARACTER*1, and it's literally a yes/no for the left Schur vectors:= 'N': do not compute the left Schur vectors;= 'V': compute the left Schur vectors. π
JOBVSRβJOBVSRisCHARACTER*1, same deal but for the right side:= 'N': do not compute the right Schur vectors;= 'V': compute the right Schur vectors. π
SORTβSORTisCHARACTER*1and it specifies whether or not to order the eigenvalues on the diagonal of the generalized Schur form:= 'N': eigenvalues are not ordered;= 'S': eigenvalues are ordered (seeSELCTG). π
SELCTGβSELCTGis aLOGICAL FUNCTIONof twoCOMPLEXarguments. it must be declaredEXTERNALin the calling subroutine, don't forget, bestie. ifSORT = 'N',SELCTGis not referenced. ifSORT = 'S',SELCTGis used to select eigenvalues to sort to the top left of the Schur form. an eigenvalueALPHA(j)/BETA(j)is selected ifSELCTG(ALPHA(j),BETA(j))is true.
note that a selected complex eigenvalue may no longer satisfySELCTG(ALPHA(j),BETA(j)) = .TRUE.after ordering, since ordering may change the value of complex eigenvalues (especially if the eigenvalue is ill-conditioned). in this caseINFOis set toN+2(seeINFObelow). lowkey rude of the roundoff but ok. π€
NβNisINTEGER: the order of the matricesA,B,VSL, andVSR.N >= 0. β¨AβAisCOMPLEX array, dimension(LDA, N). on entry, the first of the pair of matrices. on exit,Ahas been overwritten by its generalized Schur formS. π«ΆLDAβLDAisINTEGER: the leading dimension ofA.LDA >= max(1,N). βBβBisCOMPLEX array, dimension(LDB, N). on entry, the second of the pair of matrices. on exit,Bhas been overwritten by its generalized Schur formT. π«ΆLDBβLDBisINTEGER: the leading dimension ofB.LDB >= max(1,N). βSDIMβSDIMisINTEGER. ifSORT = 'N',SDIM = 0. ifSORT = 'S',SDIM = number of eigenvalues (after sorting) for which SELCTG is true. π¦ALPHAβALPHAisCOMPLEX array, dimension(N). that's it, that's the bullet. πBETAβBETAisCOMPLEX array, dimension(N). on exit,ALPHA(j)/BETA(j),j=1,...,N, will be the generalized eigenvalues.ALPHA(j),j=1,...,NandBETA(j),j=1,...,Nare the diagonals of the complex Schur form(A,B)output byCGGES. theBETA(j)will be non-negative real.
note: the quotientsALPHA(j)/BETA(j)may easily over- or underflow, andBETA(j)may even be zero. thus, the user should avoid naively computing the ratioalpha/beta. however,ALPHAwill be always less than and usually comparable withnorm(A)in magnitude, andBETAalways less than and usually comparable withnorm(B). like, don't just divide, bestie, that's the whole warning. π
VSLβVSLisCOMPLEX array, dimension(LDVSL,N). ifJOBVSL = 'V',VSLwill contain the left Schur vectors. not referenced ifJOBVSL = 'N'. πΈLDVSLβLDVSLisINTEGER: the leading dimension of the matrixVSL.LDVSL >= 1, and ifJOBVSL = 'V',LDVSL >= N. β¨VSRβVSRisCOMPLEX array, dimension(LDVSR,N). ifJOBVSR = 'V',VSRwill contain the right Schur vectors. not referenced ifJOBVSR = 'N'. πΈLDVSRβLDVSRisINTEGER: the leading dimension of the matrixVSR.LDVSR >= 1, and ifJOBVSR = 'V',LDVSR >= N. β¨WORKβWORKisCOMPLEX array, dimension(MAX(1,LWORK)). on exit, ifINFO = 0,WORK(1)returns the optimalLWORK. πLWORKβLWORKisINTEGER: the dimension of the arrayWORK.LWORK >= max(1,2*N). for good performance,LWORKmust generally be larger. ifLWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of theWORKarray, returns this value as the first entry of theWORKarray, and no error message related toLWORKis issued byXERBLA. sneaky but legal. πRWORKβRWORKisREAL array, dimension(8*N). π«BWORKβBWORKisLOGICAL array, dimension(N). not referenced ifSORT = 'N'. πINFOβINFOisINTEGER, and this is the receipts section, so listen up:= 0: successful exit π< 0: ifINFO = -i, the i-th argument had an illegal value.=1,...,N: the QZ iteration failed.(A,B)are not in Schur form, butALPHA(j)andBETA(j)should be correct forj=INFO+1,...,N.> N:=N+1: other than QZ iteration failed inCHGEQZ=N+2: after reordering, roundoff changed values of some complex eigenvalues so that leading eigenvalues in the Generalized Schur form no longer satisfySELCTG=.TRUE.this could also be caused due to scaling.=N+3: reordering failed inCTGSEN. π
π Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Definition at line 267 of file cgges.f. π
π subroutine dgges
subroutine dgges (character jobvsl, character jobvsr, character sort,
external selctg, integer n, double precision, dimension( lda, * ) a,
integer lda, double precision, dimension( ldb, * ) b, integer ldb,
integer sdim, double precision, dimension( * ) alphar, double precision,
dimension( * ) alphai, double precision, dimension( * ) beta, double
precision, dimension( ldvsl, * ) vsl, integer ldvsl, double precision,
dimension( ldvsr, * ) vsr, integer ldvsr, double precision, dimension( *
) work, integer lwork, logical, dimension( * ) bwork, integer info)
DGGES computes the eigenvalues, the Schur form, and, optionally, the matrix of Schur vectors for GE matrices β yes, again, and yes, still iconic. π
π« Purpose:
ok so DGGES β and hold that thought, because there's more coming... π¦
Okay so, picking up the DGGES saga right where we left it: DGGES is the icon that computes, for a pair of N-by-N real nonsymmetric matrices (A,B), the generalized eigenvalues, the generalized real Schur form (S,T), and optionally the left and/or right matrices of Schur vectors (VSL and VSR). This gives the generalized Schur factorization:
(A,B) = ( (VSL)*S*(VSR)**T, (VSL)*T*(VSR)**T )
Optionally, it also orders the eigenvalues so that a selected cluster of eigenvalues appears in the leading diagonal blocks of the upper quasi-triangular matrix S and the upper triangular matrix T. The leading columns of VSL and VSR then form an orthonormal basis for the corresponding left and right eigenspaces (deflating subspaces). Slay.
If you only need the generalized eigenvalues, use the driver DGGEV instead β it's faster. Noted, bestie.
A generalized eigenvalue for a pair of matrices (A,B) is a scalar w or a ratio alpha/beta = w, such that A - w*B is singular. It's usually represented as the pair (alpha,beta), because there's a reasonable interpretation for beta=0 or both being zero. Iconic.
A pair of matrices (S,T) is in generalized real Schur form if T is upper triangular with non-negative diagonal and S is block upper triangular with 1-by-1 and 2-by-2 blocks. The 1-by-1 blocks correspond to real generalized eigenvalues, while the 2-by-2 blocks of S happen by making the corresponding elements of T have the form:
[ a 0 ]
[ 0 b ]
and the pair of corresponding 2-by-2 blocks in S and T will have a complex conjugate pair of generalized eigenvalues. Periodt.
π Parameters π
JOBVSLβJOBVSL is CHARACTER*1= 'N':do not compute the left Schur vectors;= 'V':compute the left Schur vectors.
JOBVSRβJOBVSR is CHARACTER*1= 'N':do not compute the right Schur vectors;= 'V':compute the right Schur vectors.
SORTβSORT is CHARACTER*1Specifies whether or not to order the eigenvalues on the diagonal of the generalized Schur form.= 'N':Eigenvalues are not ordered;= 'S':Eigenvalues are ordered (seeSELCTG);
SELCTGβSELCTG is a LOGICAL FUNCTION of three DOUBLE PRECISION argumentsSELCTGmust be declaredEXTERNALin the calling subroutine. IfSORT = 'N',SELCTGis not referenced. IfSORT = 'S',SELCTGis used to select eigenvalues to sort to the top left of the Schur form. An eigenvalue(ALPHAR(j)+ALPHAI(j))/BETA(j)is selected ifSELCTG(ALPHAR(j),ALPHAI(j),BETA(j))is true; i.e. if either one of a complex conjugate pair of eigenvalues is selected, then both complex eigenvalues are selected.
Ill-conditioned case alert: in the ill-conditioned case, a selected complex eigenvalue may no longer satisfySELCTG(ALPHAR(j),ALPHAI(j),BETA(j)) = .TRUE.after ordering.INFOis to be set toN+2in this case.
NβN is INTEGERThe order of the matricesA,B,VSL, andVSR.N >= 0.AβA is DOUBLE PRECISION array, dimension (LDA, N)On entry, the first of the pair of matrices. On exit,Ahas been overwritten by its generalized Schur formS.LDAβLDA is INTEGERThe leading dimension ofA.LDA >= max(1,N).BβB is DOUBLE PRECISION array, dimension (LDB, N)On entry, the second of the pair of matrices. On exit,Bhas been overwritten by its generalized Schur formT.LDBβLDB is INTEGERThe leading dimension ofB.LDB >= max(1,N).SDIMβSDIM is INTEGERIfSORT = 'N',SDIM = 0. IfSORT = 'S',SDIM= number of eigenvalues (after sorting) for whichSELCTGis true. (Complex conjugate pairs for whichSELCTGis true for either eigenvalue count as 2.)ALPHARβALPHAR is DOUBLE PRECISION array, dimension (N)ALPHAIβALPHAI is DOUBLE PRECISION array, dimension (N)BETAβBETA is DOUBLE PRECISION array, dimension (N)On exit,(ALPHAR(j) + ALPHAI(j)*i)/BETA(j),j=1,...,N, will be the generalized eigenvalues.ALPHAR(j) + ALPHAI(j)*i, andBETA(j),j=1,...,Nare the diagonals of the complex Schur form(S,T)that would result if the 2-by-2 diagonal blocks of the real Schur form of(A,B)were further reduced to triangular form using 2-by-2 complex unitary transformations. IfALPHAI(j)is zero, then the j-th eigenvalue is real; if positive, then the j-th and(j+1)-st eigenvalues are a complex conjugate pair, withALPHAI(j+1)negative.
Ratio warning: the quotientsALPHAR(j)/BETA(j)andALPHAI(j)/BETA(j)may easily over- or underflow, andBETA(j)may even be zero. Thus, the user should avoid naively computing the ratio. However,ALPHARandALPHAIwill be always less than and usually comparable withnorm(A)in magnitude, andBETAalways less than and usually comparable withnorm(B).
VSLβVSL is DOUBLE PRECISION array, dimension (LDVSL,N)IfJOBVSL = 'V',VSLwill contain the left Schur vectors. Not referenced ifJOBVSL = 'N'.LDVSLβLDVSL is INTEGERThe leading dimension of the matrixVSL.LDVSL >=1, and ifJOBVSL = 'V',LDVSL >= N.VSRβVSR is DOUBLE PRECISION array, dimension (LDVSR,N)IfJOBVSR = 'V',VSRwill contain the right Schur vectors. Not referenced ifJOBVSR = 'N'.LDVSRβLDVSR is INTEGERThe leading dimension of the matrixVSR.LDVSR >= 1, and ifJOBVSR = 'V',LDVSR >= N.WORKβWORK is DOUBLE PRECISION array, dimension (MAX(1,LWORK))On exit, ifINFO = 0,WORK(1)returns the optimalLWORK.LWORKβLWORK is INTEGERThe dimension of the arrayWORK. IfN = 0,LWORK >= 1, elseLWORK >= MAX(8*N,6*N+16). For good performance,LWORKmust generally be larger. IfLWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of theWORKarray, returns this value as the first entry of theWORKarray, and no error message related toLWORKis issued byXERBLA.BWORKβBWORK is LOGICAL array, dimension (N)Not referenced ifSORT = 'N'.INFOβINFO is INTEGER= 0:successful exit< 0:ifINFO = -i, the i-th argument had an illegal value.= 1,...,N:The QZ iteration failed.(A,B)are not in Schur form, butALPHAR(j),ALPHAI(j), andBETA(j)should be correct forj=INFO+1,...,N.> N:=N+1:other than QZ iteration failed inDHGEQZ.=N+2:after reordering, roundoff changed values of some complex eigenvalues so that leading eigenvalues in the Generalized Schur form no longer satisfySELCTG=.TRUE.This could also be caused due to scaling.=N+3:reordering failed inDTGSEN.
π«Ά Author π«Ά
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Definition at line 281 of file dgges.f.
Okay so now the SGGES chapter starts, and her signature is a whole moment:
subroutine sgges (character jobvsl, character jobvsr, character sort,
external selctg, integer n, real, dimension( lda, * ) a, integer lda,
real, dimension( ldb, * ) b, integer ldb, integer sdim, real, dimension(
* ) alphar, real, dimension( * ) alphai, real, dimension( * ) beta,
real, dimension( ldvsl, * ) vsl, integer ldvsl, real, dimension( ldvsr,
* ) vsr, integer ldvsr, real, dimension( * ) work, integer lwork,
logical, dimension( * ) bwork, integer info)
SGGES computes the eigenvalues, the Schur form, and, optionally, the matrix of Schur vectors for GE matrices
Purpose
okay so SGGES is out here computing, for a pair of N-by-N real nonsymmetric matrices (A,B), the generalized eigenvalues, the generalized real Schur form (S,T), and optionally the left and/or right matrices of Schur vectors (VSL and VSR). slay. This gives the generalized Schur factorization:
(A,B) = ( (VSL)*S*(VSR)**T, (VSL)*T*(VSR)**T )
Optionally, it also orders the eigenvalues so that a selected cluster of eigenvalues appears in the leading diagonal blocks of the upper quasi-triangular matrix S and the upper triangular matrix T. The leading columns of VSL and VSR then form an orthonormal basis for the corresponding left and right eigenspaces (deflating subspaces). periodt.
(If only the generalized eigenvalues are needed, use the driver SGGEV instead, which is faster.)
A generalized eigenvalue for a pair of matrices (A,B) is a scalar w or a ratio alpha/beta = w, such that A - w*B is singular. It is usually represented as the pair (alpha,beta), as there is a reasonable interpretation for beta=0 or both being zero. no cap.
A pair of matrices (S,T) is in generalized real Schur form if T is upper triangular with non-negative diagonal and S is block upper triangular with 1-by-1 and 2-by-2 blocks. 1-by-1 blocks correspond to real generalized eigenvalues, while 2-by-2 blocks of S will be by making the corresponding elements of T have the form:
[ a 0 ]
[ 0 b ]
and the pair of corresponding 2-by-2 blocks in S and T will have a complex conjugate pair of generalized eigenvalues. it's giving structured, honestly.
πΈ Parameters πΈ
JOBVSLβJOBVSLisCHARACTER*1;'N': do not compute the left Schur vectors;'V': compute the left Schur vectors.JOBVSRβJOBVSRisCHARACTER*1;'N': do not compute the right Schur vectors;'V': compute the right Schur vectors.SORTβSORTisCHARACTER*1; specifies whether or not to order the eigenvalues on the diagonal of the generalized Schur form.'N': eigenvalues are not ordered;'S': eigenvalues are ordered (seeSELCTG).SELCTGβSELCTGis aLOGICAL FUNCTIONof threeREALarguments.SELCTGmust be declaredEXTERNALin the calling subroutine. IfSORT = 'N',SELCTGis not referenced. IfSORT = 'S',SELCTGis used to select eigenvalues to sort to the top left of the Schur form. An eigenvalue(ALPHAR(j)+ALPHAI(j))/BETA(j)is selected ifSELCTG(ALPHAR(j),ALPHAI(j),BETA(j))is true; i.e. if either one of a complex conjugate pair of eigenvalues is selected, then both complex eigenvalues are selected. Note that in the ill-conditioned case, a selected complex eigenvalue may no longer satisfySELCTG(ALPHAR(j),ALPHAI(j), BETA(j)) = .TRUE.after ordering.INFOis to be set toN+2in this case.NβNisINTEGER; the order of the matricesA,B,VSL, andVSR.N >= 0.AβAisREALarray, dimension(LDA, N). On entry, the first of the pair of matrices. On exit,Ahas been overwritten by its generalized Schur formS.LDAβLDAisINTEGER; the leading dimension ofA.LDA >= max(1,N).BβBisREALarray, dimension(LDB, N). On entry, the second of the pair of matrices. On exit,Bhas been overwritten by its generalized Schur formT.LDBβLDBisINTEGER; the leading dimension ofB.LDB >= max(1,N).SDIMβSDIMisINTEGER. IfSORT = 'N',SDIM = 0. IfSORT = 'S',SDIM = number of eigenvalues (after sorting) for which SELCTG is true. (Complex conjugate pairs for whichSELCTGis true for either eigenvalue count as2.)ALPHARβALPHARisREALarray, dimension(N).ALPHAIβALPHAIisREALarray, dimension(N).BETAβBETAisREALarray, dimension(N). On exit,(ALPHAR(j) + ALPHAI(j)*i)/BETA(j),j=1,...,N, will be the generalized eigenvalues.ALPHAR(j) + ALPHAI(j)*i, andBETA(j),j=1,...,Nare the diagonals of the complex Schur form(S,T)that would result if the2-by-2diagonal blocks of the real Schur form of(A,B)were further reduced to triangular form using2-by-2complex unitary transformations. IfALPHAI(j)is zero, then the j-th eigenvalue is real; if positive, then the j-th and(j+1)-st eigenvalues are a complex conjugate pair, withALPHAI(j+1)negative. Note: the quotientsALPHAR(j)/BETA(j)andALPHAI(j)/BETA(j)may easily over- or underflow, andBETA(j)may even be zero. Thus, the user should avoid naively computing the ratio. However,ALPHARandALPHAIwill be always less than and usually comparable withnorm(A)in magnitude, andBETAalways less than and usually comparable withnorm(B).VSLβVSLisREALarray, dimension(LDVSL,N). IfJOBVSL = 'V',VSLwill contain the left Schur vectors. Not referenced ifJOBVSL = 'N'.LDVSLβLDVSLisINTEGER; the leading dimension of the matrixVSL.LDVSL >=1, and ifJOBVSL = 'V',LDVSL >= N.VSRβVSRisREALarray, dimension(LDVSR,N). IfJOBVSR = 'V',VSRwill contain the right Schur vectors. Not referenced ifJOBVSR = 'N'.LDVSRβLDVSRisINTEGER; the leading dimension of the matrixVSR.LDVSR >= 1, and ifJOBVSR = 'V',LDVSR >= N.WORKβWORKisREALarray, dimension(MAX(1,LWORK)). On exit, ifINFO = 0,WORK(1)returns the optimalLWORK.LWORKβLWORKisINTEGER; the dimension of the arrayWORK. IfN = 0,LWORK >= 1, elseLWORK >= max(8*N,6*N+16). For good performance,LWORKmust generally be larger. IfLWORK = -1, then a workspace query is assumed; the routine only calculates the optimal size of theWORKarray, returns this value as the first entry of theWORKarray, and no error message related toLWORKis issued byXERBLA.BWORKβBWORKisLOGICALarray, dimension(N). Not referenced ifSORT = 'N'.INFOβINFOisINTEGER.= 0: successful exit.< 0: ifINFO = -i, the i-th argument had an illegal value.= 1,...,N: the QZ iteration failed.(A,B)are not in Schur form, butALPHAR(j),ALPHAI(j), andBETA(j)should be correct forj=INFO+1,...,N.> N:=N+1: other than QZ iteration failed inSHGEQZ.=N+2: after reordering, roundoff changed values of some complex eigenvalues so that leading eigenvalues in the Generalized Schur form no longer satisfySELCTG=.TRUE.This could also be caused due to scaling.=N+3: reordering failed inSTGSEN.
π Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Definition at line 281 of file sgges.f.
π¦ subroutine zgges π¦
subroutine zgges (character jobvsl, character jobvsr, character sort,
external selctg, integer n, complex*16, dimension( lda, * ) a, integer
lda, complex*16, dimension( ldb, * ) b, integer ldb, integer sdim,
complex*16, dimension( * ) alpha, complex*16, dimension( * ) beta,
complex*16, dimension( ldvsl, * ) vsl, integer ldvsl, complex*16,
dimension( ldvsr, * ) vsr, integer ldvsr, complex*16, dimension( * )
work, integer lwork, double precision, dimension( * ) rwork, logical,
dimension( * ) bwork, integer info)
ZGGES computes the eigenvalues, the Schur form, and, optionally, the matrix of Schur vectors for GE matrices. iconic.
β¨ Purpose β¨
okay so ZGGES computes for a pair of N-by-N complex nonsymmetric matrices (A,B), the generalized eigenvalues, the generalized complex Schur form (S, T), and optionally left and/or right Schur vectors (VSL and VSR). This gives the generalized Schur factorization:
(A,B) = ( (VSL)*S*(VSR)**H, (VSL)*T*(VSR)**H )
where (VSR)**H is the conjugate-transpose of VSR.
Optionally, it also orders the eigenvalues so that a selected cluster of eigenvalues appears in the leading diagonal blocks of the upper triangular matrix S and the upper triangular matrix T. The leading columns of VSL and VSR then form an unitary basis for the corresponding left and right eigenspaces (deflating subspaces).
(If only the generalized eigenvalues are needed, use the driver ZGGEV instead, which is faster.)
A generalized eigenvalue for a pair of matrices (A,B) is a scalar w or a ratio alpha/beta = w, such that A - w*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.
A pair of matrices (S,T) is in generalized complex Schur form if S and T are upper triangular and, in addition, the diagonal elements of T are non-negative real numbers. the way that is so specific, honestly.
π Parameters π
JOBVSL
JOBVSLβ okay soJOBVSLis aCHARACTER*1, bestie, and here's the whole menu:'N': do not compute the left Schur vectors;'V': compute the left Schur vectors.
JOBVSRβ alsoCHARACTER*1, same energy but for the right side:'N': do not compute the right Schur vectors;'V': compute the right Schur vectors.
SORTβCHARACTER*1; this one specifies whether or not to order the eigenvalues on the diagonal of the generalized Schur form. Vibe check:'N': Eigenvalues are not ordered;'S': Eigenvalues are ordered (seeSELCTG).
SELCTGβ this one's aLOGICAL FUNCTIONof twoCOMPLEX*16arguments.SELCTGmust be declaredEXTERNALin the calling subroutine. IfSORT = 'N',SELCTGis not referenced. IfSORT = 'S',SELCTGis used to select eigenvalues to sort to the top left of the Schur form. An eigenvalueALPHA(j)/BETA(j)is selected ifSELCTG(ALPHA(j),BETA(j))is true.
Note that a selected complex eigenvalue may no longer satisfySELCTG(ALPHA(j),BETA(j)) = .TRUE.after ordering, since ordering may change the value of complex eigenvalues (especially if the eigenvalue is ill-conditioned), in this caseINFOis set toN+2(SeeINFObelow). π
NβNisINTEGER: the order of the matricesA,B,VSL, andVSR.N >= 0.AβAisCOMPLEX*16array, dimension(LDA, N). On entry, the first of the pair of matrices. On exit,Ahas been overwritten by its generalized Schur formS.LDAβLDAisINTEGER: the leading dimension ofA.LDA >= max(1,N).BβBisCOMPLEX*16array, dimension(LDB, N). On entry, the second of the pair of matrices. On exit,Bhas been overwritten by its generalized Schur formT.LDBβLDBisINTEGER: the leading dimension ofB.LDB >= max(1,N).SDIMβSDIMisINTEGER. IfSORT = 'N',SDIM = 0. IfSORT = 'S',SDIM = number of eigenvalues (after sorting) for which SELCTG is true.ALPHAβALPHAisCOMPLEX*16array, dimension(N). That's the whole note, no extra lore.BETAβBETAisCOMPLEX*16array, dimension(N). On exit,ALPHA(j)/BETA(j),j=1,...,N, will be the generalized eigenvalues.ALPHA(j),j=1,...,NandBETA(j),j=1,...,Nare the diagonals of the complex Schur form(A,B)output byZGGES. TheBETA(j)will be non-negative real.
Note: the quotientsALPHA(j)/BETA(j)may easily over- or underflow, andBETA(j)may even be zero. Thus, the user should avoid naively computing the ratioalpha/beta. However,ALPHAwill be always less than and usually comparable withnorm(A)in magnitude, andBETAalways less than and usually comparable withnorm(B). πΈ
VSLβVSLisCOMPLEX*16array, dimension(LDVSL,N). IfJOBVSL = 'V',VSLwill contain the left Schur vectors. Not referenced ifJOBVSL = 'N'.LDVSLβLDVSLisINTEGER: the leading dimension of the matrixVSL.LDVSL >= 1, and ifJOBVSL = 'V',LDVSL >= N.VSRβVSRisCOMPLEX*16array, dimension(LDVSR,N). IfJOBVSR = 'V',VSRwill contain the right Schur vectors. Not referenced ifJOBVSR = 'N'.LDVSRβLDVSRisINTEGER: the leading dimension of the matrixVSR.LDVSR >= 1, and ifJOBVSR = 'V',LDVSR >= N.WORKβWORKisCOMPLEX*16array, dimension(MAX(1,LWORK)). On exit, ifINFO = 0,WORK(1)returns the optimalLWORK.LWORKβLWORKisINTEGER: the dimension of the arrayWORK.LWORK >= max(1,2*N). For good performance,LWORKmust generally be larger.
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.
RWORKβRWORKisDOUBLE PRECISIONarray, dimension(8*N).BWORKβBWORKisLOGICALarray, dimension(N). Not referenced ifSORT = 'N'.INFOβINFOisINTEGER, and here's the whole status tea:= 0: successful exit< 0: ifINFO = -i, the i-th argument had an illegal value.=1,...,N: The QZ iteration failed.(A,B)are not in Schur form, butALPHA(j)andBETA(j)should be correct forj=INFO+1,...,N.> N:=N+1: other than QZ iteration failed inZHGEQZ=N+2: after reordering, roundoff changed values of some complex eigenvalues so that leading eigenvalues in the Generalized Schur form no longer satisfySELCTG=.TRUE.This could also be caused due to scaling.=N+3: reordering failed inZTGSEN.
π Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Definition at line 267 of file zgges.f.
π Author (Doxygen's encore)
Generated automatically by Doxygen for LAPACK from the source code.
Okay bestie, that's the whole page π The footer's giving source/version LAPACK Version 3.12.0 and page gges(3); there's no date field on this one, so no date to spill. β¨π
π¦ where this page comes from
- arch rolling: lapack-doc 3.12.1-2 Β· custom
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms