XLPack 7.0
XLPack Numerical Library (C API) Reference Manual
Loading...
Searching...
No Matches

◆ zsteqr()

void zsteqr ( char  compz,
int  n,
double  d[],
double  e[],
int  ldz,
doublecomplex  z[],
double  work[],
int *  info 
)

Eigenvalues and eigenvectors of symmetric tridiagonal matrix to which a Hermitian matrix was reduced (QL or QR method)

Purpose
This routine computes all eigenvalues and, optionally, eigenvectors of a symmetric tridiagonal matrix to which a Hermitian matrix was reduced using the implicit QL or QR method. The eigenvectors of a full or band complex Hermitian matrix can also be found if zhetrd or zhptrd or zhbtrd has been used to reduce this matrix to tridiagonal form.
Parameters
[in]compz= 'N': Compute eigenvalues only.
= 'V': Compute eigenvalues and eigenvectors of the original Hermitian matrix. On entry, z[][] must contain the unitary matrix used to reduce the original matrix to tridiagonal form.
= 'I': Compute eigenvalues and eigenvectors of the tridiagonal matrix. z[][] is initialized to the identity matrix.
[in]nOrder of the matrix. (n >= 0) (If n = 0, returns without computation)
[in,out]d[]Array d[ld] (ld >= n)
[in] The diagonal elements of the tridiagonal matrix.
[out] If info = 0, the eigenvalues in ascending order.
[in,out]e[]Array e[le] (le >= n - 1)
[in] The (n-1) subdiagonal elements of the tridiagonal matrix.
[out] e[] has been destroyed.
[in]ldzLeading dimension of the two dimensional array z[][]. (ldz >= 1 if compz = 'N', ldz >= max(1, n) if compz = 'V' or 'I')
[in,out]z[][]Array z[lz][ldz] (lz >= n)
[in] If compz = 'V', then z[][] contains the unitary matrix used in the reduction to tridiagonal form.
[out] If info = 0, then if compz = 'V', z[][] contains the orthonormal eigenvectors of the original Hermitian matrix, and if compz = 'I', z[][] contains the orthonormal eigenvectors of the symmetric tridiagonal matrix. If compz = 'N', then z[][] is not referenced.
[out]work[]Array work[lwork] (lwork >= max(1, 2*n - 2))
Work array.
If compz = 'N', then work is not referenced.
[out]info= 0: Successful exit.
= -1: The argument compz an illegal value. (compz != 'N', 'V' nor 'I')
= -2: The argument n had an illegal value. (n < 0)
= -5: The argument ldz had an illegal value. (ldz < 1 or (compz = 'V' or 'I' and ldz < max(1, n)))
= i > 0: The algorithm has failed to find all the eigenvalues in a total of 30*n iterations. i elements of e have not converged to zero. On exit, d and e contain the elements of a symmetric tridiagonal matrix which is unitarily similar to the original matrix.
Reference
LAPACK