141 SUBROUTINE stpt02( UPLO, TRANS, DIAG, N, NRHS, AP, X, LDX, B, LDB,
150 CHARACTER diag, trans, uplo
151 INTEGER ldb, ldx, n, nrhs
155 REAL ap( * ), b( ldb, * ), work( * ), x( ldx, * )
162 parameter( zero = 0.0e+0, one = 1.0e+0 )
166 REAL anorm, bnorm, eps, xnorm
183 IF( n.LE.0 .OR. nrhs.LE.0 )
THEN
190 IF(
lsame( trans,
'N' ) )
THEN
191 anorm =
slantp(
'1', uplo, diag, n, ap, work )
193 anorm =
slantp(
'I', uplo, diag, n, ap, work )
199 IF( anorm.LE.zero )
THEN
209 CALL
scopy( n, x( 1, j ), 1, work, 1 )
210 CALL
stpmv( uplo, trans, diag, n, ap, work, 1 )
211 CALL
saxpy( n, -one, b( 1, j ), 1, work, 1 )
212 bnorm =
sasum( n, work, 1 )
213 xnorm =
sasum( n, x( 1, j ), 1 )
214 IF( xnorm.LE.zero )
THEN
217 resid = max( resid, ( ( bnorm / anorm ) / xnorm ) / eps )