114 SUBROUTINE chpt01( UPLO, N, A, AFAC, IPIV, C, LDC, RWORK, RESID )
129 COMPLEX a( * ), afac( * ), c( ldc, * )
136 parameter( zero = 0.0e+0, one = 1.0e+0 )
138 parameter( czero = ( 0.0e+0, 0.0e+0 ),
139 $ cone = ( 1.0e+0, 0.0e+0 ) )
142 INTEGER i, info, j, jc
154 INTRINSIC aimag, real
168 anorm =
clanhp(
'1', uplo, n, a, rwork )
174 IF(
lsame( uplo,
'U' ) )
THEN
176 IF( aimag( afac( jc ) ).NE.zero )
THEN
184 IF( aimag( afac( jc ) ).NE.zero )
THEN
194 CALL
claset(
'Full', n, n, czero, cone, c, ldc )
198 CALL
clavhp( uplo,
'Conjugate',
'Non-unit', n, n, afac, ipiv, c,
203 CALL
clavhp( uplo,
'No transpose',
'Unit', n, n, afac, ipiv, c,
208 IF(
lsame( uplo,
'U' ) )
THEN
212 c( i, j ) = c( i, j ) - a( jc+i )
214 c( j, j ) = c( j, j ) -
REAL( A( JC+J ) )
220 c( j, j ) = c( j, j ) -
REAL( A( JC ) )
222 c( i, j ) = c( i, j ) - a( jc+i-j )
230 resid =
clanhe(
'1', uplo, n, c, ldc, rwork )
232 IF( anorm.LE.zero )
THEN
236 resid = ( ( resid /
REAL( N ) ) / anorm ) / eps