108 SUBROUTINE zppt03( UPLO, N, A, AINV, WORK, LDWORK, RWORK, RCOND,
118 DOUBLE PRECISION RCOND, RESID
121 DOUBLE PRECISION RWORK( * )
122 COMPLEX*16 A( * ), AINV( * ), WORK( LDWORK, * )
128 DOUBLE PRECISION ZERO, ONE
129 parameter( zero = 0.0d+0, one = 1.0d+0 )
130 COMPLEX*16 CZERO, CONE
131 parameter( czero = ( 0.0d+0, 0.0d+0 ),
132 $ cone = ( 1.0d+0, 0.0d+0 ) )
136 DOUBLE PRECISION AINVNM, ANORM, EPS
140 DOUBLE PRECISION DLAMCH, ZLANGE, ZLANHP
141 EXTERNAL lsame, dlamch, zlange, zlanhp
144 INTRINSIC dble, dconjg
161 eps = dlamch(
'Epsilon' )
162 anorm = zlanhp(
'1', uplo, n, a, rwork )
163 ainvnm = zlanhp(
'1', uplo, n, ainv, rwork )
164 IF( anorm.LE.zero .OR. ainvnm.LE.zero )
THEN
169 rcond = ( one / anorm ) / ainvnm
176 IF( lsame( uplo,
'U' ) )
THEN
182 CALL zcopy( j, ainv( jj ), 1, work( 1, j+1 ), 1 )
184 work( j, i+1 ) = dconjg( ainv( jj+i-1 ) )
188 jj = ( ( n-1 )*n ) / 2 + 1
190 work( n, i+1 ) = dconjg( ainv( jj+i-1 ) )
196 CALL zhpmv(
'Upper', n, -cone, a, work( 1, j+1 ), 1, czero,
199 CALL zhpmv(
'Upper', n, -cone, a, ainv( jj ), 1, czero,
211 work( 1, i ) = dconjg( ainv( i+1 ) )
215 CALL zcopy( n-j+1, ainv( jj ), 1, work( j, j-1 ), 1 )
217 work( j, j+i-1 ) = dconjg( ainv( jj+i ) )
225 CALL zhpmv(
'Lower', n, -cone, a, work( 1, j-1 ), 1, czero,
228 CALL zhpmv(
'Lower', n, -cone, a, ainv( 1 ), 1, czero,
236 work( i, i ) = work( i, i ) + cone
241 resid = zlange(
'1', n, n, work, ldwork, rwork )
243 resid = ( ( resid*rcond ) / eps ) / dble( n )
subroutine zcopy(n, zx, incx, zy, incy)
ZCOPY
subroutine zhpmv(uplo, n, alpha, ap, x, incx, beta, y, incy)
ZHPMV
subroutine zppt03(uplo, n, a, ainv, work, ldwork, rwork, rcond, resid)
ZPPT03