136 SUBROUTINE dgelqf( M, N, A, LDA, TAU, WORK, LWORK, INFO )
144 INTEGER INFO, LDA, LWORK, M, N
147 DOUBLE PRECISION A( lda, * ), TAU( * ), WORK( * )
154 INTEGER I, IB, IINFO, IWS, K, LDWORK, LWKOPT, NB,
172 nb = ilaenv( 1,
'DGELQF',
' ', m, n, -1, -1 )
175 lquery = ( lwork.EQ.-1 )
178 ELSE IF( n.LT.0 )
THEN
180 ELSE IF( lda.LT.max( 1, m ) )
THEN
182 ELSE IF( lwork.LT.max( 1, m ) .AND. .NOT.lquery )
THEN
186 CALL xerbla(
'DGELQF', -info )
188 ELSE IF( lquery )
THEN
203 IF( nb.GT.1 .AND. nb.LT.k )
THEN
207 nx = max( 0, ilaenv( 3,
'DGELQF',
' ', m, n, -1, -1 ) )
214 IF( lwork.LT.iws )
THEN
220 nbmin = max( 2, ilaenv( 2,
'DGELQF',
' ', m, n, -1,
226 IF( nb.GE.nbmin .AND. nb.LT.k .AND. nx.LT.k )
THEN
230 DO 10 i = 1, k - nx, nb
231 ib = min( k-i+1, nb )
236 CALL dgelq2( ib, n-i+1, a( i, i ), lda, tau( i ), work,
243 CALL dlarft(
'Forward',
'Rowwise', n-i+1, ib, a( i, i ),
244 $ lda, tau( i ), work, ldwork )
248 CALL dlarfb(
'Right',
'No transpose',
'Forward',
249 $
'Rowwise', m-i-ib+1, n-i+1, ib, a( i, i ),
250 $ lda, work, ldwork, a( i+ib, i ), lda,
251 $ work( ib+1 ), ldwork )
261 $
CALL dgelq2( m-i+1, n-i+1, a( i, i ), lda, tau( i ), work,
subroutine dlarfb(SIDE, TRANS, DIRECT, STOREV, M, N, K, V, LDV, T, LDT, C, LDC, WORK, LDWORK)
DLARFB applies a block reflector or its transpose to a general rectangular matrix.
subroutine dgelq2(M, N, A, LDA, TAU, WORK, INFO)
DGELQ2 computes the LQ factorization of a general rectangular matrix using an unblocked algorithm...
subroutine dgelqf(M, N, A, LDA, TAU, WORK, LWORK, INFO)
DGELQF
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine dlarft(DIRECT, STOREV, N, K, V, LDV, TAU, T, LDT)
DLARFT forms the triangular factor T of a block reflector H = I - vtvH