205 SUBROUTINE zgebrd( M, N, A, LDA, D, E, TAUQ, TAUP, WORK, LWORK,
214 INTEGER INFO, LDA, LWORK, M, N
217 DOUBLE PRECISION D( * ), E( * )
218 COMPLEX*16 A( lda, * ), TAUP( * ), TAUQ( * ), WORK( * )
225 parameter ( one = ( 1.0d+0, 0.0d+0 ) )
229 INTEGER I, IINFO, J, LDWRKX, LDWRKY, LWKOPT, MINMN, NB,
237 INTRINSIC dble, max, min
248 nb = max( 1, ilaenv( 1,
'ZGEBRD',
' ', m, n, -1, -1 ) )
250 work( 1 ) = dble( lwkopt )
251 lquery = ( lwork.EQ.-1 )
254 ELSE IF( n.LT.0 )
THEN
256 ELSE IF( lda.LT.max( 1, m ) )
THEN
258 ELSE IF( lwork.LT.max( 1, m, n ) .AND. .NOT.lquery )
THEN
262 CALL xerbla(
'ZGEBRD', -info )
264 ELSE IF( lquery )
THEN
271 IF( minmn.EQ.0 )
THEN
280 IF( nb.GT.1 .AND. nb.LT.minmn )
THEN
284 nx = max( nb, ilaenv( 3,
'ZGEBRD',
' ', m, n, -1, -1 ) )
288 IF( nx.LT.minmn )
THEN
290 IF( lwork.LT.ws )
THEN
295 nbmin = ilaenv( 2,
'ZGEBRD',
' ', m, n, -1, -1 )
296 IF( lwork.GE.( m+n )*nbmin )
THEN
308 DO 30 i = 1, minmn - nx, nb
314 CALL zlabrd( m-i+1, n-i+1, nb, a( i, i ), lda, d( i ), e( i ),
315 $ tauq( i ), taup( i ), work, ldwrkx,
316 $ work( ldwrkx*nb+1 ), ldwrky )
321 CALL zgemm(
'No transpose',
'Conjugate transpose', m-i-nb+1,
322 $ n-i-nb+1, nb, -one, a( i+nb, i ), lda,
323 $ work( ldwrkx*nb+nb+1 ), ldwrky, one,
324 $ a( i+nb, i+nb ), lda )
325 CALL zgemm(
'No transpose',
'No transpose', m-i-nb+1, n-i-nb+1,
326 $ nb, -one, work( nb+1 ), ldwrkx, a( i, i+nb ), lda,
327 $ one, a( i+nb, i+nb ), lda )
332 DO 10 j = i, i + nb - 1
337 DO 20 j = i, i + nb - 1
346 CALL zgebd2( m-i+1, n-i+1, a( i, i ), lda, d( i ), e( i ),
347 $ tauq( i ), taup( i ), work, iinfo )
subroutine zgemm(TRANSA, TRANSB, M, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC)
ZGEMM
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine zgebrd(M, N, A, LDA, D, E, TAUQ, TAUP, WORK, LWORK, INFO)
ZGEBRD
subroutine zlabrd(M, N, NB, A, LDA, D, E, TAUQ, TAUP, X, LDX, Y, LDY)
ZLABRD reduces the first nb rows and columns of a general matrix to a bidiagonal form.
subroutine zgebd2(M, N, A, LDA, D, E, TAUQ, TAUP, WORK, INFO)
ZGEBD2 reduces a general matrix to bidiagonal form using an unblocked algorithm.