193 SUBROUTINE chetrd( UPLO, N, A, LDA, D, E, TAU, WORK, LWORK, INFO )
202 INTEGER INFO, LDA, LWORK, N
206 COMPLEX A( lda, * ), TAU( * ), WORK( * )
213 parameter ( one = 1.0e+0 )
215 parameter ( cone = ( 1.0e+0, 0.0e+0 ) )
218 LOGICAL LQUERY, UPPER
219 INTEGER I, IINFO, IWS, J, KK, LDWORK, LWKOPT, NB,
231 EXTERNAL lsame, ilaenv
238 upper = lsame( uplo,
'U' )
239 lquery = ( lwork.EQ.-1 )
240 IF( .NOT.upper .AND. .NOT.lsame( uplo,
'L' ) )
THEN
242 ELSE IF( n.LT.0 )
THEN
244 ELSE IF( lda.LT.max( 1, n ) )
THEN
246 ELSE IF( lwork.LT.1 .AND. .NOT.lquery )
THEN
254 nb = ilaenv( 1,
'CHETRD', uplo, n, -1, -1, -1 )
260 CALL xerbla(
'CHETRD', -info )
262 ELSE IF( lquery )
THEN
275 IF( nb.GT.1 .AND. nb.LT.n )
THEN
280 nx = max( nb, ilaenv( 3,
'CHETRD', uplo, n, -1, -1, -1 ) )
287 IF( lwork.LT.iws )
THEN
293 nb = max( lwork / ldwork, 1 )
294 nbmin = ilaenv( 2,
'CHETRD', uplo, n, -1, -1, -1 )
310 kk = n - ( ( n-nx+nb-1 ) / nb )*nb
311 DO 20 i = n - nb + 1, kk + 1, -nb
317 CALL clatrd( uplo, i+nb-1, nb, a, lda, e, tau, work,
323 CALL cher2k( uplo,
'No transpose', i-1, nb, -cone,
324 $ a( 1, i ), lda, work, ldwork, one, a, lda )
329 DO 10 j = i, i + nb - 1
330 a( j-1, j ) = e( j-1 )
337 CALL chetd2( uplo, kk, a, lda, d, e, tau, iinfo )
342 DO 40 i = 1, n - nx, nb
348 CALL clatrd( uplo, n-i+1, nb, a( i, i ), lda, e( i ),
349 $ tau( i ), work, ldwork )
354 CALL cher2k( uplo,
'No transpose', n-i-nb+1, nb, -cone,
355 $ a( i+nb, i ), lda, work( nb+1 ), ldwork, one,
356 $ a( i+nb, i+nb ), lda )
361 DO 30 j = i, i + nb - 1
369 CALL chetd2( uplo, n-i+1, a( i, i ), lda, d( i ), e( i ),
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine chetd2(UPLO, N, A, LDA, D, E, TAU, INFO)
CHETD2 reduces a Hermitian matrix to real symmetric tridiagonal form by an unitary similarity transfo...
subroutine clatrd(UPLO, N, NB, A, LDA, E, TAU, W, LDW)
CLATRD reduces the first nb rows and columns of a symmetric/Hermitian matrix A to real tridiagonal fo...
subroutine chetrd(UPLO, N, A, LDA, D, E, TAU, WORK, LWORK, INFO)
CHETRD
subroutine cher2k(UPLO, TRANS, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC)
CHER2K