149 SUBROUTINE zdrvab( DOTYPE, NM, MVAL, NNS,
150 $ NSVAL, THRESH, NMAX, A, AFAC, B,
151 $ X, WORK, RWORK, SWORK, IWORK, NOUT )
158 INTEGER NM, NMAX, NNS, NOUT
159 DOUBLE PRECISION THRESH
163 INTEGER MVAL( * ), NSVAL( * ), IWORK( * )
164 DOUBLE PRECISION RWORK( * )
166 COMPLEX*16 A( * ), AFAC( * ), B( * ),
173 DOUBLE PRECISION ZERO
174 PARAMETER ( ZERO = 0.0d+0 )
176 parameter( ntypes = 11 )
178 parameter( ntests = 1 )
182 CHARACTER DIST, TRANS,
TYPE, XTYPE
184 INTEGER I, IM, IMAT, INFO, IOFF, IRHS,
185 $ izero, kl, ku, lda, m, mode, n,
186 $ nerrs, nfail, nimat, nrhs, nrun
187 DOUBLE PRECISION ANORM, CNDNUM
190 INTEGER ISEED( 4 ), ISEEDY( 4 )
191 DOUBLE PRECISION RESULT( NTESTS )
201 INTRINSIC dcmplx, dble, max, min, sqrt
209 COMMON / infoc / infot, nunit, ok, lerr
210 COMMON / srnamc / srnamt
213 DATA iseedy / 2006, 2007, 2008, 2009 /
220 path( 1: 1 ) =
'Zomplex precision'
226 iseed( i ) = iseedy( i )
239 IF( m.LE.0 .OR. n.LE.0 )
242 DO 100 imat = 1, nimat
246 IF( .NOT.dotype( imat ) )
251 zerot = imat.GE.5 .AND. imat.LE.7
252 IF( zerot .AND. n.LT.imat-4 )
258 CALL zlatb4( path, imat, m, n,
TYPE, kl, ku, anorm, mode,
262 CALL zlatms( m, n, dist, iseed,
TYPE, rwork, mode,
263 $ cndnum, anorm, kl, ku,
'No packing', a, lda,
269 CALL alaerh( path,
'ZLATMS', info, 0,
' ', m, n, -1,
270 $ -1, -1, imat, nfail, nerrs, nout )
280 ELSE IF( imat.EQ.6 )
THEN
283 izero = min( m, n ) / 2 + 1
285 ioff = ( izero-1 )*lda
291 CALL zlaset(
'Full', m, n-izero+1, dcmplx(zero),
292 $ dcmplx(zero), a( ioff+1 ), lda )
304 CALL zlarhs( path, xtype,
' ', trans, n, n, kl,
305 $ ku, nrhs, a, lda, x, lda, b,
312 CALL zlacpy(
'Full', m, n, a, lda, afac, lda )
314 CALL zcgesv( n, nrhs, a, lda, iwork, b, lda, x, lda,
315 $ work, swork, rwork, iter, info)
318 CALL zlacpy(
'Full', m, n, afac, lda, a, lda )
324 IF( info.NE.izero )
THEN
326 IF( nfail.EQ.0 .AND. nerrs.EQ.0 )
327 $
CALL alahd( nout, path )
330 IF( info.NE.izero .AND. izero.NE.0 )
THEN
331 WRITE( nout, fmt = 9988 )
'ZCGESV',info,
334 WRITE( nout, fmt = 9975 )
'ZCGESV',info,
346 CALL zlacpy(
'Full', n, nrhs, b, lda, work, lda )
348 CALL zget08( trans, n, n, nrhs, a, lda, x, lda, work,
349 $ lda, rwork, result( 1 ) )
363 IF ((thresh.LE.0.0e+00)
364 $ .OR.((iter.GE.0).AND.(n.GT.0)
365 $ .AND.(result(1).GE.sqrt(dble(n))))
366 $ .OR.((iter.LT.0).AND.(result(1).GE.thresh)))
THEN
368 IF( nfail.EQ.0 .AND. nerrs.EQ.0 )
THEN
369 WRITE( nout, fmt = 8999 )
'DGE'
370 WRITE( nout, fmt =
'( '' Matrix types:'' )' )
371 WRITE( nout, fmt = 8979 )
372 WRITE( nout, fmt =
'( '' Test ratios:'' )' )
373 WRITE( nout, fmt = 8960 )1
374 WRITE( nout, fmt =
'( '' Messages:'' )' )
377 WRITE( nout, fmt = 9998 )trans, n, nrhs,
378 $ imat, 1, result( 1 )
388 IF( nfail.GT.0 )
THEN
389 WRITE( nout, fmt = 9996 )
'ZCGESV', nfail, nrun
391 WRITE( nout, fmt = 9995 )
'ZCGESV', nrun
393 IF( nerrs.GT.0 )
THEN
394 WRITE( nout, fmt = 9994 )nerrs
397 9998
FORMAT(
' TRANS=''', a1,
''', N =', i5,
', NRHS=', i3,
', type ',
398 $ i2,
', test(', i2,
') =', g12.5 )
399 9996
FORMAT( 1x, a6,
': ', i6,
' out of ', i6,
400 $
' tests failed to pass the threshold' )
401 9995
FORMAT( /1x,
'All tests for ', a6,
402 $
' routines passed the threshold ( ', i6,
' tests run)' )
403 9994
FORMAT( 6x, i6,
' error messages recorded' )
407 9988
FORMAT(
' *** ', a6,
' returned with INFO =', i5,
' instead of ',
408 $ i5, /
' ==> M =', i5,
', type ',
413 9975
FORMAT(
' *** Error code from ', a6,
'=', i5,
' for M=', i5,
415 8999
FORMAT( / 1x, a3,
': General dense matrices' )
416 8979
FORMAT( 4x,
'1. Diagonal', 24x,
'7. Last n/2 columns zero', / 4x,
417 $
'2. Upper triangular', 16x,
418 $
'8. Random, CNDNUM = sqrt(0.1/EPS)', / 4x,
419 $
'3. Lower triangular', 16x,
'9. Random, CNDNUM = 0.1/EPS',
420 $ / 4x,
'4. Random, CNDNUM = 2', 13x,
421 $
'10. Scaled near underflow', / 4x,
'5. First column zero',
422 $ 14x,
'11. Scaled near overflow', / 4x,
423 $
'6. Last column zero' )
424 8960
FORMAT( 3x, i2,
': norm_1( B - A * X ) / ',
425 $
'( norm_1(A) * norm_1(X) * EPS * SQRT(N) ) > 1 if ITERREF',
426 $ / 4x,
'or norm_1( B - A * X ) / ',
427 $
'( norm_1(A) * norm_1(X) * EPS ) > THRES if DGETRF' )
subroutine zlarhs(path, xtype, uplo, trans, m, n, kl, ku, nrhs, a, lda, x, ldx, b, ldb, iseed, info)
ZLARHS
subroutine alaerh(path, subnam, info, infoe, opts, m, n, kl, ku, n5, imat, nfail, nerrs, nout)
ALAERH
subroutine alahd(iounit, path)
ALAHD
subroutine zcgesv(n, nrhs, a, lda, ipiv, b, ldb, x, ldx, work, swork, rwork, iter, info)
ZCGESV computes the solution to system of linear equations A * X = B for GE matrices (mixed precision...
subroutine zlacpy(uplo, m, n, a, lda, b, ldb)
ZLACPY copies all or part of one two-dimensional array to another.
subroutine zlaset(uplo, m, n, alpha, beta, a, lda)
ZLASET initializes the off-diagonal elements and the diagonal elements of a matrix to given values.
subroutine zdrvab(dotype, nm, mval, nns, nsval, thresh, nmax, a, afac, b, x, work, rwork, swork, iwork, nout)
ZDRVAB
subroutine zget08(trans, m, n, nrhs, a, lda, x, ldx, b, ldb, rwork, resid)
ZGET08
subroutine zlatb4(path, imat, m, n, type, kl, ku, anorm, mode, cndnum, dist)
ZLATB4
subroutine zlatms(m, n, dist, iseed, sym, d, mode, cond, dmax, kl, ku, pack, a, lda, work, info)
ZLATMS