185 SUBROUTINE cunmrz( SIDE, TRANS, M, N, K, L, A, LDA, TAU, C, LDC,
186 $ WORK, LWORK, INFO )
193 CHARACTER SIDE, TRANS
194 INTEGER INFO, K, L, LDA, LDC, LWORK, M, N
197 COMPLEX A( LDA, * ), C( LDC, * ), TAU( * ), WORK( * )
203 INTEGER NBMAX, LDT, TSIZE
204 parameter( nbmax = 64, ldt = nbmax+1,
205 $ tsize = ldt*nbmax )
208 LOGICAL LEFT, LQUERY, NOTRAN
210 INTEGER I, I1, I2, I3, IB, IC, IINFO, IWT, JA, JC,
211 $ ldwork, lwkopt, mi, nb, nbmin, ni, nq, nw
217 EXTERNAL lsame, ilaenv, sroundup_lwork
230 left = lsame( side,
'L' )
231 notran = lsame( trans,
'N' )
232 lquery = ( lwork.EQ.-1 )
243 IF( .NOT.left .AND. .NOT.lsame( side,
'R' ) )
THEN
245 ELSE IF( .NOT.notran .AND. .NOT.lsame( trans,
'C' ) )
THEN
247 ELSE IF( m.LT.0 )
THEN
249 ELSE IF( n.LT.0 )
THEN
251 ELSE IF( k.LT.0 .OR. k.GT.nq )
THEN
253 ELSE IF( l.LT.0 .OR. ( left .AND. ( l.GT.m ) ) .OR.
254 $ ( .NOT.left .AND. ( l.GT.n ) ) )
THEN
256 ELSE IF( lda.LT.max( 1, k ) )
THEN
258 ELSE IF( ldc.LT.max( 1, m ) )
THEN
260 ELSE IF( lwork.LT.nw .AND. .NOT.lquery )
THEN
268 IF( m.EQ.0 .OR. n.EQ.0 )
THEN
271 nb = min( nbmax, ilaenv( 1,
'CUNMRQ', side // trans, m, n,
273 lwkopt = nw*nb + tsize
275 work( 1 ) = sroundup_lwork(lwkopt)
279 CALL xerbla(
'CUNMRZ', -info )
281 ELSE IF( lquery )
THEN
287 IF( m.EQ.0 .OR. n.EQ.0 )
THEN
293 nb = min( nbmax, ilaenv( 1,
'CUNMRQ', side // trans, m, n, k,
297 IF( nb.GT.1 .AND. nb.LT.k )
THEN
298 IF( lwork.LT.lwkopt )
THEN
299 nb = (lwork-tsize) / ldwork
300 nbmin = max( 2, ilaenv( 2,
'CUNMRQ', side // trans, m, n, k,
305 IF( nb.LT.nbmin .OR. nb.GE.k )
THEN
309 CALL cunmr3( side, trans, m, n, k, l, a, lda, tau, c, ldc,
316 IF( ( left .AND. .NOT.notran ) .OR.
317 $ ( .NOT.left .AND. notran ) )
THEN
322 i1 = ( ( k-1 ) / nb )*nb + 1
344 ib = min( nb, k-i+1 )
349 CALL clarzt(
'Backward',
'Rowwise', l, ib, a( i, ja ), lda,
350 $ tau( i ), work( iwt ), ldt )
368 CALL clarzb( side, transt,
'Backward',
'Rowwise', mi, ni,
369 $ ib, l, a( i, ja ), lda, work( iwt ), ldt,
370 $ c( ic, jc ), ldc, work, ldwork )
375 work( 1 ) = sroundup_lwork(lwkopt)
subroutine xerbla(srname, info)
subroutine clarzb(side, trans, direct, storev, m, n, k, l, v, ldv, t, ldt, c, ldc, work, ldwork)
CLARZB applies a block reflector or its conjugate-transpose to a general matrix.
subroutine clarzt(direct, storev, n, k, v, ldv, tau, t, ldt)
CLARZT forms the triangular factor T of a block reflector H = I - vtvH.
subroutine cunmr3(side, trans, m, n, k, l, a, lda, tau, c, ldc, work, info)
CUNMR3 multiplies a general matrix by the unitary matrix from a RZ factorization determined by ctzrzf...
subroutine cunmrz(side, trans, m, n, k, l, a, lda, tau, c, ldc, work, lwork, info)
CUNMRZ