115 RECURSIVE SUBROUTINE cgelqt3( M, N, A, LDA, T, LDT, INFO )
123 INTEGER INFO, LDA, M, N, LDT
126 COMPLEX A( lda, * ), T( ldt, * )
133 parameter( one = (1.0e+00,0.0e+00) )
134 parameter( zero = (0.0e+00,0.0e+00))
137 INTEGER I, I1, J, J1, M1, M2, N1, N2, IINFO
147 ELSE IF( n .LT. m )
THEN
149 ELSE IF( lda .LT. max( 1, m ) )
THEN
151 ELSE IF( ldt .LT. max( 1, m ) )
THEN
155 CALL xerbla(
'CGELQT3', -info )
163 CALL clarfg( n, a, a( 1, min( 2, n ) ), lda, t )
177 CALL cgelqt3( m1, n, a, lda, t, ldt, iinfo )
183 t( i+m1, j ) = a( i+m1, j )
186 CALL ctrmm(
'R',
'U',
'C',
'U', m2, m1, one,
187 & a, lda, t( i1, 1 ), ldt )
189 CALL cgemm(
'N',
'C', m2, m1, n-m1, one, a( i1, i1 ), lda,
190 & a( 1, i1 ), lda, one, t( i1, 1 ), ldt)
192 CALL ctrmm(
'R',
'U',
'N',
'N', m2, m1, one,
193 & t, ldt, t( i1, 1 ), ldt )
195 CALL cgemm(
'N',
'N', m2, n-m1, m1, -one, t( i1, 1 ), ldt,
196 & a( 1, i1 ), lda, one, a( i1, i1 ), lda )
198 CALL ctrmm(
'R',
'U',
'N',
'U', m2, m1 , one,
199 & a, lda, t( i1, 1 ), ldt )
203 a( i+m1, j ) = a( i+m1, j ) - t( i+m1, j )
210 CALL cgelqt3( m2, n-m1, a( i1, i1 ), lda,
211 & t( i1, i1 ), ldt, iinfo )
217 t( j, i+m1 ) = (a( j, i+m1 ))
221 CALL ctrmm(
'R',
'U',
'C',
'U', m1, m2, one,
222 & a( i1, i1 ), lda, t( 1, i1 ), ldt )
224 CALL cgemm(
'N',
'C', m1, m2, n-m, one, a( 1, j1 ), lda,
225 & a( i1, j1 ), lda, one, t( 1, i1 ), ldt )
227 CALL ctrmm(
'L',
'U',
'N',
'N', m1, m2, -one, t, ldt,
230 CALL ctrmm(
'R',
'U',
'N',
'N', m1, m2, one,
231 & t( i1, i1 ), ldt, t( 1, i1 ), ldt )
subroutine clarfg(N, ALPHA, X, INCX, TAU)
CLARFG generates an elementary reflector (Householder matrix).
recursive subroutine cgelqt3(M, N, A, LDA, T, LDT, INFO)
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine ctrmm(SIDE, UPLO, TRANSA, DIAG, M, N, ALPHA, A, LDA, B, LDB)
CTRMM
subroutine cgemm(TRANSA, TRANSB, M, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC)
CGEMM