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 a( ldamax*nmax, 2 ), b( nmax*maxrhs, 2 ),
111 $ rwork( nmax ), work( nmax*maxrhs*2 )
112 REAL swork(nmax*(nmax+maxrhs))
130 COMMON / infoc / infot, nunit, ok, lerr
131 COMMON / srnamc / srnamt
134 DATA intstr /
'0123456789' /
148 CALL ilaver( vers_major, vers_minor, vers_patch )
149 WRITE( nout, fmt = 9994 ) vers_major, vers_minor, vers_patch
153 READ( nin, fmt = * )nm
155 WRITE( nout, fmt = 9996 )
' NM ', nm, 1
158 ELSE IF( nm.GT.maxin )
THEN
159 WRITE( nout, fmt = 9995 )
' NM ', nm, maxin
163 READ( nin, fmt = * )( mval( i ), i = 1, nm )
165 IF( mval( i ).LT.0 )
THEN
166 WRITE( nout, fmt = 9996 )
' M ', mval( i ), 0
168 ELSE IF( mval( i ).GT.nmax )
THEN
169 WRITE( nout, fmt = 9995 )
' M ', mval( i ), nmax
174 $
WRITE( nout, fmt = 9993 )
'M ', ( mval( i ), i = 1, nm )
178 READ( nin, fmt = * )nns
180 WRITE( nout, fmt = 9996 )
' NNS', nns, 1
183 ELSE IF( nns.GT.maxin )
THEN
184 WRITE( nout, fmt = 9995 )
' NNS', nns, maxin
188 READ( nin, fmt = * )( nsval( i ), i = 1, nns )
190 IF( nsval( i ).LT.0 )
THEN
191 WRITE( nout, fmt = 9996 )
'NRHS', nsval( i ), 0
193 ELSE IF( nsval( i ).GT.maxrhs )
THEN
194 WRITE( nout, fmt = 9995 )
'NRHS', nsval( i ), maxrhs
199 $
WRITE( nout, fmt = 9993 )
'NRHS', ( nsval( i ), i = 1, nns )
203 READ( nin, fmt = * )thresh
204 WRITE( nout, fmt = 9992 )thresh
208 READ( nin, fmt = * )tstdrv
212 READ( nin, fmt = * )tsterr
215 WRITE( nout, fmt = 9999 )
221 seps =
slamch(
'Underflow threshold' )
222 WRITE( nout, fmt = 9991 )
'(single precision) underflow', seps
223 seps =
slamch(
'Overflow threshold' )
224 WRITE( nout, fmt = 9991 )
'(single precision) overflow ', seps
225 seps =
slamch(
'Epsilon' )
226 WRITE( nout, fmt = 9991 )
'(single precision) precision', seps
227 WRITE( nout, fmt = * )
229 eps =
dlamch(
'Underflow threshold' )
230 WRITE( nout, fmt = 9991 )
'(double precision) underflow', eps
231 eps =
dlamch(
'Overflow threshold' )
232 WRITE( nout, fmt = 9991 )
'(double precision) overflow ', eps
234 WRITE( nout, fmt = 9991 )
'(double precision) precision', eps
235 WRITE( nout, fmt = * )
241 READ( nin, fmt =
'(A72)',
END = 140 )aline
251 IF( aline( i: i ).EQ.
' ' )
257 IF( c1.EQ.intstr( k: k ) )
THEN
264 nmats = nmats*10 + ic
276 IF( .NOT.
lsame( c1,
'Double precision' ) )
THEN
277 WRITE( nout, fmt = 9990 )path
280 ELSE IF( nmats.LE.0 )
THEN
284 WRITE( nout, fmt = 9989 )path
287 ELSE IF(
lsamen( 2, c2,
'GE' ) )
THEN
292 CALL alareq(
'DGE', nmats, dotype, ntypes, nin, nout )
300 CALL ddrvab( dotype, nm, mval, nns,
301 $ nsval, thresh, lda, a( 1, 1 ),
302 $ a( 1, 2 ), b( 1, 1 ), b( 1, 2 ),
303 $ work, rwork, swork, iwork, nout )
305 WRITE( nout, fmt = 9989 )
'DSGESV'
308 ELSE IF(
lsamen( 2, c2,
'PO' ) )
THEN
313 CALL alareq(
'DPO', nmats, dotype, ntypes, nin, nout )
321 CALL ddrvac( 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 )path
341 WRITE( nout, fmt = 9998 )
342 WRITE( nout, fmt = 9997 )s2 - s1
344 9999
FORMAT( /
' Execution not attempted due to input errors' )
345 9998
FORMAT( /
' End of tests' )
346 9997
FORMAT(
' Total time used = ', f12.2,
' seconds', / )
347 9996
FORMAT(
' Invalid input value: ', a4,
'=', i6,
'; must be >=',
349 9995
FORMAT(
' Invalid input value: ', a4,
'=', i6,
'; must be <=',
351 9994
FORMAT(
' Tests of the DOUBLE PRECISION LAPACK DSGESV/DSPOSV',
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 ddrvab(dotype, nm, mval, nns, nsval, thresh, nmax, a, afac, b, x, work, rwork, swork, iwork, nout)
DDRVAB
subroutine ddrvac(dotype, nm, mval, nns, nsval, thresh, nmax, a, afac, b, x, work, rwork, swork, nout)
DDRVAC
subroutine derrab(nunit)
DERRAB
subroutine derrac(nunit)
DERRAC
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