public interface stemr
STEMR computes selected eigenvalues and, optionally, eigenvectors
of a real symmetric tridiagonal matrix T. Any such unreduced matrix has
a well defined set of pairwise different real eigenvalues, the corresponding
real eigenvectors are pairwise orthogonal.
The spectrum may be computed either completely or partially by specifying
either an interval (VL,VU] or a range of indices IL:IU for the desired
eigenvalues.
Depending on the number of desired eigenvalues, these are computed either
by bisection or the dqds algorithm. Numerically orthogonal eigenvectors are
computed by the use of various suitable L D L^T factorizations near clusters
of close eigenvalues (referred to as RRRs, Relatively Robust
Representations). An informal sketch of the algorithm follows.
For each unreduced block (submatrix) of T,
(a) Compute T - sigma I = L D L^T, so that L and D
define all the wanted eigenvalues to high relative accuracy.
This means that small relative changes in the entries of D and L
cause only small relative changes in the eigenvalues and
eigenvectors. The standard (unfactored) representation of the
tridiagonal matrix T does not have this property in general.
(b) Compute the eigenvalues to suitable accuracy.
If the eigenvectors are desired, the algorithm attains full
accuracy of the computed eigenvalues only right before
the corresponding vectors have to be computed, see steps c) and d).
(c) For each cluster of close eigenvalues, select a new
shift close to the cluster, find a new factorization, and refine
the shifted eigenvalues to suitable accuracy.
(d) For each eigenvalue with a large enough relative separation compute
the corresponding eigenvector by forming a rank revealing twisted
factorization. Go back to (c) for any clusters that remain.
For more details, see:
- Inderjit S. Dhillon and Beresford N. Parlett: "Multiple representations
to compute orthogonal eigenvectors of symmetric tridiagonal matrices,"
Linear Algebra and its Applications, 387(1), pp. 1-28, August 2004.
- Inderjit Dhillon and Beresford Parlett: "Orthogonal Eigenvectors and
Relative Gaps," SIAM Journal on Matrix Analysis and Applications, Vol. 25,
2004. Also LAPACK Working Note 154.
- Inderjit Dhillon: "A new O(n^2) algorithm for the symmetric
tridiagonal eigenvalue/eigenvector problem",
Computer Science Division Technical Report No. UCB/CSD-97-971,
UC Berkeley, May 1997.
Further Details
1.STEMR works only on machines which follow IEEE-754
floating-point standard in their handling of infinities and NaNs.
This permits the use of efficient inner loops avoiding a check for
zero divisors.
2. LAPACK routines can be used to reduce a complex Hermitean matrix to
real symmetric tridiagonal form.
(Any complex Hermitean tridiagonal matrix has real values on its diagonal
and potentially complex numbers on its off-diagonals. By applying a
similarity transform with an appropriate diagonal matrix
diag(1,e^{i \phy_1}, ... , e^{i \phy_{n-1}}), the complex Hermitean
matrix can be transformed into a real symmetric matrix and complex
arithmetic can be entirely avoided.)
While the eigenvectors of the real symmetric tridiagonal matrix are real,
the eigenvectors of original complex Hermitean matrix have complex entries
in general.
Since LAPACK drivers overwrite the matrix data with the eigenvectors,
STEMR accepts complex workspace to facilitate interoperability
with CUNMTR or CUPMTR.
Subroutines
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
jobz |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
range |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
n |
|
|
real(kind=sp),
|
intent(inout) |
|
|
:: |
d(*) |
|
|
real(kind=sp),
|
intent(inout) |
|
|
:: |
e(*) |
|
|
real(kind=sp),
|
intent(in) |
|
|
:: |
vl |
|
|
real(kind=sp),
|
intent(in) |
|
|
:: |
vu |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
il |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
iu |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
m |
|
|
real(kind=sp),
|
intent(out) |
|
|
:: |
w(*) |
|
|
complex(kind=sp),
|
intent(out) |
|
|
:: |
z(ldz,*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
ldz |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
nzc |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
isuppz(*) |
|
|
logical(kind=lk),
|
intent(inout) |
|
|
:: |
tryrac |
|
|
real(kind=sp),
|
intent(out) |
|
|
:: |
work(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
lwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
iwork(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
liwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
info |
|
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
jobz |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
range |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
n |
|
|
real(kind=dp),
|
intent(inout) |
|
|
:: |
d(*) |
|
|
real(kind=dp),
|
intent(inout) |
|
|
:: |
e(*) |
|
|
real(kind=dp),
|
intent(in) |
|
|
:: |
vl |
|
|
real(kind=dp),
|
intent(in) |
|
|
:: |
vu |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
il |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
iu |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
m |
|
|
real(kind=dp),
|
intent(out) |
|
|
:: |
w(*) |
|
|
real(kind=dp),
|
intent(out) |
|
|
:: |
z(ldz,*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
ldz |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
nzc |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
isuppz(*) |
|
|
logical(kind=lk),
|
intent(inout) |
|
|
:: |
tryrac |
|
|
real(kind=dp),
|
intent(out) |
|
|
:: |
work(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
lwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
iwork(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
liwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
info |
|
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
jobz |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
range |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
n |
|
|
real(kind=sp),
|
intent(inout) |
|
|
:: |
d(*) |
|
|
real(kind=sp),
|
intent(inout) |
|
|
:: |
e(*) |
|
|
real(kind=sp),
|
intent(in) |
|
|
:: |
vl |
|
|
real(kind=sp),
|
intent(in) |
|
|
:: |
vu |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
il |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
iu |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
m |
|
|
real(kind=sp),
|
intent(out) |
|
|
:: |
w(*) |
|
|
real(kind=sp),
|
intent(out) |
|
|
:: |
z(ldz,*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
ldz |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
nzc |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
isuppz(*) |
|
|
logical(kind=lk),
|
intent(inout) |
|
|
:: |
tryrac |
|
|
real(kind=sp),
|
intent(out) |
|
|
:: |
work(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
lwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
iwork(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
liwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
info |
|
Arguments
| Type |
Intent | Optional | Attributes |
|
Name |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
jobz |
|
|
character(len=1),
|
intent(in) |
|
|
:: |
range |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
n |
|
|
real(kind=dp),
|
intent(inout) |
|
|
:: |
d(*) |
|
|
real(kind=dp),
|
intent(inout) |
|
|
:: |
e(*) |
|
|
real(kind=dp),
|
intent(in) |
|
|
:: |
vl |
|
|
real(kind=dp),
|
intent(in) |
|
|
:: |
vu |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
il |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
iu |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
m |
|
|
real(kind=dp),
|
intent(out) |
|
|
:: |
w(*) |
|
|
complex(kind=dp),
|
intent(out) |
|
|
:: |
z(ldz,*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
ldz |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
nzc |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
isuppz(*) |
|
|
logical(kind=lk),
|
intent(inout) |
|
|
:: |
tryrac |
|
|
real(kind=dp),
|
intent(out) |
|
|
:: |
work(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
lwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
iwork(*) |
|
|
integer(kind=ilp),
|
intent(in) |
|
|
:: |
liwork |
|
|
integer(kind=ilp),
|
intent(out) |
|
|
:: |
info |
|
Module Procedures