1
        2
        3
        4
        5
        6
        7
        8
        9
       10
       11
       12
       13
       14
       15
       16
       17
       18
       19
       20
       21
       22
       23
       24
       25
       26
       27
       28
       29
       30
       31
       32
       33
       34
       35
       36
       37
       38
       39
       40
       41
       42
       43
       44
       45
       46
       47
       48
       49
       50
       51
       52
       53
       54
       55
       56
       57
       58
       59
       60
       61
       62
       63
       64
       65
       66
       67
       68
       69
       70
       71
       72
       73
       74
       75
       76
       77
       78
       79
       80
       81
       82
       83
       84
       85
       86
       87
       88
       89
       90
       91
       92
       93
       94
       95
       96
       97
       98
       99
      100
      101
      102
      103
      104
      105
      106
      107
      108
      109
      110
      111
      112
      113
      114
      115
      116
      117
      118
      119
      120
      121
      122
      123
      124
      125
      126
      127
      128
      129
      130
      131
      132
      133
      134
      135
      136
      137
      138
      139
      140
      141
      142
      143
      144
      145
      146
      147
      148
      149
      150
      151
      152
      153
      154
      155
      156
      157
      158
      159
      160
      161
      162
      163
      164
      165
      166
      167
      168
      169
      170
      171
      172
      173
      174
      175
      176
      177
      178
      179
      180
      181
      182
      183
      184
      185
      186
      187
      188
      189
      190
      191
      192
      193
      194
      195
      196
      197
      198
      199
      200
      201
      202
      203
      204
      205
      206
      207
      208
      209
      210
      211
      212
      213
      214
      215
      216
      217
      218
      219
      220
      221
      222
      223
      224
      225
      226
      227
      228
      229
      230
      231
      232
      233
      234
      235
      236
      237
      238
      239
      240
      241
      242
      243
      244
      245
      246
      247
      248
      249
      250
      251
      252
      253
      254
      255
      256
      257
      258
      259
      260
      261
      262
      263
      264
      265
      266
      267
      268
      269
      270
      271
      272
      273
      274
      275
      276
      277
      278
      279
      280
      281
      282
      283
      284
      285
      286
      287
      288
      289
      290
      291
      292
      293
      294
      295
      296
      297
      298
      299
      300
      301
      302
      303
      304
      305
      306
      307
      308
      309
      310
      311
      312
      313
      314
      315
      316
      317
      318
      319
      320
      321
      322
      323
      324
      325
      326
      327
      328
      329
      330
      331
      332
      333
      334
      335
      336
      337
      338
      339
      340
      341
      342
      343
      344
      345
      346
      347
      348
      349
      350
      351
      352
      353
      354
      355
      356
      357
      358
      359
      360
      361
      362
      363
      364
      365
      366
      367
      368
      369
      370
      371
      372
      373
      374
      375
      376
      377
      378
      379
      380
      381
      382
      383
      384
      385
      386
      387
      388
      389
      390
      391
      392
      393
      394
      395
      396
      397
      398
      399
      400
      401
      402
      403
      404
      405
      406
      407
      408
      409
      410
      411
      412
      413
      414
      415
      416
      417
      418
      419
      420
      421
      422
      423
      424
      425
      426
      427
      428
      429
      430
      431
      432
      433
      434
      435
      436
      437
      438
      439
      440
      441
      442
      443
      444
      445
      446
      447
      448
      449
      450
      451
      452
      453
      454
      455
      456
      457
      458
      459
      460
      461
      462
      463
      464
      465
      466
      467
      468
      469
      470
      471
      472
      473
      474
      475
      476
      477
      478
      479
      480
      481
      482
      483
      484
      485
      486
      487
      488
      489
      490
      491
      492
      493
      494
      495
      496
      497
      498
      499
      500
      501
      502
      503
      504
      505
      506
      507
      508
      509
      510
      511
      512
      513
      514
      515
      516
      517
      518
      519
      520
      521
      522
      523
      524
      525
      526
      527
      528
      529
      530
      531
      532
      533
      534
      535
      536
      537
      538
      539
      540
      541
      542
      543
      544
      545
      546
      547
      548
      549
      550
      551
      552
      553
      554
      555
      556
      557
      558
      559
      560
      561
      562
      563
      564
      565
      566
      567
      568
      569
      570
      571
      572
      573
      574
      575
      576
      577
      578
      579
      580
      581
      582
      583
      584
      585
      586
      587
      588
      589
      590
      591
      592
      593
      594
      595
      596
      597
      598
      599
      600
      601
      602
      603
      604
      605
      606
      607
      608
      609
      610
      611
      612
      613
      614
      615
      616
      617
      618
      619
      620
      621
      622
      623
      624
      625
      626
      627
      628
      629
      630
      631
      632
      633
      634
      635
      636
      637
      638
      639
      640
      641
      642
      643
      644
      645
      646
      647
      648
      649
      650
      651
      652
      653
      654
      655
      656
      657
      658
      659
      660
      661
      662
      663
      664
      665
      666
      667
      668
      669
      670
      671
      672
      673
      674
      675
      676
      677
      678
      679
      680
      681
      682
      683
      684
      685
      686
      687
      688
      689
      690
      691
      692
      693
      694
      695
      696
      697
      698
      699
      700
      701
      702
      703
      704
      705
      706
      707
      708
      709
      710
      711
      712
      713
      714
      715
      716
      717
      718
      719
      720
      721
      722
      723
      724
      725
      726
      727
      728
      729
      730
      731
      732
      733
      734
      735
      736
      737
      738
      739
      740
      741
      742
      743
      744
      745
      746
      747
      748
      749
      750
      751
      752
      753
      754
      755
      756
      757
      758
      759
      760
      761
      762
      763
      764
      765
      766
      767
      768
      769
      770
      771
      772
      773
      774
      775
      776
      777
      778
      779
      780
      781
      782
      783
      784
      785
      786
      787
      788
      789
      790
      791
      792
      793
      794
      795
      796
      797
      798
      799
      800
      801
      802
      803
      804
      805
      806
      807
      808
      809
      810
      811
      812
      813
      814
      815
      816
      817
      818
      819
      820
      821
      822
      823
      824
      825
      826
      827
      828
      829
      830
      831
      832
      833
      834
      835
      836
      837
      838
      839
      840
      841
      842
      843
      844
      845
      846
      847
      848
      849
      850
      851
      852
      853
      854
      855
      856
      857
      858
      859
      860
      861
      862
      863
      864
      865
      866
      867
      868
      869
      870
      871
      872
      873
      874
      875
      876
      877
      878
      879
      880
      881
      882
      883
      884
      885
      886
      887
      888
      889
      890
      891
      892
      893
      894
      895
      896
      897
      898
      899
      900
      901
      902
      903
      904
      905
      906
      907
      908
      909
      910
      911
      912
      913
      914
      915
      916
      917
      918
      919
      920
      921
      922
      923
      924
      925
      926
      927
      928
      929
      930
      931
      932
      933
      934
      935
      936
      937
      938
      939
      940
      941
      942
      943
      944
      945
      946
      947
      948
      949
      950
      951
      952
      953
      954
      955
      956
      957
      958
      959
      960
      961
      962
      963
      964
      965
      966
      967
      968
      969
      970
      971
      972
      973
      974
      975
      976
      977
      978
      979
      980
      981
      982
      983
      984
      985
      986
      987
      988
      989
      990
      991
      992
      993
      994
      995
      996
      997
      998
      999
     1000
     1001
     1002
     1003
     1004
     1005
     1006
     1007
     1008
     1009
     1010
     1011
     1012
     1013
     1014
     1015
     1016
     1017
     1018
     1019
     1020
     1021
     1022
     1023
     1024
     1025
     1026
     1027
     1028
     1029
     1030
     1031
     1032
     1033
     1034
     1035
     1036
     1037
     1038
     1039
     1040
     1041
     1042
     1043
     1044
     1045
     1046
     1047
     1048
     1049
     1050
     1051
     1052
     1053
     1054
     1055
     1056
     1057
     1058
     1059
     1060
     1061
     1062
     1063
     1064
     1065
     1066
     1067
     1068
     1069
     1070
     1071
     1072
     1073
     1074
     1075
     1076
     1077
     1078
     1079
     1080
     1081
     1082
     1083
     1084
     1085
     1086
     1087
     1088
     1089
     1090
     1091
     1092
     1093
     1094
     1095
     1096
     1097
     1098
     1099
     1100
     1101
     1102
     1103
     1104
     1105
     1106
     1107
     1108
     1109
     1110
     1111
     1112
     1113
     1114
     1115
     1116
     1117
     1118
     1119
     1120
     1121
     1122
     1123
     1124
     1125
     1126
     1127
     1128
     1129
     1130
     1131
     1132
     1133
     1134
     1135
     1136
     1137
     1138
     1139
     1140
     1141
     1142
     1143
     1144
     1145
     1146
     1147
     1148
     1149
     1150
     1151
     1152
     1153
     1154
     1155
     1156
     1157
     1158
     1159
     1160
     1161
     1162
     1163
     1164
     1165
     1166
     1167
     1168
     1169
     1170
     1171
     1172
     1173
     1174
     1175
     1176
     1177
     1178
     1179
     1180
     1181
     1182
     1183
     1184
     1185
     1186
     1187
     1188
     1189
     1190
     1191
     1192
     1193
     1194
     1195
     1196
     1197
     1198
     1199
     1200
     1201
     1202
     1203
     1204
     1205
     1206
     1207
     1208
     1209
     1210
     1211
     1212
     1213
     1214
     1215
     1216
     1217
     1218
     1219
     1220
     1221
     1222
     1223
     1224
     1225
     1226
     1227
     1228
     1229
     1230
     1231
     1232
     1233
     1234
     1235
     1236
     1237
     1238
     1239
     1240
     1241
     1242
     1243
     1244
     1245
     1246
     1247
     1248
     1249
     1250
     1251
     1252
     1253
     1254
     1255
     1256
     1257
     1258
     1259
     1260
     1261
     1262
     1263
     1264
     1265
     1266
     1267
     1268
     1269
     1270
     1271
     1272
     1273
     1274
     1275
     1276
     1277
     1278
     1279
     1280
     1281
     1282
     1283
     1284
     1285
     1286
     1287
     1288
     1289
     1290
     1291
     1292
     1293
     1294
     1295
     1296
     1297
     1298
     1299
     1300
     1301
     1302
     1303
     1304
     1305
     1306
     1307
     1308
     1309
     1310
     1311
     1312
     1313
     1314
     1315
     1316
     1317
     1318
     1319
     1320
     1321
     1322
     1323
     1324
     1325
     1326
     1327
     1328
     1329
     1330
     1331
     1332
     1333
     1334
     1335
     1336
     1337
     1338
     1339
     1340
     1341
     1342
     1343
     1344
     1345
     1346
     1347
     1348
     1349
     1350
     1351
     1352
     1353
     1354
     1355
     1356
     1357
     1358
     1359
     1360
     1361
     1362
     1363
     1364
     1365
     1366
     1367
     1368
     1369
     1370
     1371
     1372
     1373
     1374
     1375
     1376
     1377
     1378
     1379
     1380
     1381
     1382
     1383
     1384
     1385
     1386
     1387
     1388
     1389
     1390
     1391
     1392
     1393
     1394
     1395
     1396
     1397
     1398
     1399
     1400
     1401
     1402
     1403
     1404
     1405
     1406
     1407
     1408
     1409
     1410
     1411
     1412
     1413
     1414
     1415
     1416
     1417
     1418
     1419
     1420
     1421
     1422
     1423
     1424
     1425
     1426
     1427
     1428
     1429
     1430
     1431
     1432
     1433
     1434
     1435
     1436
     1437
     1438
     1439
     1440
     1441
     1442
     1443
     1444
     1445
     1446
     1447
     1448
     1449
     1450
     1451
     1452
     1453
     1454
     1455
     1456
     1457
     1458
     1459
     1460
     1461
     1462
     1463
     1464
     1465
     1466
     1467
     1468
     1469
     1470
     1471
     1472
     1473
     1474
     1475
     1476
     1477
     1478
     1479
     1480
     1481
     1482
     1483
     1484
     1485
     1486
     1487
     1488
     1489
     1490
     1491
     1492
     1493
     1494
     1495
     1496
     1497
     1498
     1499
     1500
     1501
     1502
     1503
     1504
     1505
     1506
     1507
     1508
     1509
     1510
     1511
     1512
     1513
     1514
     1515
     1516
     1517
     1518
     1519
     1520
     1521
     1522
     1523
     1524
     1525
     1526
     1527
     1528
     1529
     1530
     1531
     1532
     1533
     1534
     1535
     1536
     1537
     1538
     1539
     1540
     1541
     1542
     1543
     1544
     1545
     1546
     1547
     1548
     1549
     1550
     1551
     1552
     1553
     1554
     1555
     1556
     1557
     1558
     1559
     1560
     1561
     1562
     1563
     1564
     1565
     1566
     1567
     1568
     1569
     1570
     1571
     1572
     1573
     1574
     1575
     1576
     1577
     1578
     1579
     1580
     1581
     1582
     1583
     1584
     1585
     1586
     1587
     1588
     1589
     1590
     1591
     1592
     1593
     1594
     1595
     1596
     1597
     1598
     1599
     1600
     1601
     1602
     1603
     1604
     1605
     1606
     1607
     1608
     1609
     1610
     1611
     1612
     1613
     1614
     1615
     1616
     1617
     1618
     1619
     1620
     1621
     1622
     1623
     1624
     1625
     1626
     1627
     1628
     1629
     1630
     1631
     1632
     1633
     1634
     1635
     1636
     1637
     1638
     1639
     1640
     1641
     1642
     1643
     1644
     1645
     1646
     1647
     1648
     1649
     1650
     1651
     1652
     1653
     1654
     1655
     1656
     1657
     1658
     1659
     1660
     1661
     1662
     1663
     1664
     1665
     1666
     1667
     1668
     1669
     1670
     1671
     1672
     1673
     1674
     1675
     1676
     1677
     1678
     1679
     1680
     1681
     1682
     1683
     1684
     1685
     1686
     1687
     1688
     1689
     1690
     1691
     1692
     1693
     1694
     1695
     1696
     1697
     1698
     1699
     1700
     1701
     1702
     1703
     1704
     1705
     1706
     1707
     1708
     1709
     1710
     1711
     1712
     1713
     1714
     1715
     1716
     1717
     1718
     1719
     1720
     1721
     1722
     1723
     1724
     1725
     1726
     1727
     1728
     1729
     1730
     1731
     1732
     1733
     1734
     1735
     1736
     1737
     1738
     1739
     1740
     1741
     1742
     1743
     1744
     1745
     1746
     1747
     1748
     1749
     1750
     1751
     1752
     1753
     1754
     1755
     1756
     1757
     1758
     1759
     1760
     1761
     1762
     1763
     1764
     1765
     1766
     1767
     1768
     1769
     1770
     1771
     1772
     1773
     1774
     1775
     1776
     1777
     1778
     1779
     1780
     1781
     1782
     1783
     1784
     1785
     1786
     1787
     1788
     1789
     1790
     1791
     1792
     1793
     1794
     1795
     1796
     1797
     1798
     1799
     1800
     1801
     1802
     1803
     1804
     1805
     1806
     1807
     1808
     1809
     1810
     1811
     1812
     1813
     1814
     1815
     1816
     1817
     1818
     1819
     1820
     1821
     1822
     1823
     1824
     1825
     1826
     1827
     1828
     1829
     1830
     1831
     1832
     1833
     1834
     1835
     1836
     1837
     1838
     1839
     1840
     1841
     1842
     1843
     1844
     1845
     1846
     1847
     1848
     1849
     1850
     1851
     1852
     1853
     1854
     1855
     1856
     1857
     1858
     1859
     1860
     1861
     1862
     1863
     1864
     1865
     1866
     1867
     1868
     1869
     1870
     1871
     1872
     1873
     1874
     1875
     1876
     1877
     1878
     1879
     1880
     1881
     1882
     1883
     1884
     1885
     1886
     1887
     1888
     1889
     1890
     1891
     1892
     1893
     1894
     1895
     1896
     1897
     1898
     1899
     1900
     1901
     1902
     1903
     1904
     1905
     1906
     1907
     1908
     1909
     1910
     1911
     1912
     1913
     1914
     1915
     1916
     1917
     1918
     1919
     1920
     1921
     1922
     1923
     1924
     1925
     1926
     1927
     1928
     1929
     1930
     1931
     1932
     1933
     1934
     1935
     1936
     1937
     1938
     1939
     1940
     1941
     1942
     1943
     1944
     1945
     1946
     1947
     1948
     1949
     1950
     1951
     1952
     1953
     1954
     1955
     1956
     1957
     1958
     1959
     1960
     1961
     1962
     1963
     1964
     1965
     1966
     1967
     1968
     1969
     1970
     1971
     1972
     1973
     1974
     1975
     1976
     1977
     1978
     1979
     1980
     1981
     1982
     1983
     1984
     1985
     1986
     1987
     1988
     1989
     1990
     1991
     1992
     1993
     1994
     1995
     1996
     1997
     1998
     1999
     2000
     2001
     2002
     2003
     2004
     2005
     2006
     2007
     2008
     2009
     2010
     2011
     2012
     2013
     2014
     2015
     2016
     2017
     2018
     2019
     2020
     2021
     2022
     2023
     2024
     2025
     2026
     2027
     2028
     2029
     2030
     2031
     2032
     2033
     2034
     2035
     2036
     2037
     2038
     2039
     2040
     2041
     2042
     2043
     2044
     2045
     2046
     2047
     2048
     2049
     2050
     2051
     2052
     2053
     2054
     2055
     2056
     2057
     2058
     2059
     2060
     2061
     2062
     2063
     2064
     2065
     2066
     2067
     2068
     2069
     2070
     2071
     2072
     2073
     2074
     2075
     2076
     2077
     2078
     2079
     2080
     2081
     2082
     2083
     2084
     2085
     2086
     2087
     2088
     2089
     2090
     2091
     2092
     2093
     2094
     2095
     2096
     2097
     2098
     2099
     2100
     2101
     2102
     2103
     2104
     2105
     2106
     2107
     2108
     2109
     2110
     2111
     2112
     2113
     2114
     2115
     2116
     2117
     2118
     2119
     2120
     2121
     2122
     2123
     2124
     2125
     2126
     2127
     2128
     2129
     2130
     2131
     2132
     2133
     2134
     2135
     2136
     2137
     2138
     2139
     2140
     2141
     2142
     2143
     2144
     2145
     2146
     2147
     2148
     2149
     2150
     2151
     2152
     2153
     2154
     2155
     2156
     2157
     2158
     2159
     2160
     2161
     2162
     2163
     2164
     2165
     2166
     2167
     2168
     2169
     2170
     2171
     2172
     2173
     2174
     2175
     2176
     2177
     2178
     2179
     2180
     2181
     2182
     2183
     2184
     2185
     2186
     2187
     2188
     2189
     2190
     2191
     2192
     2193
     2194
     2195
     2196
     2197
     2198
     2199
     2200
     2201
     2202
     2203
     2204
     2205
     2206
     2207
     2208
     2209
     2210
     2211
     2212
     2213
     2214
     2215
     2216
     2217
     2218
     2219
     2220
     2221
     2222
     2223
     2224
     2225
     2226
     2227
     2228
     2229
     2230
     2231
     2232
     2233
     2234
     2235
     2236
     2237
     2238
     2239
     2240
     2241
     2242
     2243
     2244
     2245
     2246
     2247
     2248
     2249
     2250
     2251
     2252
     2253
     2254
     2255
     2256
     2257
     2258
     2259
     2260
     2261
     2262
     2263
     2264
     2265
     2266
     2267
     2268
     2269
     2270
     2271
     2272
     2273
     2274
     2275
     2276
     2277
     2278
     2279
     2280
     2281
     2282
     2283
     2284
     2285
     2286
     2287
     2288
     2289
     2290
     2291
     2292
     2293
     2294
     2295
     2296
     2297
     2298
     2299
     2300
     2301
     2302
     2303
     2304
     2305
     2306
     2307
     2308
     2309
     2310
     2311
     2312
     2313
     2314
     2315
     2316
     2317
     2318
     2319
     2320
     2321
     2322
     2323
     2324
     2325
     2326
     2327
     2328
     2329
     2330
     2331
     2332
     2333
     2334
     2335
     2336
     2337
     2338
     2339
     2340
     2341
     2342
     2343
     2344
     2345
     2346
     2347
     2348
     2349
     2350
     2351
     2352
     2353
     2354
     2355
     2356
     2357
     2358
     2359
     2360
     2361
     2362
     2363
     2364
     2365
     2366
     2367
     2368
     2369
     2370
     2371
     2372
     2373
     2374
     2375
     2376
     2377
     2378
     2379
     2380
     2381
     2382
     2383
     2384
     2385
     2386
     2387
     2388
     2389
     2390
     2391
     2392
     2393
     2394
     2395
     2396
     2397
     2398
     2399
     2400
     2401
     2402
     2403
     2404
     2405
     2406
     2407
     2408
     2409
     2410
     2411
     2412
     2413
     2414
     2415
     2416
     2417
     2418
     2419
     2420
     2421
     2422
     2423
      PROGRAM DCHKEE
