1298 parameter ( zero = ( 0.0d0, 0.0d0 ) )
1299 DOUBLE PRECISION rone, rzero
1300 parameter ( rone = 1.0d0, rzero = 0.0d0 )
1302 DOUBLE PRECISION eps, thresh
1303 INTEGER nalf, nbet, nidim, nmax, nout, ntra
1304 LOGICAL fatal, rewi, trace
1307 COMPLEX*16 a( nmax, nmax ), aa( nmax*nmax ), alf( nalf ),
1308 $ as( nmax*nmax ), b( nmax, nmax ),
1309 $ bb( nmax*nmax ), bet( nbet ), bs( nmax*nmax ),
1310 $ c( nmax, nmax ), cc( nmax*nmax ),
1311 $ cs( nmax*nmax ), ct( nmax )
1312 DOUBLE PRECISION g( nmax )
1313 INTEGER idim( nidim )
1315 COMPLEX*16 alpha, als, beta, bets
1316 DOUBLE PRECISION err, errmax, ralpha, rals, rbeta, rbets
1317 INTEGER i, ia, ib, ict, icu, ik, in, j, jc, jj, k, ks,
1318 $ laa, lcc, lda, ldas, ldc, ldcs, lj, ma, n, na,
1320 LOGICAL conj, null, reset, same, tran, upper
1321 CHARACTER*1 trans, transs, transt, uplo, uplos
1322 CHARACTER*2 icht, ichu
1331 INTRINSIC dcmplx, max, dble
1333 INTEGER infot, noutc
1336 COMMON /infoc/infot, noutc, ok, lerr
1338 DATA icht/
'NC'/, ichu/
'UL'/
1340 conj = sname( 2: 3 ).EQ.
'HE'
1347 DO 100 in = 1, nidim
1362 trans = icht( ict: ict )
1364 IF( tran.AND..NOT.conj )
1384 CALL zmake(
'GE',
' ',
' ', ma, na, a, nmax, aa, lda,
1388 uplo = ichu( icu: icu )
1394 ralpha = dble( alpha )
1395 alpha = dcmplx( ralpha, rzero )
1401 rbeta = dble( beta )
1402 beta = dcmplx( rbeta, rzero )
1406 $ null = null.OR.( ( k.LE.0.OR.ralpha.EQ.
1407 $ rzero ).AND.rbeta.EQ.rone )
1411 CALL zmake( sname( 2: 3 ), uplo,
' ', n, n, c,
1412 $ nmax, cc, ldc, reset, zero )
1445 $
WRITE( ntra, fmt = 9994 )nc, sname, uplo,
1446 $ trans, n, k, ralpha, lda, rbeta, ldc
1449 CALL zherk( uplo, trans, n, k, ralpha, aa,
1450 $ lda, rbeta, cc, ldc )
1453 $
WRITE( ntra, fmt = 9993 )nc, sname, uplo,
1454 $ trans, n, k, alpha, lda, beta, ldc
1457 CALL zsyrk( uplo, trans, n, k, alpha, aa,
1458 $ lda, beta, cc, ldc )
1464 WRITE( nout, fmt = 9992 )
1471 isame( 1 ) = uplos.EQ.uplo
1472 isame( 2 ) = transs.EQ.trans
1473 isame( 3 ) = ns.EQ.n
1474 isame( 4 ) = ks.EQ.k
1476 isame( 5 ) = rals.EQ.ralpha
1478 isame( 5 ) = als.EQ.alpha
1480 isame( 6 ) =
lze( as, aa, laa )
1481 isame( 7 ) = ldas.EQ.lda
1483 isame( 8 ) = rbets.EQ.rbeta
1485 isame( 8 ) = bets.EQ.beta
1488 isame( 9 ) =
lze( cs, cc, lcc )
1490 isame( 9 ) =
lzeres( sname( 2: 3 ), uplo, n,
1493 isame( 10 ) = ldcs.EQ.ldc
1500 same = same.AND.isame( i )
1501 IF( .NOT.isame( i ) )
1502 $
WRITE( nout, fmt = 9998 )i
1528 CALL zmmch( transt,
'N', lj, 1, k,
1529 $ alpha, a( 1, jj ), nmax,
1530 $ a( 1, j ), nmax, beta,
1531 $ c( jj, j ), nmax, ct, g,
1532 $ cc( jc ), ldc, eps, err,
1533 $ fatal, nout, .true. )
1535 CALL zmmch(
'N', transt, lj, 1, k,
1536 $ alpha, a( jj, 1 ), nmax,
1537 $ a( j, 1 ), nmax, beta,
1538 $ c( jj, j ), nmax, ct, g,
1539 $ cc( jc ), ldc, eps, err,
1540 $ fatal, nout, .true. )
1547 errmax = max( errmax, err )
1569 IF( errmax.LT.thresh )
THEN
1570 WRITE( nout, fmt = 9999 )sname, nc
1572 WRITE( nout, fmt = 9997 )sname, nc, errmax
1578 $
WRITE( nout, fmt = 9995 )j
1581 WRITE( nout, fmt = 9996 )sname
1583 WRITE( nout, fmt = 9994 )nc, sname, uplo, trans, n, k, ralpha,
1586 WRITE( nout, fmt = 9993 )nc, sname, uplo, trans, n, k, alpha,
1593 9999
FORMAT(
' ', a6,
' PASSED THE COMPUTATIONAL TESTS (', i6,
' CALL',
1595 9998
FORMAT(
' ******* FATAL ERROR - PARAMETER NUMBER ', i2,
' WAS CH',
1596 $
'ANGED INCORRECTLY *******' )
1597 9997
FORMAT(
' ', a6,
' COMPLETED THE COMPUTATIONAL TESTS (', i6,
' C',
1598 $
'ALLS)', /
' ******* BUT WITH MAXIMUM TEST RATIO', f8.2,
1599 $
' - SUSPECT *******' )
1600 9996
FORMAT(
' ******* ', a6,
' FAILED ON CALL NUMBER:' )
1601 9995
FORMAT(
' THESE ARE THE RESULTS FOR COLUMN ', i3 )
1602 9994
FORMAT( 1x, i6,
': ', a6,
'(', 2(
'''', a1,
''',' ), 2( i3,
',' ),
1603 $ f4.1,
', A,', i3,
',', f4.1,
', C,', i3,
') ',
1605 9993
FORMAT( 1x, i6,
': ', a6,
'(', 2(
'''', a1,
''',' ), 2( i3,
',' ),
1606 $
'(', f4.1,
',', f4.1,
') , A,', i3,
',(', f4.1,
',', f4.1,
1607 $
'), C,', i3,
') .' )
1608 9992
FORMAT(
' ******* FATAL ERROR - ERROR-EXIT TAKEN ON VALID CALL *',
logical function lzeres(TYPE, UPLO, M, N, AA, AS, LDA)
subroutine zmmch(TRANSA, TRANSB, M, N, KK, ALPHA, A, LDA, B, LDB, BETA, C, LDC, CT, G, CC, LDCC, EPS, ERR, FATAL, NOUT, MV)
subroutine zmake(TYPE, UPLO, DIAG, M, N, A, NMAX, AA, LDA, KL, KU, RESET, TRANSL)
subroutine zsyrk(UPLO, TRANS, N, K, ALPHA, A, LDA, BETA, C, LDC)
ZSYRK
logical function lze(RI, RJ, LR)
subroutine zherk(UPLO, TRANS, N, K, ALPHA, A, LDA, BETA, C, LDC)
ZHERK