105 SUBROUTINE cgetf2( M, N, A, LDA, IPIV, INFO )
112 INTEGER INFO, LDA, M, N
123 parameter( one = ( 1.0e+0, 0.0e+0 ),
124 $ zero = ( 0.0e+0, 0.0e+0 ) )
146 ELSE IF( n.LT.0 )
THEN
148 ELSE IF( lda.LT.max( 1, m ) )
THEN
152 CALL xerbla(
'CGETF2', -info )
158 IF( m.EQ.0 .OR. n.EQ.0 )
161 DO 10 j = 1, min( m, n )
165 jp = j - 1 + icamax( m-j+1, a( j, j ), 1 )
167 IF( a( jp, j ).NE.zero )
THEN
172 $
CALL cswap( n, a( j, 1 ), lda, a( jp, 1 ), lda )
177 $
CALL crscl( m-j, a( j, j ), a( j+1, j ), 1 )
179 ELSE IF( info.EQ.0 )
THEN
184 IF( j.LT.min( m, n ) )
THEN
188 CALL cgeru( m-j, n-j, -one, a( j+1, j ), 1, a( j, j+1 ),
189 $ lda, a( j+1, j+1 ), lda )
subroutine crscl(n, a, x, incx)
CRSCL multiplies a vector by the reciprocal of a real scalar.
subroutine cgeru(m, n, alpha, x, incx, y, incy, a, lda)
CGERU
subroutine cgetf2(m, n, a, lda, ipiv, info)
CGETF2 computes the LU factorization of a general m-by-n matrix using partial pivoting with row inter...