*
*  -- LAPACK test routine (version 3.3.0) --
*     Univ. of Tennessee, Univ. of California Berkeley and NAG Ltd..
*     January 2007
*
*  Purpose
*  =======
*
*  DCHKEE tests the DOUBLE PRECISION LAPACK subroutines for the matrix
*  eigenvalue problem.  The test paths in this version are
*
*  NEP (Nonsymmetric Eigenvalue Problem):
*      Test DGEHRD, DORGHR, DHSEQR, DTREVC, DHSEIN, and DORMHR
*
*  SEP (Symmetric Eigenvalue Problem):
*      Test DSYTRD, DORGTR, DSTEQR, DSTERF, DSTEIN, DSTEDC,
*      and drivers DSYEV(X), DSBEV(X), DSPEV(X), DSTEV(X),
*                  DSYEVD,   DSBEVD,   DSPEVD,   DSTEVD
*
*  SVD (Singular Value Decomposition):
*      Test DGEBRD, DORGBR, DBDSQR, DBDSDC
*      and the drivers DGESVD, DGESDD
*
*  DEV (Nonsymmetric Eigenvalue/eigenvector Driver):
*      Test DGEEV
*
*  DES (Nonsymmetric Schur form Driver):
*      Test DGEES
*
*  DVX (Nonsymmetric Eigenvalue/eigenvector Expert Driver):
*      Test DGEEVX
*
*  DSX (Nonsymmetric Schur form Expert Driver):
*      Test DGEESX
*
*  DGG (Generalized Nonsymmetric Eigenvalue Problem):
*      Test DGGHRD, DGGBAL, DGGBAK, DHGEQZ, and DTGEVC
*      and the driver routines DGEGS and DGEGV
*
*  DGS (Generalized Nonsymmetric Schur form Driver):
*      Test DGGES
*
*  DGV (Generalized Nonsymmetric Eigenvalue/eigenvector Driver):
*      Test DGGEV
*
*  DGX (Generalized Nonsymmetric Schur form Expert Driver):
*      Test DGGESX
*
*  DXV (Generalized Nonsymmetric Eigenvalue/eigenvector Expert Driver):
*      Test DGGEVX
*
*  DSG (Symmetric Generalized Eigenvalue Problem):
*      Test DSYGST, DSYGV, DSYGVD, DSYGVX, DSPGST, DSPGV, DSPGVD,
*      DSPGVX, DSBGST, DSBGV, DSBGVD, and DSBGVX
*
*  DSB (Symmetric Band Eigenvalue Problem):
*      Test DSBTRD
*
*  DBB (Band Singular Value Decomposition):
*      Test DGBBRD
*
*  DEC (Eigencondition estimation):
*      Test DLALN2, DLASY2, DLAEQU, DLAEXC, DTRSYL, DTREXC, DTRSNA,
*      DTRSEN, and DLAQTR
*
*  DBL (Balancing a general matrix)
*      Test DGEBAL
*
*  DBK (Back transformation on a balanced matrix)
*      Test DGEBAK
*
*  DGL (Balancing a matrix pair)
*      Test DGGBAL
*
*  DGK (Back transformation on a matrix pair)
*      Test DGGBAK
*
*  GLM (Generalized Linear Regression Model):
*      Tests DGGGLM
*
*  GQR (Generalized QR and RQ factorizations):
*      Tests DGGQRF and DGGRQF
*
*  GSV (Generalized Singular Value Decomposition):
*      Tests DGGSVD, DGGSVP, DTGSJA, DLAGS2, DLAPLL, and DLAPMT
*
*  CSD (CS decomposition):
*      Tests DORCSD
*
*  LSE (Constrained Linear Least Squares):
*      Tests DGGLSE
*
*  Each test path has a different set of inputs, but the data sets for
*  the driver routines xEV, xES, xVX, and xSX can be concatenated in a
*  single input file.  The first line of input should contain one of the
*  3-character path names in columns 1-3.  The number of remaining lines
*  depends on what is found on the first line.
*
*  The number of matrix types used in testing is often controllable from
*  the input file.  The number of matrix types for each path, and the
*  test routine that describes them, is as follows:
*
*  Path name(s)  Types    Test routine
*
*  DHS or NEP      21     DCHKHS
*  DST or SEP      21     DCHKST (routines)
*                  18     DDRVST (drivers)
*  DBD or SVD      16     DCHKBD (routines)
*                   5     DDRVBD (drivers)
*  DEV             21     DDRVEV
*  DES             21     DDRVES
*  DVX             21     DDRVVX
*  DSX             21     DDRVSX
*  DGG             26     DCHKGG (routines)
*                  26     DDRVGG (drivers)
*  DGS             26     DDRGES
*  DGX              5     DDRGSX
*  DGV             26     DDRGEV
*  DXV              2     DDRGVX
*  DSG             21     DDRVSG
*  DSB             15     DCHKSB
*  DBB             15     DCHKBB
*  DEC              -     DCHKEC
*  DBL              -     DCHKBL
*  DBK              -     DCHKBK
*  DGL              -     DCHKGL
*  DGK              -     DCHKGK
*  GLM              8     DCKGLM
*  GQR              8     DCKGQR
*  GSV              8     DCKGSV
*  CSD              3     DCKCSD
*  LSE              8     DCKLSE
*
*-----------------------------------------------------------------------
*
*  NEP input file:
*
*  line 2:  NN, INTEGER
*           Number of values of N.
*
*  line 3:  NVAL, INTEGER array, dimension (NN)
*           The values for the matrix dimension N.
*
*  line 4:  NPARMS, INTEGER
*           Number of values of the parameters NB, NBMIN, NX, NS, and
*           MAXB.
*
*  line 5:  NBVAL, INTEGER array, dimension (NPARMS)
*           The values for the blocksize NB.
*
*  line 6:  NBMIN, INTEGER array, dimension (NPARMS)
*           The values for the minimum blocksize NBMIN.
*
*  line 7:  NXVAL, INTEGER array, dimension (NPARMS)
*           The values for the crossover point NX.
*
*  line 8:  INMIN, INTEGER array, dimension (NPARMS)
*           LAHQR vs TTQRE crossover point, >= 11
*
*  line 9:  INWIN, INTEGER array, dimension (NPARMS)
*           recommended deflation window size
*
*  line 10: INIBL, INTEGER array, dimension (NPARMS)
*           nibble crossover point
*
*  line 11: ISHFTS, INTEGER array, dimension (NPARMS)
*           number of simultaneous shifts)
*
*  line 12: IACC22, INTEGER array, dimension (NPARMS)
*           select structured matrix multiply: 0, 1 or 2)
*
*  line 13: THRESH
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.  To have all of the test
*           ratios printed, use THRESH = 0.0 .
*
*  line 14: NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 14 was 2:
*
*  line 15: INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 15-EOF:  The remaining lines occur in sets of 1 or 2 and allow
*           the user to specify the matrix types.  Each line contains
*           a 3-character path name in columns 1-3, and the number
*           of matrix types must be the first nonblank item in columns
*           4-80.  If the number of matrix types is at least 1 but is
*           less than the maximum number of possible types, a second
*           line will be read to get the numbers of the matrix types to
*           be used.  For example,
*  NEP 21
*           requests all of the matrix types for the nonsymmetric
*           eigenvalue problem, while
*  NEP  4
*  9 10 11 12
*           requests only matrices of type 9, 10, 11, and 12.
*
*           The valid 3-character path names are 'NEP' or 'SHS' for the
*           nonsymmetric eigenvalue routines.
*
*-----------------------------------------------------------------------
*
*  SEP or DSG input file:
*
*  line 2:  NN, INTEGER
*           Number of values of N.
*
*  line 3:  NVAL, INTEGER array, dimension (NN)
*           The values for the matrix dimension N.
*
*  line 4:  NPARMS, INTEGER
*           Number of values of the parameters NB, NBMIN, and NX.
*
*  line 5:  NBVAL, INTEGER array, dimension (NPARMS)
*           The values for the blocksize NB.
*
*  line 6:  NBMIN, INTEGER array, dimension (NPARMS)
*           The values for the minimum blocksize NBMIN.
*
*  line 7:  NXVAL, INTEGER array, dimension (NPARMS)
*           The values for the crossover point NX.
*
*  line 8:  THRESH
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 9:  TSTCHK, LOGICAL
*           Flag indicating whether or not to test the LAPACK routines.
*
*  line 10: TSTDRV, LOGICAL
*           Flag indicating whether or not to test the driver routines.
*
*  line 11: TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 12: NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 12 was 2:
*
*  line 13: INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 13-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path names are 'SEP' or 'SST' for the
*           symmetric eigenvalue routines and driver routines, and
*           'DSG' for the routines for the symmetric generalized
*           eigenvalue problem.
*
*-----------------------------------------------------------------------
*
*  SVD input file:
*
*  line 2:  NN, INTEGER
*           Number of values of M and N.
*
*  line 3:  MVAL, INTEGER array, dimension (NN)
*           The values for the matrix row dimension M.
*
*  line 4:  NVAL, INTEGER array, dimension (NN)
*           The values for the matrix column dimension N.
*
*  line 5:  NPARMS, INTEGER
*           Number of values of the parameter NB, NBMIN, NX, and NRHS.
*
*  line 6:  NBVAL, INTEGER array, dimension (NPARMS)
*           The values for the blocksize NB.
*
*  line 7:  NBMIN, INTEGER array, dimension (NPARMS)
*           The values for the minimum blocksize NBMIN.
*
*  line 8:  NXVAL, INTEGER array, dimension (NPARMS)
*           The values for the crossover point NX.
*
*  line 9:  NSVAL, INTEGER array, dimension (NPARMS)
*           The values for the number of right hand sides NRHS.
*
*  line 10: THRESH
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 11: TSTCHK, LOGICAL
*           Flag indicating whether or not to test the LAPACK routines.
*
*  line 12: TSTDRV, LOGICAL
*           Flag indicating whether or not to test the driver routines.
*
*  line 13: TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 14: NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 14 was 2:
*
*  line 15: INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 15-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path names are 'SVD' or 'SBD' for both the
*           SVD routines and the SVD driver routines.
*
*-----------------------------------------------------------------------
*
*  DEV and DES data files:
*
*  line 1:  'DEV' or 'DES' in columns 1 to 3.
*
*  line 2:  NSIZES, INTEGER
*           Number of sizes of matrices to use. Should be at least 0
*           and at most 20. If NSIZES = 0, no testing is done
*           (although the remaining  3 lines are still read).
*
*  line 3:  NN, INTEGER array, dimension(NSIZES)
*           Dimensions of matrices to be tested.
*
*  line 4:  NB, NBMIN, NX, NS, NBCOL, INTEGERs
*           These integer parameters determine how blocking is done
*           (see ILAENV for details)
*           NB     : block size
*           NBMIN  : minimum block size
*           NX     : minimum dimension for blocking
*           NS     : number of shifts in xHSEQR
*           NBCOL  : minimum column dimension for blocking
*
*  line 5:  THRESH, REAL
*           The test threshold against which computed residuals are
*           compared. Should generally be in the range from 10. to 20.
*           If it is 0., all test case data will be printed.
*
*  line 6:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits.
*
*  line 7:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 7 was 2:
*
*  line 8:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 9 and following:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'DEV' to test SGEEV, or
*           'DES' to test SGEES.
*
*-----------------------------------------------------------------------
*
*  The DVX data has two parts. The first part is identical to DEV,
*  and the second part consists of test matrices with precomputed
*  solutions.
*
*  line 1:  'DVX' in columns 1-3.
*
*  line 2:  NSIZES, INTEGER
*           If NSIZES = 0, no testing of randomly generated examples
*           is done, but any precomputed examples are tested.
*
*  line 3:  NN, INTEGER array, dimension(NSIZES)
*
*  line 4:  NB, NBMIN, NX, NS, NBCOL, INTEGERs
*
*  line 5:  THRESH, REAL
*
*  line 6:  TSTERR, LOGICAL
*
*  line 7:  NEWSD, INTEGER
*
*  If line 7 was 2:
*
*  line 8:  INTEGER array, dimension (4)
*
*  lines 9 and following: The first line contains 'DVX' in columns 1-3
*           followed by the number of matrix types, possibly with
*           a second line to specify certain matrix types.
*           If the number of matrix types = 0, no testing of randomly
*           generated examples is done, but any precomputed examples
*           are tested.
*
*  remaining lines : Each matrix is stored on 1+2*N lines, where N is
*           its dimension. The first line contains the dimension (a
*           single integer). The next N lines contain the matrix, one
*           row per line. The last N lines correspond to each
*           eigenvalue. Each of these last N lines contains 4 real
*           values: the real part of the eigenvalue, the imaginary
*           part of the eigenvalue, the reciprocal condition number of
*           the eigenvalues, and the reciprocal condition number of the
*           eigenvector.  The end of data is indicated by dimension N=0.
*           Even if no data is to be tested, there must be at least one
*           line containing N=0.
*
*-----------------------------------------------------------------------
*
*  The DSX data is like DVX. The first part is identical to DEV, and the
*  second part consists of test matrices with precomputed solutions.
*
*  line 1:  'DSX' in columns 1-3.
*
*  line 2:  NSIZES, INTEGER
*           If NSIZES = 0, no testing of randomly generated examples
*           is done, but any precomputed examples are tested.
*
*  line 3:  NN, INTEGER array, dimension(NSIZES)
*
*  line 4:  NB, NBMIN, NX, NS, NBCOL, INTEGERs
*
*  line 5:  THRESH, REAL
*
*  line 6:  TSTERR, LOGICAL
*
*  line 7:  NEWSD, INTEGER
*
*  If line 7 was 2:
*
*  line 8:  INTEGER array, dimension (4)
*
*  lines 9 and following: The first line contains 'DSX' in columns 1-3
*           followed by the number of matrix types, possibly with
*           a second line to specify certain matrix types.
*           If the number of matrix types = 0, no testing of randomly
*           generated examples is done, but any precomputed examples
*           are tested.
*
*  remaining lines : Each matrix is stored on 3+N lines, where N is its
*           dimension. The first line contains the dimension N and the
*           dimension M of an invariant subspace. The second line
*           contains M integers, identifying the eigenvalues in the
*           invariant subspace (by their position in a list of
*           eigenvalues ordered by increasing real part). The next N
*           lines contain the matrix. The last line contains the
*           reciprocal condition number for the average of the selected
*           eigenvalues, and the reciprocal condition number for the
*           corresponding right invariant subspace. The end of data is
*           indicated by a line containing N=0 and M=0. Even if no data
*           is to be tested, there must be at least one line containing
*           N=0 and M=0.
*
*-----------------------------------------------------------------------
*
*  DGG input file:
*
*  line 2:  NN, INTEGER
*           Number of values of N.
*
*  line 3:  NVAL, INTEGER array, dimension (NN)
*           The values for the matrix dimension N.
*
*  line 4:  NPARMS, INTEGER
*           Number of values of the parameters NB, NBMIN, NS, MAXB, and
*           NBCOL.
*
*  line 5:  NBVAL, INTEGER array, dimension (NPARMS)
*           The values for the blocksize NB.
*
*  line 6:  NBMIN, INTEGER array, dimension (NPARMS)
*           The values for NBMIN, the minimum row dimension for blocks.
*
*  line 7:  NSVAL, INTEGER array, dimension (NPARMS)
*           The values for the number of shifts.
*
*  line 8:  MXBVAL, INTEGER array, dimension (NPARMS)
*           The values for MAXB, used in determining minimum blocksize.
*
*  line 9:  NBCOL, INTEGER array, dimension (NPARMS)
*           The values for NBCOL, the minimum column dimension for
*           blocks.
*
*  line 10: THRESH
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 11: TSTCHK, LOGICAL
*           Flag indicating whether or not to test the LAPACK routines.
*
*  line 12: TSTDRV, LOGICAL
*           Flag indicating whether or not to test the driver routines.
*
*  line 13: TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 14: NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 14 was 2:
*
*  line 15: INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 15-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'DGG' for the generalized
*           eigenvalue problem routines and driver routines.
*
*-----------------------------------------------------------------------
*
*  DGS and DGV input files:
*
*  line 1:  'DGS' or 'DGV' in columns 1 to 3.
*
*  line 2:  NN, INTEGER
*           Number of values of N.
*
*  line 3:  NVAL, INTEGER array, dimension(NN)
*           Dimensions of matrices to be tested.
*
*  line 4:  NB, NBMIN, NX, NS, NBCOL, INTEGERs
*           These integer parameters determine how blocking is done
*           (see ILAENV for details)
*           NB     : block size
*           NBMIN  : minimum block size
*           NX     : minimum dimension for blocking
*           NS     : number of shifts in xHGEQR
*           NBCOL  : minimum column dimension for blocking
*
*  line 5:  THRESH, REAL
*           The test threshold against which computed residuals are
*           compared. Should generally be in the range from 10. to 20.
*           If it is 0., all test case data will be printed.
*
*  line 6:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits.
*
*  line 7:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 17 was 2:
*
*  line 7:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 7-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'DGS' for the generalized
*           eigenvalue problem routines and driver routines.
*
*-----------------------------------------------------------------------
*
*  DXV input files:
*
*  line 1:  'DXV' in columns 1 to 3.
*
*  line 2:  N, INTEGER
*           Value of N.
*
*  line 3:  NB, NBMIN, NX, NS, NBCOL, INTEGERs
*           These integer parameters determine how blocking is done
*           (see ILAENV for details)
*           NB     : block size
*           NBMIN  : minimum block size
*           NX     : minimum dimension for blocking
*           NS     : number of shifts in xHGEQR
*           NBCOL  : minimum column dimension for blocking
*
*  line 4:  THRESH, REAL
*           The test threshold against which computed residuals are
*           compared. Should generally be in the range from 10. to 20.
*           Information will be printed about each test for which the
*           test ratio is greater than or equal to the threshold.
*
*  line 5:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 6:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 6 was 2:
*
*  line 7: INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  If line 2 was 0:
*
*  line 7-EOF: Precomputed examples are tested.
*
*  remaining lines : Each example is stored on 3+2*N lines, where N is
*           its dimension. The first line contains the dimension (a
*           single integer). The next N lines contain the matrix A, one
*           row per line. The next N lines contain the matrix B.  The
*           next line contains the reciprocals of the eigenvalue
*           condition numbers.  The last line contains the reciprocals of
*           the eigenvector condition numbers.  The end of data is
*           indicated by dimension N=0.  Even if no data is to be tested,
*           there must be at least one line containing N=0.
*
*-----------------------------------------------------------------------
*
*  DGX input files:
*
*  line 1:  'DGX' in columns 1 to 3.
*
*  line 2:  N, INTEGER
*           Value of N.
*
*  line 3:  NB, NBMIN, NX, NS, NBCOL, INTEGERs
*           These integer parameters determine how blocking is done
*           (see ILAENV for details)
*           NB     : block size
*           NBMIN  : minimum block size
*           NX     : minimum dimension for blocking
*           NS     : number of shifts in xHGEQR
*           NBCOL  : minimum column dimension for blocking
*
*  line 4:  THRESH, REAL
*           The test threshold against which computed residuals are
*           compared. Should generally be in the range from 10. to 20.
*           Information will be printed about each test for which the
*           test ratio is greater than or equal to the threshold.
*
*  line 5:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 6:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 6 was 2:
*
*  line 7: INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  If line 2 was 0:
*
*  line 7-EOF: Precomputed examples are tested.
*
*  remaining lines : Each example is stored on 3+2*N lines, where N is
*           its dimension. The first line contains the dimension (a
*           single integer).  The next line contains an integer k such
*           that only the last k eigenvalues will be selected and appear
*           in the leading diagonal blocks of $A$ and $B$. The next N
*           lines contain the matrix A, one row per line.  The next N
*           lines contain the matrix B.  The last line contains the
*           reciprocal of the eigenvalue cluster condition number and the
*           reciprocal of the deflating subspace (associated with the
*           selected eigencluster) condition number.  The end of data is
*           indicated by dimension N=0.  Even if no data is to be tested,
*           there must be at least one line containing N=0.
*
*-----------------------------------------------------------------------
*
*  DSB input file:
*
*  line 2:  NN, INTEGER
*           Number of values of N.
*
*  line 3:  NVAL, INTEGER array, dimension (NN)
*           The values for the matrix dimension N.
*
*  line 4:  NK, INTEGER
*           Number of values of K.
*
*  line 5:  KVAL, INTEGER array, dimension (NK)
*           The values for the matrix dimension K.
*
*  line 6:  THRESH
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 7:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 7 was 2:
*
*  line 8:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 8-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'DSB'.
*
*-----------------------------------------------------------------------
*
*  DBB input file:
*
*  line 2:  NN, INTEGER
*           Number of values of M and N.
*
*  line 3:  MVAL, INTEGER array, dimension (NN)
*           The values for the matrix row dimension M.
*
*  line 4:  NVAL, INTEGER array, dimension (NN)
*           The values for the matrix column dimension N.
*
*  line 4:  NK, INTEGER
*           Number of values of K.
*
*  line 5:  KVAL, INTEGER array, dimension (NK)
*           The values for the matrix bandwidth K.
*
*  line 6:  NPARMS, INTEGER
*           Number of values of the parameter NRHS
*
*  line 7:  NSVAL, INTEGER array, dimension (NPARMS)
*           The values for the number of right hand sides NRHS.
*
*  line 8:  THRESH
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 9:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 9 was 2:
*
*  line 10: INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 10-EOF:  Lines specifying matrix types, as for SVD.
*           The 3-character path name is 'DBB'.
*
*-----------------------------------------------------------------------
*
*  DEC input file:
*
*  line  2: THRESH, REAL
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  lines  3-EOF:
*
*  Input for testing the eigencondition routines consists of a set of
*  specially constructed test cases and their solutions.  The data
*  format is not intended to be modified by the user.
*
*-----------------------------------------------------------------------
*
*  DBL and DBK input files:
*
*  line 1:  'DBL' in columns 1-3 to test SGEBAL, or 'DBK' in
*           columns 1-3 to test SGEBAK.
*
*  The remaining lines consist of specially constructed test cases.
*
*-----------------------------------------------------------------------
*
*  DGL and DGK input files:
*
*  line 1:  'DGL' in columns 1-3 to test DGGBAL, or 'DGK' in
*           columns 1-3 to test DGGBAK.
*
*  The remaining lines consist of specially constructed test cases.
*
*-----------------------------------------------------------------------
*
*  GLM data file:
*
*  line 1:  'GLM' in columns 1 to 3.
*
*  line 2:  NN, INTEGER
*           Number of values of M, P, and N.
*
*  line 3:  MVAL, INTEGER array, dimension(NN)
*           Values of M (row dimension).
*
*  line 4:  PVAL, INTEGER array, dimension(NN)
*           Values of P (row dimension).
*
*  line 5:  NVAL, INTEGER array, dimension(NN)
*           Values of N (column dimension), note M <= N <= M+P.
*
*  line 6:  THRESH, REAL
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 7:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 8:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 8 was 2:
*
*  line 9:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 9-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'GLM' for the generalized
*           linear regression model routines.
*
*-----------------------------------------------------------------------
*
*  GQR data file:
*
*  line 1:  'GQR' in columns 1 to 3.
*
*  line 2:  NN, INTEGER
*           Number of values of M, P, and N.
*
*  line 3:  MVAL, INTEGER array, dimension(NN)
*           Values of M.
*
*  line 4:  PVAL, INTEGER array, dimension(NN)
*           Values of P.
*
*  line 5:  NVAL, INTEGER array, dimension(NN)
*           Values of N.
*
*  line 6:  THRESH, REAL
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 7:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 8:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 8 was 2:
*
*  line 9:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 9-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'GQR' for the generalized
*           QR and RQ routines.
*
*-----------------------------------------------------------------------
*
*  GSV data file:
*
*  line 1:  'GSV' in columns 1 to 3.
*
*  line 2:  NN, INTEGER
*           Number of values of M, P, and N.
*
*  line 3:  MVAL, INTEGER array, dimension(NN)
*           Values of M (row dimension).
*
*  line 4:  PVAL, INTEGER array, dimension(NN)
*           Values of P (row dimension).
*
*  line 5:  NVAL, INTEGER array, dimension(NN)
*           Values of N (column dimension).
*
*  line 6:  THRESH, REAL
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 7:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 8:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 8 was 2:
*
*  line 9:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 9-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'GSV' for the generalized
*           SVD routines.
*
*-----------------------------------------------------------------------
*
*  CSD data file:
*
*  line 1:  'CSD' in columns 1 to 3.
*
*  line 2:  NM, INTEGER
*           Number of values of M, P, and N.
*
*  line 3:  MVAL, INTEGER array, dimension(NM)
*           Values of M (row and column dimension of orthogonal matrix).
*
*  line 4:  PVAL, INTEGER array, dimension(NM)
*           Values of P (row dimension of top-left block).
*
*  line 5:  NVAL, INTEGER array, dimension(NM)
*           Values of N (column dimension of top-left block).
*
*  line 6:  THRESH, REAL
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 7:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 8:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 8 was 2:
*
*  line 9:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 9-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'CSD' for the CSD routine.
*
*-----------------------------------------------------------------------
*
*  LSE data file:
*
*  line 1:  'LSE' in columns 1 to 3.
*
*  line 2:  NN, INTEGER
*           Number of values of M, P, and N.
*
*  line 3:  MVAL, INTEGER array, dimension(NN)
*           Values of M.
*
*  line 4:  PVAL, INTEGER array, dimension(NN)
*           Values of P.
*
*  line 5:  NVAL, INTEGER array, dimension(NN)
*           Values of N, note P <= N <= P+M.
*
*  line 6:  THRESH, REAL
*           Threshold value for the test ratios.  Information will be
*           printed about each test for which the test ratio is greater
*           than or equal to the threshold.
*
*  line 7:  TSTERR, LOGICAL
*           Flag indicating whether or not to test the error exits for
*           the LAPACK routines and driver routines.
*
*  line 8:  NEWSD, INTEGER
*           A code indicating how to set the random number seed.
*           = 0:  Set the seed to a default value before each run
*           = 1:  Initialize the seed to a default value only before the
*                 first run
*           = 2:  Like 1, but use the seed values on the next line
*
*  If line 8 was 2:
*
*  line 9:  INTEGER array, dimension (4)
*           Four integer values for the random number seed.
*
*  lines 9-EOF:  Lines specifying matrix types, as for NEP.
*           The 3-character path name is 'GSV' for the generalized
*           SVD routines.
*
*-----------------------------------------------------------------------
*
*  NMAX is currently set to 132 and must be at least 12 for some of the
*  precomputed examples, and LWORK = NMAX*(5*NMAX+5)+1 in the parameter
*  statements below.  For SVD, we assume NRHS may be as big as N.  The
*  parameter NEED is set to 14 to allow for 14 N-by-N matrices for DGG.
*
*  =====================================================================
*
*     .. Parameters ..
      INTEGER            NMAX
      PARAMETER          ( NMAX = 132 )
      INTEGER            NCMAX
      PARAMETER          ( NCMAX = 20 )
      INTEGER            NEED
      PARAMETER          ( NEED = 14 )
      INTEGER            LWORK
      PARAMETER          ( LWORK = NMAX*5*NMAX+5 )+1 )
      INTEGER            LIWORK
      PARAMETER          ( LIWORK = NMAX*5*NMAX+20 ) )
      INTEGER            MAXIN
      PARAMETER          ( MAXIN = 20 )
      INTEGER            MAXT
      PARAMETER          ( MAXT = 30 )
      INTEGER            NINNOUT
      PARAMETER          ( NIN = 5NOUT = 6 )
