82 parameter( nmax = 132 )
84 parameter( maxin = 12 )
86 parameter( maxrhs = 16 )
88 parameter( matmax = 30 )
90 parameter( nin = 5, nout = 6 )
92 parameter( ldamax = nmax )
95 LOGICAL fatal, tstdrv, tsterr
101 INTEGER i, ic, k, lda, nm, nmats,
103 $ vers_major, vers_minor, vers_patch
104 DOUBLE PRECISION eps, s1, s2, thresh
108 LOGICAL dotype( matmax )
109 INTEGER iwork( nmax ), mval( maxin ), nsval( maxin )
110 DOUBLE PRECISION rwork(nmax)
111 COMPLEX*16 a( ldamax*nmax, 2 ), b( nmax*maxrhs, 2 ),
112 $ work( nmax*maxrhs*2 )
113 COMPLEX swork(nmax*(nmax+maxrhs))
131 COMMON / infoc / infot, nunit, ok, lerr
132 COMMON / srnamc / srnamt
135 DATA intstr /
'0123456789' /
149 CALL ilaver( vers_major, vers_minor, vers_patch )
150 WRITE( nout, fmt = 9994 ) vers_major, vers_minor, vers_patch
154 READ( nin, fmt = * )nm
156 WRITE( nout, fmt = 9996 )
' NM ', nm, 1
159 ELSE IF( nm.GT.maxin )
THEN
160 WRITE( nout, fmt = 9995 )
' NM ', nm, maxin
164 READ( nin, fmt = * )( mval( i ), i = 1, nm )
166 IF( mval( i ).LT.0 )
THEN
167 WRITE( nout, fmt = 9996 )
' M ', mval( i ), 0
169 ELSE IF( mval( i ).GT.nmax )
THEN
170 WRITE( nout, fmt = 9995 )
' M ', mval( i ), nmax
175 $
WRITE( nout, fmt = 9993 )
'M ', ( mval( i ), i = 1, nm )
179 READ( nin, fmt = * )nns
181 WRITE( nout, fmt = 9996 )
' NNS', nns, 1
184 ELSE IF( nns.GT.maxin )
THEN
185 WRITE( nout, fmt = 9995 )
' NNS', nns, maxin
189 READ( nin, fmt = * )( nsval( i ), i = 1, nns )
191 IF( nsval( i ).LT.0 )
THEN
192 WRITE( nout, fmt = 9996 )
'NRHS', nsval( i ), 0
194 ELSE IF( nsval( i ).GT.maxrhs )
THEN
195 WRITE( nout, fmt = 9995 )
'NRHS', nsval( i ), maxrhs
200 $
WRITE( nout, fmt = 9993 )
'NRHS', ( nsval( i ), i = 1, nns )
204 READ( nin, fmt = * )thresh
205 WRITE( nout, fmt = 9992 )thresh
209 READ( nin, fmt = * )tstdrv
213 READ( nin, fmt = * )tsterr
216 WRITE( nout, fmt = 9999 )
222 seps =
slamch(
'Underflow threshold' )
223 WRITE( nout, fmt = 9991 )
'(single precision) underflow', seps
224 seps =
slamch(
'Overflow threshold' )
225 WRITE( nout, fmt = 9991 )
'(single precision) overflow ', seps
226 seps =
slamch(
'Epsilon' )
227 WRITE( nout, fmt = 9991 )
'(single precision) precision', seps
228 WRITE( nout, fmt = * )
230 eps =
dlamch(
'Underflow threshold' )
231 WRITE( nout, fmt = 9991 )
'(double precision) underflow', eps
232 eps =
dlamch(
'Overflow threshold' )
233 WRITE( nout, fmt = 9991 )
'(double precision) overflow ', eps
235 WRITE( nout, fmt = 9991 )
'(double precision) precision', eps
236 WRITE( nout, fmt = * )
242 READ( nin, fmt =
'(A72)',
END = 140 )aline
252 IF( aline( i: i ).EQ.
' ' )
258 IF( c1.EQ.intstr( k: k ) )
THEN
265 nmats = nmats*10 + ic
278 IF( .NOT.
lsame( c1,
'Zomplex precision' ) )
THEN
279 WRITE( nout, fmt = 9990 )path
281 ELSE IF( nmats.LE.0 )
THEN
285 WRITE( nout, fmt = 9990 )
'ZCGESV'
288 ELSE IF(
lsamen( 2, c2,
'GE' ) )
THEN
293 CALL alareq(
'ZGE', nmats, dotype, ntypes, nin, nout )
301 CALL zdrvab( dotype, nm, mval, nns,
302 $ nsval, thresh, lda, a( 1, 1 ),
303 $ a( 1, 2 ), b( 1, 1 ), b( 1, 2 ),
304 $ work, rwork, swork, iwork, nout )
306 WRITE( nout, fmt = 9989 )
'ZCGESV'
309 ELSE IF(
lsamen( 2, c2,
'PO' ) )
THEN
314 CALL alareq(
'DPO', nmats, dotype, ntypes, nin, nout )
321 CALL zdrvac( dotype, nm, mval, nns, nsval,
322 $ thresh, lda, a( 1, 1 ), a( 1, 2 ),
323 $ b( 1, 1 ), b( 1, 2 ),
324 $ work, rwork, swork, nout )
326 WRITE( nout, fmt = 9989 )
'ZCPOSV'
342 WRITE( nout, fmt = 9998 )
343 WRITE( nout, fmt = 9997 )s2 - s1
345 9999
FORMAT( /
' Execution not attempted due to input errors' )
346 9998
FORMAT( /
' End of tests' )
347 9997
FORMAT(
' Total time used = ', f12.2,
' seconds', / )
348 9996
FORMAT(
' Invalid input value: ', a4,
'=', i6,
'; must be >=',
350 9995
FORMAT(
' Invalid input value: ', a4,
'=', i6,
'; must be <=',
352 9994
FORMAT(
' Tests of the COMPLEX*16 LAPACK ZCGESV/ZCPOSV routines ',
353 $ /
' LAPACK VERSION ', i1,
'.', i1,
'.', i1,
354 $ / /
' The following parameter values will be used:' )
355 9993
FORMAT( 4x, a4,
': ', 10i6, / 11x, 10i6 )
356 9992
FORMAT( /
' Routines pass computational tests if test ratio is ',
357 $
'less than', f8.2, / )
358 9991
FORMAT(
' Relative machine ', a,
' is taken to be', d16.6 )
359 9990
FORMAT( / 1x, a6,
' routines were not tested' )
360 9989
FORMAT( / 1x, a6,
' driver routines were not tested' )
subroutine alareq(path, nmats, dotype, ntypes, nin, nout)
ALAREQ
subroutine ilaver(vers_major, vers_minor, vers_patch)
ILAVER returns the LAPACK version.
real function slamch(cmach)
SLAMCH
double precision function dlamch(cmach)
DLAMCH
logical function lsame(ca, cb)
LSAME
logical function lsamen(n, ca, cb)
LSAMEN
double precision function dsecnd()
DSECND Using ETIME
subroutine zdrvab(dotype, nm, mval, nns, nsval, thresh, nmax, a, afac, b, x, work, rwork, swork, iwork, nout)
ZDRVAB
subroutine zdrvac(dotype, nm, mval, nns, nsval, thresh, nmax, a, afac, b, x, work, rwork, swork, nout)
ZDRVAC
subroutine zerrab(nunit)
ZERRAB
subroutine zerrac(nunit)
ZERRAC