306 SUBROUTINE zhegvx( ITYPE, JOBZ, RANGE, UPLO, N, A, LDA, B, LDB,
307 $ vl, vu, il, iu, abstol, m, w, z, ldz, work,
308 $ lwork, rwork, iwork, ifail, info )
316 CHARACTER JOBZ, RANGE, UPLO
317 INTEGER IL, INFO, ITYPE, IU, LDA, LDB, LDZ, LWORK, M, N
318 DOUBLE PRECISION ABSTOL, VL, VU
321 INTEGER IFAIL( * ), IWORK( * )
322 DOUBLE PRECISION RWORK( * ), W( * )
323 COMPLEX*16 A( lda, * ), B( ldb, * ), WORK( * ),
331 parameter ( cone = ( 1.0d+0, 0.0d+0 ) )
334 LOGICAL ALLEIG, INDEIG, LQUERY, UPPER, VALEIG, WANTZ
341 EXTERNAL lsame, ilaenv
353 wantz = lsame( jobz,
'V' )
354 upper = lsame( uplo,
'U' )
355 alleig = lsame( range,
'A' )
356 valeig = lsame( range,
'V' )
357 indeig = lsame( range,
'I' )
358 lquery = ( lwork.EQ.-1 )
361 IF( itype.LT.1 .OR. itype.GT.3 )
THEN
363 ELSE IF( .NOT.( wantz .OR. lsame( jobz,
'N' ) ) )
THEN
365 ELSE IF( .NOT.( alleig .OR. valeig .OR. indeig ) )
THEN
367 ELSE IF( .NOT.( upper .OR. lsame( uplo,
'L' ) ) )
THEN
369 ELSE IF( n.LT.0 )
THEN
371 ELSE IF( lda.LT.max( 1, n ) )
THEN
373 ELSE IF( ldb.LT.max( 1, n ) )
THEN
377 IF( n.GT.0 .AND. vu.LE.vl )
379 ELSE IF( indeig )
THEN
380 IF( il.LT.1 .OR. il.GT.max( 1, n ) )
THEN
382 ELSE IF( iu.LT.min( n, il ) .OR. iu.GT.n )
THEN
388 IF (ldz.LT.1 .OR. (wantz .AND. ldz.LT.n))
THEN
394 nb = ilaenv( 1,
'ZHETRD', uplo, n, -1, -1, -1 )
395 lwkopt = max( 1, ( nb + 1 )*n )
398 IF( lwork.LT.max( 1, 2*n ) .AND. .NOT.lquery )
THEN
404 CALL xerbla(
'ZHEGVX', -info )
406 ELSE IF( lquery )
THEN
419 CALL zpotrf( uplo, n, b, ldb, info )
427 CALL zhegst( itype, uplo, n, a, lda, b, ldb, info )
428 CALL zheevx( jobz, range, uplo, n, a, lda, vl, vu, il, iu, abstol,
429 $ m, w, z, ldz, work, lwork, rwork, iwork, ifail,
438 IF( itype.EQ.1 .OR. itype.EQ.2 )
THEN
449 CALL ztrsm(
'Left', uplo, trans,
'Non-unit', n, m, cone, b,
452 ELSE IF( itype.EQ.3 )
THEN
463 CALL ztrmm(
'Left', uplo, trans,
'Non-unit', n, m, cone, b,
subroutine zpotrf(UPLO, N, A, LDA, INFO)
ZPOTRF VARIANT: right looking block version of the algorithm, calling Level 3 BLAS.
subroutine zhegst(ITYPE, UPLO, N, A, LDA, B, LDB, INFO)
ZHEGST
subroutine zhegvx(ITYPE, JOBZ, RANGE, UPLO, N, A, LDA, B, LDB, VL, VU, IL, IU, ABSTOL, M, W, Z, LDZ, WORK, LWORK, RWORK, IWORK, IFAIL, INFO)
ZHEGVX
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine ztrmm(SIDE, UPLO, TRANSA, DIAG, M, N, ALPHA, A, LDA, B, LDB)
ZTRMM
subroutine zheevx(JOBZ, RANGE, UPLO, N, A, LDA, VL, VU, IL, IU, ABSTOL, M, W, Z, LDZ, WORK, LWORK, RWORK, IWORK, IFAIL, INFO)
ZHEEVX computes the eigenvalues and, optionally, the left and/or right eigenvectors for HE matrices ...
subroutine ztrsm(SIDE, UPLO, TRANSA, DIAG, M, N, ALPHA, A, LDA, B, LDB)
ZTRSM