140 SUBROUTINE zgeqrfp( M, N, A, LDA, TAU, WORK, LWORK, INFO )
148 INTEGER INFO, LDA, LWORK, M, N
151 COMPLEX*16 A( lda, * ), TAU( * ), WORK( * )
158 INTEGER I, IB, IINFO, IWS, K, LDWORK, LWKOPT, NB,
176 nb = ilaenv( 1,
'ZGEQRF',
' ', m, n, -1, -1 )
179 lquery = ( lwork.EQ.-1 )
182 ELSE IF( n.LT.0 )
THEN
184 ELSE IF( lda.LT.max( 1, m ) )
THEN
186 ELSE IF( lwork.LT.max( 1, n ) .AND. .NOT.lquery )
THEN
190 CALL xerbla(
'ZGEQRFP', -info )
192 ELSE IF( lquery )
THEN
207 IF( nb.GT.1 .AND. nb.LT.k )
THEN
211 nx = max( 0, ilaenv( 3,
'ZGEQRF',
' ', m, n, -1, -1 ) )
218 IF( lwork.LT.iws )
THEN
224 nbmin = max( 2, ilaenv( 2,
'ZGEQRF',
' ', m, n, -1,
230 IF( nb.GE.nbmin .AND. nb.LT.k .AND. nx.LT.k )
THEN
234 DO 10 i = 1, k - nx, nb
235 ib = min( k-i+1, nb )
240 CALL zgeqr2p( m-i+1, ib, a( i, i ), lda, tau( i ), work,
247 CALL zlarft(
'Forward',
'Columnwise', m-i+1, ib,
248 $ a( i, i ), lda, tau( i ), work, ldwork )
252 CALL zlarfb(
'Left',
'Conjugate transpose',
'Forward',
253 $
'Columnwise', m-i+1, n-i-ib+1, ib,
254 $ a( i, i ), lda, work, ldwork, a( i, i+ib ),
255 $ lda, work( ib+1 ), ldwork )
265 $
CALL zgeqr2p( m-i+1, n-i+1, a( i, i ), lda, tau( i ), work,
subroutine zgeqrfp(M, N, A, LDA, TAU, WORK, LWORK, INFO)
ZGEQRFP
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine zlarfb(SIDE, TRANS, DIRECT, STOREV, M, N, K, V, LDV, T, LDT, C, LDC, WORK, LDWORK)
ZLARFB applies a block reflector or its conjugate-transpose to a general rectangular matrix...
subroutine zlarft(DIRECT, STOREV, N, K, V, LDV, TAU, T, LDT)
ZLARFT forms the triangular factor T of a block reflector H = I - vtvH
subroutine zgeqr2p(M, N, A, LDA, TAU, WORK, INFO)
ZGEQR2P computes the QR factorization of a general rectangular matrix with non-negative diagonal elem...