hgeqz#

Functions

void shgeqz(
    const char*          job,
    const char*          compq,
    const char*          compz,
    const INT            n,
    const INT            ilo,
    const INT            ihi,
          f32*  restrict H,
    const INT            ldh,
          f32*  restrict T,
    const INT            ldt,
          f32*  restrict alphar,
          f32*  restrict alphai,
          f32*  restrict beta,
          f32*  restrict Q,
    const INT            ldq,
          f32*  restrict Z,
    const INT            ldz,
          f32*  restrict work,
    const INT            lwork,
          INT*           info
);
void shgeqz(const char *job, const char *compq, const char *compz, const INT n, const INT ilo, const INT ihi, f32 *restrict H, const INT ldh, f32 *restrict T, const INT ldt, f32 *restrict alphar, f32 *restrict alphai, f32 *restrict beta, f32 *restrict Q, const INT ldq, f32 *restrict Z, const INT ldz, f32 *restrict work, const INT lwork, INT *info)#

SHGEQZ computes the eigenvalues of a real matrix pair (H,T), where H is an upper Hessenberg matrix and T is upper triangular, using the double-shift QZ method.

Matrix pairs of this type are produced by the reduction to generalized upper Hessenberg form of a real matrix pair (A,B):

A = Q1*H*Z1**T, B = Q1*T*Z1**T,

as computed by SGGHRD.

If JOB=’S’, then the Hessenberg-triangular pair (H,T) is also reduced to generalized Schur form,

H = Q*S*Z**T, T = Q*P*Z**T,

where Q and Z are orthogonal matrices, P is an upper triangular matrix, and S is a quasi-triangular matrix with 1-by-1 and 2-by-2 diagonal blocks.

Parameters

in
job

= ‘E’: Compute eigenvalues only; = ‘S’: Compute eigenvalues and the Schur form.

in
compq

= ‘N’: Left Schur vectors (Q) are not computed; = ‘I’: Q is initialized to the unit matrix; = ‘V’: Q must contain an orthogonal matrix Q1 on entry.

in
compz

= ‘N’: Right Schur vectors (Z) are not computed; = ‘I’: Z is initialized to the unit matrix; = ‘V’: Z must contain an orthogonal matrix Z1 on entry.

in
n

The order of the matrices H, T, Q, and Z. n >= 0.

in
ilo

See ihi.

in
ihi

ILO and IHI mark the rows and columns of H which are in Hessenberg form. 0 <= ILO <= IHI <= N-1, if N > 0.

inout
H

Array of dimension (ldh, n). On entry, the N-by-N upper Hessenberg matrix H. On exit, if JOB = ‘S’, H contains the upper quasi-triangular matrix S.

in
ldh

The leading dimension of H. ldh >= max(1,n).

inout
T

Array of dimension (ldt, n). On entry, the N-by-N upper triangular matrix T. On exit, if JOB = ‘S’, T contains the upper triangular matrix P.

in
ldt

The leading dimension of T. ldt >= max(1,n).

out
alphar

Array of dimension (n). The real parts of alpha.

out
alphai

Array of dimension (n). The imaginary parts of alpha.

out
beta

Array of dimension (n). The scalars beta.

inout
Q

Array of dimension (ldq, n). The orthogonal matrix Q.

in
ldq

The leading dimension of Q. ldq >= 1; ldq >= n if COMPQ=’V’ or ‘I’.

inout
Z

Array of dimension (ldz, n). The orthogonal matrix Z.

in
ldz

The leading dimension of Z. ldz >= 1; ldz >= n if COMPZ=’V’ or ‘I’.

out
work

Workspace array of dimension (lwork).

in
lwork

The dimension of work. lwork >= max(1,n). If lwork = -1, workspace query is performed.

out
info

  • = 0: successful exit

  • < 0: if info = -i, the i-th argument had an illegal value

  • = 1,…,N: the QZ iteration did not converge.

  • = N+1,…,2*N: the shift calculation failed.

Functions

void dhgeqz(
    const char*          job,
    const char*          compq,
    const char*          compz,
    const INT            n,
    const INT            ilo,
    const INT            ihi,
          f64*  restrict H,
    const INT            ldh,
          f64*  restrict T,
    const INT            ldt,
          f64*  restrict alphar,
          f64*  restrict alphai,
          f64*  restrict beta,
          f64*  restrict Q,
    const INT            ldq,
          f64*  restrict Z,
    const INT            ldz,
          f64*  restrict work,
    const INT            lwork,
          INT*           info
);
void dhgeqz(const char *job, const char *compq, const char *compz, const INT n, const INT ilo, const INT ihi, f64 *restrict H, const INT ldh, f64 *restrict T, const INT ldt, f64 *restrict alphar, f64 *restrict alphai, f64 *restrict beta, f64 *restrict Q, const INT ldq, f64 *restrict Z, const INT ldz, f64 *restrict work, const INT lwork, INT *info)#

