231 SUBROUTINE chpgvd( ITYPE, JOBZ, UPLO, N, AP, BP, W, Z, LDZ, WORK,
232 $ lwork, rwork, lrwork, iwork, liwork, info )
241 INTEGER INFO, ITYPE, LDZ, LIWORK, LRWORK, LWORK, N
245 REAL RWORK( * ), W( * )
246 COMPLEX AP( * ), BP( * ), WORK( * ), Z( ldz, * )
252 LOGICAL LQUERY, UPPER, WANTZ
254 INTEGER J, LIWMIN, LRWMIN, LWMIN, NEIG
270 wantz = lsame( jobz,
'V' )
271 upper = lsame( uplo,
'U' )
272 lquery = ( lwork.EQ.-1 .OR. lrwork.EQ.-1 .OR. liwork.EQ.-1 )
275 IF( itype.LT.1 .OR. itype.GT.3 )
THEN
277 ELSE IF( .NOT.( wantz .OR. lsame( jobz,
'N' ) ) )
THEN
279 ELSE IF( .NOT.( upper .OR. lsame( uplo,
'L' ) ) )
THEN
281 ELSE IF( n.LT.0 )
THEN
283 ELSE IF( ldz.LT.1 .OR. ( wantz .AND. ldz.LT.n ) )
THEN
295 lrwmin = 1 + 5*n + 2*n**2
307 IF( lwork.LT.lwmin .AND. .NOT.lquery )
THEN
309 ELSE IF( lrwork.LT.lrwmin .AND. .NOT.lquery )
THEN
311 ELSE IF( liwork.LT.liwmin .AND. .NOT.lquery )
THEN
317 CALL xerbla(
'CHPGVD', -info )
319 ELSE IF( lquery )
THEN
330 CALL cpptrf( uplo, n, bp, info )
338 CALL chpgst( itype, uplo, n, ap, bp, info )
339 CALL chpevd( jobz, uplo, n, ap, w, z, ldz, work, lwork, rwork,
340 $ lrwork, iwork, liwork, info )
341 lwmin = max(
REAL( LWMIN ),
REAL( WORK( 1 ) ) )
342 lrwmin = max(
REAL( LRWMIN ),
REAL( RWORK( 1 ) ) )
343 liwmin = max(
REAL( LIWMIN ),
REAL( IWORK( 1 ) ) )
352 IF( itype.EQ.1 .OR. itype.EQ.2 )
THEN
364 CALL ctpsv( uplo, trans,
'Non-unit', n, bp, z( 1, j ),
368 ELSE IF( itype.EQ.3 )
THEN
380 CALL ctpmv( uplo, trans,
'Non-unit', n, bp, z( 1, j ),
subroutine ctpmv(UPLO, TRANS, DIAG, N, AP, X, INCX)
CTPMV
subroutine chpgst(ITYPE, UPLO, N, AP, BP, INFO)
CHPGST
subroutine chpgvd(ITYPE, JOBZ, UPLO, N, AP, BP, W, Z, LDZ, WORK, LWORK, RWORK, LRWORK, IWORK, LIWORK, INFO)
CHPGVD
subroutine cpptrf(UPLO, N, AP, INFO)
CPPTRF
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine ctpsv(UPLO, TRANS, DIAG, N, AP, X, INCX)
CTPSV
subroutine chpevd(JOBZ, UPLO, N, AP, W, Z, LDZ, WORK, LWORK, RWORK, LRWORK, IWORK, LIWORK, INFO)
CHPEVD computes the eigenvalues and, optionally, the left and/or right eigenvectors for OTHER matric...