*     ..
*     .. Local Scalars ..
      LOGICAL            CSDDBBDGGDSBFATALGLMGQRGSVLSE,
     $                   NEPDBKDBLSEPDESDEVDGKDGLDGS,
     $                   DGVDGXDSXSVDDVXDXVTSTCHKTSTDIF,
     $                   TSTDRVTSTERR
      CHARACTER          C1
      CHARACTER*3        C3PATH
      CHARACTER*32       VNAME
      CHARACTER*10       INTSTR
      CHARACTER*80       LINE
      INTEGER            II1ICINFOITMPKLENPMAXTYPNEWSD,
     $                   NKNNNPARMSNRHSNTYPES,
     $                   VERS_MAJORVERS_MINORVERS_PATCH 
      DOUBLE PRECISION   EPSS1S2THRESHTHRSHN
*     ..
*     .. Local Arrays ..
      LOGICAL            DOTYPEMAXT ), LOGWRKNMAX )
      INTEGER            IOLDSD4 ), ISEED4 ), IWORKLIWORK ),
     $                   KVALMAXIN ), MVALMAXIN ), MXBVALMAXIN ),
     $                   NBCOLMAXIN ), NBMINMAXIN ), NBVALMAXIN ),
     $                   NSVALMAXIN ), NVALMAXIN ), NXVALMAXIN ),
     $                   PVALMAXIN )
      INTEGER            INMINMAXIN ), INWINMAXIN ), INIBLMAXIN ),
     $                   ISHFTSMAXIN ), IACC22MAXIN )
      DOUBLE PRECISION   ANMAX*NMAXNEED ), BNMAX*NMAX5 ),
     $                   CNCMAX*NCMAXNCMAX*NCMAX ), DNMAX12 ),
     $                   RESULT500 ), TAUANMAX ), TAUBNMAX ),
     $                   WORKLWORK ), X5*NMAX )