DHGEQZ computes the eigenvalues of a real matrix pair (H,T), where H is an upper Hessenberg matrix and T is upper triangular, using the double-shift QZ method.

Matrix pairs of this type are produced by the reduction to generalized upper Hessenberg form of a real matrix pair (A,B):

A = Q1*H*Z1**T, B = Q1*T*Z1**T,

as computed by DGGHRD.

If JOB=’S’, then the Hessenberg-triangular pair (H,T) is also reduced to generalized Schur form,

H = Q*S*Z**T, T = Q*P*Z**T,

where Q and Z are orthogonal matrices, P is an upper triangular matrix, and S is a quasi-triangular matrix with 1-by-1 and 2-by-2 diagonal blocks.

Parameters

in
job

= ‘E’: Compute eigenvalues only; = ‘S’: Compute eigenvalues and the Schur form.

in
compq

= ‘N’: Left Schur vectors (Q) are not computed; = ‘I’: Q is initialized to the unit matrix; = ‘V’: Q must contain an orthogonal matrix Q1 on entry.

in
compz

= ‘N’: Right Schur vectors (Z) are not computed; = ‘I’: Z is initialized to the unit matrix; = ‘V’: Z must contain an orthogonal matrix Z1 on entry.

in
n

The order of the matrices H, T, Q, and Z. n >= 0.

in
ilo

See ihi.

in
ihi

ILO and IHI mark the rows and columns of H which are in Hessenberg form. 0 <= ILO <= IHI <= N-1, if N > 0.

inout
H

Array of dimension (ldh, n). On entry, the N-by-N upper Hessenberg matrix H. On exit, if JOB = ‘S’, H contains the upper quasi-triangular matrix S.

in
ldh

The leading dimension of H. ldh >= max(1,n).

inout
T

Array of dimension (ldt, n). On entry, the N-by-N upper triangular matrix T. On exit, if JOB = ‘S’, T contains the upper triangular matrix P.

in
ldt

The leading dimension of T. ldt >= max(1,n).

out
alphar

Array of dimension (n). The real parts of alpha.

out
alphai

Array of dimension (n). The imaginary parts of alpha.

out
beta

Array of dimension (n). The scalars beta.

inout
Q

Array of dimension (ldq, n). The orthogonal matrix Q.

in
ldq

The leading dimension of Q. ldq >= 1; ldq >= n if COMPQ=’V’ or ‘I’.

inout
Z

Array of dimension (ldz, n). The orthogonal matrix Z.

in
ldz

The leading dimension of Z. ldz >= 1; ldz >= n if COMPZ=’V’ or ‘I’.

out
work

Workspace array of dimension (lwork).

in
lwork

The dimension of work. lwork >= max(1,n). If lwork = -1, workspace query is performed.

out
info

  • = 0: successful exit

  • < 0: if info = -i, the i-th argument had an illegal value

  • = 1,…,N: the QZ iteration did not converge.

  • = N+1,…,2*N: the shift calculation failed.

Functions

void chgeqz(
    const char*          job,
    const char*          compq,
    const char*          compz,
    const INT            n,
    const INT            ilo,
    const INT            ihi,
          c64*  restrict H,
    const INT            ldh,
          c64*  restrict T,
    const INT            ldt,
          c64*  restrict alpha,
          c64*  restrict beta,
          c64*  restrict Q,
    const INT            ldq,
          c64*  restrict Z,
    const INT            ldz,
          c64*  restrict work,
    const INT            lwork,
          f32*  restrict rwork,
          INT*           info
);
void chgeqz(const char *job, const char *compq, const char *compz, const INT n, const INT ilo, const INT ihi, c64 *restrict H, const INT ldh, c64 *restrict T, const INT ldt, c64 *restrict alpha, c64 *restrict beta, c64 *restrict Q, const INT ldq, c64 *restrict Z, const INT ldz, c64 *restrict work, const INT lwork, f32 *restrict rwork, INT *info)#

CHGEQZ computes the eigenvalues of a complex matrix pair (H,T), where H is an upper Hessenberg matrix and T is upper triangular, using the single-shift QZ method.

Matrix pairs of this type are produced by the reduction to generalized upper Hessenberg form of a complex matrix pair (A,B):

A = Q1*H*Z1**H, B = Q1*T*Z1**H,

as computed by CGGHRD.

If JOB=’S’, then the Hessenberg-triangular pair (H,T) is also reduced to generalized Schur form,

H = Q*S*Z**H, T = Q*P*Z**H,

where Q and Z are unitary matrices and S and P are upper triangular.

Parameters

in
job

= ‘E’: Compute eigenvalues only; = ‘S’: Compute eigenvalues and the Schur form.

in
compq

= ‘N’: Left Schur vectors (Q) are not computed; = ‘I’: Q is initialized to the unit matrix; = ‘V’: Q must contain a unitary matrix Q1 on entry.

in
compz

= ‘N’: Right Schur vectors (Z) are not computed; = ‘I’: Z is initialized to the unit matrix; = ‘V’: Z must contain a unitary matrix Z1 on entry.

