107 SUBROUTINE sgetf2( M, N, A, LDA, IPIV, INFO )
114 INTEGER INFO, LDA, M, N
125 parameter( one = 1.0e+0, zero = 0.0e+0 )
134 EXTERNAL slamch, isamax
149 ELSE IF( n.LT.0 )
THEN
151 ELSE IF( lda.LT.max( 1, m ) )
THEN
155 CALL xerbla(
'SGETF2', -info )
161 IF( m.EQ.0 .OR. n.EQ.0 )
168 DO 10 j = 1, min( m, n )
172 jp = j - 1 + isamax( m-j+1, a( j, j ), 1 )
174 IF( a( jp, j ).NE.zero )
THEN
179 $
CALL sswap( n, a( j, 1 ), lda, a( jp, 1 ), lda )
184 IF( abs(a( j, j )) .GE. sfmin )
THEN
185 CALL sscal( m-j, one / a( j, j ), a( j+1, j ), 1 )
188 a( j+i, j ) = a( j+i, j ) / a( j, j )
193 ELSE IF( info.EQ.0 )
THEN
198 IF( j.LT.min( m, n ) )
THEN
202 CALL sger( m-j, n-j, -one, a( j+1, j ), 1, a( j, j+1 ), lda,
203 $ a( j+1, j+1 ), lda )
subroutine xerbla(srname, info)
subroutine sger(m, n, alpha, x, incx, y, incy, a, lda)
SGER
subroutine sgetf2(m, n, a, lda, ipiv, info)
SGETF2 computes the LU factorization of a general m-by-n matrix using partial pivoting with row inter...
subroutine sscal(n, sa, sx, incx)
SSCAL
subroutine sswap(n, sx, incx, sy, incy)
SSWAP