*     ..
*     .. External Functions ..
      LOGICAL            LSAMEN
      DOUBLE PRECISION   DLAMCHDSECND
      EXTERNAL           LSAMENDLAMCHDSECND
*     ..
*     .. External Subroutines ..
      EXTERNAL           ALAREQDCHKBBDCHKBDDCHKBKDCHKBLDCHKEC,
     $                   DCHKGGDCHKGKDCHKGLDCHKHSDCHKSBDCHKST,
     $                   DCKCSDDCKGLMDCKGQRDCKGSVDCKLSEDDRGES,
     $                   DDRGEVDDRGSXDDRGVXDDRVBDDDRVESDDRVEV,
     $                   DDRVGGDDRVSGDDRVSTDDRVSXDDRVVXDERRBD,
     $                   DERREDDERRGGDERRHSDERRSTILAVERXLAENV
*     ..
*     .. Intrinsic Functions ..
      INTRINSIC          LENMIN
*     ..
*     .. Scalars in Common ..
      LOGICAL            LERROK
      CHARACTER*32       SRNAMT
      INTEGER            INFOTMAXBNPROCNSHIFTNUNITSELDIM,
     $                   SELOPT
*     ..
*     .. Arrays in Common ..
      LOGICAL            SELVAL20 )
      INTEGER            IPARMS100 )
      DOUBLE PRECISION   SELWI20 ), SELWR20 )
*     ..
*     .. Common blocks ..
      COMMON             / CENVIR / NPROCNSHIFTMAXB
      COMMON             / INFOC / INFOTNUNITOKLERR
      COMMON             / SRNAMC / SRNAMT
      COMMON             / SSLCT / SELOPTSELDIMSELVALSELWRSELWI
      COMMON             / CLAENV / IPARMS
*     ..
*     .. Data statements ..
      DATA               INTSTR / '0123456789' /
      DATA               IOLDSD / 0001 /
