183 SUBROUTINE chbgv( JOBZ, UPLO, N, KA, KB, AB, LDAB, BB, LDBB, W, Z,
184 $ ldz, work, rwork, info )
193 INTEGER info, ka, kb, ldab, ldbb, ldz, n
196 REAL rwork( * ), w( * )
197 COMPLEX ab( ldab, * ), bb( ldbb, * ), work( * ),
206 INTEGER iinfo, inde, indwrk
219 wantz =
lsame( jobz,
'V' )
220 upper =
lsame( uplo,
'U' )
223 IF( .NOT.( wantz .OR.
lsame( jobz,
'N' ) ) )
THEN
225 ELSE IF( .NOT.( upper .OR.
lsame( uplo,
'L' ) ) )
THEN
227 ELSE IF( n.LT.0 )
THEN
229 ELSE IF( ka.LT.0 )
THEN
231 ELSE IF( kb.LT.0 .OR. kb.GT.ka )
THEN
233 ELSE IF( ldab.LT.ka+1 )
THEN
235 ELSE IF( ldbb.LT.kb+1 )
THEN
237 ELSE IF( ldz.LT.1 .OR. ( wantz .AND. ldz.LT.n ) )
THEN
241 CALL
xerbla(
'CHBGV ', -info )
252 CALL
cpbstf( uplo, n, kb, bb, ldbb, info )
262 CALL
chbgst( jobz, uplo, n, ka, kb, ab, ldab, bb, ldbb, z, ldz,
263 $ work, rwork( indwrk ), iinfo )
272 CALL
chbtrd( vect, uplo, n, ka, ab, ldab, w, rwork( inde ), z,
277 IF( .NOT.wantz )
THEN
278 CALL
ssterf( n, w, rwork( inde ), info )
280 CALL
csteqr( jobz, n, w, rwork( inde ), z, ldz,
281 $ rwork( indwrk ), info )