172 SUBROUTINE ctpqrt2( M, N, L, A, LDA, B, LDB, T, LDT, INFO )
179 INTEGER INFO, LDA, LDB, LDT, N, M, L
182 COMPLEX A( LDA, * ), B( LDB, * ), T( LDT, * )
189 parameter( one = (1.0,0.0), zero = (0.0,0.0) )
192 INTEGER I, J, P, MP, NP
208 ELSE IF( n.LT.0 )
THEN
210 ELSE IF( l.LT.0 .OR. l.GT.min(m,n) )
THEN
212 ELSE IF( lda.LT.max( 1, n ) )
THEN
214 ELSE IF( ldb.LT.max( 1, m ) )
THEN
216 ELSE IF( ldt.LT.max( 1, n ) )
THEN
220 CALL xerbla(
'CTPQRT2', -info )
226 IF( n.EQ.0 .OR. m.EQ.0 )
RETURN
233 CALL clarfg( p+1, a( i, i ), b( 1, i ), 1, t( i, 1 ) )
239 t( j, n ) = conjg(a( i, i+j ))
241 CALL cgemv(
'C', p, n-i, one, b( 1, i+1 ), ldb,
242 $ b( 1, i ), 1, one, t( 1, n ), 1 )
246 alpha = -conjg(t( i, 1 ))
248 a( i, i+j ) = a( i, i+j ) + alpha*conjg(t( j, n ))
250 CALL cgerc( p, n-i, alpha, b( 1, i ), 1,
251 $ t( 1, n ), 1, b( 1, i+1 ), ldb )
271 t( j, i ) = alpha*b( m-l+j, i )
273 CALL ctrmv(
'U',
'C',
'N', p, b( mp, 1 ), ldb,
278 CALL cgemv(
'C', l, i-1-p, alpha, b( mp, np ), ldb,
279 $ b( mp, i ), 1, zero, t( np, i ), 1 )
283 CALL cgemv(
'C', m-l, i-1, alpha, b, ldb, b( 1, i ), 1,
284 $ one, t( 1, i ), 1 )
288 CALL ctrmv(
'U',
'N',
'N', i-1, t, ldt, t( 1, i ), 1 )
292 t( i, i ) = t( i, 1 )
subroutine xerbla(srname, info)
subroutine cgemv(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
CGEMV
subroutine cgerc(m, n, alpha, x, incx, y, incy, a, lda)
CGERC
subroutine clarfg(n, alpha, x, incx, tau)
CLARFG generates an elementary reflector (Householder matrix).
subroutine ctpqrt2(m, n, l, a, lda, b, ldb, t, ldt, info)
CTPQRT2 computes a QR factorization of a real or complex "triangular-pentagonal" matrix,...
subroutine ctrmv(uplo, trans, diag, n, a, lda, x, incx)
CTRMV