*     ..
*     .. Executable Statements ..
*
      S1 = DSECND( )
      FATAL = .FALSE.
      NUNIT = NOUT
*
*     Return to here to read multiple sets of data
*
   10 CONTINUE
*
*     Read the first line and set the 3-character test path
*
      READNIN, FMT = '(A80)', END = 380 )LINE
      PATH = LINE13 )
      NEP = LSAMEN3PATH'NEP' ) .OR. LSAMEN3PATH'DHS' )
      SEP = LSAMEN3PATH'SEP' ) .OR. LSAMEN3PATH'DST' ) .OR.
     $      LSAMEN3PATH'DSG' )
      SVD = LSAMEN3PATH'SVD' ) .OR. LSAMEN3PATH'DBD' )
      DEV = LSAMEN3PATH'DEV' )
      DES = LSAMEN3PATH'DES' )
      DVX = LSAMEN3PATH'DVX' )
      DSX = LSAMEN3PATH'DSX' )
      DGG = LSAMEN3PATH'DGG' )
      DGS = LSAMEN3PATH'DGS' )
      DGX = LSAMEN3PATH'DGX' )
      DGV = LSAMEN3PATH'DGV' )
      DXV = LSAMEN3PATH'DXV' )
      DSB = LSAMEN3PATH'DSB' )
      DBB = LSAMEN3PATH'DBB' )
      GLM = LSAMEN3PATH'GLM' )
      GQR = LSAMEN3PATH'GQR' ) .OR. LSAMEN3PATH'GRQ' )
      GSV = LSAMEN3PATH'GSV' )
      CSD = LSAMEN3PATH'CSD' )
      LSE = LSAMEN3PATH'LSE' )
      DBL = LSAMEN3PATH'DBL' )
      DBK = LSAMEN3PATH'DBK' )
      DGL = LSAMEN3PATH'DGL' )
      DGK = LSAMEN3PATH'DGK' )
*
*     Report values of parameters.
*
      IFPATH.EQ.'   ' ) THEN
         GO TO 10
      ELSE IFNEP ) THEN
         WRITENOUT, FMT = 9987 )
      ELSE IFSEP ) THEN
         WRITENOUT, FMT = 9986 )
      ELSE IFSVD ) THEN
         WRITENOUT, FMT = 9985 )
      ELSE IFDEV ) THEN
         WRITENOUT, FMT = 9979 )
      ELSE IFDES ) THEN
         WRITENOUT, FMT = 9978 )
      ELSE IFDVX ) THEN
         WRITENOUT, FMT = 9977 )
      ELSE IFDSX ) THEN
         WRITENOUT, FMT = 9976 )
      ELSE IFDGG ) THEN
         WRITENOUT, FMT = 9975 )
      ELSE IFDGS ) THEN
         WRITENOUT, FMT = 9964 )
      ELSE IFDGX ) THEN
         WRITENOUT, FMT = 9965 )
      ELSE IFDGV ) THEN
         WRITENOUT, FMT = 9963 )
      ELSE IFDXV ) THEN
         WRITENOUT, FMT = 9962 )
      ELSE IFDSB ) THEN
         WRITENOUT, FMT = 9974 )
      ELSE IFDBB ) THEN
         WRITENOUT, FMT = 9967 )
      ELSE IFGLM ) THEN
         WRITENOUT, FMT = 9971 )
      ELSE IFGQR ) THEN
         WRITENOUT, FMT = 9970 )
      ELSE IFGSV ) THEN
         WRITENOUT, FMT = 9969 )
      ELSE IFCSD ) THEN
         WRITENOUT, FMT = 9960 )
      ELSE IFLSE ) THEN
         WRITENOUT, FMT = 9968 )
      ELSE IFDBL ) THEN
*
*        DGEBAL:  Balancing
*
         CALL DCHKBLNINNOUT )
         GO TO 10
      ELSE IFDBK ) THEN
*
*        DGEBAK:  Back transformation
*
         CALL DCHKBKNINNOUT )
         GO TO 10
      ELSE IFDGL ) THEN
*
*        DGGBAL:  Balancing
*
         CALL DCHKGLNINNOUT )
         GO TO 10
      ELSE IFDGK ) THEN
*
*        DGGBAK:  Back transformation
*
         CALL DCHKGKNINNOUT )
         GO TO 10
      ELSE IFLSAMEN3PATH'DEC' ) ) THEN
*
*        DEC:  Eigencondition estimation
*
         READNIN, FMT = * )THRESH
         CALL XLAENV11 )
         CALL XLAENV1211 )
         CALL XLAENV132 )
         CALL XLAENV140 )
         CALL XLAENV152 )
         CALL XLAENV162 )
         TSTERR = .TRUE.
         CALL DCHKECTHRESHTSTERRNINNOUT )
         GO TO 10
      ELSE
         WRITENOUT, FMT = 9992 )PATH
         GO TO 10
      END IF
      CALL ILAVERVERS_MAJORVERS_MINORVERS_PATCH )
      WRITENOUT, FMT = 9972 ) VERS_MAJOR, VERS_MINOR, VERS_PATCH
      WRITENOUT, FMT = 9984 )
*
*     Read the number of values of M, P, and N.
*
      READNIN, FMT = * )NN
      IFNN.LT.0 ) THEN
         WRITENOUT, FMT = 9989 )'   NN ', NN, 1
         NN = 0
         FATAL = .TRUE.
      ELSE IFNN.GT.MAXIN ) THEN
         WRITENOUT, FMT = 9988 )'   NN ', NN, MAXIN
         NN = 0
         FATAL = .TRUE.
      END IF
*
*     Read the values of M
*
      IF.NOT.DGX .OR. DXV ) ) THEN
         READNIN, FMT = * )( MVAL( I ), I = 1, NN )
         IFSVD ) THEN
            VNAME = '    M '
         ELSE
            VNAME = '    N '
         END IF
         DO 20 I = 1NN
            IFMVALI ).LT.0 ) THEN
               WRITENOUT, FMT = 9989 )VNAME, MVAL( I ), 0
               FATAL = .TRUE.
            ELSE IFMVALI ).GT.NMAX ) THEN
               WRITENOUT, FMT = 9988 )VNAME, MVAL( I ), NMAX
               FATAL = .TRUE.
            END IF
   20    CONTINUE
         WRITENOUT, FMT = 9983 )'M:    ', ( MVAL( I ), I = 1, NN )
      END IF
*
*     Read the values of P
*
      IFGLM .OR. GQR .OR. GSV .OR. CSD .OR. LSE ) THEN
         READNIN, FMT = * )( PVAL( I ), I = 1, NN )
         DO 30 I = 1NN
            IFPVALI ).LT.0 ) THEN
               WRITENOUT, FMT = 9989 )' P  ', PVAL( I ), 0
               FATAL = .TRUE.
            ELSE IFPVALI ).GT.NMAX ) THEN
               WRITENOUT, FMT = 9988 )' P  ', PVAL( I ), NMAX
               FATAL = .TRUE.
            END IF
   30    CONTINUE
         WRITENOUT, FMT = 9983 )'P:    ', ( PVAL( I ), I = 1, NN )
      END IF
*
*     Read the values of N
*
      IFSVD .OR. DBB .OR. GLM .OR. GQR .OR. GSV .OR. CSD .OR.
     $    LSE ) THEN
         READNIN, FMT = * )( NVAL( I ), I = 1, NN )
         DO 40 I = 1NN
            IFNVALI ).LT.0 ) THEN
               WRITENOUT, FMT = 9989 )'    N ', NVAL( I ), 0
               FATAL = .TRUE.
            ELSE IFNVALI ).GT.NMAX ) THEN
               WRITENOUT, FMT = 9988 )'    N ', NVAL( I ), NMAX
               FATAL = .TRUE.
            END IF
   40    CONTINUE
      ELSE
         DO 50 I = 1NN
            NVALI ) = MVALI )
   50    CONTINUE
      END IF
      IF.NOT.DGX .OR. DXV ) ) THEN
         WRITENOUT, FMT = 9983 )'N:    ', ( NVAL( I ), I = 1, NN )
      ELSE
         WRITENOUT, FMT = 9983 )'N:    ', NN
      END IF
*
*     Read the number of values of K, followed by the values of K
*
      IFDSB .OR. DBB ) THEN
         READNIN, FMT = * )NK
         READNIN, FMT = * )( KVAL( I ), I = 1, NK )
         DO 60 I = 1NK
            IFKVALI ).LT.0 ) THEN
               WRITENOUT, FMT = 9989 )'    K ', KVAL( I ), 0
               FATAL = .TRUE.
            ELSE IFKVALI ).GT.NMAX ) THEN
               WRITENOUT, FMT = 9988 )'    K ', KVAL( I ), NMAX
               FATAL = .TRUE.
            END IF
   60    CONTINUE
         WRITENOUT, FMT = 9983 )'K:    ', ( KVAL( I ), I = 1, NK )
      END IF
*
      IFDEV .OR. DES .OR. DVX .OR. DSX ) THEN
*
*        For the nonsymmetric QR driver routines, only one set of
*        parameters is allowed.
*
         READNIN, FMT = * )NBVAL( 1 ), NBMIN( 1 ), NXVAL( 1 ),
     $      INMIN( 1 ), INWIN( 1 ), INIBL(1), ISHFTS(1), IACC22(1)
         IFNBVAL1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   NB ', NBVAL( 1 ), 1
            FATAL = .TRUE.
         ELSE IFNBMIN1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'NBMIN ', NBMIN( 1 ), 1
            FATAL = .TRUE.
         ELSE IFNXVAL1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   NX ', NXVAL( 1 ), 1
            FATAL = .TRUE.
         ELSE IFINMIN1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   INMIN ', INMIN( 1 ), 1
            FATAL = .TRUE.
         ELSE IFINWIN1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   INWIN ', INWIN( 1 ), 1
            FATAL = .TRUE.
         ELSE IFINIBL1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   INIBL ', INIBL( 1 ), 1
            FATAL = .TRUE.
         ELSE IFISHFTS1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   ISHFTS ', ISHFTS( 1 ), 1
            FATAL = .TRUE.
         ELSE IFIACC221 ).LT.0 ) THEN
            WRITENOUT, FMT = 9989 )'   IACC22 ', IACC22( 1 ), 0
            FATAL = .TRUE.
         END IF
         CALL XLAENV1NBVAL1 ) )
         CALL XLAENV2NBMIN1 ) )
         CALL XLAENV3NXVAL1 ) )
         CALL XLAENV(12, MAX( 11INMIN1 ) ) )
         CALL XLAENV(13INWIN1 ) )
         CALL XLAENV(14INIBL1 ) )
         CALL XLAENV(15ISHFTS1 ) )
         CALL XLAENV(16IACC221 ) )
         WRITENOUT, FMT = 9983 )'NB:   ', NBVAL( 1 )
         WRITENOUT, FMT = 9983 )'NBMIN:', NBMIN( 1 )
         WRITENOUT, FMT = 9983 )'NX:   ', NXVAL( 1 )
         WRITENOUT, FMT = 9983 )'INMIN:   ', INMIN( 1 )
         WRITENOUT, FMT = 9983 )'INWIN: ', INWIN( 1 )
         WRITENOUT, FMT = 9983 )'INIBL: ', INIBL( 1 )
         WRITENOUT, FMT = 9983 )'ISHFTS: ', ISHFTS( 1 )
         WRITENOUT, FMT = 9983 )'IACC22: ', IACC22( 1 )
*
      ELSEIFDGS .OR. DGX .OR. DGV .OR.  DXV ) THEN
*
*        For the nonsymmetric generalized driver routines, only one set
*        of parameters is allowed.
*
         READNIN, FMT = * )NBVAL( 1 ), NBMIN( 1 ), NXVAL( 1 ),
     $      NSVAL( 1 ), MXBVAL( 1 )
         IFNBVAL1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   NB ', NBVAL( 1 ), 1
            FATAL = .TRUE.
         ELSE IFNBMIN1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'NBMIN ', NBMIN( 1 ), 1
            FATAL = .TRUE.
         ELSE IFNXVAL1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'   NX ', NXVAL( 1 ), 1
            FATAL = .TRUE.
         ELSE IFNSVAL1 ).LT.2 ) THEN
            WRITENOUT, FMT = 9989 )'   NS ', NSVAL( 1 ), 2
            FATAL = .TRUE.
         ELSE IFMXBVAL1 ).LT.1 ) THEN
            WRITENOUT, FMT = 9989 )' MAXB ', MXBVAL( 1 ), 1
            FATAL = .TRUE.
         END IF
         CALL XLAENV1NBVAL1 ) )
         CALL XLAENV2NBMIN1 ) )
         CALL XLAENV3NXVAL1 ) )
         CALL XLAENV4NSVAL1 ) )
         CALL XLAENV8MXBVAL1 ) )
         WRITENOUT, FMT = 9983 )'NB:   ', NBVAL( 1 )
         WRITENOUT, FMT = 9983 )'NBMIN:', NBMIN( 1 )
         WRITENOUT, FMT = 9983 )'NX:   ', NXVAL( 1 )
         WRITENOUT, FMT = 9983 )'NS:   ', NSVAL( 1 )
         WRITENOUT, FMT = 9983 )'MAXB: ', MXBVAL( 1 )
