schkeq.c
Go to the documentation of this file.
00001 /* schkeq.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 /* Table of constant values */
00017 
00018 static real c_b7 = 10.f;
00019 static integer c_n1 = -1;
00020 static integer c__5 = 5;
00021 static integer c__13 = 13;
00022 static integer c__1 = 1;
00023 
00024 /* Subroutine */ int schkeq_(real *thresh, integer *nout)
00025 {
00026     /* Format strings */
00027     static char fmt_9999[] = "(1x,\002All tests for \002,a3,\002 routines pa"
00028             "ssed the threshold\002)";
00029     static char fmt_9998[] = "(\002 SGEEQU failed test with value \002,e10"
00030             ".3,\002 exceeding\002,\002 threshold \002,e10.3)";
00031     static char fmt_9997[] = "(\002 SGBEQU failed test with value \002,e10"
00032             ".3,\002 exceeding\002,\002 threshold \002,e10.3)";
00033     static char fmt_9996[] = "(\002 SPOEQU failed test with value \002,e10"
00034             ".3,\002 exceeding\002,\002 threshold \002,e10.3)";
00035     static char fmt_9995[] = "(\002 SPPEQU failed test with value \002,e10"
00036             ".3,\002 exceeding\002,\002 threshold \002,e10.3)";
00037     static char fmt_9994[] = "(\002 SPBEQU failed test with value \002,e10"
00038             ".3,\002 exceeding\002,\002 threshold \002,e10.3)";
00039 
00040     /* System generated locals */
00041     integer i__1, i__2, i__3, i__4, i__5, i__6, i__7, i__8;
00042     real r__1, r__2, r__3;
00043 
00044     /* Builtin functions */
00045     /* Subroutine */ int s_copy(char *, char *, ftnlen, ftnlen);
00046     double pow_ri(real *, integer *);
00047     integer pow_ii(integer *, integer *), s_wsle(cilist *), e_wsle(void), 
00048             s_wsfe(cilist *), do_fio(integer *, char *, ftnlen), e_wsfe(void);
00049 
00050     /* Local variables */
00051     real a[25]  /* was [5][5] */, c__[5];
00052     integer i__, j, m, n;
00053     real r__[5], ab[65] /* was [13][5] */, ap[15];
00054     integer kl;
00055     logical ok;
00056     integer ku;
00057     real eps, pow[11];
00058     integer info;
00059     char path[3];
00060     real norm, rpow[11], ccond, rcond, rcmin, rcmax, ratio;
00061     extern doublereal slamch_(char *);
00062     extern /* Subroutine */ int sgbequ_(integer *, integer *, integer *, 
00063             integer *, real *, integer *, real *, real *, real *, real *, 
00064             real *, integer *), sgeequ_(integer *, integer *, real *, integer 
00065             *, real *, real *, real *, real *, real *, integer *), spbequ_(
00066             char *, integer *, integer *, real *, integer *, real *, real *, 
00067             real *, integer *);
00068     real reslts[5];
00069     extern /* Subroutine */ int spoequ_(integer *, real *, integer *, real *, 
00070             real *, real *, integer *), sppequ_(char *, integer *, real *, 
00071             real *, real *, real *, integer *);
00072 
00073     /* Fortran I/O blocks */
00074     static cilist io___25 = { 0, 0, 0, 0, 0 };
00075     static cilist io___26 = { 0, 0, 0, fmt_9999, 0 };
00076     static cilist io___27 = { 0, 0, 0, fmt_9998, 0 };
00077     static cilist io___28 = { 0, 0, 0, fmt_9997, 0 };
00078     static cilist io___29 = { 0, 0, 0, fmt_9996, 0 };
00079     static cilist io___30 = { 0, 0, 0, fmt_9995, 0 };
00080     static cilist io___31 = { 0, 0, 0, fmt_9994, 0 };
00081 
00082 
00083 
00084 /*  -- LAPACK test routine (version 3.1) -- */
00085 /*     Univ. of Tennessee, Univ. of California Berkeley and NAG Ltd.. */
00086 /*     November 2006 */
00087 
00088 /*     .. Scalar Arguments .. */
00089 /*     .. */
00090 
00091 /*  Purpose */
00092 /*  ======= */
00093 
00094 /*  SCHKEQ tests SGEEQU, SGBEQU, SPOEQU, SPPEQU and SPBEQU */
00095 
00096 /*  Arguments */
00097 /*  ========= */
00098 
00099 /*  THRESH  (input) REAL */
00100 /*          Threshold for testing routines. Should be between 2 and 10. */
00101 
00102 /*  NOUT    (input) INTEGER */
00103 /*          The unit number for output. */
00104 
00105 /*  ===================================================================== */
00106 
00107 /*     .. Parameters .. */
00108 /*     .. */
00109 /*     .. Local Scalars .. */
00110 /*     .. */
00111 /*     .. Local Arrays .. */
00112 /*     .. */
00113 /*     .. External Functions .. */
00114 /*     .. */
00115 /*     .. External Subroutines .. */
00116 /*     .. */
00117 /*     .. Intrinsic Functions .. */
00118 /*     .. */
00119 /*     .. Executable Statements .. */
00120 
00121     s_copy(path, "Single precision", (ftnlen)1, (ftnlen)16);
00122     s_copy(path + 1, "EQ", (ftnlen)2, (ftnlen)2);
00123 
00124     eps = slamch_("P");
00125     for (i__ = 1; i__ <= 5; ++i__) {
00126         reslts[i__ - 1] = 0.f;
00127 /* L10: */
00128     }
00129     for (i__ = 1; i__ <= 11; ++i__) {
00130         i__1 = i__ - 1;
00131         pow[i__ - 1] = pow_ri(&c_b7, &i__1);
00132         rpow[i__ - 1] = 1.f / pow[i__ - 1];
00133 /* L20: */
00134     }
00135 
00136 /*     Test SGEEQU */
00137 
00138     for (n = 0; n <= 5; ++n) {
00139         for (m = 0; m <= 5; ++m) {
00140 
00141             for (j = 1; j <= 5; ++j) {
00142                 for (i__ = 1; i__ <= 5; ++i__) {
00143                     if (i__ <= m && j <= n) {
00144                         i__1 = i__ + j;
00145                         a[i__ + j * 5 - 6] = pow[i__ + j] * pow_ii(&c_n1, &
00146                                 i__1);
00147                     } else {
00148                         a[i__ + j * 5 - 6] = 0.f;
00149                     }
00150 /* L30: */
00151                 }
00152 /* L40: */
00153             }
00154 
00155             sgeequ_(&m, &n, a, &c__5, r__, c__, &rcond, &ccond, &norm, &info);
00156 
00157             if (info != 0) {
00158                 reslts[0] = 1.f;
00159             } else {
00160                 if (n != 0 && m != 0) {
00161 /* Computing MAX */
00162                     r__2 = reslts[0], r__3 = (r__1 = (rcond - rpow[m - 1]) / 
00163                             rpow[m - 1], dabs(r__1));
00164                     reslts[0] = dmax(r__2,r__3);
00165 /* Computing MAX */
00166                     r__2 = reslts[0], r__3 = (r__1 = (ccond - rpow[n - 1]) / 
00167                             rpow[n - 1], dabs(r__1));
00168                     reslts[0] = dmax(r__2,r__3);
00169 /* Computing MAX */
00170                     r__2 = reslts[0], r__3 = (r__1 = (norm - pow[n + m]) / 
00171                             pow[n + m], dabs(r__1));
00172                     reslts[0] = dmax(r__2,r__3);
00173                     i__1 = m;
00174                     for (i__ = 1; i__ <= i__1; ++i__) {
00175 /* Computing MAX */
00176                         r__2 = reslts[0], r__3 = (r__1 = (r__[i__ - 1] - rpow[
00177                                 i__ + n]) / rpow[i__ + n], dabs(r__1));
00178                         reslts[0] = dmax(r__2,r__3);
00179 /* L50: */
00180                     }
00181                     i__1 = n;
00182                     for (j = 1; j <= i__1; ++j) {
00183 /* Computing MAX */
00184                         r__2 = reslts[0], r__3 = (r__1 = (c__[j - 1] - pow[n 
00185                                 - j]) / pow[n - j], dabs(r__1));
00186                         reslts[0] = dmax(r__2,r__3);
00187 /* L60: */
00188                     }
00189                 }
00190             }
00191 
00192 /* L70: */
00193         }
00194 /* L80: */
00195     }
00196 
00197 /*     Test with zero rows and columns */
00198 
00199     for (j = 1; j <= 5; ++j) {
00200         a[j * 5 - 2] = 0.f;
00201 /* L90: */
00202     }
00203     sgeequ_(&c__5, &c__5, a, &c__5, r__, c__, &rcond, &ccond, &norm, &info);
00204     if (info != 4) {
00205         reslts[0] = 1.f;
00206     }
00207 
00208     for (j = 1; j <= 5; ++j) {
00209         a[j * 5 - 2] = 1.f;
00210 /* L100: */
00211     }
00212     for (i__ = 1; i__ <= 5; ++i__) {
00213         a[i__ + 14] = 0.f;
00214 /* L110: */
00215     }
00216     sgeequ_(&c__5, &c__5, a, &c__5, r__, c__, &rcond, &ccond, &norm, &info);
00217     if (info != 9) {
00218         reslts[0] = 1.f;
00219     }
00220     reslts[0] /= eps;
00221 
00222 /*     Test SGBEQU */
00223 
00224     for (n = 0; n <= 5; ++n) {
00225         for (m = 0; m <= 5; ++m) {
00226 /* Computing MAX */
00227             i__2 = m - 1;
00228             i__1 = max(i__2,0);
00229             for (kl = 0; kl <= i__1; ++kl) {
00230 /* Computing MAX */
00231                 i__3 = n - 1;
00232                 i__2 = max(i__3,0);
00233                 for (ku = 0; ku <= i__2; ++ku) {
00234 
00235                     for (j = 1; j <= 5; ++j) {
00236                         for (i__ = 1; i__ <= 13; ++i__) {
00237                             ab[i__ + j * 13 - 14] = 0.f;
00238 /* L120: */
00239                         }
00240 /* L130: */
00241                     }
00242                     i__3 = n;
00243                     for (j = 1; j <= i__3; ++j) {
00244                         i__4 = m;
00245                         for (i__ = 1; i__ <= i__4; ++i__) {
00246 /* Computing MIN */
00247                             i__5 = m, i__6 = j + kl;
00248 /* Computing MAX */
00249                             i__7 = 1, i__8 = j - ku;
00250                             if (i__ <= min(i__5,i__6) && i__ >= max(i__7,i__8)
00251                                      && j <= n) {
00252                                 i__5 = i__ + j;
00253                                 ab[ku + 1 + i__ - j + j * 13 - 14] = pow[i__ 
00254                                         + j] * pow_ii(&c_n1, &i__5);
00255                             }
00256 /* L140: */
00257                         }
00258 /* L150: */
00259                     }
00260 
00261                     sgbequ_(&m, &n, &kl, &ku, ab, &c__13, r__, c__, &rcond, &
00262                             ccond, &norm, &info);
00263 
00264                     if (info != 0) {
00265                         if (! (n + kl < m && info == n + kl + 1 || m + ku < n 
00266                                 && info == (m << 1) + ku + 1)) {
00267                             reslts[1] = 1.f;
00268                         }
00269                     } else {
00270                         if (n != 0 && m != 0) {
00271 
00272                             rcmin = r__[0];
00273                             rcmax = r__[0];
00274                             i__3 = m;
00275                             for (i__ = 1; i__ <= i__3; ++i__) {
00276 /* Computing MIN */
00277                                 r__1 = rcmin, r__2 = r__[i__ - 1];
00278                                 rcmin = dmin(r__1,r__2);
00279 /* Computing MAX */
00280                                 r__1 = rcmax, r__2 = r__[i__ - 1];
00281                                 rcmax = dmax(r__1,r__2);
00282 /* L160: */
00283                             }
00284                             ratio = rcmin / rcmax;
00285 /* Computing MAX */
00286                             r__2 = reslts[1], r__3 = (r__1 = (rcond - ratio) /
00287                                      ratio, dabs(r__1));
00288                             reslts[1] = dmax(r__2,r__3);
00289 
00290                             rcmin = c__[0];
00291                             rcmax = c__[0];
00292                             i__3 = n;
00293                             for (j = 1; j <= i__3; ++j) {
00294 /* Computing MIN */
00295                                 r__1 = rcmin, r__2 = c__[j - 1];
00296                                 rcmin = dmin(r__1,r__2);
00297 /* Computing MAX */
00298                                 r__1 = rcmax, r__2 = c__[j - 1];
00299                                 rcmax = dmax(r__1,r__2);
00300 /* L170: */
00301                             }
00302                             ratio = rcmin / rcmax;
00303 /* Computing MAX */
00304                             r__2 = reslts[1], r__3 = (r__1 = (ccond - ratio) /
00305                                      ratio, dabs(r__1));
00306                             reslts[1] = dmax(r__2,r__3);
00307 
00308 /* Computing MAX */
00309                             r__2 = reslts[1], r__3 = (r__1 = (norm - pow[n + 
00310                                     m]) / pow[n + m], dabs(r__1));
00311                             reslts[1] = dmax(r__2,r__3);
00312                             i__3 = m;
00313                             for (i__ = 1; i__ <= i__3; ++i__) {
00314                                 rcmax = 0.f;
00315                                 i__4 = n;
00316                                 for (j = 1; j <= i__4; ++j) {
00317                                     if (i__ <= j + kl && i__ >= j - ku) {
00318                                         ratio = (r__1 = r__[i__ - 1] * pow[
00319                                                 i__ + j] * c__[j - 1], dabs(
00320                                                 r__1));
00321                                         rcmax = dmax(rcmax,ratio);
00322                                     }
00323 /* L180: */
00324                                 }
00325 /* Computing MAX */
00326                                 r__2 = reslts[1], r__3 = (r__1 = 1.f - rcmax, 
00327                                         dabs(r__1));
00328                                 reslts[1] = dmax(r__2,r__3);
00329 /* L190: */
00330                             }
00331 
00332                             i__3 = n;
00333                             for (j = 1; j <= i__3; ++j) {
00334                                 rcmax = 0.f;
00335                                 i__4 = m;
00336                                 for (i__ = 1; i__ <= i__4; ++i__) {
00337                                     if (i__ <= j + kl && i__ >= j - ku) {
00338                                         ratio = (r__1 = r__[i__ - 1] * pow[
00339                                                 i__ + j] * c__[j - 1], dabs(
00340                                                 r__1));
00341                                         rcmax = dmax(rcmax,ratio);
00342                                     }
00343 /* L200: */
00344                                 }
00345 /* Computing MAX */
00346                                 r__2 = reslts[1], r__3 = (r__1 = 1.f - rcmax, 
00347                                         dabs(r__1));
00348                                 reslts[1] = dmax(r__2,r__3);
00349 /* L210: */
00350                             }
00351                         }
00352                     }
00353 
00354 /* L220: */
00355                 }
00356 /* L230: */
00357             }
00358 /* L240: */
00359         }
00360 /* L250: */
00361     }
00362     reslts[1] /= eps;
00363 
00364 /*     Test SPOEQU */
00365 
00366     for (n = 0; n <= 5; ++n) {
00367 
00368         for (i__ = 1; i__ <= 5; ++i__) {
00369             for (j = 1; j <= 5; ++j) {
00370                 if (i__ <= n && j == i__) {
00371                     i__1 = i__ + j;
00372                     a[i__ + j * 5 - 6] = pow[i__ + j] * pow_ii(&c_n1, &i__1);
00373                 } else {
00374                     a[i__ + j * 5 - 6] = 0.f;
00375                 }
00376 /* L260: */
00377             }
00378 /* L270: */
00379         }
00380 
00381         spoequ_(&n, a, &c__5, r__, &rcond, &norm, &info);
00382 
00383         if (info != 0) {
00384             reslts[2] = 1.f;
00385         } else {
00386             if (n != 0) {
00387 /* Computing MAX */
00388                 r__2 = reslts[2], r__3 = (r__1 = (rcond - rpow[n - 1]) / rpow[
00389                         n - 1], dabs(r__1));
00390                 reslts[2] = dmax(r__2,r__3);
00391 /* Computing MAX */
00392                 r__2 = reslts[2], r__3 = (r__1 = (norm - pow[n * 2]) / pow[n *
00393                          2], dabs(r__1));
00394                 reslts[2] = dmax(r__2,r__3);
00395                 i__1 = n;
00396                 for (i__ = 1; i__ <= i__1; ++i__) {
00397 /* Computing MAX */
00398                     r__2 = reslts[2], r__3 = (r__1 = (r__[i__ - 1] - rpow[i__]
00399                             ) / rpow[i__], dabs(r__1));
00400                     reslts[2] = dmax(r__2,r__3);
00401 /* L280: */
00402                 }
00403             }
00404         }
00405 /* L290: */
00406     }
00407     a[18] = -1.f;
00408     spoequ_(&c__5, a, &c__5, r__, &rcond, &norm, &info);
00409     if (info != 4) {
00410         reslts[2] = 1.f;
00411     }
00412     reslts[2] /= eps;
00413 
00414 /*     Test SPPEQU */
00415 
00416     for (n = 0; n <= 5; ++n) {
00417 
00418 /*        Upper triangular packed storage */
00419 
00420         i__1 = n * (n + 1) / 2;
00421         for (i__ = 1; i__ <= i__1; ++i__) {
00422             ap[i__ - 1] = 0.f;
00423 /* L300: */
00424         }
00425         i__1 = n;
00426         for (i__ = 1; i__ <= i__1; ++i__) {
00427             ap[i__ * (i__ + 1) / 2 - 1] = pow[i__ * 2];
00428 /* L310: */
00429         }
00430 
00431         sppequ_("U", &n, ap, r__, &rcond, &norm, &info);
00432 
00433         if (info != 0) {
00434             reslts[3] = 1.f;
00435         } else {
00436             if (n != 0) {
00437 /* Computing MAX */
00438                 r__2 = reslts[3], r__3 = (r__1 = (rcond - rpow[n - 1]) / rpow[
00439                         n - 1], dabs(r__1));
00440                 reslts[3] = dmax(r__2,r__3);
00441 /* Computing MAX */
00442                 r__2 = reslts[3], r__3 = (r__1 = (norm - pow[n * 2]) / pow[n *
00443                          2], dabs(r__1));
00444                 reslts[3] = dmax(r__2,r__3);
00445                 i__1 = n;
00446                 for (i__ = 1; i__ <= i__1; ++i__) {
00447 /* Computing MAX */
00448                     r__2 = reslts[3], r__3 = (r__1 = (r__[i__ - 1] - rpow[i__]
00449                             ) / rpow[i__], dabs(r__1));
00450                     reslts[3] = dmax(r__2,r__3);
00451 /* L320: */
00452                 }
00453             }
00454         }
00455 
00456 /*        Lower triangular packed storage */
00457 
00458         i__1 = n * (n + 1) / 2;
00459         for (i__ = 1; i__ <= i__1; ++i__) {
00460             ap[i__ - 1] = 0.f;
00461 /* L330: */
00462         }
00463         j = 1;
00464         i__1 = n;
00465         for (i__ = 1; i__ <= i__1; ++i__) {
00466             ap[j - 1] = pow[i__ * 2];
00467             j += n - i__ + 1;
00468 /* L340: */
00469         }
00470 
00471         sppequ_("L", &n, ap, r__, &rcond, &norm, &info);
00472 
00473         if (info != 0) {
00474             reslts[3] = 1.f;
00475         } else {
00476             if (n != 0) {
00477 /* Computing MAX */
00478                 r__2 = reslts[3], r__3 = (r__1 = (rcond - rpow[n - 1]) / rpow[
00479                         n - 1], dabs(r__1));
00480                 reslts[3] = dmax(r__2,r__3);
00481 /* Computing MAX */
00482                 r__2 = reslts[3], r__3 = (r__1 = (norm - pow[n * 2]) / pow[n *
00483                          2], dabs(r__1));
00484                 reslts[3] = dmax(r__2,r__3);
00485                 i__1 = n;
00486                 for (i__ = 1; i__ <= i__1; ++i__) {
00487 /* Computing MAX */
00488                     r__2 = reslts[3], r__3 = (r__1 = (r__[i__ - 1] - rpow[i__]
00489                             ) / rpow[i__], dabs(r__1));
00490                     reslts[3] = dmax(r__2,r__3);
00491 /* L350: */
00492                 }
00493             }
00494         }
00495 
00496 /* L360: */
00497     }
00498     i__ = 13;
00499     ap[i__ - 1] = -1.f;
00500     sppequ_("L", &c__5, ap, r__, &rcond, &norm, &info);
00501     if (info != 4) {
00502         reslts[3] = 1.f;
00503     }
00504     reslts[3] /= eps;
00505 
00506 /*     Test SPBEQU */
00507 
00508     for (n = 0; n <= 5; ++n) {
00509 /* Computing MAX */
00510         i__2 = n - 1;
00511         i__1 = max(i__2,0);
00512         for (kl = 0; kl <= i__1; ++kl) {
00513 
00514 /*           Test upper triangular storage */
00515 
00516             for (j = 1; j <= 5; ++j) {
00517                 for (i__ = 1; i__ <= 13; ++i__) {
00518                     ab[i__ + j * 13 - 14] = 0.f;
00519 /* L370: */
00520                 }
00521 /* L380: */
00522             }
00523             i__2 = n;
00524             for (j = 1; j <= i__2; ++j) {
00525                 ab[kl + 1 + j * 13 - 14] = pow[j * 2];
00526 /* L390: */
00527             }
00528 
00529             spbequ_("U", &n, &kl, ab, &c__13, r__, &rcond, &norm, &info);
00530 
00531             if (info != 0) {
00532                 reslts[4] = 1.f;
00533             } else {
00534                 if (n != 0) {
00535 /* Computing MAX */
00536                     r__2 = reslts[4], r__3 = (r__1 = (rcond - rpow[n - 1]) / 
00537                             rpow[n - 1], dabs(r__1));
00538                     reslts[4] = dmax(r__2,r__3);
00539 /* Computing MAX */
00540                     r__2 = reslts[4], r__3 = (r__1 = (norm - pow[n * 2]) / 
00541                             pow[n * 2], dabs(r__1));
00542                     reslts[4] = dmax(r__2,r__3);
00543                     i__2 = n;
00544                     for (i__ = 1; i__ <= i__2; ++i__) {
00545 /* Computing MAX */
00546                         r__2 = reslts[4], r__3 = (r__1 = (r__[i__ - 1] - rpow[
00547                                 i__]) / rpow[i__], dabs(r__1));
00548                         reslts[4] = dmax(r__2,r__3);
00549 /* L400: */
00550                     }
00551                 }
00552             }
00553             if (n != 0) {
00554 /* Computing MAX */
00555                 i__2 = n - 1;
00556                 ab[kl + 1 + max(i__2,1) * 13 - 14] = -1.f;
00557                 spbequ_("U", &n, &kl, ab, &c__13, r__, &rcond, &norm, &info);
00558 /* Computing MAX */
00559                 i__2 = n - 1;
00560                 if (info != max(i__2,1)) {
00561                     reslts[4] = 1.f;
00562                 }
00563             }
00564 
00565 /*           Test lower triangular storage */
00566 
00567             for (j = 1; j <= 5; ++j) {
00568                 for (i__ = 1; i__ <= 13; ++i__) {
00569                     ab[i__ + j * 13 - 14] = 0.f;
00570 /* L410: */
00571                 }
00572 /* L420: */
00573             }
00574             i__2 = n;
00575             for (j = 1; j <= i__2; ++j) {
00576                 ab[j * 13 - 13] = pow[j * 2];
00577 /* L430: */
00578             }
00579 
00580             spbequ_("L", &n, &kl, ab, &c__13, r__, &rcond, &norm, &info);
00581 
00582             if (info != 0) {
00583                 reslts[4] = 1.f;
00584             } else {
00585                 if (n != 0) {
00586 /* Computing MAX */
00587                     r__2 = reslts[4], r__3 = (r__1 = (rcond - rpow[n - 1]) / 
00588                             rpow[n - 1], dabs(r__1));
00589                     reslts[4] = dmax(r__2,r__3);
00590 /* Computing MAX */
00591                     r__2 = reslts[4], r__3 = (r__1 = (norm - pow[n * 2]) / 
00592                             pow[n * 2], dabs(r__1));
00593                     reslts[4] = dmax(r__2,r__3);
00594                     i__2 = n;
00595                     for (i__ = 1; i__ <= i__2; ++i__) {
00596 /* Computing MAX */
00597                         r__2 = reslts[4], r__3 = (r__1 = (r__[i__ - 1] - rpow[
00598                                 i__]) / rpow[i__], dabs(r__1));
00599                         reslts[4] = dmax(r__2,r__3);
00600 /* L440: */
00601                     }
00602                 }
00603             }
00604             if (n != 0) {
00605 /* Computing MAX */
00606                 i__2 = n - 1;
00607                 ab[max(i__2,1) * 13 - 13] = -1.f;
00608                 spbequ_("L", &n, &kl, ab, &c__13, r__, &rcond, &norm, &info);
00609 /* Computing MAX */
00610                 i__2 = n - 1;
00611                 if (info != max(i__2,1)) {
00612                     reslts[4] = 1.f;
00613                 }
00614             }
00615 /* L450: */
00616         }
00617 /* L460: */
00618     }
00619     reslts[4] /= eps;
00620     ok = reslts[0] <= *thresh && reslts[1] <= *thresh && reslts[2] <= *thresh 
00621             && reslts[3] <= *thresh && reslts[4] <= *thresh;
00622     io___25.ciunit = *nout;
00623     s_wsle(&io___25);
00624     e_wsle();
00625     if (ok) {
00626         io___26.ciunit = *nout;
00627         s_wsfe(&io___26);
00628         do_fio(&c__1, path, (ftnlen)3);
00629         e_wsfe();
00630     } else {
00631         if (reslts[0] > *thresh) {
00632             io___27.ciunit = *nout;
00633             s_wsfe(&io___27);
00634             do_fio(&c__1, (char *)&reslts[0], (ftnlen)sizeof(real));
00635             do_fio(&c__1, (char *)&(*thresh), (ftnlen)sizeof(real));
00636             e_wsfe();
00637         }
00638         if (reslts[1] > *thresh) {
00639             io___28.ciunit = *nout;
00640             s_wsfe(&io___28);
00641             do_fio(&c__1, (char *)&reslts[1], (ftnlen)sizeof(real));
00642             do_fio(&c__1, (char *)&(*thresh), (ftnlen)sizeof(real));
00643             e_wsfe();
00644         }
00645         if (reslts[2] > *thresh) {
00646             io___29.ciunit = *nout;
00647             s_wsfe(&io___29);
00648             do_fio(&c__1, (char *)&reslts[2], (ftnlen)sizeof(real));
00649             do_fio(&c__1, (char *)&(*thresh), (ftnlen)sizeof(real));
00650             e_wsfe();
00651         }
00652         if (reslts[3] > *thresh) {
00653             io___30.ciunit = *nout;
00654             s_wsfe(&io___30);
00655             do_fio(&c__1, (char *)&reslts[3], (ftnlen)sizeof(real));
00656             do_fio(&c__1, (char *)&(*thresh), (ftnlen)sizeof(real));
00657             e_wsfe();
00658         }
00659         if (reslts[4] > *thresh) {
00660             io___31.ciunit = *nout;
00661             s_wsfe(&io___31);
00662             do_fio(&c__1, (char *)&reslts[4], (ftnlen)sizeof(real));
00663             do_fio(&c__1, (char *)&(*thresh), (ftnlen)sizeof(real));
00664             e_wsfe();
00665         }
00666     }
00667     return 0;
00668 
00669 /*     End of SCHKEQ */
00670 
00671 } /* schkeq_ */


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