101 SUBROUTINE dget04( N, NRHS, X, LDX, XACT, LDXACT, RCOND, RESID )
108 INTEGER LDX, LDXACT, N, NRHS
109 DOUBLE PRECISION RCOND, RESID
112 DOUBLE PRECISION X( LDX, * ), XACT( LDXACT, * )
118 DOUBLE PRECISION ZERO
119 parameter( zero = 0.0d+0 )
123 DOUBLE PRECISION DIFFNM, EPS, XNORM
127 DOUBLE PRECISION DLAMCH
128 EXTERNAL idamax, dlamch
137 IF( n.LE.0 .OR. nrhs.LE.0 )
THEN
144 eps = dlamch(
'Epsilon' )
145 IF( rcond.LT.zero )
THEN
156 ix = idamax( n, xact( 1, j ), 1 )
157 xnorm = abs( xact( ix, j ) )
160 diffnm = max( diffnm, abs( x( i, j )-xact( i, j ) ) )
162 IF( xnorm.LE.zero )
THEN
164 $ resid = 1.0d0 / eps
166 resid = max( resid, ( diffnm / xnorm )*rcond )
169 IF( resid*eps.LT.1.0d0 )
170 $ resid = resid / eps
subroutine dget04(n, nrhs, x, ldx, xact, ldxact, rcond, resid)
DGET04