151 SUBROUTINE zchkps( DOTYPE, NN, NVAL, NNB, NBVAL, NRANK, RANKVAL,
152 $ THRESH, TSTERR, NMAX, A, AFAC, PERM, PIV, WORK,
160 DOUBLE PRECISION THRESH
161 INTEGER NMAX, NN, NNB, NOUT, NRANK
165 COMPLEX*16 A( * ), AFAC( * ), PERM( * ), WORK( * )
166 DOUBLE PRECISION RWORK( * )
167 INTEGER NBVAL( * ), NVAL( * ), PIV( * ), RANKVAL( * )
175 PARAMETER ( ONE = 1.0e+0 )
177 parameter( ntypes = 9 )
180 DOUBLE PRECISION ANORM, CNDNUM, RESULT, TOL
181 INTEGER COMPRANK, I, IMAT, IN, INB, INFO, IRANK, IUPLO,
182 $ izero, kl, ku, lda, mode, n, nb, nerrs, nfail,
183 $ nimat, nrun, rank, rankdiff
184 CHARACTER DIST,
TYPE, UPLO
188 INTEGER ISEED( 4 ), ISEEDY( 4 )
201 COMMON / infoc / infot, nunit, ok, lerr
202 COMMON / srnamc / srnamt
205 INTRINSIC dble, max, ceiling
208 DATA iseedy / 1988, 1989, 1990, 1991 /
209 DATA uplos /
'U',
'L' /
215 path( 1: 1 ) =
'Zomplex Precision'
221 iseed( i ) = iseedy( i )
227 $
CALL zerrps( path, nout )
240 DO 140 imat = 1, nimat
244 IF( .NOT.dotype( imat ) )
249 DO 130 irank = 1, nrank
254 IF( ( imat.LT.3 .OR. imat.GT.5 ) .AND. irank.GT.1 )
257 rank = ceiling( ( n * dble( rankval( irank ) ) )
264 uplo = uplos( iuplo )
269 CALL zlatb5( path, imat, n,
TYPE, kl, ku, anorm,
270 $ mode, cndnum, dist )
273 CALL zlatmt( n, n, dist, iseed,
TYPE, rwork, mode,
274 $ cndnum, anorm, rank, kl, ku, uplo, a,
280 CALL alaerh( path,
'ZLATMT', info, 0, uplo, n,
281 $ n, -1, -1, -1, imat, nfail, nerrs,
295 CALL zlacpy( uplo, n, n, a, lda, afac, lda )
301 CALL zpstrf( uplo, n, afac, lda, piv, comprank,
307 $ .OR.(info.NE.izero.AND.rank.EQ.n)
308 $ .OR.(info.LE.izero.AND.rank.LT.n) )
THEN
309 CALL alaerh( path,
'ZPSTRF', info, izero,
310 $ uplo, n, n, -1, -1, nb, imat,
311 $ nfail, nerrs, nout )
324 CALL zpst01( uplo, n, a, lda, afac, lda, perm, lda,
325 $ piv, rwork, result, comprank )
332 rankdiff = rank - comprank
333 IF( result.GE.thresh )
THEN
334 IF( nfail.EQ.0 .AND. nerrs.EQ.0 )
335 $
CALL alahd( nout, path )
336 WRITE( nout, fmt = 9999 )uplo, n, rank,
337 $ rankdiff, nb, imat, result
350 CALL alasum( path, nout, nfail, nrun, nerrs )
352 9999
FORMAT(
' UPLO = ''', a1,
''', N =', i5,
', RANK =', i3,
353 $
', Diff =', i5,
', NB =', i4,
', type ', i2,
', Ratio =',
subroutine alasum(type, nout, nfail, nrun, nerrs)
ALASUM
subroutine xlaenv(ispec, nvalue)
XLAENV
subroutine alaerh(path, subnam, info, infoe, opts, m, n, kl, ku, n5, imat, nfail, nerrs, nout)
ALAERH
subroutine alahd(iounit, path)
ALAHD
subroutine zlacpy(uplo, m, n, a, lda, b, ldb)
ZLACPY copies all or part of one two-dimensional array to another.
subroutine zpstrf(uplo, n, a, lda, piv, rank, tol, work, info)
ZPSTRF computes the Cholesky factorization with complete pivoting of a complex Hermitian positive sem...
subroutine zchkps(dotype, nn, nval, nnb, nbval, nrank, rankval, thresh, tsterr, nmax, a, afac, perm, piv, work, rwork, nout)
ZCHKPS
subroutine zerrps(path, nunit)
ZERRPS
subroutine zlatb5(path, imat, n, type, kl, ku, anorm, mode, cndnum, dist)
ZLATB5
subroutine zlatmt(m, n, dist, iseed, sym, d, mode, cond, dmax, rank, kl, ku, pack, a, lda, work, info)
ZLATMT
subroutine zpst01(uplo, n, a, lda, afac, ldafac, perm, ldperm, piv, rwork, resid, rank)
ZPST01