168 SUBROUTINE cunmtr( SIDE, UPLO, TRANS, M, N, A, LDA, TAU, C,
170 $ WORK, LWORK, INFO )
177 CHARACTER SIDE, TRANS, UPLO
178 INTEGER INFO, LDA, LDC, LWORK, M, N
181 COMPLEX A( LDA, * ), C( LDC, * ), TAU( * ),
188 LOGICAL LEFT, LQUERY, UPPER
189 INTEGER I1, I2, IINFO, LWKOPT, MI, NB, NI, NQ, NW
195 EXTERNAL ilaenv, lsame, sroundup_lwork
208 left = lsame( side,
'L' )
209 upper = lsame( uplo,
'U' )
210 lquery = ( lwork.EQ.-1 )
221 IF( .NOT.left .AND. .NOT.lsame( side,
'R' ) )
THEN
223 ELSE IF( .NOT.upper .AND. .NOT.lsame( uplo,
'L' ) )
THEN
225 ELSE IF( .NOT.lsame( trans,
'N' ) .AND.
226 $ .NOT.lsame( trans,
'C' ) )
229 ELSE IF( m.LT.0 )
THEN
231 ELSE IF( n.LT.0 )
THEN
233 ELSE IF( lda.LT.max( 1, nq ) )
THEN
235 ELSE IF( ldc.LT.max( 1, m ) )
THEN
237 ELSE IF( lwork.LT.nw .AND. .NOT.lquery )
THEN
244 nb = ilaenv( 1,
'CUNMQL', side // trans, m-1, n, m-1,
247 nb = ilaenv( 1,
'CUNMQL', side // trans, m, n-1, n-1,
252 nb = ilaenv( 1,
'CUNMQR', side // trans, m-1, n, m-1,
255 nb = ilaenv( 1,
'CUNMQR', side // trans, m, n-1, n-1,
260 work( 1 ) = sroundup_lwork(lwkopt)
264 CALL xerbla(
'CUNMTR', -info )
266 ELSE IF( lquery )
THEN
272 IF( m.EQ.0 .OR. n.EQ.0 .OR. nq.EQ.1 )
THEN
289 CALL cunmql( side, trans, mi, ni, nq-1, a( 1, 2 ), lda, tau,
291 $ ldc, work, lwork, iinfo )
303 CALL cunmqr( side, trans, mi, ni, nq-1, a( 2, 1 ), lda, tau,
304 $ c( i1, i2 ), ldc, work, lwork, iinfo )
306 work( 1 ) = sroundup_lwork(lwkopt)
subroutine cunmql(side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork, info)
CUNMQL
subroutine cunmqr(side, trans, m, n, k, a, lda, tau, c, ldc, work, lwork, info)
CUNMQR
subroutine cunmtr(side, uplo, trans, m, n, a, lda, tau, c, ldc, work, lwork, info)
CUNMTR