1CHBGVD(1) LAPACK driver routine (version 3.1) CHBGVD(1)
2
3
4
6 CHBGVD - all the eigenvalues, and optionally, the eigenvectors of a
7 complex generalized Hermitian-definite banded eigenproblem, of the form
8 A*x=(lambda)*B*x
9
11 SUBROUTINE CHBGVD( JOBZ, UPLO, N, KA, KB, AB, LDAB, BB, LDBB, W, Z,
12 LDZ, WORK, LWORK, RWORK, LRWORK, IWORK, LIWORK, INFO
13 )
14
15 CHARACTER JOBZ, UPLO
16
17 INTEGER INFO, KA, KB, LDAB, LDBB, LDZ, LIWORK, LRWORK,
18 LWORK, N
19
20 INTEGER IWORK( * )
21
22 REAL RWORK( * ), W( * )
23
24 COMPLEX AB( LDAB, * ), BB( LDBB, * ), WORK( * ), Z( LDZ, * )
25
27 CHBGVD computes all the eigenvalues, and optionally, the eigenvectors
28 of a complex generalized Hermitian-definite banded eigenproblem, of the
29 form A*x=(lambda)*B*x. Here A and B are assumed to be Hermitian and
30 banded, and B is also positive definite. If eigenvectors are desired,
31 it uses a divide and conquer algorithm.
32
33 The divide and conquer algorithm makes very mild assumptions about
34 floating point arithmetic. It will work on machines with a guard digit
35 in add/subtract, or on those binary machines without guard digits which
36 subtract like the Cray X-MP, Cray Y-MP, Cray C-90, or Cray-2. It could
37 conceivably fail on hexadecimal or decimal machines without guard dig‐
38 its, but we know of none.
39
40
42 JOBZ (input) CHARACTER*1
43 = 'N': Compute eigenvalues only;
44 = 'V': Compute eigenvalues and eigenvectors.
45
46 UPLO (input) CHARACTER*1
47 = 'U': Upper triangles of A and B are stored;
48 = 'L': Lower triangles of A and B are stored.
49
50 N (input) INTEGER
51 The order of the matrices A and B. N >= 0.
52
53 KA (input) INTEGER
54 The number of superdiagonals of the matrix A if UPLO = 'U', or
55 the number of subdiagonals if UPLO = 'L'. KA >= 0.
56
57 KB (input) INTEGER
58 The number of superdiagonals of the matrix B if UPLO = 'U', or
59 the number of subdiagonals if UPLO = 'L'. KB >= 0.
60
61 AB (input/output) COMPLEX array, dimension (LDAB, N)
62 On entry, the upper or lower triangle of the Hermitian band
63 matrix A, stored in the first ka+1 rows of the array. The j-th
64 column of A is stored in the j-th column of the array AB as
65 follows: if UPLO = 'U', AB(ka+1+i-j,j) = A(i,j) for max(1,j-
66 ka)<=i<=j; if UPLO = 'L', AB(1+i-j,j) = A(i,j) for
67 j<=i<=min(n,j+ka).
68
69 On exit, the contents of AB are destroyed.
70
71 LDAB (input) INTEGER
72 The leading dimension of the array AB. LDAB >= KA+1.
73
74 BB (input/output) COMPLEX array, dimension (LDBB, N)
75 On entry, the upper or lower triangle of the Hermitian band
76 matrix B, stored in the first kb+1 rows of the array. The j-th
77 column of B is stored in the j-th column of the array BB as
78 follows: if UPLO = 'U', BB(kb+1+i-j,j) = B(i,j) for max(1,j-
79 kb)<=i<=j; if UPLO = 'L', BB(1+i-j,j) = B(i,j) for
80 j<=i<=min(n,j+kb).
81
82 On exit, the factor S from the split Cholesky factorization B =
83 S**H*S, as returned by CPBSTF.
84
85 LDBB (input) INTEGER
86 The leading dimension of the array BB. LDBB >= KB+1.
87
88 W (output) REAL array, dimension (N)
89 If INFO = 0, the eigenvalues in ascending order.
90
91 Z (output) COMPLEX array, dimension (LDZ, N)
92 If JOBZ = 'V', then if INFO = 0, Z contains the matrix Z of
93 eigenvectors, with the i-th column of Z holding the eigenvector
94 associated with W(i). The eigenvectors are normalized so that
95 Z**H*B*Z = I. If JOBZ = 'N', then Z is not referenced.
96
97 LDZ (input) INTEGER
98 The leading dimension of the array Z. LDZ >= 1, and if JOBZ =
99 'V', LDZ >= N.
100
101 WORK (workspace/output) COMPLEX array, dimension (MAX(1,LWORK))
102 On exit, if INFO=0, WORK(1) returns the optimal LWORK.
103
104 LWORK (input) INTEGER
105 The dimension of the array WORK. If N <= 1,
106 LWORK >= 1. If JOBZ = 'N' and N > 1, LWORK >= N. If JOBZ =
107 'V' and N > 1, LWORK >= 2*N**2.
108
109 If LWORK = -1, then a workspace query is assumed; the routine
110 only calculates the optimal sizes of the WORK, RWORK and IWORK
111 arrays, returns these values as the first entries of the WORK,
112 RWORK and IWORK arrays, and no error message related to LWORK
113 or LRWORK or LIWORK is issued by XERBLA.
114
115 RWORK (workspace/output) REAL array, dimension (MAX(1,LRWORK))
116 On exit, if INFO=0, RWORK(1) returns the optimal LRWORK.
117
118 LRWORK (input) INTEGER
119 The dimension of array RWORK. If N <= 1, LRWORK
120 >= 1. If JOBZ = 'N' and N > 1, LRWORK >= N. If JOBZ = 'V' and
121 N > 1, LRWORK >= 1 + 5*N + 2*N**2.
122
123 If LRWORK = -1, then a workspace query is assumed; the routine
124 only calculates the optimal sizes of the WORK, RWORK and IWORK
125 arrays, returns these values as the first entries of the WORK,
126 RWORK and IWORK arrays, and no error message related to LWORK
127 or LRWORK or LIWORK is issued by XERBLA.
128
129 IWORK (workspace/output) INTEGER array, dimension (MAX(1,LIWORK))
130 On exit, if INFO=0, IWORK(1) returns the optimal LIWORK.
131
132 LIWORK (input) INTEGER
133 The dimension of array IWORK. If JOBZ = 'N' or N <= 1, LIWORK
134 >= 1. If JOBZ = 'V' and N > 1, LIWORK >= 3 + 5*N.
135
136 If LIWORK = -1, then a workspace query is assumed; the routine
137 only calculates the optimal sizes of the WORK, RWORK and IWORK
138 arrays, returns these values as the first entries of the WORK,
139 RWORK and IWORK arrays, and no error message related to LWORK
140 or LRWORK or LIWORK is issued by XERBLA.
141
142 INFO (output) INTEGER
143 = 0: successful exit
144 < 0: if INFO = -i, the i-th argument had an illegal value
145 > 0: if INFO = i, and i is:
146 <= N: the algorithm failed to converge: i off-diagonal ele‐
147 ments of an intermediate tridiagonal form did not converge to
148 zero; > N: if INFO = N + i, for 1 <= i <= N, then CPBSTF
149 returned INFO = i: B is not positive definite. The factoriza‐
150 tion of B could not be completed and no eigenvalues or eigen‐
151 vectors were computed.
152
154 Based on contributions by
155 Mark Fahey, Department of Mathematics, Univ. of Kentucky, USA
156
157
158
159
160 LAPACK driver routine (version 3.N1o)vember 2006 CHBGVD(1)