122 SUBROUTINE dgerqs( M, N, NRHS, A, LDA, TAU, B, LDB, WORK, LWORK,
131 INTEGER INFO, LDA, LDB, LWORK, M, N, NRHS
134 DOUBLE PRECISION A( lda, * ), B( ldb, * ), TAU( * ),
141 DOUBLE PRECISION ZERO, ONE
142 parameter ( zero = 0.0d+0, one = 1.0d+0 )
157 ELSE IF( n.LT.0 .OR. m.GT.n )
THEN
159 ELSE IF( nrhs.LT.0 )
THEN
161 ELSE IF( lda.LT.max( 1, m ) )
THEN
163 ELSE IF( ldb.LT.max( 1, n ) )
THEN
165 ELSE IF( lwork.LT.1 .OR. lwork.LT.nrhs .AND. m.GT.0 .AND. n.GT.0 )
170 CALL xerbla(
'DGERQS', -info )
176 IF( n.EQ.0 .OR. nrhs.EQ.0 .OR. m.EQ.0 )
181 CALL dtrsm(
'Left',
'Upper',
'No transpose',
'Non-unit', m, nrhs,
182 $ one, a( 1, n-m+1 ), lda, b( n-m+1, 1 ), ldb )
186 CALL dlaset(
'Full', n-m, nrhs, zero, zero, b, ldb )
190 CALL dormrq(
'Left',
'Transpose', n, nrhs, m, a, lda, tau, b, ldb,
191 $ work, lwork, info )
subroutine dtrsm(SIDE, UPLO, TRANSA, DIAG, M, N, ALPHA, A, LDA, B, LDB)
DTRSM
subroutine dlaset(UPLO, M, N, ALPHA, BETA, A, LDA)
DLASET initializes the off-diagonal elements and the diagonal elements of a matrix to given values...
subroutine dgerqs(M, N, NRHS, A, LDA, TAU, B, LDB, WORK, LWORK, INFO)
DGERQS
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine dormrq(SIDE, TRANS, M, N, K, A, LDA, TAU, C, LDC, WORK, LWORK, INFO)
DORMRQ