123 SUBROUTINE dgtt02( TRANS, N, NRHS, DL, D, DU, X, LDX, B, LDB,
132 INTEGER LDB, LDX, N, NRHS
133 DOUBLE PRECISION RESID
136 DOUBLE PRECISION B( LDB, * ), D( * ), DL( * ), DU( * ),
143 DOUBLE PRECISION ONE, ZERO
144 parameter( one = 1.0d+0, zero = 0.0d+0 )
148 DOUBLE PRECISION ANORM, BNORM, EPS, XNORM
152 DOUBLE PRECISION DASUM, DLAMCH, DLANGT
153 EXTERNAL lsame, dasum, dlamch, dlangt
166 IF( n.LE.0 .OR. nrhs.EQ.0 )
172 IF( lsame( trans,
'N' ) )
THEN
173 anorm = dlangt(
'1', n, dl, d, du )
175 anorm = dlangt(
'I', n, dl, d, du )
180 eps = dlamch(
'Epsilon' )
181 IF( anorm.LE.zero )
THEN
188 CALL dlagtm( trans, n, nrhs, -one, dl, d, du, x, ldx, one, b,
192 bnorm = dasum( n, b( 1, j ), 1 )
193 xnorm = dasum( n, x( 1, j ), 1 )
194 IF( xnorm.LE.zero )
THEN
197 resid = max( resid, ( ( bnorm / anorm ) / xnorm ) / eps )
subroutine dgtt02(trans, n, nrhs, dl, d, du, x, ldx, b, ldb, resid)
DGTT02
subroutine dlagtm(trans, n, nrhs, alpha, dl, d, du, x, ldx, beta, b, ldb)
DLAGTM performs a matrix-matrix product of the form C = αAB+βC, where A is a tridiagonal matrix,...