in
n

The order of the matrices H, T, Q, and Z. n >= 0.

in
ilo

0-based lower bound of active submatrix.

in
ihi

0-based upper bound of active submatrix.

inout
H

Complex array, dimension (ldh, n). Upper Hessenberg matrix.

in
ldh

Leading dimension of H. ldh >= max(1,n).

inout
T

Complex array, dimension (ldt, n). Upper triangular matrix.

in
ldt

Leading dimension of T. ldt >= max(1,n).

out
alpha

Complex array, dimension (n). Eigenvalue numerators.

out
beta

Complex array, dimension (n). Eigenvalue denominators.

inout
Q

Complex array, dimension (ldq, n). Left Schur vectors.

in
ldq

Leading dimension of Q. ldq >= 1; ldq >= n if COMPQ=’V’ or ‘I’.

inout
Z

Complex array, dimension (ldz, n). Right Schur vectors.

in
ldz

Leading dimension of Z. ldz >= 1; ldz >= n if COMPZ=’V’ or ‘I’.

out
work

Complex workspace array, dimension (max(1,lwork)).

in
lwork

Dimension of work. lwork >= max(1,n). If lwork = -1, workspace query.

out
rwork

Single precision array, dimension (n).

out
info

= 0: successful exit. < 0: if info = -i, the i-th argument had an illegal value. = 1,…,N: the QZ iteration did not converge. = N+1,…,2*N: the shift calculation failed.

Functions

void zhgeqz(
    const char*          job,
    const char*          compq,
    const char*          compz,
    const INT            n,
    const INT            ilo,
    const INT            ihi,
          c128* restrict H,
    const INT            ldh,
          c128* restrict T,
    const INT            ldt,
          c128* restrict alpha,
          c128* restrict beta,
          c128* restrict Q,
    const INT            ldq,
          c128* restrict Z,
    const INT            ldz,
          c128* restrict work,
    const INT            lwork,
          f64*  restrict rwork,
          INT*           info
);
void zhgeqz(const char *job, const char *compq, const char *compz, const INT n, const INT ilo, const INT ihi, c128 *restrict H, const INT ldh, c128 *restrict T, const INT ldt, c128 *restrict alpha, c128 *restrict beta, c128 *restrict Q, const INT ldq, c128 *restrict Z, const INT ldz, c128 *restrict work, const INT lwork, f64 *restrict rwork, INT *info)#

ZHGEQZ computes the eigenvalues of a complex matrix pair (H,T), where H is an upper Hessenberg matrix and T is upper triangular, using the single-shift QZ method.

Matrix pairs of this type are produced by the reduction to generalized upper Hessenberg form of a complex matrix pair (A,B):

A = Q1*H*Z1**H, B = Q1*T*Z1**H,

as computed by ZGGHRD.

If JOB=’S’, then the Hessenberg-triangular pair (H,T) is also reduced to generalized Schur form,

H = Q*S*Z**H, T = Q*P*Z**H,

where Q and Z are unitary matrices and S and P are upper triangular.

Parameters

in
job

= ‘E’: Compute eigenvalues only; = ‘S’: Compute eigenvalues and the Schur form.

in
compq

= ‘N’: Left Schur vectors (Q) are not computed; = ‘I’: Q is initialized to the unit matrix; = ‘V’: Q must contain a unitary matrix Q1 on entry.

in
compz

= ‘N’: Right Schur vectors (Z) are not computed; = ‘I’: Z is initialized to the unit matrix; = ‘V’: Z must contain a unitary matrix Z1 on entry.

in
n

The order of the matrices H, T, Q, and Z. n >= 0.

in
ilo

0-based lower bound of active submatrix.

in
ihi

0-based upper bound of active submatrix.

inout
H

Complex array, dimension (ldh, n). Upper Hessenberg matrix.

in
ldh

Leading dimension of H. ldh >= max(1,n).

inout
T

Complex array, dimension (ldt, n). Upper triangular matrix.

in
ldt

Leading dimension of T. ldt >= max(1,n).

out
alpha

Complex array, dimension (n). Eigenvalue numerators.

out
beta

Complex array, dimension (n). Eigenvalue denominators.

inout
Q

Complex array, dimension (ldq, n). Left Schur vectors.

in
ldq

Leading dimension of Q. ldq >= 1; ldq >= n if COMPQ=’V’ or ‘I’.

inout
Z

Complex array, dimension (ldz, n). Right Schur vectors.

in
ldz

Leading dimension of Z. ldz >= 1; ldz >= n if COMPZ=’V’ or ‘I’.

out
work

Complex workspace array, dimension (max(1,lwork)).

in
lwork

Dimension of work. lwork >= max(1,n). If lwork = -1, workspace query.

out
rwork

Double precision array, dimension (n).

out
info

= 0: successful exit. < 0: if info = -i, the i-th argument had an illegal value. = 1,…,N: the QZ iteration did not converge. = N+1,…,2*N: the shift calculation failed.