113 SUBROUTINE dgesc2( N, A, LDA, RHS, IPIV, JPIV, SCALE )
121 DOUBLE PRECISION SCALE
124 INTEGER IPIV( * ), JPIV( * )
125 DOUBLE PRECISION A( LDA, * ), RHS( * )
131 DOUBLE PRECISION ONE, TWO
132 parameter( one = 1.0d+0, two = 2.0d+0 )
136 DOUBLE PRECISION BIGNUM, EPS, SMLNUM, TEMP
143 DOUBLE PRECISION DLAMCH
144 EXTERNAL idamax, dlamch
154 smlnum = dlamch(
'S' ) / eps
155 bignum = one / smlnum
156 CALL dlabad( smlnum, bignum )
160 CALL dlaswp( 1, rhs, lda, 1, n-1, ipiv, 1 )
166 rhs( j ) = rhs( j ) - a( j, i )*rhs( i )
176 i = idamax( n, rhs, 1 )
177 IF( two*smlnum*abs( rhs( i ) ).GT.abs( a( n, n ) ) )
THEN
178 temp = ( one / two ) / abs( rhs( i ) )
179 CALL dscal( n, temp, rhs( 1 ), 1 )
184 temp = one / a( i, i )
185 rhs( i ) = rhs( i )*temp
187 rhs( i ) = rhs( i ) - rhs( j )*( a( i, j )*temp )
193 CALL dlaswp( 1, rhs, lda, 1, n-1, jpiv, -1 )
subroutine dlabad(SMALL, LARGE)
DLABAD
subroutine dscal(N, DA, DX, INCX)
DSCAL
subroutine dgesc2(N, A, LDA, RHS, IPIV, JPIV, SCALE)
DGESC2 solves a system of linear equations using the LU factorization with complete pivoting computed...
subroutine dlaswp(N, A, LDA, K1, K2, IPIV, INCX)
DLASWP performs a series of row interchanges on a general rectangular matrix.