176 SUBROUTINE zgbt05( TRANS, N, KL, KU, NRHS, AB, LDAB, B, LDB, X,
177 $ ldx, xact, ldxact, ferr, berr, reslts )
186 INTEGER KL, KU, LDAB, LDB, LDX, LDXACT, N, NRHS
189 DOUBLE PRECISION BERR( * ), FERR( * ), RESLTS( * )
190 COMPLEX*16 AB( ldab, * ), B( ldb, * ), X( ldx, * ),
197 DOUBLE PRECISION ZERO, ONE
198 parameter ( zero = 0.0d+0, one = 1.0d+0 )
202 INTEGER I, IMAX, J, K, NZ
203 DOUBLE PRECISION AXBI, DIFF, EPS, ERRBND, OVFL, TMP, UNFL, XNORM
209 DOUBLE PRECISION DLAMCH
210 EXTERNAL lsame, izamax, dlamch
213 INTRINSIC abs, dble, dimag, max, min
216 DOUBLE PRECISION CABS1
219 cabs1( zdum ) = abs( dble( zdum ) ) + abs( dimag( zdum ) )
225 IF( n.LE.0 .OR. nrhs.LE.0 )
THEN
231 eps = dlamch(
'Epsilon' )
232 unfl = dlamch(
'Safe minimum' )
234 notran = lsame( trans,
'N' )
235 nz = min( kl+ku+2, n+1 )
243 imax = izamax( n, x( 1, j ), 1 )
244 xnorm = max( cabs1( x( imax, j ) ), unfl )
247 diff = max( diff, cabs1( x( i, j )-xact( i, j ) ) )
250 IF( xnorm.GT.one )
THEN
252 ELSE IF( diff.LE.ovfl*xnorm )
THEN
260 IF( diff / xnorm.LE.ferr( j ) )
THEN
261 errbnd = max( errbnd, ( diff / xnorm ) / ferr( j ) )
273 tmp = cabs1( b( i, k ) )
275 DO 40 j = max( i-kl, 1 ), min( i+ku, n )
276 tmp = tmp + cabs1( ab( ku+1+i-j, j ) )*
280 DO 50 j = max( i-ku, 1 ), min( i+kl, n )
281 tmp = tmp + cabs1( ab( ku+1+j-i, i ) )*
288 axbi = min( axbi, tmp )
291 tmp = berr( k ) / ( nz*eps+nz*unfl / max( axbi, nz*unfl ) )
295 reslts( 2 ) = max( reslts( 2 ), tmp )
subroutine zgbt05(TRANS, N, KL, KU, NRHS, AB, LDAB, B, LDB, X, LDX, XACT, LDXACT, FERR, BERR, RESLTS)
ZGBT05