*
      ELSE IF.NOT.DSB .AND. .NOT.GLM .AND. .NOT.GQR .AND. .NOT.
     $         GSV .AND. .NOT.CSD .AND. .NOT.LSE ) THEN
*
*        For the other paths, the number of parameters can be varied
*        from the input file.  Read the number of parameter values.
*
         READNIN, FMT = * )NPARMS
         IFNPARMS.LT.1 ) THEN
            WRITENOUT, FMT = 9989 )'NPARMS', NPARMS, 1
            NPARMS = 0
            FATAL = .TRUE.
         ELSE IFNPARMS.GT.MAXIN ) THEN
            WRITENOUT, FMT = 9988 )'NPARMS', NPARMS, MAXIN
            NPARMS = 0
            FATAL = .TRUE.
         END IF
*
*        Read the values of NB
*
         IF.NOT.DBB ) THEN
            READNIN, FMT = * )( NBVAL( I ), I = 1, NPARMS )
            DO 70 I = 1NPARMS
               IFNBVALI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )'   NB ', NBVAL( I ), 0
                  FATAL = .TRUE.
               ELSE IFNBVALI ).GT.NMAX ) THEN
                  WRITENOUT, FMT = 9988 )'   NB ', NBVAL( I ), NMAX
                  FATAL = .TRUE.
               END IF
   70       CONTINUE
            WRITENOUT, FMT = 9983 )'NB:   ',
     $         ( NBVAL( I ), I = 1, NPARMS )
         END IF
*
*        Read the values of NBMIN
*
         IFNEP .OR. SEP .OR. SVD .OR. DGG ) THEN
            READNIN, FMT = * )( NBMIN( I ), I = 1, NPARMS )
            DO 80 I = 1NPARMS
               IFNBMINI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )'NBMIN ', NBMIN( I ), 0
                  FATAL = .TRUE.
               ELSE IFNBMINI ).GT.NMAX ) THEN
                  WRITENOUT, FMT = 9988 )'NBMIN ', NBMIN( I ), NMAX
                  FATAL = .TRUE.
               END IF
   80       CONTINUE
            WRITENOUT, FMT = 9983 )'NBMIN:',
     $         ( NBMIN( I ), I = 1, NPARMS )
         ELSE
            DO 90 I = 1NPARMS
               NBMINI ) = 1
   90       CONTINUE
         END IF
*
*        Read the values of NX
*
         IFNEP .OR. SEP .OR. SVD ) THEN
            READNIN, FMT = * )( NXVAL( I ), I = 1, NPARMS )
            DO 100 I = 1NPARMS
               IFNXVALI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )'   NX ', NXVAL( I ), 0
                  FATAL = .TRUE.
               ELSE IFNXVALI ).GT.NMAX ) THEN
                  WRITENOUT, FMT = 9988 )'   NX ', NXVAL( I ), NMAX
                  FATAL = .TRUE.
               END IF
  100       CONTINUE
            WRITENOUT, FMT = 9983 )'NX:   ',
     $         ( NXVAL( I ), I = 1, NPARMS )
         ELSE
            DO 110 I = 1NPARMS
               NXVALI ) = 1
  110       CONTINUE
         END IF
*
*        Read the values of NSHIFT (if DGG) or NRHS (if SVD
*        or DBB).
*
         IFSVD .OR. DBB .OR. DGG ) THEN
            READNIN, FMT = * )( NSVAL( I ), I = 1, NPARMS )
            DO 120 I = 1NPARMS
               IFNSVALI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )'   NS ', NSVAL( I ), 0
                  FATAL = .TRUE.
               ELSE IFNSVALI ).GT.NMAX ) THEN
                  WRITENOUT, FMT = 9988 )'   NS ', NSVAL( I ), NMAX
                  FATAL = .TRUE.
               END IF
  120       CONTINUE
            WRITENOUT, FMT = 9983 )'NS:   ',
     $         ( NSVAL( I ), I = 1, NPARMS )
         ELSE
            DO 130 I = 1NPARMS
               NSVALI ) = 1
  130       CONTINUE
         END IF
*
*        Read the values for MAXB.
*
         IFDGG ) THEN
            READNIN, FMT = * )( MXBVAL( I ), I = 1, NPARMS )
            DO 140 I = 1NPARMS
               IFMXBVALI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )' MAXB ', MXBVAL( I ), 0
                  FATAL = .TRUE.
               ELSE IFMXBVALI ).GT.NMAX ) THEN
                  WRITENOUT, FMT = 9988 )' MAXB ', MXBVAL( I ), NMAX
                  FATAL = .TRUE.
               END IF
  140       CONTINUE
            WRITENOUT, FMT = 9983 )'MAXB: ',
     $         ( MXBVAL( I ), I = 1, NPARMS )
         ELSE
            DO 150 I = 1NPARMS
               MXBVALI ) = 1
  150       CONTINUE
         END IF
*
*        Read the values for INMIN.
*
         IFNEP ) THEN
            READNIN, FMT = * )( INMIN( I ), I = 1, NPARMS )
            DO 540 I = 1NPARMS
               IFINMINI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )' INMIN ', INMIN( I ), 0
                  FATAL = .TRUE.
               END IF
  540       CONTINUE
            WRITENOUT, FMT = 9983 )'INMIN: ',
     $         ( INMIN( I ), I = 1, NPARMS )
         ELSE
            DO 550 I = 1NPARMS
               INMINI ) = 1
  550       CONTINUE
         END IF
*
*        Read the values for INWIN.
*
         IFNEP ) THEN
            READNIN, FMT = * )( INWIN( I ), I = 1, NPARMS )
            DO 560 I = 1NPARMS
               IFINWINI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )' INWIN ', INWIN( I ), 0
                  FATAL = .TRUE.
               END IF
  560       CONTINUE
            WRITENOUT, FMT = 9983 )'INWIN: ',
     $         ( INWIN( I ), I = 1, NPARMS )
         ELSE
            DO 570 I = 1NPARMS
               INWINI ) = 1
  570       CONTINUE
         END IF
*
*        Read the values for INIBL.
*
         IFNEP ) THEN
            READNIN, FMT = * )( INIBL( I ), I = 1, NPARMS )
            DO 580 I = 1NPARMS
               IFINIBLI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )' INIBL ', INIBL( I ), 0
                  FATAL = .TRUE.
               END IF
  580       CONTINUE
            WRITENOUT, FMT = 9983 )'INIBL: ',
     $         ( INIBL( I ), I = 1, NPARMS )
         ELSE
            DO 590 I = 1NPARMS
               INIBLI ) = 1
  590       CONTINUE
         END IF
*
*        Read the values for ISHFTS.
*
         IFNEP ) THEN
            READNIN, FMT = * )( ISHFTS( I ), I = 1, NPARMS )
            DO 600 I = 1NPARMS
               IFISHFTSI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )' ISHFTS ', ISHFTS( I ), 0
                  FATAL = .TRUE.
               END IF
  600       CONTINUE
            WRITENOUT, FMT = 9983 )'ISHFTS: ',
     $         ( ISHFTS( I ), I = 1, NPARMS )
         ELSE
            DO 610 I = 1NPARMS
               ISHFTSI ) = 1
  610       CONTINUE
         END IF
*
*        Read the values for IACC22.
*
         IFNEP ) THEN
            READNIN, FMT = * )( IACC22( I ), I = 1, NPARMS )
            DO 620 I = 1NPARMS
               IFIACC22I ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )' IACC22 ', IACC22( I ), 0
                  FATAL = .TRUE.
               END IF
  620       CONTINUE
            WRITENOUT, FMT = 9983 )'IACC22: ',
     $         ( IACC22( I ), I = 1, NPARMS )
         ELSE
            DO 630 I = 1NPARMS
               IACC22I ) = 1
  630       CONTINUE
         END IF
*
*        Read the values for NBCOL.
*
         IFDGG ) THEN
            READNIN, FMT = * )( NBCOL( I ), I = 1, NPARMS )
            DO 160 I = 1NPARMS
               IFNBCOLI ).LT.0 ) THEN
                  WRITENOUT, FMT = 9989 )'NBCOL ', NBCOL( I ), 0
                  FATAL = .TRUE.
               ELSE IFNBCOLI ).GT.NMAX ) THEN
                  WRITENOUT, FMT = 9988 )'NBCOL ', NBCOL( I ), NMAX
                  FATAL = .TRUE.
               END IF
  160       CONTINUE
            WRITENOUT, FMT = 9983 )'NBCOL:',
     $         ( NBCOL( I ), I = 1, NPARMS )
         ELSE
            DO 170 I = 1NPARMS
               NBCOLI ) = 1
  170       CONTINUE
         END IF
      END IF
*
*     Calculate and print the machine dependent constants.
*
      WRITENOUT, FMT = * )
      EPS = DLAMCH'Underflow threshold' )
      WRITENOUT, FMT = 9981 )'underflow', EPS
      EPS = DLAMCH'Overflow threshold' )
      WRITENOUT, FMT = 9981 )'overflow ', EPS
      EPS = DLAMCH'Epsilon' )
      WRITENOUT, FMT = 9981 )'precision', EPS
*
*     Read the threshold value for the test ratios.
*
      READNIN, FMT = * )THRESH
      WRITENOUT, FMT = 9982 )THRESH
      IFSEP .OR. SVD .OR. DGG ) THEN
*
*        Read the flag that indicates whether to test LAPACK routines.
*
         READNIN, FMT = * )TSTCHK
*
*        Read the flag that indicates whether to test driver routines.
*
         READNIN, FMT = * )TSTDRV
      END IF
*
*     Read the flag that indicates whether to test the error exits.
*
      READNIN, FMT = * )TSTERR
*
*     Read the code describing how to set the random number seed.
*
      READNIN, FMT = * )NEWSD
*
*     If NEWSD = 2, read another line with 4 integers for the seed.
*
      IFNEWSD.EQ.2 )
     $   READNIN, FMT = * )( IOLDSD( I ), I = 14 )
*
      DO 180 I = 14
         ISEEDI ) = IOLDSDI )
  180 CONTINUE
*
      IFFATAL ) THEN
         WRITENOUT, FMT = 9999 )
         STOP
      END IF
*
*     Read the input lines indicating the test path and its parameters.
*     The first three characters indicate the test path, and the number
*     of test matrix types must be the first nonblank item in columns
*     4-80.
*
  190 CONTINUE
*
      IF.NOT.DGX .OR. DXV ) ) THEN
*
  200    CONTINUE
         READNIN, FMT = '(A80)', END = 380 )LINE
         C3 = LINE13 )
         LENP = LENLINE )
         I = 3
         ITMP = 0
         I1 = 0
  210    CONTINUE
         I = I + 1
         IFI.GT.LENP ) THEN
            IFI1.GT.0 ) THEN
               GO TO 240
            ELSE
               NTYPES = MAXT
               GO TO 240
            END IF
         END IF
         IFLINEII ).NE.' ' .AND. LINEII ).NE.',' ) THEN
            I1 = I
            C1 = LINEI1I1 )
*
*        Check that a valid integer was read
*
            DO 220 K = 110
               IFC1.EQ.INTSTRKK ) ) THEN
                  IC = K - 1
                  GO TO 230
               END IF
  220       CONTINUE
            WRITENOUT, FMT = 9991 )I, LINE
            GO TO 200
  230       CONTINUE
            ITMP = 10*ITMP + IC
            GO TO 210
         ELSE IFI1.GT.0 ) THEN
            GO TO 240
         ELSE
            GO TO 210
         END IF
  240    CONTINUE
         NTYPES = ITMP
*
*     Skip the tests if NTYPES is <= 0.
*
         IF.NOT.DEV .OR. DES .OR. DVX .OR. DSX .OR. DGV .OR.
     $       DGS ) .AND. NTYPES.LE.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
            GO TO 200
         END IF
*
      ELSE
         IFDXV )
     $      C3 = 'DXV'
         IFDGX )
     $      C3 = 'DGX'
      END IF
*
*     Reset the random number seed.
*
      IFNEWSD.EQ.0 ) THEN
         DO 250 K = 14
            ISEEDK ) = IOLDSDK )
  250    CONTINUE
      END IF
*
      IFLSAMEN3C3'DHS' ) .OR. LSAMEN3C3'NEP' ) ) THEN
*
*        -------------------------------------
*        NEP:  Nonsymmetric Eigenvalue Problem
*        -------------------------------------
*        Vary the parameters
*           NB    = block size
*           NBMIN = minimum block size
*           NX    = crossover point
*           NS    = number of shifts
*           MAXB  = minimum submatrix size
*
         MAXTYP = 21
         NTYPES = MINMAXTYPNTYPES )
         CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
         CALL XLAENV11 )
         IFTSTERR )
     $      CALL DERRHS'DHSEQR'NOUT )
         DO 270 I = 1NPARMS
            CALL XLAENV1NBVALI ) )
            CALL XLAENV2NBMINI ) )
            CALL XLAENV3NXVALI ) )
            CALL XLAENV(12, MAX( 11INMINI ) ) )
            CALL XLAENV(13INWINI ) )
            CALL XLAENV(14INIBLI ) )
            CALL XLAENV(15ISHFTSI ) )
            CALL XLAENV(16IACC22I ) )
