1STRSNA(1) LAPACK routine (version 3.2) STRSNA(1)
2
3
4
6 STRSNA - estimates reciprocal condition numbers for specified eigenval‐
7 ues and/or right eigenvectors of a real upper quasi-triangular matrix T
8 (or of any matrix Q*T*Q**T with Q orthogonal)
9
11 SUBROUTINE STRSNA( JOB, HOWMNY, SELECT, N, T, LDT, VL, LDVL, VR, LDVR,
12 S, SEP, MM, M, WORK, LDWORK, IWORK, INFO )
13
14 CHARACTER HOWMNY, JOB
15
16 INTEGER INFO, LDT, LDVL, LDVR, LDWORK, M, MM, N
17
18 LOGICAL SELECT( * )
19
20 INTEGER IWORK( * )
21
22 REAL S( * ), SEP( * ), T( LDT, * ), VL( LDVL, * ), VR(
23 LDVR, * ), WORK( LDWORK, * )
24
26 STRSNA estimates reciprocal condition numbers for specified eigenvalues
27 and/or right eigenvectors of a real upper quasi-triangular matrix T (or
28 of any matrix Q*T*Q**T with Q orthogonal). T must be in Schur canoni‐
29 cal form (as returned by SHSEQR), that is, block upper triangular with
30 1-by-1 and 2-by-2 diagonal blocks; each 2-by-2 diagonal block has its
31 diagonal elements equal and its off-diagonal elements of opposite sign.
32
34 JOB (input) CHARACTER*1
35 Specifies whether condition numbers are required for eigenval‐
36 ues (S) or eigenvectors (SEP):
37 = 'E': for eigenvalues only (S);
38 = 'V': for eigenvectors only (SEP);
39 = 'B': for both eigenvalues and eigenvectors (S and SEP).
40
41 HOWMNY (input) CHARACTER*1
42 = 'A': compute condition numbers for all eigenpairs;
43 = 'S': compute condition numbers for selected eigenpairs speci‐
44 fied by the array SELECT.
45
46 SELECT (input) LOGICAL array, dimension (N)
47 If HOWMNY = 'S', SELECT specifies the eigenpairs for which con‐
48 dition numbers are required. To select condition numbers for
49 the eigenpair corresponding to a real eigenvalue w(j),
50 SELECT(j) must be set to .TRUE.. To select condition numbers
51 corresponding to a complex conjugate pair of eigenvalues w(j)
52 and w(j+1), either SELECT(j) or SELECT(j+1) or both, must be
53 set to .TRUE.. If HOWMNY = 'A', SELECT is not referenced.
54
55 N (input) INTEGER
56 The order of the matrix T. N >= 0.
57
58 T (input) REAL array, dimension (LDT,N)
59 The upper quasi-triangular matrix T, in Schur canonical form.
60
61 LDT (input) INTEGER
62 The leading dimension of the array T. LDT >= max(1,N).
63
64 VL (input) REAL array, dimension (LDVL,M)
65 If JOB = 'E' or 'B', VL must contain left eigenvectors of T (or
66 of any Q*T*Q**T with Q orthogonal), corresponding to the eigen‐
67 pairs specified by HOWMNY and SELECT. The eigenvectors must be
68 stored in consecutive columns of VL, as returned by SHSEIN or
69 STREVC. If JOB = 'V', VL is not referenced.
70
71 LDVL (input) INTEGER
72 The leading dimension of the array VL. LDVL >= 1; and if JOB =
73 'E' or 'B', LDVL >= N.
74
75 VR (input) REAL array, dimension (LDVR,M)
76 If JOB = 'E' or 'B', VR must contain right eigenvectors of T
77 (or of any Q*T*Q**T with Q orthogonal), corresponding to the
78 eigenpairs specified by HOWMNY and SELECT. The eigenvectors
79 must be stored in consecutive columns of VR, as returned by
80 SHSEIN or STREVC. If JOB = 'V', VR is not referenced.
81
82 LDVR (input) INTEGER
83 The leading dimension of the array VR. LDVR >= 1; and if JOB =
84 'E' or 'B', LDVR >= N.
85
86 S (output) REAL array, dimension (MM)
87 If JOB = 'E' or 'B', the reciprocal condition numbers of the
88 selected eigenvalues, stored in consecutive elements of the
89 array. For a complex conjugate pair of eigenvalues two consecu‐
90 tive elements of S are set to the same value. Thus S(j),
91 SEP(j), and the j-th columns of VL and VR all correspond to the
92 same eigenpair (but not in general the j-th eigenpair, unless
93 all eigenpairs are selected). If JOB = 'V', S is not refer‐
94 enced.
95
96 SEP (output) REAL array, dimension (MM)
97 If JOB = 'V' or 'B', the estimated reciprocal condition numbers
98 of the selected eigenvectors, stored in consecutive elements of
99 the array. For a complex eigenvector two consecutive elements
100 of SEP are set to the same value. If the eigenvalues cannot be
101 reordered to compute SEP(j), SEP(j) is set to 0; this can only
102 occur when the true value would be very small anyway. If JOB =
103 'E', SEP is not referenced.
104
105 MM (input) INTEGER
106 The number of elements in the arrays S (if JOB = 'E' or 'B')
107 and/or SEP (if JOB = 'V' or 'B'). MM >= M.
108
109 M (output) INTEGER
110 The number of elements of the arrays S and/or SEP actually used
111 to store the estimated condition numbers. If HOWMNY = 'A', M
112 is set to N.
113
114 WORK (workspace) REAL array, dimension (LDWORK,N+6)
115 If JOB = 'E', WORK is not referenced.
116
117 LDWORK (input) INTEGER
118 The leading dimension of the array WORK. LDWORK >= 1; and if
119 JOB = 'V' or 'B', LDWORK >= N.
120
121 IWORK (workspace) INTEGER array, dimension (2*(N-1))
122 If JOB = 'E', IWORK is not referenced.
123
124 INFO (output) INTEGER
125 = 0: successful exit
126 < 0: if INFO = -i, the i-th argument had an illegal value
127
129 The reciprocal of the condition number of an eigenvalue lambda is
130 defined as
131 S(lambda) = |v'*u| / (norm(u)*norm(v))
132 where u and v are the right and left eigenvectors of T corresponding to
133 lambda; v' denotes the conjugate-transpose of v, and norm(u) denotes
134 the Euclidean norm. These reciprocal condition numbers always lie
135 between zero (very badly conditioned) and one (very well conditioned).
136 If n = 1, S(lambda) is defined to be 1.
137 An approximate error bound for a computed eigenvalue W(i) is given by
138 EPS * norm(T) / S(i)
139 where EPS is the machine precision.
140 The reciprocal of the condition number of the right eigenvector u cor‐
141 responding to lambda is defined as follows. Suppose
142 T = ( lambda c )
143 ( 0 T22 )
144 Then the reciprocal condition number is
145 SEP( lambda, T22 ) = sigma-min( T22 - lambda*I )
146 where sigma-min denotes the smallest singular value. We approximate the
147 smallest singular value by the reciprocal of an estimate of the one-
148 norm of the inverse of T22 - lambda*I. If n = 1, SEP(1) is defined to
149 be abs(T(1,1)).
150 An approximate error bound for a computed right eigenvector VR(i) is
151 given by
152 EPS * norm(T) / SEP(i)
153
154
155
156 LAPACK routine (version 3.2) November 2008 STRSNA(1)