114 RECURSIVE SUBROUTINE cgetrf2( M, N, A, LDA, IPIV, INFO )
122 INTEGER INFO, LDA, M, N
133 parameter ( one = ( 1.0e+0, 0.0e+0 ),
134 $ zero = ( 0.0e+0, 0.0e+0 ) )
139 INTEGER I, IINFO, N1, N2
144 EXTERNAL slamch, icamax
159 ELSE IF( n.LT.0 )
THEN
161 ELSE IF( lda.LT.max( 1, m ) )
THEN
165 CALL xerbla(
'CGETRF2', -info )
171 IF( m.EQ.0 .OR. n.EQ.0 )
180 IF ( a(1,1).EQ.zero )
183 ELSE IF( n.EQ.1 )
THEN
194 i = icamax( m, a( 1, 1 ), 1 )
196 IF( a( i, 1 ).NE.zero )
THEN
202 a( 1, 1 ) = a( i, 1 )
208 IF( abs(a( 1, 1 )) .GE. sfmin )
THEN
209 CALL cscal( m-1, one / a( 1, 1 ), a( 2, 1 ), 1 )
212 a( 1+i, 1 ) = a( 1+i, 1 ) / a( 1, 1 )
231 CALL cgetrf2( m, n1, a, lda, ipiv, iinfo )
233 IF ( info.EQ.0 .AND. iinfo.GT.0 )
240 CALL claswp( n2, a( 1, n1+1 ), lda, 1, n1, ipiv, 1 )
244 CALL ctrsm(
'L',
'L',
'N',
'U', n1, n2, one, a, lda,
245 $ a( 1, n1+1 ), lda )
249 CALL cgemm(
'N',
'N', m-n1, n2, n1, -one, a( n1+1, 1 ), lda,
250 $ a( 1, n1+1 ), lda, one, a( n1+1, n1+1 ), lda )
254 CALL cgetrf2( m-n1, n2, a( n1+1, n1+1 ), lda, ipiv( n1+1 ),
259 IF ( info.EQ.0 .AND. iinfo.GT.0 )
261 DO 20 i = n1+1, min( m, n )
262 ipiv( i ) = ipiv( i ) + n1
267 CALL claswp( n1, a( 1, 1 ), lda, n1+1, min( m, n), ipiv, 1 )
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine cscal(N, CA, CX, INCX)
CSCAL
subroutine ctrsm(SIDE, UPLO, TRANSA, DIAG, M, N, ALPHA, A, LDA, B, LDB)
CTRSM
recursive subroutine cgetrf2(M, N, A, LDA, IPIV, INFO)
CGETRF2
subroutine cgemm(TRANSA, TRANSB, M, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC)
CGEMM
subroutine claswp(N, A, LDA, K1, K2, IPIV, INCX)
CLASWP performs a series of row interchanges on a general rectangular matrix.