dchksy.c
Go to the documentation of this file.
00001 /* dchksy.f -- translated by f2c (version 20061008).
00002    You must link the resulting object file with libf2c:
00003         on Microsoft Windows system, link with libf2c.lib;
00004         on Linux or Unix systems, link with .../path/to/libf2c.a -lm
00005         or, if you install libf2c.a in a standard place, with -lf2c -lm
00006         -- in that order, at the end of the command line, as in
00007                 cc *.o -lf2c -lm
00008         Source for libf2c is in /netlib/f2c/libf2c.zip, e.g.,
00009 
00010                 http://www.netlib.org/f2c/libf2c.zip
00011 */
00012 
00013 #include "f2c.h"
00014 #include "blaswrap.h"
00015 
00016 /* Common Block Declarations */
00017 
00018 struct {
00019     integer infot, nunit;
00020     logical ok, lerr;
00021 } infoc_;
00022 
00023 #define infoc_1 infoc_
00024 
00025 struct {
00026     char srnamt[32];
00027 } srnamc_;
00028 
00029 #define srnamc_1 srnamc_
00030 
00031 /* Table of constant values */
00032 
00033 static integer c__2 = 2;
00034 static integer c__0 = 0;
00035 static integer c_n1 = -1;
00036 static integer c__1 = 1;
00037 static integer c__8 = 8;
00038 
00039 /* Subroutine */ int dchksy_(logical *dotype, integer *nn, integer *nval, 
00040         integer *nnb, integer *nbval, integer *nns, integer *nsval, 
00041         doublereal *thresh, logical *tsterr, integer *nmax, doublereal *a, 
00042         doublereal *afac, doublereal *ainv, doublereal *b, doublereal *x, 
00043         doublereal *xact, doublereal *work, doublereal *rwork, integer *iwork, 
00044          integer *nout)
00045 {
00046     /* Initialized data */
00047 
00048     static integer iseedy[4] = { 1988,1989,1990,1991 };
00049     static char uplos[1*2] = "U" "L";
00050 
00051     /* Format strings */
00052     static char fmt_9999[] = "(\002 UPLO = '\002,a1,\002', N =\002,i5,\002, "
00053             "NB =\002,i4,\002, type \002,i2,\002, test \002,i2,\002, ratio "
00054             "=\002,g12.5)";
00055     static char fmt_9998[] = "(\002 UPLO = '\002,a1,\002', N =\002,i5,\002, "
00056             "NRHS=\002,i3,\002, type \002,i2,\002, test(\002,i2,\002) =\002,g"
00057             "12.5)";
00058     static char fmt_9997[] = "(\002 UPLO = '\002,a1,\002', N =\002,i5,\002"
00059             ",\002,10x,\002 type \002,i2,\002, test(\002,i2,\002) =\002,g12.5)"
00060             ;
00061 
00062     /* System generated locals */
00063     integer i__1, i__2, i__3, i__4;
00064 
00065     /* Builtin functions */
00066     /* Subroutine */ int s_copy(char *, char *, ftnlen, ftnlen);
00067     integer s_wsfe(cilist *), do_fio(integer *, char *, ftnlen), e_wsfe(void);
00068 
00069     /* Local variables */
00070     integer i__, j, k, n, i1, i2, nb, in, kl, ku, nt, lda, inb, ioff, mode, 
00071             imat, info;
00072     char path[3], dist[1];
00073     integer irhs, nrhs;
00074     char uplo[1], type__[1];
00075     integer nrun;
00076     extern /* Subroutine */ int alahd_(integer *, char *), dget04_(
00077             integer *, integer *, doublereal *, integer *, doublereal *, 
00078             integer *, doublereal *, doublereal *);
00079     integer nfail, iseed[4];
00080     extern doublereal dget06_(doublereal *, doublereal *);
00081     doublereal rcond;
00082     integer nimat;
00083     extern /* Subroutine */ int dpot02_(char *, integer *, integer *, 
00084             doublereal *, integer *, doublereal *, integer *, doublereal *, 
00085             integer *, doublereal *, doublereal *), dpot03_(char *, 
00086             integer *, doublereal *, integer *, doublereal *, integer *, 
00087             doublereal *, integer *, doublereal *, doublereal *, doublereal *), dpot05_(char *, integer *, integer *, doublereal *, 
00088             integer *, doublereal *, integer *, doublereal *, integer *, 
00089             doublereal *, integer *, doublereal *, doublereal *, doublereal *);
00090     doublereal anorm;
00091     extern /* Subroutine */ int dsyt01_(char *, integer *, doublereal *, 
00092             integer *, doublereal *, integer *, integer *, doublereal *, 
00093             integer *, doublereal *, doublereal *);
00094     integer iuplo, izero, nerrs, lwork;
00095     logical zerot;
00096     char xtype[1];
00097     extern /* Subroutine */ int dlatb4_(char *, integer *, integer *, integer 
00098             *, char *, integer *, integer *, doublereal *, integer *, 
00099             doublereal *, char *), alaerh_(char *, 
00100             char *, integer *, integer *, char *, integer *, integer *, 
00101             integer *, integer *, integer *, integer *, integer *, integer *, 
00102             integer *);
00103     doublereal rcondc;
00104     extern /* Subroutine */ int dlacpy_(char *, integer *, integer *, 
00105             doublereal *, integer *, doublereal *, integer *), 
00106             dlarhs_(char *, char *, char *, char *, integer *, integer *, 
00107             integer *, integer *, integer *, doublereal *, integer *, 
00108             doublereal *, integer *, doublereal *, integer *, integer *, 
00109             integer *), alasum_(char *, 
00110             integer *, integer *, integer *, integer *);
00111     doublereal cndnum;
00112     extern /* Subroutine */ int dlatms_(integer *, integer *, char *, integer 
00113             *, char *, doublereal *, integer *, doublereal *, doublereal *, 
00114             integer *, integer *, char *, doublereal *, integer *, doublereal 
00115             *, integer *);
00116     extern doublereal dlansy_(char *, char *, integer *, doublereal *, 
00117             integer *, doublereal *);
00118     logical trfcon;
00119     extern /* Subroutine */ int xlaenv_(integer *, integer *), dsycon_(char *, 
00120              integer *, doublereal *, integer *, integer *, doublereal *, 
00121             doublereal *, doublereal *, integer *, integer *), 
00122             derrsy_(char *, integer *), dsyrfs_(char *, integer *, 
00123             integer *, doublereal *, integer *, doublereal *, integer *, 
00124             integer *, doublereal *, integer *, doublereal *, integer *, 
00125             doublereal *, doublereal *, doublereal *, integer *, integer *), dsytrf_(char *, integer *, doublereal *, integer *, 
00126             integer *, doublereal *, integer *, integer *);
00127     doublereal result[8];
00128     extern /* Subroutine */ int dsytri_(char *, integer *, doublereal *, 
00129             integer *, integer *, doublereal *, integer *), dsytrs_(
00130             char *, integer *, integer *, doublereal *, integer *, integer *, 
00131             doublereal *, integer *, integer *);
00132 
00133     /* Fortran I/O blocks */
00134     static cilist io___39 = { 0, 0, 0, fmt_9999, 0 };
00135     static cilist io___42 = { 0, 0, 0, fmt_9998, 0 };
00136     static cilist io___44 = { 0, 0, 0, fmt_9997, 0 };
00137 
00138 
00139 
00140 /*  -- LAPACK test routine (version 3.1) -- */
00141 /*     Univ. of Tennessee, Univ. of California Berkeley and NAG Ltd.. */
00142 /*     November 2006 */
00143 
00144 /*     .. Scalar Arguments .. */
00145 /*     .. */
00146 /*     .. Array Arguments .. */
00147 /*     .. */
00148 
00149 /*  Purpose */
00150 /*  ======= */
00151 
00152 /*  DCHKSY tests DSYTRF, -TRI, -TRS, -RFS, and -CON. */
00153 
00154 /*  Arguments */
00155 /*  ========= */
00156 
00157 /*  DOTYPE  (input) LOGICAL array, dimension (NTYPES) */
00158 /*          The matrix types to be used for testing.  Matrices of type j */
00159 /*          (for 1 <= j <= NTYPES) are used for testing if DOTYPE(j) = */
00160 /*          .TRUE.; if DOTYPE(j) = .FALSE., then type j is not used. */
00161 
00162 /*  NN      (input) INTEGER */
00163 /*          The number of values of N contained in the vector NVAL. */
00164 
00165 /*  NVAL    (input) INTEGER array, dimension (NN) */
00166 /*          The values of the matrix dimension N. */
00167 
00168 /*  NNB     (input) INTEGER */
00169 /*          The number of values of NB contained in the vector NBVAL. */
00170 
00171 /*  NBVAL   (input) INTEGER array, dimension (NBVAL) */
00172 /*          The values of the blocksize NB. */
00173 
00174 /*  NNS     (input) INTEGER */
00175 /*          The number of values of NRHS contained in the vector NSVAL. */
00176 
00177 /*  NSVAL   (input) INTEGER array, dimension (NNS) */
00178 /*          The values of the number of right hand sides NRHS. */
00179 
00180 /*  THRESH  (input) DOUBLE PRECISION */
00181 /*          The threshold value for the test ratios.  A result is */
00182 /*          included in the output file if RESULT >= THRESH.  To have */
00183 /*          every test ratio printed, use THRESH = 0. */
00184 
00185 /*  TSTERR  (input) LOGICAL */
00186 /*          Flag that indicates whether error exits are to be tested. */
00187 
00188 /*  NMAX    (input) INTEGER */
00189 /*          The maximum value permitted for N, used in dimensioning the */
00190 /*          work arrays. */
00191 
00192 /*  A       (workspace) DOUBLE PRECISION array, dimension (NMAX*NMAX) */
00193 
00194 /*  AFAC    (workspace) DOUBLE PRECISION array, dimension (NMAX*NMAX) */
00195 
00196 /*  AINV    (workspace) DOUBLE PRECISION array, dimension (NMAX*NMAX) */
00197 
00198 /*  B       (workspace) DOUBLE PRECISION array, dimension (NMAX*NSMAX) */
00199 /*          where NSMAX is the largest entry in NSVAL. */
00200 
00201 /*  X       (workspace) DOUBLE PRECISION array, dimension (NMAX*NSMAX) */
00202 
00203 /*  XACT    (workspace) DOUBLE PRECISION array, dimension (NMAX*NSMAX) */
00204 
00205 /*  WORK    (workspace) DOUBLE PRECISION array, dimension */
00206 /*                      (NMAX*max(3,NSMAX)) */
00207 
00208 /*  RWORK   (workspace) DOUBLE PRECISION array, dimension */
00209 /*                      (max(NMAX,2*NSMAX)) */
00210 
00211 /*  IWORK   (workspace) INTEGER array, dimension (2*NMAX) */
00212 
00213 /*  NOUT    (input) INTEGER */
00214 /*          The unit number for output. */
00215 
00216 /*  ===================================================================== */
00217 
00218 /*     .. Parameters .. */
00219 /*     .. */
00220 /*     .. Local Scalars .. */
00221 /*     .. */
00222 /*     .. Local Arrays .. */
00223 /*     .. */
00224 /*     .. External Functions .. */
00225 /*     .. */
00226 /*     .. External Subroutines .. */
00227 /*     .. */
00228 /*     .. Intrinsic Functions .. */
00229 /*     .. */
00230 /*     .. Scalars in Common .. */
00231 /*     .. */
00232 /*     .. Common blocks .. */
00233 /*     .. */
00234 /*     .. Data statements .. */
00235     /* Parameter adjustments */
00236     --iwork;
00237     --rwork;
00238     --work;
00239     --xact;
00240     --x;
00241     --b;
00242     --ainv;
00243     --afac;
00244     --a;
00245     --nsval;
00246     --nbval;
00247     --nval;
00248     --dotype;
00249 
00250     /* Function Body */
00251 /*     .. */
00252 /*     .. Executable Statements .. */
00253 
00254 /*     Initialize constants and the random number seed. */
00255 
00256     s_copy(path, "Double precision", (ftnlen)1, (ftnlen)16);
00257     s_copy(path + 1, "SY", (ftnlen)2, (ftnlen)2);
00258     nrun = 0;
00259     nfail = 0;
00260     nerrs = 0;
00261     for (i__ = 1; i__ <= 4; ++i__) {
00262         iseed[i__ - 1] = iseedy[i__ - 1];
00263 /* L10: */
00264     }
00265 
00266 /*     Test the error exits */
00267 
00268     if (*tsterr) {
00269         derrsy_(path, nout);
00270     }
00271     infoc_1.infot = 0;
00272     xlaenv_(&c__2, &c__2);
00273 
00274 /*     Do for each value of N in NVAL */
00275 
00276     i__1 = *nn;
00277     for (in = 1; in <= i__1; ++in) {
00278         n = nval[in];
00279         lda = max(n,1);
00280         *(unsigned char *)xtype = 'N';
00281         nimat = 10;
00282         if (n <= 0) {
00283             nimat = 1;
00284         }
00285 
00286         izero = 0;
00287         i__2 = nimat;
00288         for (imat = 1; imat <= i__2; ++imat) {
00289 
00290 /*           Do the tests only if DOTYPE( IMAT ) is true. */
00291 
00292             if (! dotype[imat]) {
00293                 goto L170;
00294             }
00295 
00296 /*           Skip types 3, 4, 5, or 6 if the matrix size is too small. */
00297 
00298             zerot = imat >= 3 && imat <= 6;
00299             if (zerot && n < imat - 2) {
00300                 goto L170;
00301             }
00302 
00303 /*           Do first for UPLO = 'U', then for UPLO = 'L' */
00304 
00305             for (iuplo = 1; iuplo <= 2; ++iuplo) {
00306                 *(unsigned char *)uplo = *(unsigned char *)&uplos[iuplo - 1];
00307 
00308 /*              Set up parameters with DLATB4 and generate a test matrix */
00309 /*              with DLATMS. */
00310 
00311                 dlatb4_(path, &imat, &n, &n, type__, &kl, &ku, &anorm, &mode, 
00312                         &cndnum, dist);
00313 
00314                 s_copy(srnamc_1.srnamt, "DLATMS", (ftnlen)32, (ftnlen)6);
00315                 dlatms_(&n, &n, dist, iseed, type__, &rwork[1], &mode, &
00316                         cndnum, &anorm, &kl, &ku, uplo, &a[1], &lda, &work[1], 
00317                          &info);
00318 
00319 /*              Check error code from DLATMS. */
00320 
00321                 if (info != 0) {
00322                     alaerh_(path, "DLATMS", &info, &c__0, uplo, &n, &n, &c_n1, 
00323                              &c_n1, &c_n1, &imat, &nfail, &nerrs, nout);
00324                     goto L160;
00325                 }
00326 
00327 /*              For types 3-6, zero one or more rows and columns of */
00328 /*              the matrix to test that INFO is returned correctly. */
00329 
00330                 if (zerot) {
00331                     if (imat == 3) {
00332                         izero = 1;
00333                     } else if (imat == 4) {
00334                         izero = n;
00335                     } else {
00336                         izero = n / 2 + 1;
00337                     }
00338 
00339                     if (imat < 6) {
00340 
00341 /*                    Set row and column IZERO to zero. */
00342 
00343                         if (iuplo == 1) {
00344                             ioff = (izero - 1) * lda;
00345                             i__3 = izero - 1;
00346                             for (i__ = 1; i__ <= i__3; ++i__) {
00347                                 a[ioff + i__] = 0.;
00348 /* L20: */
00349                             }
00350                             ioff += izero;
00351                             i__3 = n;
00352                             for (i__ = izero; i__ <= i__3; ++i__) {
00353                                 a[ioff] = 0.;
00354                                 ioff += lda;
00355 /* L30: */
00356                             }
00357                         } else {
00358                             ioff = izero;
00359                             i__3 = izero - 1;
00360                             for (i__ = 1; i__ <= i__3; ++i__) {
00361                                 a[ioff] = 0.;
00362                                 ioff += lda;
00363 /* L40: */
00364                             }
00365                             ioff -= izero;
00366                             i__3 = n;
00367                             for (i__ = izero; i__ <= i__3; ++i__) {
00368                                 a[ioff + i__] = 0.;
00369 /* L50: */
00370                             }
00371                         }
00372                     } else {
00373                         ioff = 0;
00374                         if (iuplo == 1) {
00375 
00376 /*                       Set the first IZERO rows and columns to zero. */
00377 
00378                             i__3 = n;
00379                             for (j = 1; j <= i__3; ++j) {
00380                                 i2 = min(j,izero);
00381                                 i__4 = i2;
00382                                 for (i__ = 1; i__ <= i__4; ++i__) {
00383                                     a[ioff + i__] = 0.;
00384 /* L60: */
00385                                 }
00386                                 ioff += lda;
00387 /* L70: */
00388                             }
00389                         } else {
00390 
00391 /*                       Set the last IZERO rows and columns to zero. */
00392 
00393                             i__3 = n;
00394                             for (j = 1; j <= i__3; ++j) {
00395                                 i1 = max(j,izero);
00396                                 i__4 = n;
00397                                 for (i__ = i1; i__ <= i__4; ++i__) {
00398                                     a[ioff + i__] = 0.;
00399 /* L80: */
00400                                 }
00401                                 ioff += lda;
00402 /* L90: */
00403                             }
00404                         }
00405                     }
00406                 } else {
00407                     izero = 0;
00408                 }
00409 
00410 /*              Do for each value of NB in NBVAL */
00411 
00412                 i__3 = *nnb;
00413                 for (inb = 1; inb <= i__3; ++inb) {
00414                     nb = nbval[inb];
00415                     xlaenv_(&c__1, &nb);
00416 
00417 /*                 Compute the L*D*L' or U*D*U' factorization of the */
00418 /*                 matrix. */
00419 
00420                     dlacpy_(uplo, &n, &n, &a[1], &lda, &afac[1], &lda);
00421                     lwork = max(2,nb) * lda;
00422                     s_copy(srnamc_1.srnamt, "DSYTRF", (ftnlen)32, (ftnlen)6);
00423                     dsytrf_(uplo, &n, &afac[1], &lda, &iwork[1], &ainv[1], &
00424                             lwork, &info);
00425 
00426 /*                 Adjust the expected value of INFO to account for */
00427 /*                 pivoting. */
00428 
00429                     k = izero;
00430                     if (k > 0) {
00431 L100:
00432                         if (iwork[k] < 0) {
00433                             if (iwork[k] != -k) {
00434                                 k = -iwork[k];
00435                                 goto L100;
00436                             }
00437                         } else if (iwork[k] != k) {
00438                             k = iwork[k];
00439                             goto L100;
00440                         }
00441                     }
00442 
00443 /*                 Check error code from DSYTRF. */
00444 
00445                     if (info != k) {
00446                         alaerh_(path, "DSYTRF", &info, &k, uplo, &n, &n, &
00447                                 c_n1, &c_n1, &nb, &imat, &nfail, &nerrs, nout);
00448                     }
00449                     if (info != 0) {
00450                         trfcon = TRUE_;
00451                     } else {
00452                         trfcon = FALSE_;
00453                     }
00454 
00455 /* +    TEST 1 */
00456 /*                 Reconstruct matrix from factors and compute residual. */
00457 
00458                     dsyt01_(uplo, &n, &a[1], &lda, &afac[1], &lda, &iwork[1], 
00459                             &ainv[1], &lda, &rwork[1], result);
00460                     nt = 1;
00461 
00462 /* +    TEST 2 */
00463 /*                 Form the inverse and compute the residual. */
00464 
00465                     if (inb == 1 && ! trfcon) {
00466                         dlacpy_(uplo, &n, &n, &afac[1], &lda, &ainv[1], &lda);
00467                         s_copy(srnamc_1.srnamt, "DSYTRI", (ftnlen)32, (ftnlen)
00468                                 6);
00469                         dsytri_(uplo, &n, &ainv[1], &lda, &iwork[1], &work[1], 
00470                                  &info);
00471 
00472 /*                 Check error code from DSYTRI. */
00473 
00474                         if (info != 0) {
00475                             alaerh_(path, "DSYTRI", &info, &c_n1, uplo, &n, &
00476                                     n, &c_n1, &c_n1, &c_n1, &imat, &nfail, &
00477                                     nerrs, nout);
00478                         }
00479 
00480                         dpot03_(uplo, &n, &a[1], &lda, &ainv[1], &lda, &work[
00481                                 1], &lda, &rwork[1], &rcondc, &result[1]);
00482                         nt = 2;
00483                     }
00484 
00485 /*                 Print information about the tests that did not pass */
00486 /*                 the threshold. */
00487 
00488                     i__4 = nt;
00489                     for (k = 1; k <= i__4; ++k) {
00490                         if (result[k - 1] >= *thresh) {
00491                             if (nfail == 0 && nerrs == 0) {
00492                                 alahd_(nout, path);
00493                             }
00494                             io___39.ciunit = *nout;
00495                             s_wsfe(&io___39);
00496                             do_fio(&c__1, uplo, (ftnlen)1);
00497                             do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer))
00498                                     ;
00499                             do_fio(&c__1, (char *)&nb, (ftnlen)sizeof(integer)
00500                                     );
00501                             do_fio(&c__1, (char *)&imat, (ftnlen)sizeof(
00502                                     integer));
00503                             do_fio(&c__1, (char *)&k, (ftnlen)sizeof(integer))
00504                                     ;
00505                             do_fio(&c__1, (char *)&result[k - 1], (ftnlen)
00506                                     sizeof(doublereal));
00507                             e_wsfe();
00508                             ++nfail;
00509                         }
00510 /* L110: */
00511                     }
00512                     nrun += nt;
00513 
00514 /*                 Skip the other tests if this is not the first block */
00515 /*                 size. */
00516 
00517                     if (inb > 1) {
00518                         goto L150;
00519                     }
00520 
00521 /*                 Do only the condition estimate if INFO is not 0. */
00522 
00523                     if (trfcon) {
00524                         rcondc = 0.;
00525                         goto L140;
00526                     }
00527 
00528                     i__4 = *nns;
00529                     for (irhs = 1; irhs <= i__4; ++irhs) {
00530                         nrhs = nsval[irhs];
00531 
00532 /* +    TEST 3 */
00533 /*                 Solve and compute residual for  A * X = B. */
00534 
00535                         s_copy(srnamc_1.srnamt, "DLARHS", (ftnlen)32, (ftnlen)
00536                                 6);
00537                         dlarhs_(path, xtype, uplo, " ", &n, &n, &kl, &ku, &
00538                                 nrhs, &a[1], &lda, &xact[1], &lda, &b[1], &
00539                                 lda, iseed, &info);
00540                         dlacpy_("Full", &n, &nrhs, &b[1], &lda, &x[1], &lda);
00541 
00542                         s_copy(srnamc_1.srnamt, "DSYTRS", (ftnlen)32, (ftnlen)
00543                                 6);
00544                         dsytrs_(uplo, &n, &nrhs, &afac[1], &lda, &iwork[1], &
00545                                 x[1], &lda, &info);
00546 
00547 /*                 Check error code from DSYTRS. */
00548 
00549                         if (info != 0) {
00550                             alaerh_(path, "DSYTRS", &info, &c__0, uplo, &n, &
00551                                     n, &c_n1, &c_n1, &nrhs, &imat, &nfail, &
00552                                     nerrs, nout);
00553                         }
00554 
00555                         dlacpy_("Full", &n, &nrhs, &b[1], &lda, &work[1], &
00556                                 lda);
00557                         dpot02_(uplo, &n, &nrhs, &a[1], &lda, &x[1], &lda, &
00558                                 work[1], &lda, &rwork[1], &result[2]);
00559 
00560 /* +    TEST 4 */
00561 /*                 Check solution from generated exact solution. */
00562 
00563                         dget04_(&n, &nrhs, &x[1], &lda, &xact[1], &lda, &
00564                                 rcondc, &result[3]);
00565 
00566 /* +    TESTS 5, 6, and 7 */
00567 /*                 Use iterative refinement to improve the solution. */
00568 
00569                         s_copy(srnamc_1.srnamt, "DSYRFS", (ftnlen)32, (ftnlen)
00570                                 6);
00571                         dsyrfs_(uplo, &n, &nrhs, &a[1], &lda, &afac[1], &lda, 
00572                                 &iwork[1], &b[1], &lda, &x[1], &lda, &rwork[1]
00573 , &rwork[nrhs + 1], &work[1], &iwork[n + 1], &
00574                                 info);
00575 
00576 /*                 Check error code from DSYRFS. */
00577 
00578                         if (info != 0) {
00579                             alaerh_(path, "DSYRFS", &info, &c__0, uplo, &n, &
00580                                     n, &c_n1, &c_n1, &nrhs, &imat, &nfail, &
00581                                     nerrs, nout);
00582                         }
00583 
00584                         dget04_(&n, &nrhs, &x[1], &lda, &xact[1], &lda, &
00585                                 rcondc, &result[4]);
00586                         dpot05_(uplo, &n, &nrhs, &a[1], &lda, &b[1], &lda, &x[
00587                                 1], &lda, &xact[1], &lda, &rwork[1], &rwork[
00588                                 nrhs + 1], &result[5]);
00589 
00590 /*                    Print information about the tests that did not pass */
00591 /*                    the threshold. */
00592 
00593                         for (k = 3; k <= 7; ++k) {
00594                             if (result[k - 1] >= *thresh) {
00595                                 if (nfail == 0 && nerrs == 0) {
00596                                     alahd_(nout, path);
00597                                 }
00598                                 io___42.ciunit = *nout;
00599                                 s_wsfe(&io___42);
00600                                 do_fio(&c__1, uplo, (ftnlen)1);
00601                                 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(
00602                                         integer));
00603                                 do_fio(&c__1, (char *)&nrhs, (ftnlen)sizeof(
00604                                         integer));
00605                                 do_fio(&c__1, (char *)&imat, (ftnlen)sizeof(
00606                                         integer));
00607                                 do_fio(&c__1, (char *)&k, (ftnlen)sizeof(
00608                                         integer));
00609                                 do_fio(&c__1, (char *)&result[k - 1], (ftnlen)
00610                                         sizeof(doublereal));
00611                                 e_wsfe();
00612                                 ++nfail;
00613                             }
00614 /* L120: */
00615                         }
00616                         nrun += 5;
00617 /* L130: */
00618                     }
00619 
00620 /* +    TEST 8 */
00621 /*                 Get an estimate of RCOND = 1/CNDNUM. */
00622 
00623 L140:
00624                     anorm = dlansy_("1", uplo, &n, &a[1], &lda, &rwork[1]);
00625                     s_copy(srnamc_1.srnamt, "DSYCON", (ftnlen)32, (ftnlen)6);
00626                     dsycon_(uplo, &n, &afac[1], &lda, &iwork[1], &anorm, &
00627                             rcond, &work[1], &iwork[n + 1], &info);
00628 
00629 /*                 Check error code from DSYCON. */
00630 
00631                     if (info != 0) {
00632                         alaerh_(path, "DSYCON", &info, &c__0, uplo, &n, &n, &
00633                                 c_n1, &c_n1, &c_n1, &imat, &nfail, &nerrs, 
00634                                 nout);
00635                     }
00636 
00637                     result[7] = dget06_(&rcond, &rcondc);
00638 
00639 /*                 Print information about the tests that did not pass */
00640 /*                 the threshold. */
00641 
00642                     if (result[7] >= *thresh) {
00643                         if (nfail == 0 && nerrs == 0) {
00644                             alahd_(nout, path);
00645                         }
00646                         io___44.ciunit = *nout;
00647                         s_wsfe(&io___44);
00648                         do_fio(&c__1, uplo, (ftnlen)1);
00649                         do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
00650                         do_fio(&c__1, (char *)&imat, (ftnlen)sizeof(integer));
00651                         do_fio(&c__1, (char *)&c__8, (ftnlen)sizeof(integer));
00652                         do_fio(&c__1, (char *)&result[7], (ftnlen)sizeof(
00653                                 doublereal));
00654                         e_wsfe();
00655                         ++nfail;
00656                     }
00657                     ++nrun;
00658 L150:
00659                     ;
00660                 }
00661 
00662 L160:
00663                 ;
00664             }
00665 L170:
00666             ;
00667         }
00668 /* L180: */
00669     }
00670 
00671 /*     Print a summary of the results. */
00672 
00673     alasum_(path, nout, &nfail, &nrun, &nerrs);
00674 
00675     return 0;
00676 
00677 /*     End of DCHKSY */
00678 
00679 } /* dchksy_ */


swiftnav
Author(s):
autogenerated on Sat Jun 8 2019 18:55:39