215 SUBROUTINE cggqrf( N, M, P, A, LDA, TAUA, B, LDB, TAUB, WORK,
224 INTEGER INFO, LDA, LDB, LWORK, M, N, P
227 COMPLEX A( lda, * ), B( ldb, * ), TAUA( * ), TAUB( * ),
235 INTEGER LOPT, LWKOPT, NB, NB1, NB2, NB3
245 INTRINSIC int, max, min
252 nb1 = ilaenv( 1,
'CGEQRF',
' ', n, m, -1, -1 )
253 nb2 = ilaenv( 1,
'CGERQF',
' ', n, p, -1, -1 )
254 nb3 = ilaenv( 1,
'CUNMQR',
' ', n, m, p, -1 )
255 nb = max( nb1, nb2, nb3 )
256 lwkopt = max( n, m, p)*nb
258 lquery = ( lwork.EQ.-1 )
261 ELSE IF( m.LT.0 )
THEN
263 ELSE IF( p.LT.0 )
THEN
265 ELSE IF( lda.LT.max( 1, n ) )
THEN
267 ELSE IF( ldb.LT.max( 1, n ) )
THEN
269 ELSE IF( lwork.LT.max( 1, n, m, p ) .AND. .NOT.lquery )
THEN
273 CALL xerbla(
'CGGQRF', -info )
275 ELSE IF( lquery )
THEN
281 CALL cgeqrf( n, m, a, lda, taua, work, lwork, info )
286 CALL cunmqr(
'Left',
'Conjugate Transpose', n, p, min( n, m ), a,
287 $ lda, taua, b, ldb, work, lwork, info )
288 lopt = max( lopt, int( work( 1 ) ) )
292 CALL cgerqf( n, p, b, ldb, taub, work, lwork, info )
293 work( 1 ) = max( lopt, int( work( 1 ) ) )
subroutine cggqrf(N, M, P, A, LDA, TAUA, B, LDB, TAUB, WORK, LWORK, INFO)
CGGQRF
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine cunmqr(SIDE, TRANS, M, N, K, A, LDA, TAU, C, LDC, WORK, LWORK, INFO)
CUNMQR
subroutine cgerqf(M, N, A, LDA, TAU, WORK, LWORK, INFO)
CGERQF
subroutine cgeqrf(M, N, A, LDA, TAU, WORK, LWORK, INFO)
CGEQRF