193 SUBROUTINE ssytrd( UPLO, N, A, LDA, D, E, TAU, WORK, LWORK, INFO )
202 INTEGER INFO, LDA, LWORK, N
205 REAL A( lda, * ), D( * ), E( * ), TAU( * ),
213 parameter ( one = 1.0e+0 )
216 LOGICAL LQUERY, UPPER
217 INTEGER I, IINFO, IWS, J, KK, LDWORK, LWKOPT, NB,
229 EXTERNAL lsame, ilaenv
236 upper = lsame( uplo,
'U' )
237 lquery = ( lwork.EQ.-1 )
238 IF( .NOT.upper .AND. .NOT.lsame( uplo,
'L' ) )
THEN
240 ELSE IF( n.LT.0 )
THEN
242 ELSE IF( lda.LT.max( 1, n ) )
THEN
244 ELSE IF( lwork.LT.1 .AND. .NOT.lquery )
THEN
252 nb = ilaenv( 1,
'SSYTRD', uplo, n, -1, -1, -1 )
258 CALL xerbla(
'SSYTRD', -info )
260 ELSE IF( lquery )
THEN
273 IF( nb.GT.1 .AND. nb.LT.n )
THEN
278 nx = max( nb, ilaenv( 3,
'SSYTRD', uplo, n, -1, -1, -1 ) )
285 IF( lwork.LT.iws )
THEN
291 nb = max( lwork / ldwork, 1 )
292 nbmin = ilaenv( 2,
'SSYTRD', uplo, n, -1, -1, -1 )
308 kk = n - ( ( n-nx+nb-1 ) / nb )*nb
309 DO 20 i = n - nb + 1, kk + 1, -nb
315 CALL slatrd( uplo, i+nb-1, nb, a, lda, e, tau, work,
321 CALL ssyr2k( uplo,
'No transpose', i-1, nb, -one, a( 1, i ),
322 $ lda, work, ldwork, one, a, lda )
327 DO 10 j = i, i + nb - 1
328 a( j-1, j ) = e( j-1 )
335 CALL ssytd2( uplo, kk, a, lda, d, e, tau, iinfo )
340 DO 40 i = 1, n - nx, nb
346 CALL slatrd( uplo, n-i+1, nb, a( i, i ), lda, e( i ),
347 $ tau( i ), work, ldwork )
352 CALL ssyr2k( uplo,
'No transpose', n-i-nb+1, nb, -one,
353 $ a( i+nb, i ), lda, work( nb+1 ), ldwork, one,
354 $ a( i+nb, i+nb ), lda )
359 DO 30 j = i, i + nb - 1
367 CALL ssytd2( uplo, n-i+1, a( i, i ), lda, d( i ), e( i ),
subroutine ssytd2(UPLO, N, A, LDA, D, E, TAU, INFO)
SSYTD2 reduces a symmetric matrix to real symmetric tridiagonal form by an orthogonal similarity tran...
subroutine ssytrd(UPLO, N, A, LDA, D, E, TAU, WORK, LWORK, INFO)
SSYTRD
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine ssyr2k(UPLO, TRANS, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC)
SSYR2K
subroutine slatrd(UPLO, N, NB, A, LDA, E, TAU, W, LDW)
SLATRD reduces the first nb rows and columns of a symmetric/Hermitian matrix A to real tridiagonal fo...