197 SUBROUTINE dlatrd( UPLO, N, NB, A, LDA, E, TAU, W, LDW )
205 INTEGER LDA, LDW, N, NB
208 DOUBLE PRECISION A( LDA, * ), E( * ), TAU( * ), W( LDW, * )
214 DOUBLE PRECISION ZERO, ONE, HALF
215 parameter( zero = 0.0d+0, one = 1.0d+0, half = 0.5d+0 )
219 DOUBLE PRECISION ALPHA
226 DOUBLE PRECISION DDOT
239 IF( lsame( uplo,
'U' ) )
THEN
243 DO 10 i = n, n - nb + 1, -1
249 CALL dgemv(
'No transpose', i, n-i, -one, a( 1, i+1 ),
250 $ lda, w( i, iw+1 ), ldw, one, a( 1, i ), 1 )
251 CALL dgemv(
'No transpose', i, n-i, -one, w( 1, iw+1 ),
252 $ ldw, a( i, i+1 ), lda, one, a( 1, i ), 1 )
259 CALL dlarfg( i-1, a( i-1, i ), a( 1, i ), 1, tau( i-1 ) )
260 e( i-1 ) = a( i-1, i )
265 CALL dsymv(
'Upper', i-1, one, a, lda, a( 1, i ), 1,
266 $ zero, w( 1, iw ), 1 )
268 CALL dgemv(
'Transpose', i-1, n-i, one, w( 1, iw+1 ),
269 $ ldw, a( 1, i ), 1, zero, w( i+1, iw ), 1 )
270 CALL dgemv(
'No transpose', i-1, n-i, -one,
271 $ a( 1, i+1 ), lda, w( i+1, iw ), 1, one,
273 CALL dgemv(
'Transpose', i-1, n-i, one, a( 1, i+1 ),
274 $ lda, a( 1, i ), 1, zero, w( i+1, iw ), 1 )
275 CALL dgemv(
'No transpose', i-1, n-i, -one,
276 $ w( 1, iw+1 ), ldw, w( i+1, iw ), 1, one,
279 CALL dscal( i-1, tau( i-1 ), w( 1, iw ), 1 )
280 alpha = -half*tau( i-1 )*ddot( i-1, w( 1, iw ), 1,
282 CALL daxpy( i-1, alpha, a( 1, i ), 1, w( 1, iw ), 1 )
294 CALL dgemv(
'No transpose', n-i+1, i-1, -one, a( i, 1 ),
295 $ lda, w( i, 1 ), ldw, one, a( i, i ), 1 )
296 CALL dgemv(
'No transpose', n-i+1, i-1, -one, w( i, 1 ),
297 $ ldw, a( i, 1 ), lda, one, a( i, i ), 1 )
303 CALL dlarfg( n-i, a( i+1, i ), a( min( i+2, n ), i ), 1,
310 CALL dsymv(
'Lower', n-i, one, a( i+1, i+1 ), lda,
311 $ a( i+1, i ), 1, zero, w( i+1, i ), 1 )
312 CALL dgemv(
'Transpose', n-i, i-1, one, w( i+1, 1 ), ldw,
313 $ a( i+1, i ), 1, zero, w( 1, i ), 1 )
314 CALL dgemv(
'No transpose', n-i, i-1, -one, a( i+1, 1 ),
315 $ lda, w( 1, i ), 1, one, w( i+1, i ), 1 )
316 CALL dgemv(
'Transpose', n-i, i-1, one, a( i+1, 1 ), lda,
317 $ a( i+1, i ), 1, zero, w( 1, i ), 1 )
318 CALL dgemv(
'No transpose', n-i, i-1, -one, w( i+1, 1 ),
319 $ ldw, w( 1, i ), 1, one, w( i+1, i ), 1 )
320 CALL dscal( n-i, tau( i ), w( i+1, i ), 1 )
321 alpha = -half*tau( i )*ddot( n-i, w( i+1, i ), 1,
323 CALL daxpy( n-i, alpha, a( i+1, i ), 1, w( i+1, i ), 1 )
subroutine daxpy(n, da, dx, incx, dy, incy)
DAXPY
subroutine dgemv(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
DGEMV
subroutine dsymv(uplo, n, alpha, a, lda, x, incx, beta, y, incy)
DSYMV
subroutine dlarfg(n, alpha, x, incx, tau)
DLARFG generates an elementary reflector (Householder matrix).
subroutine dlatrd(uplo, n, nb, a, lda, e, tau, w, ldw)
DLATRD reduces the first nb rows and columns of a symmetric/Hermitian matrix A to real tridiagonal fo...
subroutine dscal(n, da, dx, incx)
DSCAL