00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013 #include "f2c.h"
00014 #include "blaswrap.h"
00015
00016
00017
00018 struct {
00019 char srnamt[32];
00020 } srnamc_;
00021
00022 #define srnamc_1 srnamc_
00023
00024
00025
00026 static integer c__2 = 2;
00027 static real c_b20 = 0.f;
00028 static integer c__0 = 0;
00029 static integer c__6 = 6;
00030 static real c_b34 = 1.f;
00031 static integer c__1 = 1;
00032 static integer c__4 = 4;
00033 static integer c__3 = 3;
00034
00035 int sdrvst_(integer *nsizes, integer *nn, integer *ntypes,
00036 logical *dotype, integer *iseed, real *thresh, integer *nounit, real *
00037 a, integer *lda, real *d1, real *d2, real *d3, real *d4, real *eveigs,
00038 real *wa1, real *wa2, real *wa3, real *u, integer *ldu, real *v,
00039 real *tau, real *z__, real *work, integer *lwork, integer *iwork,
00040 integer *liwork, real *result, integer *info)
00041 {
00042
00043
00044 static integer ktype[18] = { 1,2,4,4,4,4,4,5,5,5,5,5,8,8,8,9,9,9 };
00045 static integer kmagn[18] = { 1,1,1,1,1,2,3,1,1,1,2,3,1,2,3,1,2,3 };
00046 static integer kmode[18] = { 0,0,4,3,1,4,4,4,3,1,4,4,0,0,0,4,4,4 };
00047
00048
00049 static char fmt_9999[] = "(\002 SDRVST: \002,a,\002 returned INFO=\002,i"
00050 "6,\002.\002,/9x,\002N=\002,i6,\002, JTYPE=\002,i6,\002, ISEED="
00051 "(\002,3(i5,\002,\002),i5,\002)\002)";
00052
00053
00054 address a__1[3];
00055 integer a_dim1, a_offset, u_dim1, u_offset, v_dim1, v_offset, z_dim1,
00056 z_offset, i__1, i__2, i__3, i__4, i__5, i__6[3], i__7;
00057 real r__1, r__2, r__3, r__4;
00058 char ch__1[10], ch__2[13], ch__3[11];
00059
00060
00061 double sqrt(doublereal), log(doublereal);
00062 integer pow_ii(integer *, integer *), s_wsfe(cilist *), do_fio(integer *,
00063 char *, ftnlen), e_wsfe(void);
00064 int s_copy(char *, char *, ftnlen, ftnlen), s_cat(char *,
00065 char **, integer *, integer *, ftnlen);
00066
00067
00068 integer i__, j, m, n, j1, j2, m2, m3, kd, il, iu;
00069 real vl, vu;
00070 integer lgn;
00071 real ulp, cond;
00072 integer jcol, ihbw, indx, nmax;
00073 real unfl, ovfl;
00074 char uplo[1];
00075 integer irow;
00076 real temp1, temp2, temp3;
00077 integer idiag;
00078 logical badnn;
00079 extern doublereal ssxt1_(integer *, real *, integer *, real *, integer *,
00080 real *, real *, real *);
00081 integer imode, lwedc, iinfo;
00082 real aninv, anorm;
00083 integer itemp, nmats;
00084 extern int ssbev_(char *, char *, integer *, integer *,
00085 real *, integer *, real *, real *, integer *, real *, integer *);
00086 integer jsize, iuplo, nerrs, itype, jtype, ntest;
00087 extern int sspev_(char *, char *, integer *, real *,
00088 real *, real *, integer *, real *, integer *),
00089 sstt21_(integer *, integer *, real *, real *, real *, real *,
00090 real *, integer *, real *, real *), sstt22_(integer *, integer *,
00091 integer *, real *, real *, real *, real *, real *, integer *,
00092 real *, integer *, real *), sstev_(char *, integer *, real *,
00093 real *, real *, integer *, real *, integer *), ssyt21_(
00094 integer *, char *, integer *, integer *, real *, integer *, real *
00095 , real *, real *, integer *, real *, integer *, real *, real *,
00096 real *), ssyt22_(integer *, char *, integer *, integer *,
00097 integer *, real *, integer *, real *, real *, real *, integer *,
00098 real *, integer *, real *, real *, real *), ssyev_(char *,
00099 char *, integer *, real *, integer *, real *, real *, integer *,
00100 integer *);
00101 integer iseed2[4], iseed3[4];
00102 extern int slabad_(real *, real *);
00103 integer liwedc;
00104 extern doublereal slamch_(char *);
00105 integer idumma[1];
00106 extern int xerbla_(char *, integer *);
00107 integer ioldsd[4];
00108 extern doublereal slarnd_(integer *, integer *);
00109 real abstol;
00110 extern int alasvm_(char *, integer *, integer *, integer
00111 *, integer *), ssbevd_(char *, char *, integer *, integer
00112 *, real *, integer *, real *, real *, integer *, real *, integer *
00113 , integer *, integer *, integer *), slacpy_(char *
00114 , integer *, integer *, real *, integer *, real *, integer *), slafts_(char *, integer *, integer *, integer *, integer
00115 *, real *, integer *, real *, integer *, integer *),
00116 slaset_(char *, integer *, integer *, real *, real *, real *,
00117 integer *), slatmr_(integer *, integer *, char *, integer
00118 *, char *, real *, integer *, real *, real *, char *, char *,
00119 real *, integer *, real *, real *, integer *, real *, char *,
00120 integer *, integer *, integer *, real *, real *, char *, real *,
00121 integer *, integer *, integer *), slatms_(integer *, integer *, char *, integer *,
00122 char *, real *, integer *, real *, real *, integer *, integer *,
00123 char *, real *, integer *, real *, integer *), sspevd_(char *, char *, integer *, real *, real *, real *
00124 , integer *, real *, integer *, integer *, integer *, integer *), sstevd_(char *, integer *, real *, real *, real *
00125 , integer *, real *, integer *, integer *, integer *, integer *);
00126 real rtunfl, rtovfl, ulpinv;
00127 extern int ssbevx_(char *, char *, char *, integer *,
00128 integer *, real *, integer *, real *, integer *, real *, real *,
00129 integer *, integer *, real *, integer *, real *, real *, integer *
00130 , real *, integer *, integer *, integer *)
00131 ;
00132 integer mtypes, ntestt;
00133 extern int sstevr_(char *, char *, integer *, real *,
00134 real *, real *, real *, integer *, integer *, real *, integer *,
00135 real *, real *, integer *, integer *, real *, integer *, integer *
00136 , integer *, integer *), ssyevd_(char *, char *,
00137 integer *, real *, integer *, real *, real *, integer *, integer *
00138 , integer *, integer *), sspevx_(char *, char *,
00139 char *, integer *, real *, real *, real *, integer *, integer *,
00140 real *, integer *, real *, real *, integer *, real *, integer *,
00141 integer *, integer *), ssyevr_(char *,
00142 char *, char *, integer *, real *, integer *, real *, real *,
00143 integer *, integer *, real *, integer *, real *, real *, integer *
00144 , integer *, real *, integer *, integer *, integer *, integer *), sstevx_(char *, char *, integer *, real *
00145 , real *, real *, real *, integer *, integer *, real *, integer *,
00146 real *, real *, integer *, real *, integer *, integer *, integer
00147 *), ssyevx_(char *, char *, char *, integer *,
00148 real *, integer *, real *, real *, integer *, integer *, real *,
00149 integer *, real *, real *, integer *, real *, integer *, integer *
00150 , integer *, integer *);
00151
00152
00153 static cilist io___43 = { 0, 0, 0, fmt_9999, 0 };
00154 static cilist io___48 = { 0, 0, 0, fmt_9999, 0 };
00155 static cilist io___49 = { 0, 0, 0, fmt_9999, 0 };
00156 static cilist io___53 = { 0, 0, 0, fmt_9999, 0 };
00157 static cilist io___56 = { 0, 0, 0, fmt_9999, 0 };
00158 static cilist io___57 = { 0, 0, 0, fmt_9999, 0 };
00159 static cilist io___58 = { 0, 0, 0, fmt_9999, 0 };
00160 static cilist io___59 = { 0, 0, 0, fmt_9999, 0 };
00161 static cilist io___61 = { 0, 0, 0, fmt_9999, 0 };
00162 static cilist io___62 = { 0, 0, 0, fmt_9999, 0 };
00163 static cilist io___63 = { 0, 0, 0, fmt_9999, 0 };
00164 static cilist io___64 = { 0, 0, 0, fmt_9999, 0 };
00165 static cilist io___65 = { 0, 0, 0, fmt_9999, 0 };
00166 static cilist io___66 = { 0, 0, 0, fmt_9999, 0 };
00167 static cilist io___67 = { 0, 0, 0, fmt_9999, 0 };
00168 static cilist io___68 = { 0, 0, 0, fmt_9999, 0 };
00169 static cilist io___69 = { 0, 0, 0, fmt_9999, 0 };
00170 static cilist io___72 = { 0, 0, 0, fmt_9999, 0 };
00171 static cilist io___73 = { 0, 0, 0, fmt_9999, 0 };
00172 static cilist io___74 = { 0, 0, 0, fmt_9999, 0 };
00173 static cilist io___75 = { 0, 0, 0, fmt_9999, 0 };
00174 static cilist io___76 = { 0, 0, 0, fmt_9999, 0 };
00175 static cilist io___77 = { 0, 0, 0, fmt_9999, 0 };
00176 static cilist io___78 = { 0, 0, 0, fmt_9999, 0 };
00177 static cilist io___79 = { 0, 0, 0, fmt_9999, 0 };
00178 static cilist io___81 = { 0, 0, 0, fmt_9999, 0 };
00179 static cilist io___82 = { 0, 0, 0, fmt_9999, 0 };
00180 static cilist io___83 = { 0, 0, 0, fmt_9999, 0 };
00181 static cilist io___84 = { 0, 0, 0, fmt_9999, 0 };
00182 static cilist io___85 = { 0, 0, 0, fmt_9999, 0 };
00183 static cilist io___86 = { 0, 0, 0, fmt_9999, 0 };
00184 static cilist io___87 = { 0, 0, 0, fmt_9999, 0 };
00185 static cilist io___88 = { 0, 0, 0, fmt_9999, 0 };
00186 static cilist io___90 = { 0, 0, 0, fmt_9999, 0 };
00187 static cilist io___91 = { 0, 0, 0, fmt_9999, 0 };
00188 static cilist io___92 = { 0, 0, 0, fmt_9999, 0 };
00189 static cilist io___93 = { 0, 0, 0, fmt_9999, 0 };
00190 static cilist io___94 = { 0, 0, 0, fmt_9999, 0 };
00191 static cilist io___95 = { 0, 0, 0, fmt_9999, 0 };
00192 static cilist io___96 = { 0, 0, 0, fmt_9999, 0 };
00193 static cilist io___97 = { 0, 0, 0, fmt_9999, 0 };
00194 static cilist io___98 = { 0, 0, 0, fmt_9999, 0 };
00195 static cilist io___99 = { 0, 0, 0, fmt_9999, 0 };
00196 static cilist io___100 = { 0, 0, 0, fmt_9999, 0 };
00197 static cilist io___101 = { 0, 0, 0, fmt_9999, 0 };
00198 static cilist io___102 = { 0, 0, 0, fmt_9999, 0 };
00199 static cilist io___103 = { 0, 0, 0, fmt_9999, 0 };
00200 static cilist io___104 = { 0, 0, 0, fmt_9999, 0 };
00201 static cilist io___105 = { 0, 0, 0, fmt_9999, 0 };
00202 static cilist io___106 = { 0, 0, 0, fmt_9999, 0 };
00203 static cilist io___107 = { 0, 0, 0, fmt_9999, 0 };
00204 static cilist io___108 = { 0, 0, 0, fmt_9999, 0 };
00205 static cilist io___109 = { 0, 0, 0, fmt_9999, 0 };
00206
00207
00208
00209
00210
00211
00212
00213
00214
00215
00216
00217
00218
00219
00220
00221
00222
00223
00224
00225
00226
00227
00228
00229
00230
00231
00232
00233
00234
00235
00236
00237
00238
00239
00240
00241
00242
00243
00244
00245
00246
00247
00248
00249
00250
00251
00252
00253
00254
00255
00256
00257
00258
00259
00260
00261
00262
00263
00264
00265
00266
00267
00268
00269
00270
00271
00272
00273
00274
00275
00276
00277
00278
00279
00280
00281
00282
00283
00284
00285
00286
00287
00288
00289
00290
00291
00292
00293
00294
00295
00296
00297
00298
00299
00300
00301
00302
00303
00304
00305
00306
00307
00308
00309
00310
00311
00312
00313
00314
00315
00316
00317
00318
00319
00320
00321
00322
00323
00324
00325
00326
00327
00328
00329
00330
00331
00332
00333
00334
00335
00336
00337
00338
00339
00340
00341
00342
00343
00344
00345
00346
00347
00348
00349
00350
00351
00352
00353
00354
00355
00356
00357
00358
00359
00360
00361
00362
00363
00364
00365
00366
00367
00368
00369
00370
00371
00372
00373
00374
00375
00376
00377
00378
00379
00380
00381
00382
00383
00384
00385
00386
00387
00388
00389
00390
00391
00392
00393
00394
00395
00396
00397
00398
00399
00400
00401
00402
00403
00404
00405
00406
00407
00408
00409
00410
00411
00412
00413
00414
00415
00416
00417
00418
00419
00420
00421
00422
00423
00424
00425
00426
00427
00428
00429
00430
00431
00432
00433
00434
00435
00436
00437
00438
00439
00440
00441
00442
00443
00444
00445
00446
00447
00448
00449
00450
00451
00452
00453
00454
00455
00456
00457
00458
00459
00460
00461
00462
00463
00464
00465
00466
00467
00468
00469
00470
00471
00472
00473
00474
00475
00476
00477
00478
00479
00480
00481
00482
00483
00484
00485
00486
00487
00488
00489
00490
00491
00492
00493
00494
00495
00496
00497
00498
00499
00500
00501
00502
00503
00504
00505
00506
00507
00508
00509
00510
00511
00512
00513
00514
00515
00516
00517
00518
00519
00520
00521
00522
00523
00524
00525
00526
00527
00528
00529
00530
00531
00532
00533
00534
00535
00536
00537
00538
00539
00540
00541
00542
00543
00544
00545
00546
00547
00548
00549
00550
00551
00552
00553
00554
00555
00556
00557
00558
00559
00560
00561
00562
00563
00564
00565
00566
00567
00568
00569
00570
00571
00572
00573
00574
00575
00576
00577
00578
00579
00580
00581
00582
00583
00584
00585
00586
00587
00588
00589
00590
00591
00592
00593
00594
00595
00596
00597
00598
00599
00600
00601
00602
00603
00604
00605
00606
00607
00608
00609
00610
00611
00612
00613
00614
00615
00616
00617
00618
00619
00620
00621
00622
00623
00624
00625
00626
00627
00628
00629
00630
00631
00632
00633
00634
00635
00636
00637
00638
00639
00640
00641 --nn;
00642 --dotype;
00643 --iseed;
00644 a_dim1 = *lda;
00645 a_offset = 1 + a_dim1;
00646 a -= a_offset;
00647 --d1;
00648 --d2;
00649 --d3;
00650 --d4;
00651 --eveigs;
00652 --wa1;
00653 --wa2;
00654 --wa3;
00655 z_dim1 = *ldu;
00656 z_offset = 1 + z_dim1;
00657 z__ -= z_offset;
00658 v_dim1 = *ldu;
00659 v_offset = 1 + v_dim1;
00660 v -= v_offset;
00661 u_dim1 = *ldu;
00662 u_offset = 1 + u_dim1;
00663 u -= u_offset;
00664 --tau;
00665 --work;
00666 --iwork;
00667 --result;
00668
00669
00670
00671
00672
00673
00674
00675 vl = 0.f;
00676 vu = 0.f;
00677
00678
00679
00680 ntestt = 0;
00681 *info = 0;
00682
00683 badnn = FALSE_;
00684 nmax = 1;
00685 i__1 = *nsizes;
00686 for (j = 1; j <= i__1; ++j) {
00687
00688 i__2 = nmax, i__3 = nn[j];
00689 nmax = max(i__2,i__3);
00690 if (nn[j] < 0) {
00691 badnn = TRUE_;
00692 }
00693
00694 }
00695
00696
00697
00698 if (*nsizes < 0) {
00699 *info = -1;
00700 } else if (badnn) {
00701 *info = -2;
00702 } else if (*ntypes < 0) {
00703 *info = -3;
00704 } else if (*lda < nmax) {
00705 *info = -9;
00706 } else if (*ldu < nmax) {
00707 *info = -16;
00708 } else {
00709
00710 i__1 = max(2,nmax);
00711 if (i__1 * i__1 << 1 > *lwork) {
00712 *info = -21;
00713 }
00714 }
00715
00716 if (*info != 0) {
00717 i__1 = -(*info);
00718 xerbla_("SDRVST", &i__1);
00719 return 0;
00720 }
00721
00722
00723
00724 if (*nsizes == 0 || *ntypes == 0) {
00725 return 0;
00726 }
00727
00728
00729
00730 unfl = slamch_("Safe minimum");
00731 ovfl = slamch_("Overflow");
00732 slabad_(&unfl, &ovfl);
00733 ulp = slamch_("Epsilon") * slamch_("Base");
00734 ulpinv = 1.f / ulp;
00735 rtunfl = sqrt(unfl);
00736 rtovfl = sqrt(ovfl);
00737
00738
00739
00740 for (i__ = 1; i__ <= 4; ++i__) {
00741 iseed2[i__ - 1] = iseed[i__];
00742 iseed3[i__ - 1] = iseed[i__];
00743
00744 }
00745
00746 nerrs = 0;
00747 nmats = 0;
00748
00749
00750 i__1 = *nsizes;
00751 for (jsize = 1; jsize <= i__1; ++jsize) {
00752 n = nn[jsize];
00753 if (n > 0) {
00754 lgn = (integer) (log((real) n) / log(2.f));
00755 if (pow_ii(&c__2, &lgn) < n) {
00756 ++lgn;
00757 }
00758 if (pow_ii(&c__2, &lgn) < n) {
00759 ++lgn;
00760 }
00761
00762 i__2 = n;
00763 lwedc = (n << 2) + 1 + (n << 1) * lgn + (i__2 * i__2 << 2);
00764
00765 liwedc = n * 5 + 3;
00766 } else {
00767 lwedc = 9;
00768
00769 liwedc = 8;
00770 }
00771 aninv = 1.f / (real) max(1,n);
00772
00773 if (*nsizes != 1) {
00774 mtypes = min(18,*ntypes);
00775 } else {
00776 mtypes = min(19,*ntypes);
00777 }
00778
00779 i__2 = mtypes;
00780 for (jtype = 1; jtype <= i__2; ++jtype) {
00781
00782 if (! dotype[jtype]) {
00783 goto L1730;
00784 }
00785 ++nmats;
00786 ntest = 0;
00787
00788 for (j = 1; j <= 4; ++j) {
00789 ioldsd[j - 1] = iseed[j];
00790
00791 }
00792
00793
00794
00795
00796
00797
00798
00799
00800
00801
00802
00803
00804
00805
00806
00807
00808 if (mtypes > 18) {
00809 goto L110;
00810 }
00811
00812 itype = ktype[jtype - 1];
00813 imode = kmode[jtype - 1];
00814
00815
00816
00817 switch (kmagn[jtype - 1]) {
00818 case 1: goto L40;
00819 case 2: goto L50;
00820 case 3: goto L60;
00821 }
00822
00823 L40:
00824 anorm = 1.f;
00825 goto L70;
00826
00827 L50:
00828 anorm = rtovfl * ulp * aninv;
00829 goto L70;
00830
00831 L60:
00832 anorm = rtunfl * n * ulpinv;
00833 goto L70;
00834
00835 L70:
00836
00837 slaset_("Full", lda, &n, &c_b20, &c_b20, &a[a_offset], lda);
00838 iinfo = 0;
00839 cond = ulpinv;
00840
00841
00842
00843
00844
00845 if (itype == 1) {
00846 iinfo = 0;
00847
00848 } else if (itype == 2) {
00849
00850
00851
00852 i__3 = n;
00853 for (jcol = 1; jcol <= i__3; ++jcol) {
00854 a[jcol + jcol * a_dim1] = anorm;
00855
00856 }
00857
00858 } else if (itype == 4) {
00859
00860
00861
00862 slatms_(&n, &n, "S", &iseed[1], "S", &work[1], &imode, &cond,
00863 &anorm, &c__0, &c__0, "N", &a[a_offset], lda, &work[n
00864 + 1], &iinfo);
00865
00866 } else if (itype == 5) {
00867
00868
00869
00870 slatms_(&n, &n, "S", &iseed[1], "S", &work[1], &imode, &cond,
00871 &anorm, &n, &n, "N", &a[a_offset], lda, &work[n + 1],
00872 &iinfo);
00873
00874 } else if (itype == 7) {
00875
00876
00877
00878 idumma[0] = 1;
00879 slatmr_(&n, &n, "S", &iseed[1], "S", &work[1], &c__6, &c_b34,
00880 &c_b34, "T", "N", &work[n + 1], &c__1, &c_b34, &work[(
00881 n << 1) + 1], &c__1, &c_b34, "N", idumma, &c__0, &
00882 c__0, &c_b20, &anorm, "NO", &a[a_offset], lda, &iwork[
00883 1], &iinfo);
00884
00885 } else if (itype == 8) {
00886
00887
00888
00889 idumma[0] = 1;
00890 slatmr_(&n, &n, "S", &iseed[1], "S", &work[1], &c__6, &c_b34,
00891 &c_b34, "T", "N", &work[n + 1], &c__1, &c_b34, &work[(
00892 n << 1) + 1], &c__1, &c_b34, "N", idumma, &n, &n, &
00893 c_b20, &anorm, "NO", &a[a_offset], lda, &iwork[1], &
00894 iinfo);
00895
00896 } else if (itype == 9) {
00897
00898
00899
00900 ihbw = (integer) ((n - 1) * slarnd_(&c__1, iseed3));
00901 slatms_(&n, &n, "S", &iseed[1], "S", &work[1], &imode, &cond,
00902 &anorm, &ihbw, &ihbw, "Z", &u[u_offset], ldu, &work[n
00903 + 1], &iinfo);
00904
00905
00906
00907 slaset_("Full", lda, &n, &c_b20, &c_b20, &a[a_offset], lda);
00908 i__3 = ihbw;
00909 for (idiag = -ihbw; idiag <= i__3; ++idiag) {
00910 irow = ihbw - idiag + 1;
00911
00912 i__4 = 1, i__5 = idiag + 1;
00913 j1 = max(i__4,i__5);
00914
00915 i__4 = n, i__5 = n + idiag;
00916 j2 = min(i__4,i__5);
00917 i__4 = j2;
00918 for (j = j1; j <= i__4; ++j) {
00919 i__ = j - idiag;
00920 a[i__ + j * a_dim1] = u[irow + j * u_dim1];
00921
00922 }
00923
00924 }
00925 } else {
00926 iinfo = 1;
00927 }
00928
00929 if (iinfo != 0) {
00930 io___43.ciunit = *nounit;
00931 s_wsfe(&io___43);
00932 do_fio(&c__1, "Generator", (ftnlen)9);
00933 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
00934 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
00935 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
00936 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer));
00937 e_wsfe();
00938 *info = abs(iinfo);
00939 return 0;
00940 }
00941
00942 L110:
00943
00944 abstol = unfl + unfl;
00945 if (n <= 1) {
00946 il = 1;
00947 iu = n;
00948 } else {
00949 il = (integer) ((n - 1) * slarnd_(&c__1, iseed2)) + 1;
00950 iu = (integer) ((n - 1) * slarnd_(&c__1, iseed2)) + 1;
00951 if (il > iu) {
00952 itemp = il;
00953 il = iu;
00954 iu = itemp;
00955 }
00956 }
00957
00958
00959
00960 if (jtype <= 7) {
00961 ntest = 1;
00962 i__3 = n;
00963 for (i__ = 1; i__ <= i__3; ++i__) {
00964 d1[i__] = a[i__ + i__ * a_dim1];
00965
00966 }
00967 i__3 = n - 1;
00968 for (i__ = 1; i__ <= i__3; ++i__) {
00969 d2[i__] = a[i__ + 1 + i__ * a_dim1];
00970
00971 }
00972 s_copy(srnamc_1.srnamt, "SSTEV", (ftnlen)32, (ftnlen)5);
00973 sstev_("V", &n, &d1[1], &d2[1], &z__[z_offset], ldu, &work[1],
00974 &iinfo);
00975 if (iinfo != 0) {
00976 io___48.ciunit = *nounit;
00977 s_wsfe(&io___48);
00978 do_fio(&c__1, "SSTEV(V)", (ftnlen)8);
00979 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
00980 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
00981 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
00982 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
00983 ;
00984 e_wsfe();
00985 *info = abs(iinfo);
00986 if (iinfo < 0) {
00987 return 0;
00988 } else {
00989 result[1] = ulpinv;
00990 result[2] = ulpinv;
00991 result[3] = ulpinv;
00992 goto L180;
00993 }
00994 }
00995
00996
00997
00998 i__3 = n;
00999 for (i__ = 1; i__ <= i__3; ++i__) {
01000 d3[i__] = a[i__ + i__ * a_dim1];
01001
01002 }
01003 i__3 = n - 1;
01004 for (i__ = 1; i__ <= i__3; ++i__) {
01005 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01006
01007 }
01008 sstt21_(&n, &c__0, &d3[1], &d4[1], &d1[1], &d2[1], &z__[
01009 z_offset], ldu, &work[1], &result[1]);
01010
01011 ntest = 3;
01012 i__3 = n - 1;
01013 for (i__ = 1; i__ <= i__3; ++i__) {
01014 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01015
01016 }
01017 s_copy(srnamc_1.srnamt, "SSTEV", (ftnlen)32, (ftnlen)5);
01018 sstev_("N", &n, &d3[1], &d4[1], &z__[z_offset], ldu, &work[1],
01019 &iinfo);
01020 if (iinfo != 0) {
01021 io___49.ciunit = *nounit;
01022 s_wsfe(&io___49);
01023 do_fio(&c__1, "SSTEV(N)", (ftnlen)8);
01024 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01025 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01026 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01027 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01028 ;
01029 e_wsfe();
01030 *info = abs(iinfo);
01031 if (iinfo < 0) {
01032 return 0;
01033 } else {
01034 result[3] = ulpinv;
01035 goto L180;
01036 }
01037 }
01038
01039
01040
01041 temp1 = 0.f;
01042 temp2 = 0.f;
01043 i__3 = n;
01044 for (j = 1; j <= i__3; ++j) {
01045
01046 r__3 = temp1, r__4 = (r__1 = d1[j], dabs(r__1)), r__3 =
01047 max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2));
01048 temp1 = dmax(r__3,r__4);
01049
01050 r__2 = temp2, r__3 = (r__1 = d1[j] - d3[j], dabs(r__1));
01051 temp2 = dmax(r__2,r__3);
01052
01053 }
01054
01055 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
01056 result[3] = temp2 / dmax(r__1,r__2);
01057
01058 L180:
01059
01060 ntest = 4;
01061 i__3 = n;
01062 for (i__ = 1; i__ <= i__3; ++i__) {
01063 eveigs[i__] = d3[i__];
01064 d1[i__] = a[i__ + i__ * a_dim1];
01065
01066 }
01067 i__3 = n - 1;
01068 for (i__ = 1; i__ <= i__3; ++i__) {
01069 d2[i__] = a[i__ + 1 + i__ * a_dim1];
01070
01071 }
01072 s_copy(srnamc_1.srnamt, "SSTEVX", (ftnlen)32, (ftnlen)6);
01073 sstevx_("V", "A", &n, &d1[1], &d2[1], &vl, &vu, &il, &iu, &
01074 abstol, &m, &wa1[1], &z__[z_offset], ldu, &work[1], &
01075 iwork[1], &iwork[n * 5 + 1], &iinfo);
01076 if (iinfo != 0) {
01077 io___53.ciunit = *nounit;
01078 s_wsfe(&io___53);
01079 do_fio(&c__1, "SSTEVX(V,A)", (ftnlen)11);
01080 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01081 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01082 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01083 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01084 ;
01085 e_wsfe();
01086 *info = abs(iinfo);
01087 if (iinfo < 0) {
01088 return 0;
01089 } else {
01090 result[4] = ulpinv;
01091 result[5] = ulpinv;
01092 result[6] = ulpinv;
01093 goto L250;
01094 }
01095 }
01096 if (n > 0) {
01097
01098 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
01099 temp3 = dmax(r__2,r__3);
01100 } else {
01101 temp3 = 0.f;
01102 }
01103
01104
01105
01106 i__3 = n;
01107 for (i__ = 1; i__ <= i__3; ++i__) {
01108 d3[i__] = a[i__ + i__ * a_dim1];
01109
01110 }
01111 i__3 = n - 1;
01112 for (i__ = 1; i__ <= i__3; ++i__) {
01113 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01114
01115 }
01116 sstt21_(&n, &c__0, &d3[1], &d4[1], &wa1[1], &d2[1], &z__[
01117 z_offset], ldu, &work[1], &result[4]);
01118
01119 ntest = 6;
01120 i__3 = n - 1;
01121 for (i__ = 1; i__ <= i__3; ++i__) {
01122 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01123
01124 }
01125 s_copy(srnamc_1.srnamt, "SSTEVX", (ftnlen)32, (ftnlen)6);
01126 sstevx_("N", "A", &n, &d3[1], &d4[1], &vl, &vu, &il, &iu, &
01127 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &work[1], &
01128 iwork[1], &iwork[n * 5 + 1], &iinfo);
01129 if (iinfo != 0) {
01130 io___56.ciunit = *nounit;
01131 s_wsfe(&io___56);
01132 do_fio(&c__1, "SSTEVX(N,A)", (ftnlen)11);
01133 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01134 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01135 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01136 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01137 ;
01138 e_wsfe();
01139 *info = abs(iinfo);
01140 if (iinfo < 0) {
01141 return 0;
01142 } else {
01143 result[6] = ulpinv;
01144 goto L250;
01145 }
01146 }
01147
01148
01149
01150 temp1 = 0.f;
01151 temp2 = 0.f;
01152 i__3 = n;
01153 for (j = 1; j <= i__3; ++j) {
01154
01155 r__3 = temp1, r__4 = (r__1 = wa2[j], dabs(r__1)), r__3 =
01156 max(r__3,r__4), r__4 = (r__2 = eveigs[j], dabs(
01157 r__2));
01158 temp1 = dmax(r__3,r__4);
01159
01160 r__2 = temp2, r__3 = (r__1 = wa2[j] - eveigs[j], dabs(
01161 r__1));
01162 temp2 = dmax(r__2,r__3);
01163
01164 }
01165
01166 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
01167 result[6] = temp2 / dmax(r__1,r__2);
01168
01169 L250:
01170
01171 ntest = 7;
01172 i__3 = n;
01173 for (i__ = 1; i__ <= i__3; ++i__) {
01174 d1[i__] = a[i__ + i__ * a_dim1];
01175
01176 }
01177 i__3 = n - 1;
01178 for (i__ = 1; i__ <= i__3; ++i__) {
01179 d2[i__] = a[i__ + 1 + i__ * a_dim1];
01180
01181 }
01182 s_copy(srnamc_1.srnamt, "SSTEVR", (ftnlen)32, (ftnlen)6);
01183 i__3 = *liwork - (n << 1);
01184 sstevr_("V", "A", &n, &d1[1], &d2[1], &vl, &vu, &il, &iu, &
01185 abstol, &m, &wa1[1], &z__[z_offset], ldu, &iwork[1], &
01186 work[1], lwork, &iwork[(n << 1) + 1], &i__3, &iinfo);
01187 if (iinfo != 0) {
01188 io___57.ciunit = *nounit;
01189 s_wsfe(&io___57);
01190 do_fio(&c__1, "SSTEVR(V,A)", (ftnlen)11);
01191 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01192 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01193 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01194 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01195 ;
01196 e_wsfe();
01197 *info = abs(iinfo);
01198 if (iinfo < 0) {
01199 return 0;
01200 } else {
01201 result[7] = ulpinv;
01202 result[8] = ulpinv;
01203 goto L320;
01204 }
01205 }
01206 if (n > 0) {
01207
01208 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
01209 temp3 = dmax(r__2,r__3);
01210 } else {
01211 temp3 = 0.f;
01212 }
01213
01214
01215
01216 i__3 = n;
01217 for (i__ = 1; i__ <= i__3; ++i__) {
01218 d3[i__] = a[i__ + i__ * a_dim1];
01219
01220 }
01221 i__3 = n - 1;
01222 for (i__ = 1; i__ <= i__3; ++i__) {
01223 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01224
01225 }
01226 sstt21_(&n, &c__0, &d3[1], &d4[1], &wa1[1], &d2[1], &z__[
01227 z_offset], ldu, &work[1], &result[7]);
01228
01229 ntest = 9;
01230 i__3 = n - 1;
01231 for (i__ = 1; i__ <= i__3; ++i__) {
01232 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01233
01234 }
01235 s_copy(srnamc_1.srnamt, "SSTEVR", (ftnlen)32, (ftnlen)6);
01236 i__3 = *liwork - (n << 1);
01237 sstevr_("N", "A", &n, &d3[1], &d4[1], &vl, &vu, &il, &iu, &
01238 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &iwork[1],
01239 &work[1], lwork, &iwork[(n << 1) + 1], &i__3, &iinfo);
01240 if (iinfo != 0) {
01241 io___58.ciunit = *nounit;
01242 s_wsfe(&io___58);
01243 do_fio(&c__1, "SSTEVR(N,A)", (ftnlen)11);
01244 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01245 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01246 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01247 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01248 ;
01249 e_wsfe();
01250 *info = abs(iinfo);
01251 if (iinfo < 0) {
01252 return 0;
01253 } else {
01254 result[9] = ulpinv;
01255 goto L320;
01256 }
01257 }
01258
01259
01260
01261 temp1 = 0.f;
01262 temp2 = 0.f;
01263 i__3 = n;
01264 for (j = 1; j <= i__3; ++j) {
01265
01266 r__3 = temp1, r__4 = (r__1 = wa2[j], dabs(r__1)), r__3 =
01267 max(r__3,r__4), r__4 = (r__2 = eveigs[j], dabs(
01268 r__2));
01269 temp1 = dmax(r__3,r__4);
01270
01271 r__2 = temp2, r__3 = (r__1 = wa2[j] - eveigs[j], dabs(
01272 r__1));
01273 temp2 = dmax(r__2,r__3);
01274
01275 }
01276
01277 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
01278 result[9] = temp2 / dmax(r__1,r__2);
01279
01280 L320:
01281
01282
01283 ntest = 10;
01284 i__3 = n;
01285 for (i__ = 1; i__ <= i__3; ++i__) {
01286 d1[i__] = a[i__ + i__ * a_dim1];
01287
01288 }
01289 i__3 = n - 1;
01290 for (i__ = 1; i__ <= i__3; ++i__) {
01291 d2[i__] = a[i__ + 1 + i__ * a_dim1];
01292
01293 }
01294 s_copy(srnamc_1.srnamt, "SSTEVX", (ftnlen)32, (ftnlen)6);
01295 sstevx_("V", "I", &n, &d1[1], &d2[1], &vl, &vu, &il, &iu, &
01296 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &work[1], &
01297 iwork[1], &iwork[n * 5 + 1], &iinfo);
01298 if (iinfo != 0) {
01299 io___59.ciunit = *nounit;
01300 s_wsfe(&io___59);
01301 do_fio(&c__1, "SSTEVX(V,I)", (ftnlen)11);
01302 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01303 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01304 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01305 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01306 ;
01307 e_wsfe();
01308 *info = abs(iinfo);
01309 if (iinfo < 0) {
01310 return 0;
01311 } else {
01312 result[10] = ulpinv;
01313 result[11] = ulpinv;
01314 result[12] = ulpinv;
01315 goto L380;
01316 }
01317 }
01318
01319
01320
01321 i__3 = n;
01322 for (i__ = 1; i__ <= i__3; ++i__) {
01323 d3[i__] = a[i__ + i__ * a_dim1];
01324
01325 }
01326 i__3 = n - 1;
01327 for (i__ = 1; i__ <= i__3; ++i__) {
01328 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01329
01330 }
01331 i__3 = max(1,m2);
01332 sstt22_(&n, &m2, &c__0, &d3[1], &d4[1], &wa2[1], &d2[1], &z__[
01333 z_offset], ldu, &work[1], &i__3, &result[10]);
01334
01335
01336 ntest = 12;
01337 i__3 = n - 1;
01338 for (i__ = 1; i__ <= i__3; ++i__) {
01339 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01340
01341 }
01342 s_copy(srnamc_1.srnamt, "SSTEVX", (ftnlen)32, (ftnlen)6);
01343 sstevx_("N", "I", &n, &d3[1], &d4[1], &vl, &vu, &il, &iu, &
01344 abstol, &m3, &wa3[1], &z__[z_offset], ldu, &work[1], &
01345 iwork[1], &iwork[n * 5 + 1], &iinfo);
01346 if (iinfo != 0) {
01347 io___61.ciunit = *nounit;
01348 s_wsfe(&io___61);
01349 do_fio(&c__1, "SSTEVX(N,I)", (ftnlen)11);
01350 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01351 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01352 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01353 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01354 ;
01355 e_wsfe();
01356 *info = abs(iinfo);
01357 if (iinfo < 0) {
01358 return 0;
01359 } else {
01360 result[12] = ulpinv;
01361 goto L380;
01362 }
01363 }
01364
01365
01366
01367 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
01368 ulp, &unfl);
01369 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
01370 ulp, &unfl);
01371
01372 r__1 = unfl, r__2 = ulp * temp3;
01373 result[12] = (temp1 + temp2) / dmax(r__1,r__2);
01374
01375 L380:
01376
01377 ntest = 12;
01378 if (n > 0) {
01379 if (il != 1) {
01380
01381 r__1 = (wa1[il] - wa1[il - 1]) * .5f, r__2 = ulp *
01382 10.f * temp3, r__1 = max(r__1,r__2), r__2 =
01383 rtunfl * 10.f;
01384 vl = wa1[il] - dmax(r__1,r__2);
01385 } else {
01386
01387 r__1 = (wa1[n] - wa1[1]) * .5f, r__2 = ulp * 10.f *
01388 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
01389 10.f;
01390 vl = wa1[1] - dmax(r__1,r__2);
01391 }
01392 if (iu != n) {
01393
01394 r__1 = (wa1[iu + 1] - wa1[iu]) * .5f, r__2 = ulp *
01395 10.f * temp3, r__1 = max(r__1,r__2), r__2 =
01396 rtunfl * 10.f;
01397 vu = wa1[iu] + dmax(r__1,r__2);
01398 } else {
01399
01400 r__1 = (wa1[n] - wa1[1]) * .5f, r__2 = ulp * 10.f *
01401 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
01402 10.f;
01403 vu = wa1[n] + dmax(r__1,r__2);
01404 }
01405 } else {
01406 vl = 0.f;
01407 vu = 1.f;
01408 }
01409
01410 i__3 = n;
01411 for (i__ = 1; i__ <= i__3; ++i__) {
01412 d1[i__] = a[i__ + i__ * a_dim1];
01413
01414 }
01415 i__3 = n - 1;
01416 for (i__ = 1; i__ <= i__3; ++i__) {
01417 d2[i__] = a[i__ + 1 + i__ * a_dim1];
01418
01419 }
01420 s_copy(srnamc_1.srnamt, "SSTEVX", (ftnlen)32, (ftnlen)6);
01421 sstevx_("V", "V", &n, &d1[1], &d2[1], &vl, &vu, &il, &iu, &
01422 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &work[1], &
01423 iwork[1], &iwork[n * 5 + 1], &iinfo);
01424 if (iinfo != 0) {
01425 io___62.ciunit = *nounit;
01426 s_wsfe(&io___62);
01427 do_fio(&c__1, "SSTEVX(V,V)", (ftnlen)11);
01428 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01429 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01430 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01431 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01432 ;
01433 e_wsfe();
01434 *info = abs(iinfo);
01435 if (iinfo < 0) {
01436 return 0;
01437 } else {
01438 result[13] = ulpinv;
01439 result[14] = ulpinv;
01440 result[15] = ulpinv;
01441 goto L440;
01442 }
01443 }
01444
01445 if (m2 == 0 && n > 0) {
01446 result[13] = ulpinv;
01447 result[14] = ulpinv;
01448 result[15] = ulpinv;
01449 goto L440;
01450 }
01451
01452
01453
01454 i__3 = n;
01455 for (i__ = 1; i__ <= i__3; ++i__) {
01456 d3[i__] = a[i__ + i__ * a_dim1];
01457
01458 }
01459 i__3 = n - 1;
01460 for (i__ = 1; i__ <= i__3; ++i__) {
01461 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01462
01463 }
01464 i__3 = max(1,m2);
01465 sstt22_(&n, &m2, &c__0, &d3[1], &d4[1], &wa2[1], &d2[1], &z__[
01466 z_offset], ldu, &work[1], &i__3, &result[13]);
01467
01468 ntest = 15;
01469 i__3 = n - 1;
01470 for (i__ = 1; i__ <= i__3; ++i__) {
01471 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01472
01473 }
01474 s_copy(srnamc_1.srnamt, "SSTEVX", (ftnlen)32, (ftnlen)6);
01475 sstevx_("N", "V", &n, &d3[1], &d4[1], &vl, &vu, &il, &iu, &
01476 abstol, &m3, &wa3[1], &z__[z_offset], ldu, &work[1], &
01477 iwork[1], &iwork[n * 5 + 1], &iinfo);
01478 if (iinfo != 0) {
01479 io___63.ciunit = *nounit;
01480 s_wsfe(&io___63);
01481 do_fio(&c__1, "SSTEVX(N,V)", (ftnlen)11);
01482 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01483 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01484 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01485 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01486 ;
01487 e_wsfe();
01488 *info = abs(iinfo);
01489 if (iinfo < 0) {
01490 return 0;
01491 } else {
01492 result[15] = ulpinv;
01493 goto L440;
01494 }
01495 }
01496
01497
01498
01499 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
01500 ulp, &unfl);
01501 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
01502 ulp, &unfl);
01503
01504 r__1 = unfl, r__2 = temp3 * ulp;
01505 result[15] = (temp1 + temp2) / dmax(r__1,r__2);
01506
01507 L440:
01508
01509 ntest = 16;
01510 i__3 = n;
01511 for (i__ = 1; i__ <= i__3; ++i__) {
01512 d1[i__] = a[i__ + i__ * a_dim1];
01513
01514 }
01515 i__3 = n - 1;
01516 for (i__ = 1; i__ <= i__3; ++i__) {
01517 d2[i__] = a[i__ + 1 + i__ * a_dim1];
01518
01519 }
01520 s_copy(srnamc_1.srnamt, "SSTEVD", (ftnlen)32, (ftnlen)6);
01521 sstevd_("V", &n, &d1[1], &d2[1], &z__[z_offset], ldu, &work[1]
01522 , &lwedc, &iwork[1], &liwedc, &iinfo);
01523 if (iinfo != 0) {
01524 io___64.ciunit = *nounit;
01525 s_wsfe(&io___64);
01526 do_fio(&c__1, "SSTEVD(V)", (ftnlen)9);
01527 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01528 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01529 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01530 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01531 ;
01532 e_wsfe();
01533 *info = abs(iinfo);
01534 if (iinfo < 0) {
01535 return 0;
01536 } else {
01537 result[16] = ulpinv;
01538 result[17] = ulpinv;
01539 result[18] = ulpinv;
01540 goto L510;
01541 }
01542 }
01543
01544
01545
01546 i__3 = n;
01547 for (i__ = 1; i__ <= i__3; ++i__) {
01548 d3[i__] = a[i__ + i__ * a_dim1];
01549
01550 }
01551 i__3 = n - 1;
01552 for (i__ = 1; i__ <= i__3; ++i__) {
01553 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01554
01555 }
01556 sstt21_(&n, &c__0, &d3[1], &d4[1], &d1[1], &d2[1], &z__[
01557 z_offset], ldu, &work[1], &result[16]);
01558
01559 ntest = 18;
01560 i__3 = n - 1;
01561 for (i__ = 1; i__ <= i__3; ++i__) {
01562 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01563
01564 }
01565 s_copy(srnamc_1.srnamt, "SSTEVD", (ftnlen)32, (ftnlen)6);
01566 sstevd_("N", &n, &d3[1], &d4[1], &z__[z_offset], ldu, &work[1]
01567 , &lwedc, &iwork[1], &liwedc, &iinfo);
01568 if (iinfo != 0) {
01569 io___65.ciunit = *nounit;
01570 s_wsfe(&io___65);
01571 do_fio(&c__1, "SSTEVD(N)", (ftnlen)9);
01572 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01573 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01574 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01575 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01576 ;
01577 e_wsfe();
01578 *info = abs(iinfo);
01579 if (iinfo < 0) {
01580 return 0;
01581 } else {
01582 result[18] = ulpinv;
01583 goto L510;
01584 }
01585 }
01586
01587
01588
01589 temp1 = 0.f;
01590 temp2 = 0.f;
01591 i__3 = n;
01592 for (j = 1; j <= i__3; ++j) {
01593
01594 r__3 = temp1, r__4 = (r__1 = eveigs[j], dabs(r__1)), r__3
01595 = max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2)
01596 );
01597 temp1 = dmax(r__3,r__4);
01598
01599 r__2 = temp2, r__3 = (r__1 = eveigs[j] - d3[j], dabs(r__1)
01600 );
01601 temp2 = dmax(r__2,r__3);
01602
01603 }
01604
01605 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
01606 result[18] = temp2 / dmax(r__1,r__2);
01607
01608 L510:
01609
01610 ntest = 19;
01611 i__3 = n;
01612 for (i__ = 1; i__ <= i__3; ++i__) {
01613 d1[i__] = a[i__ + i__ * a_dim1];
01614
01615 }
01616 i__3 = n - 1;
01617 for (i__ = 1; i__ <= i__3; ++i__) {
01618 d2[i__] = a[i__ + 1 + i__ * a_dim1];
01619
01620 }
01621 s_copy(srnamc_1.srnamt, "SSTEVR", (ftnlen)32, (ftnlen)6);
01622 i__3 = *liwork - (n << 1);
01623 sstevr_("V", "I", &n, &d1[1], &d2[1], &vl, &vu, &il, &iu, &
01624 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &iwork[1],
01625 &work[1], lwork, &iwork[(n << 1) + 1], &i__3, &iinfo);
01626 if (iinfo != 0) {
01627 io___66.ciunit = *nounit;
01628 s_wsfe(&io___66);
01629 do_fio(&c__1, "SSTEVR(V,I)", (ftnlen)11);
01630 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01631 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01632 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01633 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01634 ;
01635 e_wsfe();
01636 *info = abs(iinfo);
01637 if (iinfo < 0) {
01638 return 0;
01639 } else {
01640 result[19] = ulpinv;
01641 result[20] = ulpinv;
01642 result[21] = ulpinv;
01643 goto L570;
01644 }
01645 }
01646
01647
01648
01649 i__3 = n;
01650 for (i__ = 1; i__ <= i__3; ++i__) {
01651 d3[i__] = a[i__ + i__ * a_dim1];
01652
01653 }
01654 i__3 = n - 1;
01655 for (i__ = 1; i__ <= i__3; ++i__) {
01656 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01657
01658 }
01659 i__3 = max(1,m2);
01660 sstt22_(&n, &m2, &c__0, &d3[1], &d4[1], &wa2[1], &d2[1], &z__[
01661 z_offset], ldu, &work[1], &i__3, &result[19]);
01662
01663
01664 ntest = 21;
01665 i__3 = n - 1;
01666 for (i__ = 1; i__ <= i__3; ++i__) {
01667 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01668
01669 }
01670 s_copy(srnamc_1.srnamt, "SSTEVR", (ftnlen)32, (ftnlen)6);
01671 i__3 = *liwork - (n << 1);
01672 sstevr_("N", "I", &n, &d3[1], &d4[1], &vl, &vu, &il, &iu, &
01673 abstol, &m3, &wa3[1], &z__[z_offset], ldu, &iwork[1],
01674 &work[1], lwork, &iwork[(n << 1) + 1], &i__3, &iinfo);
01675 if (iinfo != 0) {
01676 io___67.ciunit = *nounit;
01677 s_wsfe(&io___67);
01678 do_fio(&c__1, "SSTEVR(N,I)", (ftnlen)11);
01679 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01680 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01681 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01682 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01683 ;
01684 e_wsfe();
01685 *info = abs(iinfo);
01686 if (iinfo < 0) {
01687 return 0;
01688 } else {
01689 result[21] = ulpinv;
01690 goto L570;
01691 }
01692 }
01693
01694
01695
01696 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
01697 ulp, &unfl);
01698 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
01699 ulp, &unfl);
01700
01701 r__1 = unfl, r__2 = ulp * temp3;
01702 result[21] = (temp1 + temp2) / dmax(r__1,r__2);
01703
01704 L570:
01705
01706 ntest = 21;
01707 if (n > 0) {
01708 if (il != 1) {
01709
01710 r__1 = (wa1[il] - wa1[il - 1]) * .5f, r__2 = ulp *
01711 10.f * temp3, r__1 = max(r__1,r__2), r__2 =
01712 rtunfl * 10.f;
01713 vl = wa1[il] - dmax(r__1,r__2);
01714 } else {
01715
01716 r__1 = (wa1[n] - wa1[1]) * .5f, r__2 = ulp * 10.f *
01717 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
01718 10.f;
01719 vl = wa1[1] - dmax(r__1,r__2);
01720 }
01721 if (iu != n) {
01722
01723 r__1 = (wa1[iu + 1] - wa1[iu]) * .5f, r__2 = ulp *
01724 10.f * temp3, r__1 = max(r__1,r__2), r__2 =
01725 rtunfl * 10.f;
01726 vu = wa1[iu] + dmax(r__1,r__2);
01727 } else {
01728
01729 r__1 = (wa1[n] - wa1[1]) * .5f, r__2 = ulp * 10.f *
01730 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
01731 10.f;
01732 vu = wa1[n] + dmax(r__1,r__2);
01733 }
01734 } else {
01735 vl = 0.f;
01736 vu = 1.f;
01737 }
01738
01739 i__3 = n;
01740 for (i__ = 1; i__ <= i__3; ++i__) {
01741 d1[i__] = a[i__ + i__ * a_dim1];
01742
01743 }
01744 i__3 = n - 1;
01745 for (i__ = 1; i__ <= i__3; ++i__) {
01746 d2[i__] = a[i__ + 1 + i__ * a_dim1];
01747
01748 }
01749 s_copy(srnamc_1.srnamt, "SSTEVR", (ftnlen)32, (ftnlen)6);
01750 i__3 = *liwork - (n << 1);
01751 sstevr_("V", "V", &n, &d1[1], &d2[1], &vl, &vu, &il, &iu, &
01752 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &iwork[1],
01753 &work[1], lwork, &iwork[(n << 1) + 1], &i__3, &iinfo);
01754 if (iinfo != 0) {
01755 io___68.ciunit = *nounit;
01756 s_wsfe(&io___68);
01757 do_fio(&c__1, "SSTEVR(V,V)", (ftnlen)11);
01758 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01759 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01760 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01761 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01762 ;
01763 e_wsfe();
01764 *info = abs(iinfo);
01765 if (iinfo < 0) {
01766 return 0;
01767 } else {
01768 result[22] = ulpinv;
01769 result[23] = ulpinv;
01770 result[24] = ulpinv;
01771 goto L630;
01772 }
01773 }
01774
01775 if (m2 == 0 && n > 0) {
01776 result[22] = ulpinv;
01777 result[23] = ulpinv;
01778 result[24] = ulpinv;
01779 goto L630;
01780 }
01781
01782
01783
01784 i__3 = n;
01785 for (i__ = 1; i__ <= i__3; ++i__) {
01786 d3[i__] = a[i__ + i__ * a_dim1];
01787
01788 }
01789 i__3 = n - 1;
01790 for (i__ = 1; i__ <= i__3; ++i__) {
01791 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01792
01793 }
01794 i__3 = max(1,m2);
01795 sstt22_(&n, &m2, &c__0, &d3[1], &d4[1], &wa2[1], &d2[1], &z__[
01796 z_offset], ldu, &work[1], &i__3, &result[22]);
01797
01798 ntest = 24;
01799 i__3 = n - 1;
01800 for (i__ = 1; i__ <= i__3; ++i__) {
01801 d4[i__] = a[i__ + 1 + i__ * a_dim1];
01802
01803 }
01804 s_copy(srnamc_1.srnamt, "SSTEVR", (ftnlen)32, (ftnlen)6);
01805 i__3 = *liwork - (n << 1);
01806 sstevr_("N", "V", &n, &d3[1], &d4[1], &vl, &vu, &il, &iu, &
01807 abstol, &m3, &wa3[1], &z__[z_offset], ldu, &iwork[1],
01808 &work[1], lwork, &iwork[(n << 1) + 1], &i__3, &iinfo);
01809 if (iinfo != 0) {
01810 io___69.ciunit = *nounit;
01811 s_wsfe(&io___69);
01812 do_fio(&c__1, "SSTEVR(N,V)", (ftnlen)11);
01813 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01814 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01815 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01816 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01817 ;
01818 e_wsfe();
01819 *info = abs(iinfo);
01820 if (iinfo < 0) {
01821 return 0;
01822 } else {
01823 result[24] = ulpinv;
01824 goto L630;
01825 }
01826 }
01827
01828
01829
01830 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
01831 ulp, &unfl);
01832 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
01833 ulp, &unfl);
01834
01835 r__1 = unfl, r__2 = temp3 * ulp;
01836 result[24] = (temp1 + temp2) / dmax(r__1,r__2);
01837
01838 L630:
01839
01840
01841
01842 ;
01843 } else {
01844
01845 for (i__ = 1; i__ <= 24; ++i__) {
01846 result[i__] = 0.f;
01847
01848 }
01849 ntest = 24;
01850 }
01851
01852
01853
01854
01855 for (iuplo = 0; iuplo <= 1; ++iuplo) {
01856 if (iuplo == 0) {
01857 *(unsigned char *)uplo = 'L';
01858 } else {
01859 *(unsigned char *)uplo = 'U';
01860 }
01861
01862
01863
01864 slacpy_(" ", &n, &n, &a[a_offset], lda, &v[v_offset], ldu);
01865
01866 ++ntest;
01867 s_copy(srnamc_1.srnamt, "SSYEV", (ftnlen)32, (ftnlen)5);
01868 ssyev_("V", uplo, &n, &a[a_offset], ldu, &d1[1], &work[1],
01869 lwork, &iinfo);
01870 if (iinfo != 0) {
01871 io___72.ciunit = *nounit;
01872 s_wsfe(&io___72);
01873
01874 i__6[0] = 8, a__1[0] = "SSYEV(V,";
01875 i__6[1] = 1, a__1[1] = uplo;
01876 i__6[2] = 1, a__1[2] = ")";
01877 s_cat(ch__1, a__1, i__6, &c__3, (ftnlen)10);
01878 do_fio(&c__1, ch__1, (ftnlen)10);
01879 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01880 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01881 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01882 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01883 ;
01884 e_wsfe();
01885 *info = abs(iinfo);
01886 if (iinfo < 0) {
01887 return 0;
01888 } else {
01889 result[ntest] = ulpinv;
01890 result[ntest + 1] = ulpinv;
01891 result[ntest + 2] = ulpinv;
01892 goto L660;
01893 }
01894 }
01895
01896
01897
01898 ssyt21_(&c__1, uplo, &n, &c__0, &v[v_offset], ldu, &d1[1], &
01899 d2[1], &a[a_offset], ldu, &z__[z_offset], ldu, &tau[1]
01900 , &work[1], &result[ntest]);
01901
01902 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
01903
01904 ntest += 2;
01905 s_copy(srnamc_1.srnamt, "SSYEV", (ftnlen)32, (ftnlen)5);
01906 ssyev_("N", uplo, &n, &a[a_offset], ldu, &d3[1], &work[1],
01907 lwork, &iinfo);
01908 if (iinfo != 0) {
01909 io___73.ciunit = *nounit;
01910 s_wsfe(&io___73);
01911
01912 i__6[0] = 8, a__1[0] = "SSYEV(N,";
01913 i__6[1] = 1, a__1[1] = uplo;
01914 i__6[2] = 1, a__1[2] = ")";
01915 s_cat(ch__1, a__1, i__6, &c__3, (ftnlen)10);
01916 do_fio(&c__1, ch__1, (ftnlen)10);
01917 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
01918 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
01919 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
01920 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
01921 ;
01922 e_wsfe();
01923 *info = abs(iinfo);
01924 if (iinfo < 0) {
01925 return 0;
01926 } else {
01927 result[ntest] = ulpinv;
01928 goto L660;
01929 }
01930 }
01931
01932
01933
01934 temp1 = 0.f;
01935 temp2 = 0.f;
01936 i__3 = n;
01937 for (j = 1; j <= i__3; ++j) {
01938
01939 r__3 = temp1, r__4 = (r__1 = d1[j], dabs(r__1)), r__3 =
01940 max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2));
01941 temp1 = dmax(r__3,r__4);
01942
01943 r__2 = temp2, r__3 = (r__1 = d1[j] - d3[j], dabs(r__1));
01944 temp2 = dmax(r__2,r__3);
01945
01946 }
01947
01948 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
01949 result[ntest] = temp2 / dmax(r__1,r__2);
01950
01951 L660:
01952 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
01953
01954 ++ntest;
01955
01956 if (n > 0) {
01957
01958 r__2 = dabs(d1[1]), r__3 = (r__1 = d1[n], dabs(r__1));
01959 temp3 = dmax(r__2,r__3);
01960 if (il != 1) {
01961
01962 r__1 = (d1[il] - d1[il - 1]) * .5f, r__2 = ulp * 10.f
01963 * temp3, r__1 = max(r__1,r__2), r__2 = rtunfl
01964 * 10.f;
01965 vl = d1[il] - dmax(r__1,r__2);
01966 } else if (n > 0) {
01967
01968 r__1 = (d1[n] - d1[1]) * .5f, r__2 = ulp * 10.f *
01969 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
01970 10.f;
01971 vl = d1[1] - dmax(r__1,r__2);
01972 }
01973 if (iu != n) {
01974
01975 r__1 = (d1[iu + 1] - d1[iu]) * .5f, r__2 = ulp * 10.f
01976 * temp3, r__1 = max(r__1,r__2), r__2 = rtunfl
01977 * 10.f;
01978 vu = d1[iu] + dmax(r__1,r__2);
01979 } else if (n > 0) {
01980
01981 r__1 = (d1[n] - d1[1]) * .5f, r__2 = ulp * 10.f *
01982 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
01983 10.f;
01984 vu = d1[n] + dmax(r__1,r__2);
01985 }
01986 } else {
01987 temp3 = 0.f;
01988 vl = 0.f;
01989 vu = 1.f;
01990 }
01991
01992 s_copy(srnamc_1.srnamt, "SSYEVX", (ftnlen)32, (ftnlen)6);
01993 ssyevx_("V", "A", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
01994 &iu, &abstol, &m, &wa1[1], &z__[z_offset], ldu, &work[
01995 1], lwork, &iwork[1], &iwork[n * 5 + 1], &iinfo);
01996 if (iinfo != 0) {
01997 io___74.ciunit = *nounit;
01998 s_wsfe(&io___74);
01999
02000 i__6[0] = 11, a__1[0] = "SSYEVX(V,A,";
02001 i__6[1] = 1, a__1[1] = uplo;
02002 i__6[2] = 1, a__1[2] = ")";
02003 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02004 do_fio(&c__1, ch__2, (ftnlen)13);
02005 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02006 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02007 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02008 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02009 ;
02010 e_wsfe();
02011 *info = abs(iinfo);
02012 if (iinfo < 0) {
02013 return 0;
02014 } else {
02015 result[ntest] = ulpinv;
02016 result[ntest + 1] = ulpinv;
02017 result[ntest + 2] = ulpinv;
02018 goto L680;
02019 }
02020 }
02021
02022
02023
02024 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02025
02026 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], ldu, &d1[1], &
02027 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
02028 , &work[1], &result[ntest]);
02029
02030 ntest += 2;
02031 s_copy(srnamc_1.srnamt, "SSYEVX", (ftnlen)32, (ftnlen)6);
02032 ssyevx_("N", "A", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
02033 &iu, &abstol, &m2, &wa2[1], &z__[z_offset], ldu, &
02034 work[1], lwork, &iwork[1], &iwork[n * 5 + 1], &iinfo);
02035 if (iinfo != 0) {
02036 io___75.ciunit = *nounit;
02037 s_wsfe(&io___75);
02038
02039 i__6[0] = 11, a__1[0] = "SSYEVX(N,A,";
02040 i__6[1] = 1, a__1[1] = uplo;
02041 i__6[2] = 1, a__1[2] = ")";
02042 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02043 do_fio(&c__1, ch__2, (ftnlen)13);
02044 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02045 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02046 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02047 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02048 ;
02049 e_wsfe();
02050 *info = abs(iinfo);
02051 if (iinfo < 0) {
02052 return 0;
02053 } else {
02054 result[ntest] = ulpinv;
02055 goto L680;
02056 }
02057 }
02058
02059
02060
02061 temp1 = 0.f;
02062 temp2 = 0.f;
02063 i__3 = n;
02064 for (j = 1; j <= i__3; ++j) {
02065
02066 r__3 = temp1, r__4 = (r__1 = wa1[j], dabs(r__1)), r__3 =
02067 max(r__3,r__4), r__4 = (r__2 = wa2[j], dabs(r__2))
02068 ;
02069 temp1 = dmax(r__3,r__4);
02070
02071 r__2 = temp2, r__3 = (r__1 = wa1[j] - wa2[j], dabs(r__1));
02072 temp2 = dmax(r__2,r__3);
02073
02074 }
02075
02076 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
02077 result[ntest] = temp2 / dmax(r__1,r__2);
02078
02079 L680:
02080
02081 ++ntest;
02082 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02083 s_copy(srnamc_1.srnamt, "SSYEVX", (ftnlen)32, (ftnlen)6);
02084 ssyevx_("V", "I", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
02085 &iu, &abstol, &m2, &wa2[1], &z__[z_offset], ldu, &
02086 work[1], lwork, &iwork[1], &iwork[n * 5 + 1], &iinfo);
02087 if (iinfo != 0) {
02088 io___76.ciunit = *nounit;
02089 s_wsfe(&io___76);
02090
02091 i__6[0] = 11, a__1[0] = "SSYEVX(V,I,";
02092 i__6[1] = 1, a__1[1] = uplo;
02093 i__6[2] = 1, a__1[2] = ")";
02094 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02095 do_fio(&c__1, ch__2, (ftnlen)13);
02096 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02097 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02098 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02099 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02100 ;
02101 e_wsfe();
02102 *info = abs(iinfo);
02103 if (iinfo < 0) {
02104 return 0;
02105 } else {
02106 result[ntest] = ulpinv;
02107 result[ntest + 1] = ulpinv;
02108 result[ntest + 2] = ulpinv;
02109 goto L690;
02110 }
02111 }
02112
02113
02114
02115 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02116
02117 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
02118 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
02119 tau[1], &work[1], &result[ntest]);
02120
02121 ntest += 2;
02122 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02123 s_copy(srnamc_1.srnamt, "SSYEVX", (ftnlen)32, (ftnlen)6);
02124 ssyevx_("N", "I", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
02125 &iu, &abstol, &m3, &wa3[1], &z__[z_offset], ldu, &
02126 work[1], lwork, &iwork[1], &iwork[n * 5 + 1], &iinfo);
02127 if (iinfo != 0) {
02128 io___77.ciunit = *nounit;
02129 s_wsfe(&io___77);
02130
02131 i__6[0] = 11, a__1[0] = "SSYEVX(N,I,";
02132 i__6[1] = 1, a__1[1] = uplo;
02133 i__6[2] = 1, a__1[2] = ")";
02134 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02135 do_fio(&c__1, ch__2, (ftnlen)13);
02136 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02137 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02138 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02139 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02140 ;
02141 e_wsfe();
02142 *info = abs(iinfo);
02143 if (iinfo < 0) {
02144 return 0;
02145 } else {
02146 result[ntest] = ulpinv;
02147 goto L690;
02148 }
02149 }
02150
02151
02152
02153 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
02154 ulp, &unfl);
02155 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
02156 ulp, &unfl);
02157
02158 r__1 = unfl, r__2 = ulp * temp3;
02159 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
02160 L690:
02161
02162 ++ntest;
02163 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02164 s_copy(srnamc_1.srnamt, "SSYEVX", (ftnlen)32, (ftnlen)6);
02165 ssyevx_("V", "V", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
02166 &iu, &abstol, &m2, &wa2[1], &z__[z_offset], ldu, &
02167 work[1], lwork, &iwork[1], &iwork[n * 5 + 1], &iinfo);
02168 if (iinfo != 0) {
02169 io___78.ciunit = *nounit;
02170 s_wsfe(&io___78);
02171
02172 i__6[0] = 11, a__1[0] = "SSYEVX(V,V,";
02173 i__6[1] = 1, a__1[1] = uplo;
02174 i__6[2] = 1, a__1[2] = ")";
02175 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02176 do_fio(&c__1, ch__2, (ftnlen)13);
02177 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02178 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02179 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02180 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02181 ;
02182 e_wsfe();
02183 *info = abs(iinfo);
02184 if (iinfo < 0) {
02185 return 0;
02186 } else {
02187 result[ntest] = ulpinv;
02188 result[ntest + 1] = ulpinv;
02189 result[ntest + 2] = ulpinv;
02190 goto L700;
02191 }
02192 }
02193
02194
02195
02196 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02197
02198 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
02199 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
02200 tau[1], &work[1], &result[ntest]);
02201
02202 ntest += 2;
02203 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02204 s_copy(srnamc_1.srnamt, "SSYEVX", (ftnlen)32, (ftnlen)6);
02205 ssyevx_("N", "V", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
02206 &iu, &abstol, &m3, &wa3[1], &z__[z_offset], ldu, &
02207 work[1], lwork, &iwork[1], &iwork[n * 5 + 1], &iinfo);
02208 if (iinfo != 0) {
02209 io___79.ciunit = *nounit;
02210 s_wsfe(&io___79);
02211
02212 i__6[0] = 11, a__1[0] = "SSYEVX(N,V,";
02213 i__6[1] = 1, a__1[1] = uplo;
02214 i__6[2] = 1, a__1[2] = ")";
02215 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02216 do_fio(&c__1, ch__2, (ftnlen)13);
02217 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02218 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02219 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02220 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02221 ;
02222 e_wsfe();
02223 *info = abs(iinfo);
02224 if (iinfo < 0) {
02225 return 0;
02226 } else {
02227 result[ntest] = ulpinv;
02228 goto L700;
02229 }
02230 }
02231
02232 if (m3 == 0 && n > 0) {
02233 result[ntest] = ulpinv;
02234 goto L700;
02235 }
02236
02237
02238
02239 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
02240 ulp, &unfl);
02241 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
02242 ulp, &unfl);
02243 if (n > 0) {
02244
02245 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
02246 temp3 = dmax(r__2,r__3);
02247 } else {
02248 temp3 = 0.f;
02249 }
02250
02251 r__1 = unfl, r__2 = temp3 * ulp;
02252 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
02253
02254 L700:
02255
02256
02257
02258 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
02259
02260
02261
02262
02263 if (iuplo == 1) {
02264 indx = 1;
02265 i__3 = n;
02266 for (j = 1; j <= i__3; ++j) {
02267 i__4 = j;
02268 for (i__ = 1; i__ <= i__4; ++i__) {
02269 work[indx] = a[i__ + j * a_dim1];
02270 ++indx;
02271
02272 }
02273
02274 }
02275 } else {
02276 indx = 1;
02277 i__3 = n;
02278 for (j = 1; j <= i__3; ++j) {
02279 i__4 = n;
02280 for (i__ = j; i__ <= i__4; ++i__) {
02281 work[indx] = a[i__ + j * a_dim1];
02282 ++indx;
02283
02284 }
02285
02286 }
02287 }
02288
02289 ++ntest;
02290 s_copy(srnamc_1.srnamt, "SSPEV", (ftnlen)32, (ftnlen)5);
02291 sspev_("V", uplo, &n, &work[1], &d1[1], &z__[z_offset], ldu, &
02292 v[v_offset], &iinfo);
02293 if (iinfo != 0) {
02294 io___81.ciunit = *nounit;
02295 s_wsfe(&io___81);
02296
02297 i__6[0] = 8, a__1[0] = "SSPEV(V,";
02298 i__6[1] = 1, a__1[1] = uplo;
02299 i__6[2] = 1, a__1[2] = ")";
02300 s_cat(ch__1, a__1, i__6, &c__3, (ftnlen)10);
02301 do_fio(&c__1, ch__1, (ftnlen)10);
02302 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02303 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02304 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02305 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02306 ;
02307 e_wsfe();
02308 *info = abs(iinfo);
02309 if (iinfo < 0) {
02310 return 0;
02311 } else {
02312 result[ntest] = ulpinv;
02313 result[ntest + 1] = ulpinv;
02314 result[ntest + 2] = ulpinv;
02315 goto L800;
02316 }
02317 }
02318
02319
02320
02321 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], lda, &d1[1], &
02322 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
02323 , &work[1], &result[ntest]);
02324
02325 if (iuplo == 1) {
02326 indx = 1;
02327 i__3 = n;
02328 for (j = 1; j <= i__3; ++j) {
02329 i__4 = j;
02330 for (i__ = 1; i__ <= i__4; ++i__) {
02331 work[indx] = a[i__ + j * a_dim1];
02332 ++indx;
02333
02334 }
02335
02336 }
02337 } else {
02338 indx = 1;
02339 i__3 = n;
02340 for (j = 1; j <= i__3; ++j) {
02341 i__4 = n;
02342 for (i__ = j; i__ <= i__4; ++i__) {
02343 work[indx] = a[i__ + j * a_dim1];
02344 ++indx;
02345
02346 }
02347
02348 }
02349 }
02350
02351 ntest += 2;
02352 s_copy(srnamc_1.srnamt, "SSPEV", (ftnlen)32, (ftnlen)5);
02353 sspev_("N", uplo, &n, &work[1], &d3[1], &z__[z_offset], ldu, &
02354 v[v_offset], &iinfo);
02355 if (iinfo != 0) {
02356 io___82.ciunit = *nounit;
02357 s_wsfe(&io___82);
02358
02359 i__6[0] = 8, a__1[0] = "SSPEV(N,";
02360 i__6[1] = 1, a__1[1] = uplo;
02361 i__6[2] = 1, a__1[2] = ")";
02362 s_cat(ch__1, a__1, i__6, &c__3, (ftnlen)10);
02363 do_fio(&c__1, ch__1, (ftnlen)10);
02364 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02365 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02366 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02367 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02368 ;
02369 e_wsfe();
02370 *info = abs(iinfo);
02371 if (iinfo < 0) {
02372 return 0;
02373 } else {
02374 result[ntest] = ulpinv;
02375 goto L800;
02376 }
02377 }
02378
02379
02380
02381 temp1 = 0.f;
02382 temp2 = 0.f;
02383 i__3 = n;
02384 for (j = 1; j <= i__3; ++j) {
02385
02386 r__3 = temp1, r__4 = (r__1 = d1[j], dabs(r__1)), r__3 =
02387 max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2));
02388 temp1 = dmax(r__3,r__4);
02389
02390 r__2 = temp2, r__3 = (r__1 = d1[j] - d3[j], dabs(r__1));
02391 temp2 = dmax(r__2,r__3);
02392
02393 }
02394
02395 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
02396 result[ntest] = temp2 / dmax(r__1,r__2);
02397
02398
02399
02400
02401 L800:
02402 if (iuplo == 1) {
02403 indx = 1;
02404 i__3 = n;
02405 for (j = 1; j <= i__3; ++j) {
02406 i__4 = j;
02407 for (i__ = 1; i__ <= i__4; ++i__) {
02408 work[indx] = a[i__ + j * a_dim1];
02409 ++indx;
02410
02411 }
02412
02413 }
02414 } else {
02415 indx = 1;
02416 i__3 = n;
02417 for (j = 1; j <= i__3; ++j) {
02418 i__4 = n;
02419 for (i__ = j; i__ <= i__4; ++i__) {
02420 work[indx] = a[i__ + j * a_dim1];
02421 ++indx;
02422
02423 }
02424
02425 }
02426 }
02427
02428 ++ntest;
02429
02430 if (n > 0) {
02431
02432 r__2 = dabs(d1[1]), r__3 = (r__1 = d1[n], dabs(r__1));
02433 temp3 = dmax(r__2,r__3);
02434 if (il != 1) {
02435
02436 r__1 = (d1[il] - d1[il - 1]) * .5f, r__2 = ulp * 10.f
02437 * temp3, r__1 = max(r__1,r__2), r__2 = rtunfl
02438 * 10.f;
02439 vl = d1[il] - dmax(r__1,r__2);
02440 } else if (n > 0) {
02441
02442 r__1 = (d1[n] - d1[1]) * .5f, r__2 = ulp * 10.f *
02443 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
02444 10.f;
02445 vl = d1[1] - dmax(r__1,r__2);
02446 }
02447 if (iu != n) {
02448
02449 r__1 = (d1[iu + 1] - d1[iu]) * .5f, r__2 = ulp * 10.f
02450 * temp3, r__1 = max(r__1,r__2), r__2 = rtunfl
02451 * 10.f;
02452 vu = d1[iu] + dmax(r__1,r__2);
02453 } else if (n > 0) {
02454
02455 r__1 = (d1[n] - d1[1]) * .5f, r__2 = ulp * 10.f *
02456 temp3, r__1 = max(r__1,r__2), r__2 = rtunfl *
02457 10.f;
02458 vu = d1[n] + dmax(r__1,r__2);
02459 }
02460 } else {
02461 temp3 = 0.f;
02462 vl = 0.f;
02463 vu = 1.f;
02464 }
02465
02466 s_copy(srnamc_1.srnamt, "SSPEVX", (ftnlen)32, (ftnlen)6);
02467 sspevx_("V", "A", uplo, &n, &work[1], &vl, &vu, &il, &iu, &
02468 abstol, &m, &wa1[1], &z__[z_offset], ldu, &v[v_offset]
02469 , &iwork[1], &iwork[n * 5 + 1], &iinfo);
02470 if (iinfo != 0) {
02471 io___83.ciunit = *nounit;
02472 s_wsfe(&io___83);
02473
02474 i__6[0] = 11, a__1[0] = "SSPEVX(V,A,";
02475 i__6[1] = 1, a__1[1] = uplo;
02476 i__6[2] = 1, a__1[2] = ")";
02477 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02478 do_fio(&c__1, ch__2, (ftnlen)13);
02479 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02480 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02481 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02482 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02483 ;
02484 e_wsfe();
02485 *info = abs(iinfo);
02486 if (iinfo < 0) {
02487 return 0;
02488 } else {
02489 result[ntest] = ulpinv;
02490 result[ntest + 1] = ulpinv;
02491 result[ntest + 2] = ulpinv;
02492 goto L900;
02493 }
02494 }
02495
02496
02497
02498 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], ldu, &wa1[1], &
02499 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
02500 , &work[1], &result[ntest]);
02501
02502 ntest += 2;
02503
02504 if (iuplo == 1) {
02505 indx = 1;
02506 i__3 = n;
02507 for (j = 1; j <= i__3; ++j) {
02508 i__4 = j;
02509 for (i__ = 1; i__ <= i__4; ++i__) {
02510 work[indx] = a[i__ + j * a_dim1];
02511 ++indx;
02512
02513 }
02514
02515 }
02516 } else {
02517 indx = 1;
02518 i__3 = n;
02519 for (j = 1; j <= i__3; ++j) {
02520 i__4 = n;
02521 for (i__ = j; i__ <= i__4; ++i__) {
02522 work[indx] = a[i__ + j * a_dim1];
02523 ++indx;
02524
02525 }
02526
02527 }
02528 }
02529
02530 s_copy(srnamc_1.srnamt, "SSPEVX", (ftnlen)32, (ftnlen)6);
02531 sspevx_("N", "A", uplo, &n, &work[1], &vl, &vu, &il, &iu, &
02532 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &v[
02533 v_offset], &iwork[1], &iwork[n * 5 + 1], &iinfo);
02534 if (iinfo != 0) {
02535 io___84.ciunit = *nounit;
02536 s_wsfe(&io___84);
02537
02538 i__6[0] = 11, a__1[0] = "SSPEVX(N,A,";
02539 i__6[1] = 1, a__1[1] = uplo;
02540 i__6[2] = 1, a__1[2] = ")";
02541 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02542 do_fio(&c__1, ch__2, (ftnlen)13);
02543 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02544 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02545 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02546 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02547 ;
02548 e_wsfe();
02549 *info = abs(iinfo);
02550 if (iinfo < 0) {
02551 return 0;
02552 } else {
02553 result[ntest] = ulpinv;
02554 goto L900;
02555 }
02556 }
02557
02558
02559
02560 temp1 = 0.f;
02561 temp2 = 0.f;
02562 i__3 = n;
02563 for (j = 1; j <= i__3; ++j) {
02564
02565 r__3 = temp1, r__4 = (r__1 = wa1[j], dabs(r__1)), r__3 =
02566 max(r__3,r__4), r__4 = (r__2 = wa2[j], dabs(r__2))
02567 ;
02568 temp1 = dmax(r__3,r__4);
02569
02570 r__2 = temp2, r__3 = (r__1 = wa1[j] - wa2[j], dabs(r__1));
02571 temp2 = dmax(r__2,r__3);
02572
02573 }
02574
02575 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
02576 result[ntest] = temp2 / dmax(r__1,r__2);
02577
02578 L900:
02579 if (iuplo == 1) {
02580 indx = 1;
02581 i__3 = n;
02582 for (j = 1; j <= i__3; ++j) {
02583 i__4 = j;
02584 for (i__ = 1; i__ <= i__4; ++i__) {
02585 work[indx] = a[i__ + j * a_dim1];
02586 ++indx;
02587
02588 }
02589
02590 }
02591 } else {
02592 indx = 1;
02593 i__3 = n;
02594 for (j = 1; j <= i__3; ++j) {
02595 i__4 = n;
02596 for (i__ = j; i__ <= i__4; ++i__) {
02597 work[indx] = a[i__ + j * a_dim1];
02598 ++indx;
02599
02600 }
02601
02602 }
02603 }
02604
02605 ++ntest;
02606
02607 s_copy(srnamc_1.srnamt, "SSPEVX", (ftnlen)32, (ftnlen)6);
02608 sspevx_("V", "I", uplo, &n, &work[1], &vl, &vu, &il, &iu, &
02609 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &v[
02610 v_offset], &iwork[1], &iwork[n * 5 + 1], &iinfo);
02611 if (iinfo != 0) {
02612 io___85.ciunit = *nounit;
02613 s_wsfe(&io___85);
02614
02615 i__6[0] = 11, a__1[0] = "SSPEVX(V,I,";
02616 i__6[1] = 1, a__1[1] = uplo;
02617 i__6[2] = 1, a__1[2] = ")";
02618 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02619 do_fio(&c__1, ch__2, (ftnlen)13);
02620 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02621 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02622 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02623 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02624 ;
02625 e_wsfe();
02626 *info = abs(iinfo);
02627 if (iinfo < 0) {
02628 return 0;
02629 } else {
02630 result[ntest] = ulpinv;
02631 result[ntest + 1] = ulpinv;
02632 result[ntest + 2] = ulpinv;
02633 goto L990;
02634 }
02635 }
02636
02637
02638
02639 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
02640 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
02641 tau[1], &work[1], &result[ntest]);
02642
02643 ntest += 2;
02644
02645 if (iuplo == 1) {
02646 indx = 1;
02647 i__3 = n;
02648 for (j = 1; j <= i__3; ++j) {
02649 i__4 = j;
02650 for (i__ = 1; i__ <= i__4; ++i__) {
02651 work[indx] = a[i__ + j * a_dim1];
02652 ++indx;
02653
02654 }
02655
02656 }
02657 } else {
02658 indx = 1;
02659 i__3 = n;
02660 for (j = 1; j <= i__3; ++j) {
02661 i__4 = n;
02662 for (i__ = j; i__ <= i__4; ++i__) {
02663 work[indx] = a[i__ + j * a_dim1];
02664 ++indx;
02665
02666 }
02667
02668 }
02669 }
02670
02671 s_copy(srnamc_1.srnamt, "SSPEVX", (ftnlen)32, (ftnlen)6);
02672 sspevx_("N", "I", uplo, &n, &work[1], &vl, &vu, &il, &iu, &
02673 abstol, &m3, &wa3[1], &z__[z_offset], ldu, &v[
02674 v_offset], &iwork[1], &iwork[n * 5 + 1], &iinfo);
02675 if (iinfo != 0) {
02676 io___86.ciunit = *nounit;
02677 s_wsfe(&io___86);
02678
02679 i__6[0] = 11, a__1[0] = "SSPEVX(N,I,";
02680 i__6[1] = 1, a__1[1] = uplo;
02681 i__6[2] = 1, a__1[2] = ")";
02682 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02683 do_fio(&c__1, ch__2, (ftnlen)13);
02684 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02685 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02686 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02687 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02688 ;
02689 e_wsfe();
02690 *info = abs(iinfo);
02691 if (iinfo < 0) {
02692 return 0;
02693 } else {
02694 result[ntest] = ulpinv;
02695 goto L990;
02696 }
02697 }
02698
02699 if (m3 == 0 && n > 0) {
02700 result[ntest] = ulpinv;
02701 goto L990;
02702 }
02703
02704
02705
02706 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
02707 ulp, &unfl);
02708 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
02709 ulp, &unfl);
02710 if (n > 0) {
02711
02712 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
02713 temp3 = dmax(r__2,r__3);
02714 } else {
02715 temp3 = 0.f;
02716 }
02717
02718 r__1 = unfl, r__2 = temp3 * ulp;
02719 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
02720
02721 L990:
02722 if (iuplo == 1) {
02723 indx = 1;
02724 i__3 = n;
02725 for (j = 1; j <= i__3; ++j) {
02726 i__4 = j;
02727 for (i__ = 1; i__ <= i__4; ++i__) {
02728 work[indx] = a[i__ + j * a_dim1];
02729 ++indx;
02730
02731 }
02732
02733 }
02734 } else {
02735 indx = 1;
02736 i__3 = n;
02737 for (j = 1; j <= i__3; ++j) {
02738 i__4 = n;
02739 for (i__ = j; i__ <= i__4; ++i__) {
02740 work[indx] = a[i__ + j * a_dim1];
02741 ++indx;
02742
02743 }
02744
02745 }
02746 }
02747
02748 ++ntest;
02749
02750 s_copy(srnamc_1.srnamt, "SSPEVX", (ftnlen)32, (ftnlen)6);
02751 sspevx_("V", "V", uplo, &n, &work[1], &vl, &vu, &il, &iu, &
02752 abstol, &m2, &wa2[1], &z__[z_offset], ldu, &v[
02753 v_offset], &iwork[1], &iwork[n * 5 + 1], &iinfo);
02754 if (iinfo != 0) {
02755 io___87.ciunit = *nounit;
02756 s_wsfe(&io___87);
02757
02758 i__6[0] = 11, a__1[0] = "SSPEVX(V,V,";
02759 i__6[1] = 1, a__1[1] = uplo;
02760 i__6[2] = 1, a__1[2] = ")";
02761 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02762 do_fio(&c__1, ch__2, (ftnlen)13);
02763 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02764 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02765 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02766 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02767 ;
02768 e_wsfe();
02769 *info = abs(iinfo);
02770 if (iinfo < 0) {
02771 return 0;
02772 } else {
02773 result[ntest] = ulpinv;
02774 result[ntest + 1] = ulpinv;
02775 result[ntest + 2] = ulpinv;
02776 goto L1080;
02777 }
02778 }
02779
02780
02781
02782 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
02783 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
02784 tau[1], &work[1], &result[ntest]);
02785
02786 ntest += 2;
02787
02788 if (iuplo == 1) {
02789 indx = 1;
02790 i__3 = n;
02791 for (j = 1; j <= i__3; ++j) {
02792 i__4 = j;
02793 for (i__ = 1; i__ <= i__4; ++i__) {
02794 work[indx] = a[i__ + j * a_dim1];
02795 ++indx;
02796
02797 }
02798
02799 }
02800 } else {
02801 indx = 1;
02802 i__3 = n;
02803 for (j = 1; j <= i__3; ++j) {
02804 i__4 = n;
02805 for (i__ = j; i__ <= i__4; ++i__) {
02806 work[indx] = a[i__ + j * a_dim1];
02807 ++indx;
02808
02809 }
02810
02811 }
02812 }
02813
02814 s_copy(srnamc_1.srnamt, "SSPEVX", (ftnlen)32, (ftnlen)6);
02815 sspevx_("N", "V", uplo, &n, &work[1], &vl, &vu, &il, &iu, &
02816 abstol, &m3, &wa3[1], &z__[z_offset], ldu, &v[
02817 v_offset], &iwork[1], &iwork[n * 5 + 1], &iinfo);
02818 if (iinfo != 0) {
02819 io___88.ciunit = *nounit;
02820 s_wsfe(&io___88);
02821
02822 i__6[0] = 11, a__1[0] = "SSPEVX(N,V,";
02823 i__6[1] = 1, a__1[1] = uplo;
02824 i__6[2] = 1, a__1[2] = ")";
02825 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
02826 do_fio(&c__1, ch__2, (ftnlen)13);
02827 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02828 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02829 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02830 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02831 ;
02832 e_wsfe();
02833 *info = abs(iinfo);
02834 if (iinfo < 0) {
02835 return 0;
02836 } else {
02837 result[ntest] = ulpinv;
02838 goto L1080;
02839 }
02840 }
02841
02842 if (m3 == 0 && n > 0) {
02843 result[ntest] = ulpinv;
02844 goto L1080;
02845 }
02846
02847
02848
02849 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
02850 ulp, &unfl);
02851 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
02852 ulp, &unfl);
02853 if (n > 0) {
02854
02855 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
02856 temp3 = dmax(r__2,r__3);
02857 } else {
02858 temp3 = 0.f;
02859 }
02860
02861 r__1 = unfl, r__2 = temp3 * ulp;
02862 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
02863
02864 L1080:
02865
02866
02867
02868 if (jtype <= 7) {
02869 kd = 1;
02870 } else if (jtype >= 8 && jtype <= 15) {
02871
02872 i__3 = n - 1;
02873 kd = max(i__3,0);
02874 } else {
02875 kd = ihbw;
02876 }
02877
02878
02879
02880
02881 if (iuplo == 1) {
02882 i__3 = n;
02883 for (j = 1; j <= i__3; ++j) {
02884
02885 i__4 = 1, i__5 = j - kd;
02886 i__7 = j;
02887 for (i__ = max(i__4,i__5); i__ <= i__7; ++i__) {
02888 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
02889 a_dim1];
02890
02891 }
02892
02893 }
02894 } else {
02895 i__3 = n;
02896 for (j = 1; j <= i__3; ++j) {
02897
02898 i__4 = n, i__5 = j + kd;
02899 i__7 = min(i__4,i__5);
02900 for (i__ = j; i__ <= i__7; ++i__) {
02901 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
02902
02903 }
02904
02905 }
02906 }
02907
02908 ++ntest;
02909 s_copy(srnamc_1.srnamt, "SSBEV", (ftnlen)32, (ftnlen)5);
02910 ssbev_("V", uplo, &n, &kd, &v[v_offset], ldu, &d1[1], &z__[
02911 z_offset], ldu, &work[1], &iinfo);
02912 if (iinfo != 0) {
02913 io___90.ciunit = *nounit;
02914 s_wsfe(&io___90);
02915
02916 i__6[0] = 8, a__1[0] = "SSBEV(V,";
02917 i__6[1] = 1, a__1[1] = uplo;
02918 i__6[2] = 1, a__1[2] = ")";
02919 s_cat(ch__1, a__1, i__6, &c__3, (ftnlen)10);
02920 do_fio(&c__1, ch__1, (ftnlen)10);
02921 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02922 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02923 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02924 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02925 ;
02926 e_wsfe();
02927 *info = abs(iinfo);
02928 if (iinfo < 0) {
02929 return 0;
02930 } else {
02931 result[ntest] = ulpinv;
02932 result[ntest + 1] = ulpinv;
02933 result[ntest + 2] = ulpinv;
02934 goto L1180;
02935 }
02936 }
02937
02938
02939
02940 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], lda, &d1[1], &
02941 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
02942 , &work[1], &result[ntest]);
02943
02944 if (iuplo == 1) {
02945 i__3 = n;
02946 for (j = 1; j <= i__3; ++j) {
02947
02948 i__7 = 1, i__4 = j - kd;
02949 i__5 = j;
02950 for (i__ = max(i__7,i__4); i__ <= i__5; ++i__) {
02951 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
02952 a_dim1];
02953
02954 }
02955
02956 }
02957 } else {
02958 i__3 = n;
02959 for (j = 1; j <= i__3; ++j) {
02960
02961 i__7 = n, i__4 = j + kd;
02962 i__5 = min(i__7,i__4);
02963 for (i__ = j; i__ <= i__5; ++i__) {
02964 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
02965
02966 }
02967
02968 }
02969 }
02970
02971 ntest += 2;
02972 s_copy(srnamc_1.srnamt, "SSBEV", (ftnlen)32, (ftnlen)5);
02973 ssbev_("N", uplo, &n, &kd, &v[v_offset], ldu, &d3[1], &z__[
02974 z_offset], ldu, &work[1], &iinfo);
02975 if (iinfo != 0) {
02976 io___91.ciunit = *nounit;
02977 s_wsfe(&io___91);
02978
02979 i__6[0] = 8, a__1[0] = "SSBEV(N,";
02980 i__6[1] = 1, a__1[1] = uplo;
02981 i__6[2] = 1, a__1[2] = ")";
02982 s_cat(ch__1, a__1, i__6, &c__3, (ftnlen)10);
02983 do_fio(&c__1, ch__1, (ftnlen)10);
02984 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
02985 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
02986 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
02987 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
02988 ;
02989 e_wsfe();
02990 *info = abs(iinfo);
02991 if (iinfo < 0) {
02992 return 0;
02993 } else {
02994 result[ntest] = ulpinv;
02995 goto L1180;
02996 }
02997 }
02998
02999
03000
03001 temp1 = 0.f;
03002 temp2 = 0.f;
03003 i__3 = n;
03004 for (j = 1; j <= i__3; ++j) {
03005
03006 r__3 = temp1, r__4 = (r__1 = d1[j], dabs(r__1)), r__3 =
03007 max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2));
03008 temp1 = dmax(r__3,r__4);
03009
03010 r__2 = temp2, r__3 = (r__1 = d1[j] - d3[j], dabs(r__1));
03011 temp2 = dmax(r__2,r__3);
03012
03013 }
03014
03015 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
03016 result[ntest] = temp2 / dmax(r__1,r__2);
03017
03018
03019
03020
03021 L1180:
03022 if (iuplo == 1) {
03023 i__3 = n;
03024 for (j = 1; j <= i__3; ++j) {
03025
03026 i__5 = 1, i__7 = j - kd;
03027 i__4 = j;
03028 for (i__ = max(i__5,i__7); i__ <= i__4; ++i__) {
03029 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03030 a_dim1];
03031
03032 }
03033
03034 }
03035 } else {
03036 i__3 = n;
03037 for (j = 1; j <= i__3; ++j) {
03038
03039 i__5 = n, i__7 = j + kd;
03040 i__4 = min(i__5,i__7);
03041 for (i__ = j; i__ <= i__4; ++i__) {
03042 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03043
03044 }
03045
03046 }
03047 }
03048
03049 ++ntest;
03050 s_copy(srnamc_1.srnamt, "SSBEVX", (ftnlen)32, (ftnlen)6);
03051 ssbevx_("V", "A", uplo, &n, &kd, &v[v_offset], ldu, &u[
03052 u_offset], ldu, &vl, &vu, &il, &iu, &abstol, &m, &wa2[
03053 1], &z__[z_offset], ldu, &work[1], &iwork[1], &iwork[
03054 n * 5 + 1], &iinfo);
03055 if (iinfo != 0) {
03056 io___92.ciunit = *nounit;
03057 s_wsfe(&io___92);
03058
03059 i__6[0] = 11, a__1[0] = "SSBEVX(V,A,";
03060 i__6[1] = 1, a__1[1] = uplo;
03061 i__6[2] = 1, a__1[2] = ")";
03062 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03063 do_fio(&c__1, ch__2, (ftnlen)13);
03064 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03065 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03066 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03067 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03068 ;
03069 e_wsfe();
03070 *info = abs(iinfo);
03071 if (iinfo < 0) {
03072 return 0;
03073 } else {
03074 result[ntest] = ulpinv;
03075 result[ntest + 1] = ulpinv;
03076 result[ntest + 2] = ulpinv;
03077 goto L1280;
03078 }
03079 }
03080
03081
03082
03083 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], ldu, &wa2[1], &
03084 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
03085 , &work[1], &result[ntest]);
03086
03087 ntest += 2;
03088
03089 if (iuplo == 1) {
03090 i__3 = n;
03091 for (j = 1; j <= i__3; ++j) {
03092
03093 i__4 = 1, i__5 = j - kd;
03094 i__7 = j;
03095 for (i__ = max(i__4,i__5); i__ <= i__7; ++i__) {
03096 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03097 a_dim1];
03098
03099 }
03100
03101 }
03102 } else {
03103 i__3 = n;
03104 for (j = 1; j <= i__3; ++j) {
03105
03106 i__4 = n, i__5 = j + kd;
03107 i__7 = min(i__4,i__5);
03108 for (i__ = j; i__ <= i__7; ++i__) {
03109 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03110
03111 }
03112
03113 }
03114 }
03115
03116 s_copy(srnamc_1.srnamt, "SSBEVX", (ftnlen)32, (ftnlen)6);
03117 ssbevx_("N", "A", uplo, &n, &kd, &v[v_offset], ldu, &u[
03118 u_offset], ldu, &vl, &vu, &il, &iu, &abstol, &m3, &
03119 wa3[1], &z__[z_offset], ldu, &work[1], &iwork[1], &
03120 iwork[n * 5 + 1], &iinfo);
03121 if (iinfo != 0) {
03122 io___93.ciunit = *nounit;
03123 s_wsfe(&io___93);
03124
03125 i__6[0] = 11, a__1[0] = "SSBEVX(N,A,";
03126 i__6[1] = 1, a__1[1] = uplo;
03127 i__6[2] = 1, a__1[2] = ")";
03128 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03129 do_fio(&c__1, ch__2, (ftnlen)13);
03130 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03131 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03132 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03133 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03134 ;
03135 e_wsfe();
03136 *info = abs(iinfo);
03137 if (iinfo < 0) {
03138 return 0;
03139 } else {
03140 result[ntest] = ulpinv;
03141 goto L1280;
03142 }
03143 }
03144
03145
03146
03147 temp1 = 0.f;
03148 temp2 = 0.f;
03149 i__3 = n;
03150 for (j = 1; j <= i__3; ++j) {
03151
03152 r__3 = temp1, r__4 = (r__1 = wa2[j], dabs(r__1)), r__3 =
03153 max(r__3,r__4), r__4 = (r__2 = wa3[j], dabs(r__2))
03154 ;
03155 temp1 = dmax(r__3,r__4);
03156
03157 r__2 = temp2, r__3 = (r__1 = wa2[j] - wa3[j], dabs(r__1));
03158 temp2 = dmax(r__2,r__3);
03159
03160 }
03161
03162 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
03163 result[ntest] = temp2 / dmax(r__1,r__2);
03164
03165 L1280:
03166 ++ntest;
03167 if (iuplo == 1) {
03168 i__3 = n;
03169 for (j = 1; j <= i__3; ++j) {
03170
03171 i__7 = 1, i__4 = j - kd;
03172 i__5 = j;
03173 for (i__ = max(i__7,i__4); i__ <= i__5; ++i__) {
03174 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03175 a_dim1];
03176
03177 }
03178
03179 }
03180 } else {
03181 i__3 = n;
03182 for (j = 1; j <= i__3; ++j) {
03183
03184 i__7 = n, i__4 = j + kd;
03185 i__5 = min(i__7,i__4);
03186 for (i__ = j; i__ <= i__5; ++i__) {
03187 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03188
03189 }
03190
03191 }
03192 }
03193
03194 s_copy(srnamc_1.srnamt, "SSBEVX", (ftnlen)32, (ftnlen)6);
03195 ssbevx_("V", "I", uplo, &n, &kd, &v[v_offset], ldu, &u[
03196 u_offset], ldu, &vl, &vu, &il, &iu, &abstol, &m2, &
03197 wa2[1], &z__[z_offset], ldu, &work[1], &iwork[1], &
03198 iwork[n * 5 + 1], &iinfo);
03199 if (iinfo != 0) {
03200 io___94.ciunit = *nounit;
03201 s_wsfe(&io___94);
03202
03203 i__6[0] = 11, a__1[0] = "SSBEVX(V,I,";
03204 i__6[1] = 1, a__1[1] = uplo;
03205 i__6[2] = 1, a__1[2] = ")";
03206 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03207 do_fio(&c__1, ch__2, (ftnlen)13);
03208 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03209 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03210 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03211 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03212 ;
03213 e_wsfe();
03214 *info = abs(iinfo);
03215 if (iinfo < 0) {
03216 return 0;
03217 } else {
03218 result[ntest] = ulpinv;
03219 result[ntest + 1] = ulpinv;
03220 result[ntest + 2] = ulpinv;
03221 goto L1370;
03222 }
03223 }
03224
03225
03226
03227 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
03228 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
03229 tau[1], &work[1], &result[ntest]);
03230
03231 ntest += 2;
03232
03233 if (iuplo == 1) {
03234 i__3 = n;
03235 for (j = 1; j <= i__3; ++j) {
03236
03237 i__5 = 1, i__7 = j - kd;
03238 i__4 = j;
03239 for (i__ = max(i__5,i__7); i__ <= i__4; ++i__) {
03240 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03241 a_dim1];
03242
03243 }
03244
03245 }
03246 } else {
03247 i__3 = n;
03248 for (j = 1; j <= i__3; ++j) {
03249
03250 i__5 = n, i__7 = j + kd;
03251 i__4 = min(i__5,i__7);
03252 for (i__ = j; i__ <= i__4; ++i__) {
03253 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03254
03255 }
03256
03257 }
03258 }
03259
03260 s_copy(srnamc_1.srnamt, "SSBEVX", (ftnlen)32, (ftnlen)6);
03261 ssbevx_("N", "I", uplo, &n, &kd, &v[v_offset], ldu, &u[
03262 u_offset], ldu, &vl, &vu, &il, &iu, &abstol, &m3, &
03263 wa3[1], &z__[z_offset], ldu, &work[1], &iwork[1], &
03264 iwork[n * 5 + 1], &iinfo);
03265 if (iinfo != 0) {
03266 io___95.ciunit = *nounit;
03267 s_wsfe(&io___95);
03268
03269 i__6[0] = 11, a__1[0] = "SSBEVX(N,I,";
03270 i__6[1] = 1, a__1[1] = uplo;
03271 i__6[2] = 1, a__1[2] = ")";
03272 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03273 do_fio(&c__1, ch__2, (ftnlen)13);
03274 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03275 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03276 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03277 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03278 ;
03279 e_wsfe();
03280 *info = abs(iinfo);
03281 if (iinfo < 0) {
03282 return 0;
03283 } else {
03284 result[ntest] = ulpinv;
03285 goto L1370;
03286 }
03287 }
03288
03289
03290
03291 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
03292 ulp, &unfl);
03293 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
03294 ulp, &unfl);
03295 if (n > 0) {
03296
03297 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
03298 temp3 = dmax(r__2,r__3);
03299 } else {
03300 temp3 = 0.f;
03301 }
03302
03303 r__1 = unfl, r__2 = temp3 * ulp;
03304 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
03305
03306 L1370:
03307 ++ntest;
03308 if (iuplo == 1) {
03309 i__3 = n;
03310 for (j = 1; j <= i__3; ++j) {
03311
03312 i__4 = 1, i__5 = j - kd;
03313 i__7 = j;
03314 for (i__ = max(i__4,i__5); i__ <= i__7; ++i__) {
03315 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03316 a_dim1];
03317
03318 }
03319
03320 }
03321 } else {
03322 i__3 = n;
03323 for (j = 1; j <= i__3; ++j) {
03324
03325 i__4 = n, i__5 = j + kd;
03326 i__7 = min(i__4,i__5);
03327 for (i__ = j; i__ <= i__7; ++i__) {
03328 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03329
03330 }
03331
03332 }
03333 }
03334
03335 s_copy(srnamc_1.srnamt, "SSBEVX", (ftnlen)32, (ftnlen)6);
03336 ssbevx_("V", "V", uplo, &n, &kd, &v[v_offset], ldu, &u[
03337 u_offset], ldu, &vl, &vu, &il, &iu, &abstol, &m2, &
03338 wa2[1], &z__[z_offset], ldu, &work[1], &iwork[1], &
03339 iwork[n * 5 + 1], &iinfo);
03340 if (iinfo != 0) {
03341 io___96.ciunit = *nounit;
03342 s_wsfe(&io___96);
03343
03344 i__6[0] = 11, a__1[0] = "SSBEVX(V,V,";
03345 i__6[1] = 1, a__1[1] = uplo;
03346 i__6[2] = 1, a__1[2] = ")";
03347 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03348 do_fio(&c__1, ch__2, (ftnlen)13);
03349 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03350 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03351 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03352 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03353 ;
03354 e_wsfe();
03355 *info = abs(iinfo);
03356 if (iinfo < 0) {
03357 return 0;
03358 } else {
03359 result[ntest] = ulpinv;
03360 result[ntest + 1] = ulpinv;
03361 result[ntest + 2] = ulpinv;
03362 goto L1460;
03363 }
03364 }
03365
03366
03367
03368 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
03369 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
03370 tau[1], &work[1], &result[ntest]);
03371
03372 ntest += 2;
03373
03374 if (iuplo == 1) {
03375 i__3 = n;
03376 for (j = 1; j <= i__3; ++j) {
03377
03378 i__7 = 1, i__4 = j - kd;
03379 i__5 = j;
03380 for (i__ = max(i__7,i__4); i__ <= i__5; ++i__) {
03381 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03382 a_dim1];
03383
03384 }
03385
03386 }
03387 } else {
03388 i__3 = n;
03389 for (j = 1; j <= i__3; ++j) {
03390
03391 i__7 = n, i__4 = j + kd;
03392 i__5 = min(i__7,i__4);
03393 for (i__ = j; i__ <= i__5; ++i__) {
03394 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03395
03396 }
03397
03398 }
03399 }
03400
03401 s_copy(srnamc_1.srnamt, "SSBEVX", (ftnlen)32, (ftnlen)6);
03402 ssbevx_("N", "V", uplo, &n, &kd, &v[v_offset], ldu, &u[
03403 u_offset], ldu, &vl, &vu, &il, &iu, &abstol, &m3, &
03404 wa3[1], &z__[z_offset], ldu, &work[1], &iwork[1], &
03405 iwork[n * 5 + 1], &iinfo);
03406 if (iinfo != 0) {
03407 io___97.ciunit = *nounit;
03408 s_wsfe(&io___97);
03409
03410 i__6[0] = 11, a__1[0] = "SSBEVX(N,V,";
03411 i__6[1] = 1, a__1[1] = uplo;
03412 i__6[2] = 1, a__1[2] = ")";
03413 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03414 do_fio(&c__1, ch__2, (ftnlen)13);
03415 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03416 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03417 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03418 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03419 ;
03420 e_wsfe();
03421 *info = abs(iinfo);
03422 if (iinfo < 0) {
03423 return 0;
03424 } else {
03425 result[ntest] = ulpinv;
03426 goto L1460;
03427 }
03428 }
03429
03430 if (m3 == 0 && n > 0) {
03431 result[ntest] = ulpinv;
03432 goto L1460;
03433 }
03434
03435
03436
03437 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
03438 ulp, &unfl);
03439 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
03440 ulp, &unfl);
03441 if (n > 0) {
03442
03443 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
03444 temp3 = dmax(r__2,r__3);
03445 } else {
03446 temp3 = 0.f;
03447 }
03448
03449 r__1 = unfl, r__2 = temp3 * ulp;
03450 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
03451
03452 L1460:
03453
03454
03455
03456 slacpy_(" ", &n, &n, &a[a_offset], lda, &v[v_offset], ldu);
03457
03458 ++ntest;
03459 s_copy(srnamc_1.srnamt, "SSYEVD", (ftnlen)32, (ftnlen)6);
03460 ssyevd_("V", uplo, &n, &a[a_offset], ldu, &d1[1], &work[1], &
03461 lwedc, &iwork[1], &liwedc, &iinfo);
03462 if (iinfo != 0) {
03463 io___98.ciunit = *nounit;
03464 s_wsfe(&io___98);
03465
03466 i__6[0] = 9, a__1[0] = "SSYEVD(V,";
03467 i__6[1] = 1, a__1[1] = uplo;
03468 i__6[2] = 1, a__1[2] = ")";
03469 s_cat(ch__3, a__1, i__6, &c__3, (ftnlen)11);
03470 do_fio(&c__1, ch__3, (ftnlen)11);
03471 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03472 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03473 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03474 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03475 ;
03476 e_wsfe();
03477 *info = abs(iinfo);
03478 if (iinfo < 0) {
03479 return 0;
03480 } else {
03481 result[ntest] = ulpinv;
03482 result[ntest + 1] = ulpinv;
03483 result[ntest + 2] = ulpinv;
03484 goto L1480;
03485 }
03486 }
03487
03488
03489
03490 ssyt21_(&c__1, uplo, &n, &c__0, &v[v_offset], ldu, &d1[1], &
03491 d2[1], &a[a_offset], ldu, &z__[z_offset], ldu, &tau[1]
03492 , &work[1], &result[ntest]);
03493
03494 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
03495
03496 ntest += 2;
03497 s_copy(srnamc_1.srnamt, "SSYEVD", (ftnlen)32, (ftnlen)6);
03498 ssyevd_("N", uplo, &n, &a[a_offset], ldu, &d3[1], &work[1], &
03499 lwedc, &iwork[1], &liwedc, &iinfo);
03500 if (iinfo != 0) {
03501 io___99.ciunit = *nounit;
03502 s_wsfe(&io___99);
03503
03504 i__6[0] = 9, a__1[0] = "SSYEVD(N,";
03505 i__6[1] = 1, a__1[1] = uplo;
03506 i__6[2] = 1, a__1[2] = ")";
03507 s_cat(ch__3, a__1, i__6, &c__3, (ftnlen)11);
03508 do_fio(&c__1, ch__3, (ftnlen)11);
03509 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03510 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03511 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03512 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03513 ;
03514 e_wsfe();
03515 *info = abs(iinfo);
03516 if (iinfo < 0) {
03517 return 0;
03518 } else {
03519 result[ntest] = ulpinv;
03520 goto L1480;
03521 }
03522 }
03523
03524
03525
03526 temp1 = 0.f;
03527 temp2 = 0.f;
03528 i__3 = n;
03529 for (j = 1; j <= i__3; ++j) {
03530
03531 r__3 = temp1, r__4 = (r__1 = d1[j], dabs(r__1)), r__3 =
03532 max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2));
03533 temp1 = dmax(r__3,r__4);
03534
03535 r__2 = temp2, r__3 = (r__1 = d1[j] - d3[j], dabs(r__1));
03536 temp2 = dmax(r__2,r__3);
03537
03538 }
03539
03540 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
03541 result[ntest] = temp2 / dmax(r__1,r__2);
03542
03543 L1480:
03544
03545
03546
03547 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
03548
03549
03550
03551
03552 if (iuplo == 1) {
03553 indx = 1;
03554 i__3 = n;
03555 for (j = 1; j <= i__3; ++j) {
03556 i__5 = j;
03557 for (i__ = 1; i__ <= i__5; ++i__) {
03558 work[indx] = a[i__ + j * a_dim1];
03559 ++indx;
03560
03561 }
03562
03563 }
03564 } else {
03565 indx = 1;
03566 i__3 = n;
03567 for (j = 1; j <= i__3; ++j) {
03568 i__5 = n;
03569 for (i__ = j; i__ <= i__5; ++i__) {
03570 work[indx] = a[i__ + j * a_dim1];
03571 ++indx;
03572
03573 }
03574
03575 }
03576 }
03577
03578 ++ntest;
03579 s_copy(srnamc_1.srnamt, "SSPEVD", (ftnlen)32, (ftnlen)6);
03580 i__3 = lwedc - indx + 1;
03581 sspevd_("V", uplo, &n, &work[1], &d1[1], &z__[z_offset], ldu,
03582 &work[indx], &i__3, &iwork[1], &liwedc, &iinfo);
03583 if (iinfo != 0) {
03584 io___100.ciunit = *nounit;
03585 s_wsfe(&io___100);
03586
03587 i__6[0] = 9, a__1[0] = "SSPEVD(V,";
03588 i__6[1] = 1, a__1[1] = uplo;
03589 i__6[2] = 1, a__1[2] = ")";
03590 s_cat(ch__3, a__1, i__6, &c__3, (ftnlen)11);
03591 do_fio(&c__1, ch__3, (ftnlen)11);
03592 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03593 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03594 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03595 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03596 ;
03597 e_wsfe();
03598 *info = abs(iinfo);
03599 if (iinfo < 0) {
03600 return 0;
03601 } else {
03602 result[ntest] = ulpinv;
03603 result[ntest + 1] = ulpinv;
03604 result[ntest + 2] = ulpinv;
03605 goto L1580;
03606 }
03607 }
03608
03609
03610
03611 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], lda, &d1[1], &
03612 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
03613 , &work[1], &result[ntest]);
03614
03615 if (iuplo == 1) {
03616 indx = 1;
03617 i__3 = n;
03618 for (j = 1; j <= i__3; ++j) {
03619 i__5 = j;
03620 for (i__ = 1; i__ <= i__5; ++i__) {
03621
03622 work[indx] = a[i__ + j * a_dim1];
03623 ++indx;
03624
03625 }
03626
03627 }
03628 } else {
03629 indx = 1;
03630 i__3 = n;
03631 for (j = 1; j <= i__3; ++j) {
03632 i__5 = n;
03633 for (i__ = j; i__ <= i__5; ++i__) {
03634 work[indx] = a[i__ + j * a_dim1];
03635 ++indx;
03636
03637 }
03638
03639 }
03640 }
03641
03642 ntest += 2;
03643 s_copy(srnamc_1.srnamt, "SSPEVD", (ftnlen)32, (ftnlen)6);
03644 i__3 = lwedc - indx + 1;
03645 sspevd_("N", uplo, &n, &work[1], &d3[1], &z__[z_offset], ldu,
03646 &work[indx], &i__3, &iwork[1], &liwedc, &iinfo);
03647 if (iinfo != 0) {
03648 io___101.ciunit = *nounit;
03649 s_wsfe(&io___101);
03650
03651 i__6[0] = 9, a__1[0] = "SSPEVD(N,";
03652 i__6[1] = 1, a__1[1] = uplo;
03653 i__6[2] = 1, a__1[2] = ")";
03654 s_cat(ch__3, a__1, i__6, &c__3, (ftnlen)11);
03655 do_fio(&c__1, ch__3, (ftnlen)11);
03656 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03657 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03658 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03659 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03660 ;
03661 e_wsfe();
03662 *info = abs(iinfo);
03663 if (iinfo < 0) {
03664 return 0;
03665 } else {
03666 result[ntest] = ulpinv;
03667 goto L1580;
03668 }
03669 }
03670
03671
03672
03673 temp1 = 0.f;
03674 temp2 = 0.f;
03675 i__3 = n;
03676 for (j = 1; j <= i__3; ++j) {
03677
03678 r__3 = temp1, r__4 = (r__1 = d1[j], dabs(r__1)), r__3 =
03679 max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2));
03680 temp1 = dmax(r__3,r__4);
03681
03682 r__2 = temp2, r__3 = (r__1 = d1[j] - d3[j], dabs(r__1));
03683 temp2 = dmax(r__2,r__3);
03684
03685 }
03686
03687 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
03688 result[ntest] = temp2 / dmax(r__1,r__2);
03689 L1580:
03690
03691
03692
03693 if (jtype <= 7) {
03694 kd = 1;
03695 } else if (jtype >= 8 && jtype <= 15) {
03696
03697 i__3 = n - 1;
03698 kd = max(i__3,0);
03699 } else {
03700 kd = ihbw;
03701 }
03702
03703
03704
03705
03706 if (iuplo == 1) {
03707 i__3 = n;
03708 for (j = 1; j <= i__3; ++j) {
03709
03710 i__5 = 1, i__7 = j - kd;
03711 i__4 = j;
03712 for (i__ = max(i__5,i__7); i__ <= i__4; ++i__) {
03713 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03714 a_dim1];
03715
03716 }
03717
03718 }
03719 } else {
03720 i__3 = n;
03721 for (j = 1; j <= i__3; ++j) {
03722
03723 i__5 = n, i__7 = j + kd;
03724 i__4 = min(i__5,i__7);
03725 for (i__ = j; i__ <= i__4; ++i__) {
03726 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03727
03728 }
03729
03730 }
03731 }
03732
03733 ++ntest;
03734 s_copy(srnamc_1.srnamt, "SSBEVD", (ftnlen)32, (ftnlen)6);
03735 ssbevd_("V", uplo, &n, &kd, &v[v_offset], ldu, &d1[1], &z__[
03736 z_offset], ldu, &work[1], &lwedc, &iwork[1], &liwedc,
03737 &iinfo);
03738 if (iinfo != 0) {
03739 io___102.ciunit = *nounit;
03740 s_wsfe(&io___102);
03741
03742 i__6[0] = 9, a__1[0] = "SSBEVD(V,";
03743 i__6[1] = 1, a__1[1] = uplo;
03744 i__6[2] = 1, a__1[2] = ")";
03745 s_cat(ch__3, a__1, i__6, &c__3, (ftnlen)11);
03746 do_fio(&c__1, ch__3, (ftnlen)11);
03747 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03748 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03749 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03750 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03751 ;
03752 e_wsfe();
03753 *info = abs(iinfo);
03754 if (iinfo < 0) {
03755 return 0;
03756 } else {
03757 result[ntest] = ulpinv;
03758 result[ntest + 1] = ulpinv;
03759 result[ntest + 2] = ulpinv;
03760 goto L1680;
03761 }
03762 }
03763
03764
03765
03766 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], lda, &d1[1], &
03767 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
03768 , &work[1], &result[ntest]);
03769
03770 if (iuplo == 1) {
03771 i__3 = n;
03772 for (j = 1; j <= i__3; ++j) {
03773
03774 i__4 = 1, i__5 = j - kd;
03775 i__7 = j;
03776 for (i__ = max(i__4,i__5); i__ <= i__7; ++i__) {
03777 v[kd + 1 + i__ - j + j * v_dim1] = a[i__ + j *
03778 a_dim1];
03779
03780 }
03781
03782 }
03783 } else {
03784 i__3 = n;
03785 for (j = 1; j <= i__3; ++j) {
03786
03787 i__4 = n, i__5 = j + kd;
03788 i__7 = min(i__4,i__5);
03789 for (i__ = j; i__ <= i__7; ++i__) {
03790 v[i__ + 1 - j + j * v_dim1] = a[i__ + j * a_dim1];
03791
03792 }
03793
03794 }
03795 }
03796
03797 ntest += 2;
03798 s_copy(srnamc_1.srnamt, "SSBEVD", (ftnlen)32, (ftnlen)6);
03799 ssbevd_("N", uplo, &n, &kd, &v[v_offset], ldu, &d3[1], &z__[
03800 z_offset], ldu, &work[1], &lwedc, &iwork[1], &liwedc,
03801 &iinfo);
03802 if (iinfo != 0) {
03803 io___103.ciunit = *nounit;
03804 s_wsfe(&io___103);
03805
03806 i__6[0] = 9, a__1[0] = "SSBEVD(N,";
03807 i__6[1] = 1, a__1[1] = uplo;
03808 i__6[2] = 1, a__1[2] = ")";
03809 s_cat(ch__3, a__1, i__6, &c__3, (ftnlen)11);
03810 do_fio(&c__1, ch__3, (ftnlen)11);
03811 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03812 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03813 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03814 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03815 ;
03816 e_wsfe();
03817 *info = abs(iinfo);
03818 if (iinfo < 0) {
03819 return 0;
03820 } else {
03821 result[ntest] = ulpinv;
03822 goto L1680;
03823 }
03824 }
03825
03826
03827
03828 temp1 = 0.f;
03829 temp2 = 0.f;
03830 i__3 = n;
03831 for (j = 1; j <= i__3; ++j) {
03832
03833 r__3 = temp1, r__4 = (r__1 = d1[j], dabs(r__1)), r__3 =
03834 max(r__3,r__4), r__4 = (r__2 = d3[j], dabs(r__2));
03835 temp1 = dmax(r__3,r__4);
03836
03837 r__2 = temp2, r__3 = (r__1 = d1[j] - d3[j], dabs(r__1));
03838 temp2 = dmax(r__2,r__3);
03839
03840 }
03841
03842 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
03843 result[ntest] = temp2 / dmax(r__1,r__2);
03844
03845 L1680:
03846
03847
03848 slacpy_(" ", &n, &n, &a[a_offset], lda, &v[v_offset], ldu);
03849 ++ntest;
03850 s_copy(srnamc_1.srnamt, "SSYEVR", (ftnlen)32, (ftnlen)6);
03851 i__3 = *liwork - (n << 1);
03852 ssyevr_("V", "A", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
03853 &iu, &abstol, &m, &wa1[1], &z__[z_offset], ldu, &
03854 iwork[1], &work[1], lwork, &iwork[(n << 1) + 1], &
03855 i__3, &iinfo);
03856 if (iinfo != 0) {
03857 io___104.ciunit = *nounit;
03858 s_wsfe(&io___104);
03859
03860 i__6[0] = 11, a__1[0] = "SSYEVR(V,A,";
03861 i__6[1] = 1, a__1[1] = uplo;
03862 i__6[2] = 1, a__1[2] = ")";
03863 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03864 do_fio(&c__1, ch__2, (ftnlen)13);
03865 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03866 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03867 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03868 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03869 ;
03870 e_wsfe();
03871 *info = abs(iinfo);
03872 if (iinfo < 0) {
03873 return 0;
03874 } else {
03875 result[ntest] = ulpinv;
03876 result[ntest + 1] = ulpinv;
03877 result[ntest + 2] = ulpinv;
03878 goto L1700;
03879 }
03880 }
03881
03882
03883
03884 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
03885
03886 ssyt21_(&c__1, uplo, &n, &c__0, &a[a_offset], ldu, &wa1[1], &
03887 d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &tau[1]
03888 , &work[1], &result[ntest]);
03889
03890 ntest += 2;
03891 s_copy(srnamc_1.srnamt, "SSYEVR", (ftnlen)32, (ftnlen)6);
03892 i__3 = *liwork - (n << 1);
03893 ssyevr_("N", "A", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
03894 &iu, &abstol, &m2, &wa2[1], &z__[z_offset], ldu, &
03895 iwork[1], &work[1], lwork, &iwork[(n << 1) + 1], &
03896 i__3, &iinfo);
03897 if (iinfo != 0) {
03898 io___105.ciunit = *nounit;
03899 s_wsfe(&io___105);
03900
03901 i__6[0] = 11, a__1[0] = "SSYEVR(N,A,";
03902 i__6[1] = 1, a__1[1] = uplo;
03903 i__6[2] = 1, a__1[2] = ")";
03904 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03905 do_fio(&c__1, ch__2, (ftnlen)13);
03906 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03907 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03908 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03909 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03910 ;
03911 e_wsfe();
03912 *info = abs(iinfo);
03913 if (iinfo < 0) {
03914 return 0;
03915 } else {
03916 result[ntest] = ulpinv;
03917 goto L1700;
03918 }
03919 }
03920
03921
03922
03923 temp1 = 0.f;
03924 temp2 = 0.f;
03925 i__3 = n;
03926 for (j = 1; j <= i__3; ++j) {
03927
03928 r__3 = temp1, r__4 = (r__1 = wa1[j], dabs(r__1)), r__3 =
03929 max(r__3,r__4), r__4 = (r__2 = wa2[j], dabs(r__2))
03930 ;
03931 temp1 = dmax(r__3,r__4);
03932
03933 r__2 = temp2, r__3 = (r__1 = wa1[j] - wa2[j], dabs(r__1));
03934 temp2 = dmax(r__2,r__3);
03935
03936 }
03937
03938 r__1 = unfl, r__2 = ulp * dmax(temp1,temp2);
03939 result[ntest] = temp2 / dmax(r__1,r__2);
03940
03941 L1700:
03942
03943 ++ntest;
03944 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
03945 s_copy(srnamc_1.srnamt, "SSYEVR", (ftnlen)32, (ftnlen)6);
03946 i__3 = *liwork - (n << 1);
03947 ssyevr_("V", "I", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
03948 &iu, &abstol, &m2, &wa2[1], &z__[z_offset], ldu, &
03949 iwork[1], &work[1], lwork, &iwork[(n << 1) + 1], &
03950 i__3, &iinfo);
03951 if (iinfo != 0) {
03952 io___106.ciunit = *nounit;
03953 s_wsfe(&io___106);
03954
03955 i__6[0] = 11, a__1[0] = "SSYEVR(V,I,";
03956 i__6[1] = 1, a__1[1] = uplo;
03957 i__6[2] = 1, a__1[2] = ")";
03958 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
03959 do_fio(&c__1, ch__2, (ftnlen)13);
03960 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
03961 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
03962 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
03963 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
03964 ;
03965 e_wsfe();
03966 *info = abs(iinfo);
03967 if (iinfo < 0) {
03968 return 0;
03969 } else {
03970 result[ntest] = ulpinv;
03971 result[ntest + 1] = ulpinv;
03972 result[ntest + 2] = ulpinv;
03973 goto L1710;
03974 }
03975 }
03976
03977
03978
03979 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
03980
03981 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
03982 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
03983 tau[1], &work[1], &result[ntest]);
03984
03985 ntest += 2;
03986 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
03987 s_copy(srnamc_1.srnamt, "SSYEVR", (ftnlen)32, (ftnlen)6);
03988 i__3 = *liwork - (n << 1);
03989 ssyevr_("N", "I", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
03990 &iu, &abstol, &m3, &wa3[1], &z__[z_offset], ldu, &
03991 iwork[1], &work[1], lwork, &iwork[(n << 1) + 1], &
03992 i__3, &iinfo);
03993 if (iinfo != 0) {
03994 io___107.ciunit = *nounit;
03995 s_wsfe(&io___107);
03996
03997 i__6[0] = 11, a__1[0] = "SSYEVR(N,I,";
03998 i__6[1] = 1, a__1[1] = uplo;
03999 i__6[2] = 1, a__1[2] = ")";
04000 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
04001 do_fio(&c__1, ch__2, (ftnlen)13);
04002 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
04003 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
04004 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
04005 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
04006 ;
04007 e_wsfe();
04008 *info = abs(iinfo);
04009 if (iinfo < 0) {
04010 return 0;
04011 } else {
04012 result[ntest] = ulpinv;
04013 goto L1710;
04014 }
04015 }
04016
04017
04018
04019 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
04020 ulp, &unfl);
04021 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
04022 ulp, &unfl);
04023
04024 r__1 = unfl, r__2 = ulp * temp3;
04025 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
04026 L1710:
04027
04028 ++ntest;
04029 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
04030 s_copy(srnamc_1.srnamt, "SSYEVR", (ftnlen)32, (ftnlen)6);
04031 i__3 = *liwork - (n << 1);
04032 ssyevr_("V", "V", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
04033 &iu, &abstol, &m2, &wa2[1], &z__[z_offset], ldu, &
04034 iwork[1], &work[1], lwork, &iwork[(n << 1) + 1], &
04035 i__3, &iinfo);
04036 if (iinfo != 0) {
04037 io___108.ciunit = *nounit;
04038 s_wsfe(&io___108);
04039
04040 i__6[0] = 11, a__1[0] = "SSYEVR(V,V,";
04041 i__6[1] = 1, a__1[1] = uplo;
04042 i__6[2] = 1, a__1[2] = ")";
04043 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
04044 do_fio(&c__1, ch__2, (ftnlen)13);
04045 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
04046 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
04047 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
04048 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
04049 ;
04050 e_wsfe();
04051 *info = abs(iinfo);
04052 if (iinfo < 0) {
04053 return 0;
04054 } else {
04055 result[ntest] = ulpinv;
04056 result[ntest + 1] = ulpinv;
04057 result[ntest + 2] = ulpinv;
04058 goto L700;
04059 }
04060 }
04061
04062
04063
04064 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
04065
04066 ssyt22_(&c__1, uplo, &n, &m2, &c__0, &a[a_offset], ldu, &wa2[
04067 1], &d2[1], &z__[z_offset], ldu, &v[v_offset], ldu, &
04068 tau[1], &work[1], &result[ntest]);
04069
04070 ntest += 2;
04071 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
04072 s_copy(srnamc_1.srnamt, "SSYEVR", (ftnlen)32, (ftnlen)6);
04073 i__3 = *liwork - (n << 1);
04074 ssyevr_("N", "V", uplo, &n, &a[a_offset], ldu, &vl, &vu, &il,
04075 &iu, &abstol, &m3, &wa3[1], &z__[z_offset], ldu, &
04076 iwork[1], &work[1], lwork, &iwork[(n << 1) + 1], &
04077 i__3, &iinfo);
04078 if (iinfo != 0) {
04079 io___109.ciunit = *nounit;
04080 s_wsfe(&io___109);
04081
04082 i__6[0] = 11, a__1[0] = "SSYEVR(N,V,";
04083 i__6[1] = 1, a__1[1] = uplo;
04084 i__6[2] = 1, a__1[2] = ")";
04085 s_cat(ch__2, a__1, i__6, &c__3, (ftnlen)13);
04086 do_fio(&c__1, ch__2, (ftnlen)13);
04087 do_fio(&c__1, (char *)&iinfo, (ftnlen)sizeof(integer));
04088 do_fio(&c__1, (char *)&n, (ftnlen)sizeof(integer));
04089 do_fio(&c__1, (char *)&jtype, (ftnlen)sizeof(integer));
04090 do_fio(&c__4, (char *)&ioldsd[0], (ftnlen)sizeof(integer))
04091 ;
04092 e_wsfe();
04093 *info = abs(iinfo);
04094 if (iinfo < 0) {
04095 return 0;
04096 } else {
04097 result[ntest] = ulpinv;
04098 goto L700;
04099 }
04100 }
04101
04102 if (m3 == 0 && n > 0) {
04103 result[ntest] = ulpinv;
04104 goto L700;
04105 }
04106
04107
04108
04109 temp1 = ssxt1_(&c__1, &wa2[1], &m2, &wa3[1], &m3, &abstol, &
04110 ulp, &unfl);
04111 temp2 = ssxt1_(&c__1, &wa3[1], &m3, &wa2[1], &m2, &abstol, &
04112 ulp, &unfl);
04113 if (n > 0) {
04114
04115 r__2 = dabs(wa1[1]), r__3 = (r__1 = wa1[n], dabs(r__1));
04116 temp3 = dmax(r__2,r__3);
04117 } else {
04118 temp3 = 0.f;
04119 }
04120
04121 r__1 = unfl, r__2 = temp3 * ulp;
04122 result[ntest] = (temp1 + temp2) / dmax(r__1,r__2);
04123
04124 slacpy_(" ", &n, &n, &v[v_offset], ldu, &a[a_offset], lda);
04125
04126
04127 }
04128
04129
04130
04131 ntestt += ntest;
04132
04133 slafts_("SST", &n, &n, &jtype, &ntest, &result[1], ioldsd, thresh,
04134 nounit, &nerrs);
04135
04136 L1730:
04137 ;
04138 }
04139
04140 }
04141
04142
04143
04144 alasvm_("SST", nounit, &nerrs, &ntestt, &c__0);
04145
04146
04147 return 0;
04148
04149
04150
04151 }