122 SUBROUTINE zgerq2( M, N, A, LDA, TAU, WORK, INFO )
129 INTEGER INFO, LDA, M, N
132 COMPLEX*16 A( LDA, * ), TAU( * ), WORK( * )
139 parameter( one = ( 1.0d+0, 0.0d+0 ) )
158 ELSE IF( n.LT.0 )
THEN
160 ELSE IF( lda.LT.max( 1, m ) )
THEN
164 CALL xerbla(
'ZGERQ2', -info )
175 CALL zlacgv( n-k+i, a( m-k+i, 1 ), lda )
176 alpha = a( m-k+i, n-k+i )
177 CALL zlarfg( n-k+i, alpha, a( m-k+i, 1 ), lda, tau( i ) )
181 a( m-k+i, n-k+i ) = one
182 CALL zlarf(
'Right', m-k+i-1, n-k+i, a( m-k+i, 1 ), lda,
183 $ tau( i ), a, lda, work )
184 a( m-k+i, n-k+i ) = alpha
185 CALL zlacgv( n-k+i-1, a( m-k+i, 1 ), lda )
subroutine xerbla(srname, info)
subroutine zgerq2(m, n, a, lda, tau, work, info)
ZGERQ2 computes the RQ factorization of a general rectangular matrix using an unblocked algorithm.
subroutine zlacgv(n, x, incx)
ZLACGV conjugates a complex vector.
subroutine zlarf(side, m, n, v, incv, tau, c, ldc, work)
ZLARF applies an elementary reflector to a general rectangular matrix.
subroutine zlarfg(n, alpha, x, incx, tau)
ZLARFG generates an elementary reflector (Householder matrix).