103 SUBROUTINE dget04( N, NRHS, X, LDX, XACT, LDXACT, RCOND, RESID )
111 INTEGER LDX, LDXACT, N, NRHS
112 DOUBLE PRECISION RCOND, RESID
115 DOUBLE PRECISION X( ldx, * ), XACT( ldxact, * )
121 DOUBLE PRECISION ZERO
122 parameter ( zero = 0.0d+0 )
126 DOUBLE PRECISION DIFFNM, EPS, XNORM
130 DOUBLE PRECISION DLAMCH
131 EXTERNAL idamax, dlamch
140 IF( n.LE.0 .OR. nrhs.LE.0 )
THEN
147 eps = dlamch(
'Epsilon' )
148 IF( rcond.LT.zero )
THEN
159 ix = idamax( n, xact( 1, j ), 1 )
160 xnorm = abs( xact( ix, j ) )
163 diffnm = max( diffnm, abs( x( i, j )-xact( i, j ) ) )
165 IF( xnorm.LE.zero )
THEN
167 $ resid = 1.0d0 / eps
169 resid = max( resid, ( diffnm / xnorm )*rcond )
172 IF( resid*eps.LT.1.0d0 )
173 $ resid = resid / eps
subroutine dget04(N, NRHS, X, LDX, XACT, LDXACT, RCOND, RESID)
DGET04