*
            IFNEWSD.EQ.0 ) THEN
               DO 260 K = 14
                  ISEEDK ) = IOLDSDK )
  260          CONTINUE
            END IF
            WRITENOUT, FMT = 9961 )C3, NBVAL( I ), NBMIN( I ),
     $         NXVAL( I ), MAX( 11, INMIN(I)),
     $         INWIN( I ), INIBL( I ), ISHFTS( I ), IACC22( I )
            CALL DCHKHSNNNVALMAXTYPDOTYPEISEEDTHRESHNOUT,
     $                   A11 ), NMAXA12 ), A13 ),
     $                   A14 ), A15 ), NMAXA16 ),
     $                   A17 ), D11 ), D12 ), D13 ),
     $                   D14 ), A18 ), A19 ), A110 ),
     $                   A111 ), A112 ), D15 ), WORKLWORK,
     $                   IWORKLOGWRKRESULTINFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DCHKHS', INFO
  270    CONTINUE
*
      ELSE IFLSAMEN3C3'DST' ) .OR. LSAMEN3C3'SEP' ) ) THEN
*
*        ----------------------------------
*        SEP:  Symmetric Eigenvalue Problem
*        ----------------------------------
*        Vary the parameters
*           NB    = block size
*           NBMIN = minimum block size
*           NX    = crossover point
*
         MAXTYP = 21
         NTYPES = MINMAXTYPNTYPES )
         CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
         CALL XLAENV11 )
         CALL XLAENV925 )
         IFTSTERR )
     $      CALL DERRST'DST'NOUT )
         DO 290 I = 1NPARMS
            CALL XLAENV1NBVALI ) )
            CALL XLAENV2NBMINI ) )
            CALL XLAENV3NXVALI ) )
*
            IFNEWSD.EQ.0 ) THEN
               DO 280 K = 14
                  ISEEDK ) = IOLDSDK )
  280          CONTINUE
            END IF
            WRITENOUT, FMT = 9997 )C3, NBVAL( I ), NBMIN( I ),
     $         NXVAL( I )
            IFTSTCHK ) THEN
               CALL DCHKSTNNNVALMAXTYPDOTYPEISEEDTHRESH,
     $                      NOUTA11 ), NMAXA12 ), D11 ),
     $                      D12 ), D13 ), D14 ), D15 ),
     $                      D16 ), D17 ), D18 ), D19 ),
     $                      D110 ), D111 ), A13 ), NMAX,
     $                      A14 ), A15 ), D112 ), A16 ),
     $                      WORKLWORKIWORKLIWORKRESULTINFO )
               IFINFO.NE.0 )
     $            WRITENOUT, FMT = 9980 )'DCHKST', INFO
            END IF
            IFTSTDRV ) THEN
               CALL DDRVSTNNNVAL18DOTYPEISEEDTHRESHNOUT,
     $                      A11 ), NMAXD13 ), D14 ),
     $                      D15 ), D16 ), D18 ), D19 ),
     $                      D110 ), D111 ), A12 ), NMAX,
     $                      A13 ), D112 ), A14 ), WORK,
     $                      LWORKIWORKLIWORKRESULTINFO )
               IFINFO.NE.0 )
     $            WRITENOUT, FMT = 9980 )'DDRVST', INFO
            END IF
  290    CONTINUE
*
      ELSE IFLSAMEN3C3'DSG' ) ) THEN
*
*        ----------------------------------------------
*        DSG:  Symmetric Generalized Eigenvalue Problem
*        ----------------------------------------------
*        Vary the parameters
*           NB    = block size
*           NBMIN = minimum block size
*           NX    = crossover point
*
         MAXTYP = 21
         NTYPES = MINMAXTYPNTYPES )
         CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
         CALL XLAENV925 )
         DO 310 I = 1NPARMS
            CALL XLAENV1NBVALI ) )
            CALL XLAENV2NBMINI ) )
            CALL XLAENV3NXVALI ) )
*
            IFNEWSD.EQ.0 ) THEN
               DO 300 K = 14
                  ISEEDK ) = IOLDSDK )
  300          CONTINUE
            END IF
            WRITENOUT, FMT = 9997 )C3, NBVAL( I ), NBMIN( I ),
     $         NXVAL( I )
            IFTSTCHK ) THEN
               CALL DDRVSGNNNVALMAXTYPDOTYPEISEEDTHRESH,
     $                      NOUTA11 ), NMAXA12 ), NMAX,
     $                      D13 ), A13 ), NMAXA14 ),
     $                      A15 ), A16 ), A17 ), WORK,
     $                      LWORKIWORKLIWORKRESULTINFO )
               IFINFO.NE.0 )
     $            WRITENOUT, FMT = 9980 )'DDRVSG', INFO
            END IF
  310    CONTINUE
*
      ELSE IFLSAMEN3C3'DBD' ) .OR. LSAMEN3C3'SVD' ) ) THEN
*
*        ----------------------------------
*        SVD:  Singular Value Decomposition
*        ----------------------------------
*        Vary the parameters
*           NB    = block size
*           NBMIN = minimum block size
*           NX    = crossover point
*           NRHS  = number of right hand sides
*
         MAXTYP = 16
         NTYPES = MINMAXTYPNTYPES )
         CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
         CALL XLAENV11 )
         CALL XLAENV925 )
*
*        Test the error exits
*
         IFTSTERR .AND. TSTCHK )
     $      CALL DERRBD'DBD'NOUT )
         IFTSTERR .AND. TSTDRV )
     $      CALL DERRED'DBD'NOUT )
*
         DO 330 I = 1NPARMS
            NRHS = NSVALI )
            CALL XLAENV1NBVALI ) )
            CALL XLAENV2NBMINI ) )
            CALL XLAENV3NXVALI ) )
            IFNEWSD.EQ.0 ) THEN
               DO 320 K = 14
                  ISEEDK ) = IOLDSDK )
  320          CONTINUE
            END IF
            WRITENOUT, FMT = 9995 )C3, NBVAL( I ), NBMIN( I ),
     $         NXVAL( I ), NRHS
            IFTSTCHK ) THEN
               CALL DCHKBDNNMVALNVALMAXTYPDOTYPENRHSISEED,
     $                      THRESHA11 ), NMAXD11 ),
     $                      D12 ), D13 ), D14 ), A12 ),
     $                      NMAXA13 ), A14 ), A15 ), NMAX,
     $                      A16 ), NMAXA17 ), A18 ), WORK,
     $                      LWORKIWORKNOUTINFO )
               IFINFO.NE.0 )
     $            WRITENOUT, FMT = 9980 )'DCHKBD', INFO
            END IF
            IFTSTDRV )
     $         CALL DDRVBDNNMVALNVALMAXTYPDOTYPEISEED,
     $                      THRESHA11 ), NMAXA12 ), NMAX,
     $                      A13 ), NMAXA14 ), A15 ),
     $                      A16 ), D11 ), D12 ), D13 ),
     $                      WORKLWORKIWORKNOUTINFO )
  330    CONTINUE
*
      ELSE IFLSAMEN3C3'DEV' ) ) THEN
*
*        --------------------------------------------
*        DEV:  Nonsymmetric Eigenvalue Problem Driver
*              DGEEV (eigenvalues and eigenvectors)
*        --------------------------------------------
*
         MAXTYP = 21
         NTYPES = MINMAXTYPNTYPES )
         IFNTYPES.LE.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERREDC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL DDRVEVNNNVALNTYPESDOTYPEISEEDTHRESHNOUT,
     $                   A11 ), NMAXA12 ), D11 ),
     $                   D12 ), D13 ), D14 ), A13 ),
     $                   NMAXA14 ), NMAXA15 ), NMAXRESULT,
     $                   WORKLWORKIWORKINFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DGEEV', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFLSAMEN3C3'DES' ) ) THEN
*
*        --------------------------------------------
*        DES:  Nonsymmetric Eigenvalue Problem Driver
*              DGEES (Schur form)
*        --------------------------------------------
*
         MAXTYP = 21
         NTYPES = MINMAXTYPNTYPES )
         IFNTYPES.LE.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERREDC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL DDRVESNNNVALNTYPESDOTYPEISEEDTHRESHNOUT,
     $                   A11 ), NMAXA12 ), A13 ),
     $                   D11 ), D12 ), D13 ), D14 ),
     $                   A14 ), NMAXRESULTWORKLWORKIWORK,
     $                   LOGWRKINFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DGEES', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFLSAMEN3C3'DVX' ) ) THEN
*
*        --------------------------------------------------------------
*        DVX:  Nonsymmetric Eigenvalue Problem Expert Driver
*              DGEEVX (eigenvalues, eigenvectors and condition numbers)
*        --------------------------------------------------------------
*
         MAXTYP = 21
         NTYPES = MINMAXTYPNTYPES )
         IFNTYPES.LT.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERREDC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL DDRVVXNNNVALNTYPESDOTYPEISEEDTHRESHNIN,
     $                   NOUTA11 ), NMAXA12 ), D11 ),
     $                   D12 ), D13 ), D14 ), A13 ),
     $                   NMAXA14 ), NMAXA15 ), NMAX,
     $                   D15 ), D16 ), D17 ), D18 ),
     $                   D19 ), D110 ), D111 ), D112 ),
     $                   RESULTWORKLWORKIWORKINFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DGEEVX', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFLSAMEN3C3'DSX' ) ) THEN
*
*        ---------------------------------------------------
*        DSX:  Nonsymmetric Eigenvalue Problem Expert Driver
*              DGEESX (Schur form and condition numbers)
*        ---------------------------------------------------
*
         MAXTYP = 21
         NTYPES = MINMAXTYPNTYPES )
         IFNTYPES.LT.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERREDC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL DDRVSXNNNVALNTYPESDOTYPEISEEDTHRESHNIN,
     $                   NOUTA11 ), NMAXA12 ), A13 ),
     $                   D11 ), D12 ), D13 ), D14 ),
     $                   D15 ), D16 ), A14 ), NMAX,
     $                   A15 ), RESULTWORKLWORKIWORKLOGWRK,
     $                   INFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DGEESX', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFLSAMEN3C3'DGG' ) ) THEN
*
*        -------------------------------------------------
*        DGG:  Generalized Nonsymmetric Eigenvalue Problem
*        -------------------------------------------------
*        Vary the parameters
*           NB    = block size
*           NBMIN = minimum block size
*           NS    = number of shifts
*           MAXB  = minimum submatrix size
*           NBCOL = minimum column dimension for blocks
*
         MAXTYP = 26
         NTYPES = MINMAXTYPNTYPES )
         CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
         IFTSTCHK .AND. TSTERR )
     $      CALL DERRGGC3NOUT )
         DO 350 I = 1NPARMS
            CALL XLAENV1NBVALI ) )
            CALL XLAENV2NBMINI ) )
            CALL XLAENV4NSVALI ) )
            CALL XLAENV8MXBVALI ) )
            CALL XLAENV5NBCOLI ) )
*
            IFNEWSD.EQ.0 ) THEN
               DO 340 K = 14
                  ISEEDK ) = IOLDSDK )
  340          CONTINUE
            END IF
            WRITENOUT, FMT = 9996 )C3, NBVAL( I ), NBMIN( I ),
     $         NSVAL( I ), MXBVAL( I ), NBCOL( I )
            TSTDIF = .FALSE.
            THRSHN = 10.D0
            IFTSTCHK ) THEN
               CALL DCHKGGNNNVALMAXTYPDOTYPEISEEDTHRESH,
     $                      TSTDIFTHRSHNNOUTA11 ), NMAX,
     $                      A12 ), A13 ), A14 ), A15 ),
     $                      A16 ), A17 ), A18 ), A19 ),
     $                      NMAXA110 ), A111 ), A112 ),
     $                      D11 ), D12 ), D13 ), D14 ),
     $                      D15 ), D16 ), A113 ),
     $                      A114 ), WORKLWORKLOGWRKRESULT,
     $                      INFO )
               IFINFO.NE.0 )
     $            WRITENOUT, FMT = 9980 )'DCHKGG', INFO
            END IF
            CALL XLAENV11 )
            IFTSTDRV ) THEN
               CALL DDRVGGNNNVALMAXTYPDOTYPEISEEDTHRESH,
     $                      THRSHNNOUTA11 ), NMAXA12 ),
     $                      A13 ), A14 ), A15 ), A16 ),
     $                      A17 ), NMAXA18 ), D11 ),
     $                      D12 ), D13 ), D14 ), D15 ),
     $                      D16 ), A113 ), A114 ), WORK,
     $                      LWORKRESULTINFO )
               IFINFO.NE.0 )
     $            WRITENOUT, FMT = 9980 )'DDRVGG', INFO
            END IF
  350    CONTINUE
*
      ELSE IFLSAMEN3C3'DGS' ) ) THEN
*
*        -------------------------------------------------
*        DGS:  Generalized Nonsymmetric Eigenvalue Problem
*              DGGES (Schur form)
*        -------------------------------------------------
*
         MAXTYP = 26
         NTYPES = MINMAXTYPNTYPES )
         IFNTYPES.LE.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERRGGC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL DDRGESNNNVALMAXTYPDOTYPEISEEDTHRESHNOUT,
     $                   A11 ), NMAXA12 ), A13 ),
     $                   A14 ), A17 ), NMAXA18 ),
     $                   D11 ), D12 ), D13 ), WORKLWORK,
     $                   RESULTLOGWRKINFO )
