115 SUBROUTINE sgesc2( N, A, LDA, RHS, IPIV, JPIV, SCALE )
127 INTEGER ipiv( * ), jpiv( * )
128 REAL a( lda, * ), rhs( * )
135 parameter( one = 1.0e+0, two = 2.0e+0 )
139 REAL bignum, eps, smlnum, temp
157 smlnum =
slamch(
'S' ) / eps
158 bignum = one / smlnum
159 CALL
slabad( smlnum, bignum )
163 CALL
slaswp( 1, rhs, lda, 1, n-1, ipiv, 1 )
169 rhs( j ) = rhs( j ) - a( j, i )*rhs( i )
180 IF( two*smlnum*abs( rhs( i ) ).GT.abs( a( n, n ) ) )
THEN
181 temp = ( one / two ) / abs( rhs( i ) )
182 CALL
sscal( n, temp, rhs( 1 ), 1 )
187 temp = one / a( i, i )
188 rhs( i ) = rhs( i )*temp
190 rhs( i ) = rhs( i ) - rhs( j )*( a( i, j )*temp )
196 CALL
slaswp( 1, rhs, lda, 1, n-1, jpiv, -1 )
real function slamch(CMACH)
SLAMCH
subroutine sgesc2(N, A, LDA, RHS, IPIV, JPIV, SCALE)
SGESC2
integer function isamax(N, SX, INCX)
ISAMAX
subroutine slabad(SMALL, LARGE)
SLABAD
subroutine sscal(N, SA, SX, INCX)
SSCAL
subroutine slaswp(N, A, LDA, K1, K2, IPIV, INCX)
SLASWP