127 SUBROUTINE zpot02( UPLO, N, NRHS, A, LDA, X, LDX, B, LDB, RWORK,
137 INTEGER lda, ldb, ldx, n, nrhs
138 DOUBLE PRECISION resid
141 DOUBLE PRECISION rwork( * )
142 COMPLEX*16 a( lda, * ), b( ldb, * ), x( ldx, * )
148 DOUBLE PRECISION zero, one
149 parameter( zero = 0.0d+0, one = 1.0d+0 )
151 parameter( cone = ( 1.0d+0, 0.0d+0 ) )
155 DOUBLE PRECISION anorm, bnorm, eps, xnorm
171 IF( n.LE.0 .OR. nrhs.LE.0 )
THEN
179 anorm =
zlanhe(
'1', uplo, n, a, lda, rwork )
180 IF( anorm.LE.zero )
THEN
187 CALL
zhemm(
'Left', uplo, n, nrhs, -cone, a, lda, x, ldx, cone, b,
195 bnorm =
dzasum( n, b( 1, j ), 1 )
196 xnorm =
dzasum( n, x( 1, j ), 1 )
197 IF( xnorm.LE.zero )
THEN
200 resid = max( resid, ( ( bnorm / anorm ) / xnorm ) / eps )