*
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DDRGES', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFDGX ) THEN
*
*        -------------------------------------------------
*        DGX:  Generalized Nonsymmetric Eigenvalue Problem
*              DGGESX (Schur form and condition numbers)
*        -------------------------------------------------
*
         MAXTYP = 5
         NTYPES = MAXTYP
         IFNN.LT.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERRGGC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL XLAENV52 )
            CALL DDRGSXNNNCMAXTHRESHNINNOUTA11 ), NMAX,
     $                   A12 ), A13 ), A14 ), A15 ),
     $                   A16 ), D11 ), D12 ), D13 ),
     $                   C11 ), NCMAX*NCMAXA112 ), WORK,
     $                   LWORKIWORKLIWORKLOGWRKINFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DDRGSX', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFLSAMEN3C3'DGV' ) ) THEN
*
*        -------------------------------------------------
*        DGV:  Generalized Nonsymmetric Eigenvalue Problem
*              DGGEV (Eigenvalue/vector form)
*        -------------------------------------------------
*
         MAXTYP = 26
         NTYPES = MINMAXTYPNTYPES )
         IFNTYPES.LE.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERRGGC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL DDRGEVNNNVALMAXTYPDOTYPEISEEDTHRESHNOUT,
     $                   A11 ), NMAXA12 ), A13 ),
     $                   A14 ), A17 ), NMAXA18 ),
     $                   A19 ), NMAXD11 ), D12 ),
     $                   D13 ), D14 ), D15 ), D16 ),
     $                   WORKLWORKRESULTINFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DDRGEV', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFDXV ) THEN
*
*        -------------------------------------------------
*        DXV:  Generalized Nonsymmetric Eigenvalue Problem
*              DGGEVX (eigenvalue/vector with condition numbers)
*        -------------------------------------------------
*
         MAXTYP = 2
         NTYPES = MAXTYP
         IFNN.LT.0 ) THEN
            WRITENOUT, FMT = 9990 )C3
         ELSE
            IFTSTERR )
     $         CALL DERRGGC3NOUT )
            CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
            CALL DDRGVXNNTHRESHNINNOUTA11 ), NMAX,
     $                   A12 ), A13 ), A14 ), D11 ),
     $                   D12 ), D13 ), A15 ), A16 ),
     $                   IWORK1 ), IWORK2 ), D14 ), D15 ),
     $                   D16 ), D17 ), D18 ), D19 ),
     $                   WORKLWORKIWORK3 ), LIWORK-2RESULT,
     $                   LOGWRKINFO )
*
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DDRGVX', INFO
         END IF
         WRITENOUT, FMT = 9973 )
         GO TO 10
*
      ELSE IFLSAMEN3C3'DSB' ) ) THEN
*
*        ------------------------------
*        DSB:  Symmetric Band Reduction
*        ------------------------------
*
         MAXTYP = 15
         NTYPES = MINMAXTYPNTYPES )
         CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
         IFTSTERR )
     $      CALL DERRST'DSB'NOUT )
         CALL DCHKSBNNNVALNKKVALMAXTYPDOTYPEISEEDTHRESH,
     $                NOUTA11 ), NMAXD11 ), D12 ),
     $                A12 ), NMAXWORKLWORKRESULTINFO )
         IFINFO.NE.0 )
     $      WRITENOUT, FMT = 9980 )'DCHKSB', INFO
*
      ELSE IFLSAMEN3C3'DBB' ) ) THEN
*
*        ------------------------------
*        DBB:  General Band Reduction
*        ------------------------------
*
         MAXTYP = 15
         NTYPES = MINMAXTYPNTYPES )
         CALL ALAREQC3NTYPESDOTYPEMAXTYPNINNOUT )
         DO 370 I = 1NPARMS
            NRHS = NSVALI )
*
            IFNEWSD.EQ.0 ) THEN
               DO 360 K = 14
                  ISEEDK ) = IOLDSDK )
  360          CONTINUE
            END IF
            WRITENOUT, FMT = 9966 )C3, NRHS
            CALL DCHKBBNNMVALNVALNKKVALMAXTYPDOTYPENRHS,
     $                   ISEEDTHRESHNOUTA11 ), NMAX,
     $                   A12 ), 2*NMAXD11 ), D12 ),
     $                   A14 ), NMAXA15 ), NMAXA16 ),
     $                   NMAXA17 ), WORKLWORKRESULTINFO )
            IFINFO.NE.0 )
     $         WRITENOUT, FMT = 9980 )'DCHKBB', INFO
  370    CONTINUE
*
      ELSE IFLSAMEN3C3'GLM' ) ) THEN
*
*        -----------------------------------------
*        GLM:  Generalized Linear Regression Model
*        -----------------------------------------
*
         CALL XLAENV11 )
         IFTSTERR )
     $      CALL DERRGG'GLM'NOUT )
         CALL DCKGLMNNMVALPVALNVALNTYPESISEEDTHRESHNMAX,
     $                A11 ), A12 ), B11 ), B12 ), X,
     $                WORKD11 ), NINNOUTINFO )
         IFINFO.NE.0 )
     $      WRITENOUT, FMT = 9980 )'DCKGLM', INFO
*
      ELSE IFLSAMEN3C3'GQR' ) ) THEN
*
*        ------------------------------------------
*        GQR:  Generalized QR and RQ factorizations
*        ------------------------------------------
*
         CALL XLAENV11 )
         IFTSTERR )
     $      CALL DERRGG'GQR'NOUT )
         CALL DCKGQRNNMVALNNPVALNNNVALNTYPESISEED,
     $                THRESHNMAXA11 ), A12 ), A13 ),
     $                A14 ), TAUAB11 ), B12 ), B13 ),
     $                B14 ), B15 ), TAUBWORKD11 ), NIN,
     $                NOUTINFO )
         IFINFO.NE.0 )
     $      WRITENOUT, FMT = 9980 )'DCKGQR', INFO
*
      ELSE IFLSAMEN3C3'GSV' ) ) THEN
*
*        ----------------------------------------------
*        GSV:  Generalized Singular Value Decomposition
*        ----------------------------------------------
*
         IFTSTERR )
     $      CALL DERRGG'GSV'NOUT )
         CALL DCKGSVNNMVALPVALNVALNTYPESISEEDTHRESHNMAX,
     $                A11 ), A12 ), B11 ), B12 ),
     $                A13 ), B13 ), A14 ), TAUATAUB,
     $                B14 ), IWORKWORKD11 ), NINNOUT,
     $                INFO )
         IFINFO.NE.0 )
     $      WRITENOUT, FMT = 9980 )'DCKGSV', INFO
*
      ELSE IFLSAMEN3C3'CSD' ) ) THEN
*
*        ----------------------------------------------
*        CSD:  CS Decomposition
*        ----------------------------------------------
*
         IFTSTERR )
     $      CALL DERRGG'CSD'NOUT )
         CALL DCKCSDNNMVALPVALNVALNTYPESISEEDTHRESHNMAX,
     $                A11 ), A12 ), A13 ), A14 ),
     $                A15 ), A16 ), A17 ), IWORKWORK,
     $                D11 ), NINNOUTINFO )
         IFINFO.NE.0 )
     $      WRITENOUT, FMT = 9980 )'DCKCSD', INFO
*
      ELSE IFLSAMEN3C3'LSE' ) ) THEN
*
*        --------------------------------------
*        LSE:  Constrained Linear Least Squares
*        --------------------------------------
*
         CALL XLAENV11 )
         IFTSTERR )
     $      CALL DERRGG'LSE'NOUT )
         CALL DCKLSENNMVALPVALNVALNTYPESISEEDTHRESHNMAX,
     $                A11 ), A12 ), B11 ), B12 ), X,
     $                WORKD11 ), NINNOUTINFO )
         IFINFO.NE.0 )
     $      WRITENOUT, FMT = 9980 )'DCKLSE', INFO
*
      ELSE
         WRITENOUT, FMT = * )
         WRITENOUT, FMT = * )
         WRITENOUT, FMT = 9992 )C3
      END IF
      IF.NOT.DGX .OR. DXV ) )
     $   GO TO 190
  380 CONTINUE
      WRITENOUT, FMT = 9994 )
      S2 = DSECND( )
      WRITENOUT, FMT = 9993 )S2 - S1
*
 9999 FORMAT( / ' Execution not attempted due to input errors' )
 9998 FORMAT( / / 1X, A3, ':  NB =', I4, ', NBMIN =', I4, ', NX =', I4,
     $      ', NS =', I4, ', MAXB =', I4 )
 9997 FORMAT( / / 1X, A3, ':  NB =', I4, ', NBMIN =', I4, ', NX =', I4 )
 9996 FORMAT( / / 1X, A3, ':  NB =', I4, ', NBMIN =', I4, ', NS =', I4,
     $      ', MAXB =', I4, ', NBCOL =', I4 )
 9995 FORMAT( / / 1X, A3, ':  NB =', I4, ', NBMIN =', I4, ', NX =', I4,
     $      ', NRHS =', I4 )
 9994 FORMAT( / / ' End of tests' )
 9993 FORMAT( ' Total time used = ', F12.2, ' seconds', / )
 9992 FORMAT( 1X, A3, ':  Unrecognized path name' )
 9991 FORMAT( / / ' *** Invalid integer value in column ', I2,
     $      ' of input', ' line:', / A79 )
 9990 FORMAT( / / 1X, A3, ' routines were not tested' )
 9989 FORMAT( ' Invalid input value: ', A, '=', I6, '; must be >=',
     $      I6 )
 9988 FORMAT( ' Invalid input value: ', A, '=', I6, '; must be <=',
     $      I6 )
 9987 FORMAT( ' Tests of the Nonsymmetric Eigenvalue Problem routines' )
 9986 FORMAT( ' Tests of the Symmetric Eigenvalue Problem routines' )
 9985 FORMAT( ' Tests of the Singular Value Decomposition routines' )
 9984 FORMAT( / ' The following parameter values will be used:' )
 9983 FORMAT( 4X, A, 10I6, / 10X, 10I6 )
 9982 FORMAT( / ' Routines pass computational tests if test ratio is ',
     $      'less than', F8.2, / )
 9981 FORMAT( ' Relative machine ', A, ' is taken to be', D16.6 )
 9980 FORMAT( ' *** Error code from ', A, ' = ', I4 )
 9979 FORMAT( / ' Tests of the Nonsymmetric Eigenvalue Problem Driver',
     $      / '    DGEEV (eigenvalues and eigevectors)' )
 9978 FORMAT( / ' Tests of the Nonsymmetric Eigenvalue Problem Driver',
     $      / '    DGEES (Schur form)' )
 9977 FORMAT( / ' Tests of the Nonsymmetric Eigenvalue Problem Expert',
     $      ' Driver', / '    DGEEVX (eigenvalues, eigenvectors and',
     $      ' condition numbers)' )
 9976 FORMAT( / ' Tests of the Nonsymmetric Eigenvalue Problem Expert',
     $      ' Driver', / '    DGEESX (Schur form and condition',
     $      ' numbers)' )
 9975 FORMAT( / ' Tests of the Generalized Nonsymmetric Eigenvalue ',
     $      'Problem routines' )
 9974 FORMAT( ' Tests of DSBTRD', / ' (reduction of a symmetric band ',
     $      'matrix to tridiagonal form)' )
 9973 FORMAT( / 1X, 71( '-' ) )
 9972 FORMAT( / ' LAPACK VERSION ', I1, '.', I1, '.', I1 )
 9971 FORMAT( / ' Tests of the Generalized Linear Regression Model ',
     $      'routines' )
 9970 FORMAT( / ' Tests of the Generalized QR and RQ routines' )
 9969 FORMAT( / ' Tests of the Generalized Singular Value',
     $      ' Decomposition routines' )
 9968 FORMAT( / ' Tests of the Linear Least Squares routines' )
 9967 FORMAT( ' Tests of DGBBRD', / ' (reduction of a general band ',
     $      'matrix to real bidiagonal form)' )
 9966 FORMAT( / / 1X, A3, ':  NRHS =', I4 )
 9965 FORMAT( / ' Tests of the Generalized Nonsymmetric Eigenvalue ',
     $      'Problem Expert Driver DGGESX' )
 9964 FORMAT( / ' Tests of the Generalized Nonsymmetric Eigenvalue ',
     $      'Problem Driver DGGES' )
 9963 FORMAT( / ' Tests of the Generalized Nonsymmetric Eigenvalue ',
     $      'Problem Driver DGGEV' )
 9962 FORMAT( / ' Tests of the Generalized Nonsymmetric Eigenvalue ',
     $      'Problem Expert Driver DGGEVX' )
 9961 FORMAT( / / 1X, A3, ':  NB =', I4, ', NBMIN =', I4, ', NX =', I4,
     $      ', INMIN=', I4, 
     $      ', INWIN =', I4, ', INIBL =', I4, ', ISHFTS =', I4,
     $      ', IACC22 =', I4)
 9960 FORMAT( / ' Tests of the CS Decomposition routines' )
*
*     End of DCHKEE
*
      END