169 SUBROUTINE spbt05( UPLO, N, KD, NRHS, AB, LDAB, B, LDB, X, LDX,
170 $ XACT, LDXACT, FERR, BERR, RESLTS )
178 INTEGER KD, LDAB, LDB, LDX, LDXACT, N, NRHS
181 REAL AB( LDAB, * ), B( LDB, * ), BERR( * ),
182 $ ferr( * ), reslts( * ), x( ldx, * ),
190 parameter( zero = 0.0e+0, one = 1.0e+0 )
194 INTEGER I, IMAX, J, K, NZ
195 REAL AXBI, DIFF, EPS, ERRBND, OVFL, TMP, UNFL, XNORM
201 EXTERNAL lsame, isamax, slamch
204 INTRINSIC abs, max, min
210 IF( n.LE.0 .OR. nrhs.LE.0 )
THEN
216 eps = slamch(
'Epsilon' )
217 unfl = slamch(
'Safe minimum' )
219 upper = lsame( uplo,
'U' )
220 nz = 2*max( kd, n-1 ) + 1
228 imax = isamax( n, x( 1, j ), 1 )
229 xnorm = max( abs( x( imax, j ) ), unfl )
232 diff = max( diff, abs( x( i, j )-xact( i, j ) ) )
235 IF( xnorm.GT.one )
THEN
237 ELSE IF( diff.LE.ovfl*xnorm )
THEN
245 IF( diff / xnorm.LE.ferr( j ) )
THEN
246 errbnd = max( errbnd, ( diff / xnorm ) / ferr( j ) )
258 tmp = abs( b( i, k ) )
260 DO 40 j = max( i-kd, 1 ), i
261 tmp = tmp + abs( ab( kd+1-i+j, i ) )*abs( x( j, k ) )
263 DO 50 j = i + 1, min( i+kd, n )
264 tmp = tmp + abs( ab( kd+1+i-j, j ) )*abs( x( j, k ) )
267 DO 60 j = max( i-kd, 1 ), i - 1
268 tmp = tmp + abs( ab( 1+i-j, j ) )*abs( x( j, k ) )
270 DO 70 j = i, min( i+kd, n )
271 tmp = tmp + abs( ab( 1+j-i, i ) )*abs( x( j, k ) )
277 axbi = min( axbi, tmp )
280 tmp = berr( k ) / ( nz*eps+nz*unfl / max( axbi, nz*unfl ) )
284 reslts( 2 ) = max( reslts( 2 ), tmp )
subroutine spbt05(uplo, n, kd, nrhs, ab, ldab, b, ldb, x, ldx, xact, ldxact, ferr, berr, reslts)
SPBT05