summaryrefslogtreecommitdiff
path: root/macros/text1/macros/txt1v409.tex
blob: afc9acb6c2e933cdf8751acd5b446dfbb75a7f8f (plain)
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
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
%                                          MACROS FOR TEXT1
%
%         This work is protected as an unpublished work under
%         U.S. copyright laws.
%         Copyright 1987, by Washington State University.
%         All rights reserved.
%
%               Last updated on 7/24/95 (drg)
%
\everyjob{\immediate\write16{TEXT1 Version 4.09}
          \titlepage\spn{1}
}
%
%	The following variables are used for allowing conditional compilation 
%	of special code depending on which version of TeX you are using.
%	See these special notes in the next paragarph
\catcode`* = 11
\catcode`@ = 11
%
\newif\if*MAC  \*MACfalse     % This is not a Macintosh
\newif\if*CMS  \*CMSfalse     % This is not on CMS
\newif\if*PC   \*PCfalse      % This is not a PC
\newif\if*CG   \*CGfalse      % This is not a Compugraphics 8600 typesetter  
%
%   Note that non CMS versions must be modified. Here are the changes
%   necessary for the IBM PC/DOS version of TEXT1, Macintosh version,
%   and other non-CMS versions.
%
%      1. The filetype (extension) can only be 3 characters at the most
%         for the PC/DOS version.
%         This requires the following changes:
%            toc1     => tc1
%            toc2     => tc2
%            toc3     => tc3
%            endnotes => end
%            textext  => txt
%            texmath  => mth
%            texmodel => mdl
%
%      2. The Compugraphics dependent stuff in \selectspecificfont must
%         be omitted for all but CMS versions.
%
%      3. The routines \nonIBM and \IBM should be set to null for all but CMS
%         versions
%
%      4. The Macintosh/Textures version uses a special \include
%


%   Some temporary variables to be used throughout
%
\newbox\A
\newtoks\B
\newskip\C
\newdimen\D
\newdimen\*D
\newcount\E
\newcount\F
\newcount\G
\newcount\N
\newcount\Q
\newcount\R
%             \T \U \V \W are used throughout TEXT1 as temp definitions
%             \I \J \K \M \X \Y \Z are temporary too, be careful if you use these
%
% ragged rightindent on bq troublesome.
% titleleadskip works only with titlepage command in text.
% for doublecolumns, change hsize and line--refer to ccndbl
% for multiple right and centerline--refer to aztex
%
%           IBM/NONIBM character definitions, added by Dean 7/11/86
%
% Use this macro when not printing with IBM standard distribution fonts


\newif\if*IBM \*IBMfalse

\if*CMS
\def\nonIBM{\if*IBM \*IBMfalse%
    \def\aa{\accent23a}%
    \def\AA{\leavevmode\setbox0\hbox{h}\dimen@\ht0\advance\dimen@-1ex%
      \rlap{\raise.67\dimen@\hbox{\char'27}}A}%
    \def\c##1{\setbox\z@\hbox{##1}\ifdim\ht\z@=1ex\accent24 ##1%
      \else{\ooalign{\hidewidth\char24\hidewidth\crcr\unhbox\z@}}\fi}%
    \def\`##1{{\accent18 ##1}}%
    \def\'##1{{\accent19 ##1}}%
    \def\^##1{{\accent94 ##1}}\let\^^D=\|%
    \def\~##1{{\accent"7E ##1}}%
    \def\"##1{{\accent"7F ##1}}%
    \chardef\i="10 % dummy dotless lowercase i
    \def\dag{\mathhexbox279}%
    \def\ddag{\mathhexbox27A}%
    \def\S{\mathhexbox278}%
    \def\P{\mathhexbox27B}%
    \let\}=\rbrace%
    \let\{=\lbrace%
    \def\cents{\hbox{\rm\rlap/c}}\fi}% end non-IBM
%
% Use this macro when printing with the IBM standard distribution fonts
\def\IBM{\*IBMtrue
    \chardef\aa="8A % a overcircle
    \chardef\AA="8B % A overcircle
    \chardef\c="18 % cedilla
    \chardef\`="12 % grave
    \chardef\'="13 % acute
    \chardef\^="5E % circumflex
    \chardef\~="7E % tilde
    \chardef\"="7F % umlaut
    \chardef\i="69 % dummy dotless lowercase i
    \chardef\S="DC % section number sign
    \chardef\P="DD % paragraph sign or pilcrow
    \chardef\dag="DE % dagger or obelisk
    \chardef\ddag="DF % double dagger or diesis
    \chardef\{="AE % left brace
    \chardef\}="AF % right brace
    \chardef\cents="CD}% end IBM
\else
\def\nonIBM{}
\def\IBM{}
\fi
%
% Redefined from PLAIN.TEX to omit the at sign "@"
%    @ symbol will be read as begin and end math mode otherwise
\message{redefining some plain commands, }
\newdimen\zZ \zZ=0pt % can be used both for 0pt and 0
\mathchardef\zmz=1000
\mathchardef\zMz=10000
\mathchardef\zMMz=20000
\def~{\penalty\zMz\ } % tie
\def\break{\penalty-\zMz}
\def\nobreak{\penalty \zMz}
\def\allowbreak{\penalty \zZ}
\def\supereject{\par\penalty-\zMMz}
\def\nopagenumbers{\rhf{\bothpages{}}\rff{\bothpages{}}}
%
%  Redefined from PLAIN.TEX to \unskip last skip if in h mode
%
\message{redefining some plain commands, }
\def\removelastskip{\ifvmode\ifdim\lastskip=\z@\else\vskip-\lastskip\fi
                            \else\unskip\unskip\unskip\unskip\fi}
\let\rlsk=\removelastskip
%
%  Redefined from PLAIN.TEX to 12 point topskip
\def\raggedbottom{\topskip 12\p@ plus60\p@ \r@ggedbottomtrue}%
\def\normalbottom{\topskip 12\p@ \r@ggedbottomfalse}%
%
%  Redefined from PLAIN.TEX to omit extraneous skips and such surprises.
\def\endinsert{\egroup % finish the \vbox
  \if@mid \dimen@\ht\z@ \advance\dimen@\dp\z@
    \advance\dimen@12\p@ \advance\dimen@\pagetotal
    \ifdim\dimen@>\pagegoal\@midfalse\p@gefalse\fi\fi
  \if@mid \box\z@\goodbreak
  \else\insert\topins{\penalty100 % floating insertion
    \splittopskip\z@skip
    \splitmaxdepth\maxdimen \floatingpenalty\z@
    \ifp@ge \dimen@\dp\z@
    \vbox to\vsize{\unvbox\z@\kern-\dimen@}% depth is zero
    \else \box\z@\nobreak\fi}\fi\endgroup}
%
%         Redefined from PLAIN.TEX to take mode into account
\mathchardef\*dda="227A
\mathchardef\*dag="2279
\mathchardef\*neg="023A
\def\ddagger{\relax\ifmmode\*dda\else$\*dda$\fi}%
\def\dagger{\relax\ifmmode\*dag\else$\*dag$\fi}%
\def\neg{\relax\ifmmode\*neg\else$\*neg$\fi}
%
%         Redefined from PLAIN.TEX to take present font size into account
%
\def\strut{\relax
    \setbox\strutbox=\hbox{\vrule height 1.8ex depth .6ex width 0pt}%
    \ifmmode\copy\strutbox\else\unhcopy\strutbox\fi}%
%
%
%   Starting TEXT1 Definitions
%
%  Use this one for Textures
%
\if*MAC
	\def\include#1{\special {picture #1}}%
  \else
	\def\include#1{\special {IPS #1}}%     added by gap 1/27/87
\fi
\let\incl=\include
%
\def\text#1{{\it\TeX T1}}%             added by drg 9/26/86
\def\bf{\bd}%                          added by jkw 6/30/86
\def\cents{\hbox{\rm\rlap/c}}%         added by jkw 6/30/86
\def\fraction#1/#2 {%                  added by jkw 7/8/86
  \leavevmode\kern.1em \raise.6ex\hbox{\the\scriptfont0 #1}\kern-.1em
  /\kern-.15em\lower.25ex\hbox{\the\scriptfont0 #2}}
\let\frac=\fraction
\message{bibliography, }
%                      Bibliography
%
\newtoks\bi*f     \bi*f={\goodbreak\vs{1\bl}\hp\nin}      % init bibentry
\newtoks\bi*t     \bi*t={\dumpinsertseject\cl{\bd\bibtitle}
                            \vs{1\bl}}% init bibliography title format
\newtoks\bi*r     \bi*r={width 3em height .6ex depth -.5ex}
\newcount\bi*n    \bi*n=0            % counter for numbered bibliography
\newif\if*TC*bib  \*TC*bibtrue
%
\long\def\bibliographyformat#1{{% definition of bibliographic format
      \def\incontents##1{\global\*TC*bibtrue
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U              % Already true
                 \else \ifx \T\V \global\*TC*bibfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in bibliographyformat is not "yes" or "no".
                                      "yes" will be assumed}
                 \fi\fi}%
    \long\def\everybibentry##1{\global\bi*f={##1}}%
%      Remove this some day
    \let\bibentryformat=\everybibentry%
    \long\def\titleformat##1{\global\bi*t={##1}}%  replacement format for bibliography title
    \def\sameauthorrulesize##1{\global\bi*r={##1}}%
    #1}}%
\let\bif=\bibliographyformat
%
\def\bibtitle{}
\def\bibliography#1{% calls bibtitle format and passes title
    \global\bi*n=0                   % set bib counter to zero each call
    \global\def\bibtitle{#1}         % collect title tokens
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\bi*t
    \egroup
    \D=\lastskip
    \removelastskip
    \if*TC*bib \putincontents1{\the\*btf}\fi % call bib title format
    \ignorespaces
    \vs{\D}
}% end bibliography markup
\let\bib=\bibliography
%
\def\bibnumber{\the\bi*n}%
\def\bibentry{\par\global\advance\bi*n by1\the\bi*f}%
\let\bie=\bibentry                   % abbreviation for \bibentry
%
\def\sameauthor{\vrule\the\bi*r}%
\let\sau=\sameauthor
%
\message{misc, }
\def\underscore#1{$\underline{\smash{\hbox{#1}}}$}%
\let\us=\underscore
\def\leader{\leaders\hbox to 8pt{\hss.\hss}\hfill}%
%
\def\hyphenoff{\pretolerance=10000\hbadness=10000}%
\let\hof=\hyphenoff
\def\hyphenon{\pretolerance=100\hbadness=1000}%
\let\hon=\hyphenon
%
\def\today{\ifcase\month\or
   January\or February\or March\or April\or May\or June\or
   July\or August\or September\or October\or November\or December\fi
   \space\number\day,\space\number\year}%
%
%
\def\tilde{\relax\ifmmode\mathaccent"707E % relax added to trigger math
             \else{\sy\char'030}\fi}%       mode in tabs 1/27/87
%
\def\_{\leavevmode \kern.06em \vbox{\hrule width.3em}}%
%
\def\}{\relax\ifmmode \rbrace % relax added to trigger math mode in tabs
          \else $\rbrace$\fi}%
%
\def\{{\relax\ifmmode \lbrace % relax added to trigger math mode in tabs
          \else $\lbrace$\fi}%
%
\def\\{\relax\ifmmode \delimiter"26E30F % relax added to trigger math
          \else $\delimiter"26E30F$\fi}%  mode in tabs
%
\let\leftsquarebracket=[
\let\rightsquarebracket=]
\let\lsb=[
\let\rsb=]
\def\~#1{{\relax\ifmmode\mathaccent"707E % relax added to trigger math
             \else \accent"7E #1\fi}}%     mode in tabs
%
% baselineskip = interlineskip
%
\newskip\*isk
\newskip\baseline
\let\bl=\baseline
\def\interlineskip#1{\baselineskip=#1%
                     \baseline=#1%
                     \*isk=#1\relax}%
\let\isk=\interlineskip
%
\message{selectfontset, }
\newfam\bifam   \newfam\ccfam
%
%   The \selectfontset macros are by JKW
%
\newtoks\naMEtok
\newtoks\maTHtok
\newskip\bAseSkip
\newtoks\*sfslbl
\if*PC
	\*sfslbl={.txt}
  \else
	\*sfslbl={.textext}
\fi

\def\selectfontset#1#2#3{\naMEtok={#2}
   \edef\T{default}%
   \edef\U{#3}%
   \ifx\U\T \bAseSkip=0pt
      \else \bAseSkip=#3\fi
   \input #1\the\*sfslbl }%
\let\sfs=\selectfontset
\sfs{cm12}{twelvept}{default}
\sfs{cm10}{tenpt}{default}
\twelvept
%
\newtoks\*smslbl
\if*PC
	\*smslbl={.mth}
  \else
	\*smslbl={.texmath}
\fi

\def\selectmathset#1#2{\maTHtok={#2}\input #1\the\*smslbl}%
\let\sms=\selectmathset
\selectmathset{cm97m}{mathdefault} %
\mathdefault
%
%  SELECT SPECIFIC FONT, jkw 8/26/86
\newread\ckfnt
\newif\ifnotcfend
\newtoks\nUMtok
\newtoks\nmtok

\if*CMS
\def\selectspecificfont#1#2#3{\naMEtok={#1}\nUMtok={#3}
    \nmtok={#1\romannumeral #2}
    \def\T{\uppercase{#1 }}%
    \expandafter\xdef\csname I\the\nmtok\endcsname{\isk{\the\nUMtok}}
    \openin\ckfnt=cgfonts.lclist
       \loop\read\ckfnt to \W
       \edef\U{\uppercase{\W}}%
           \ifx\U\T
               \expandafter\font\csname F\the\nmtok%
                  \endcsname=#1 at #2 pt \notcfendfalse
           \else\ifeof\ckfnt
               \expandafter\font\csname F\the\nmtok%
                 \endcsname=#1#2  \notcfendfalse
            \else\notcfendtrue\fi\fi
     \ifnotcfend           \repeat
    \closein\ckfnt
    \expandafter\xdef\csname\the\naMEtok\endcsname ##1;{%
                \noexpand\csname F\the\naMEtok
                \noexpand\romannumeral\noexpand ##1\noexpand\endcsname
                \noexpand\csname I\the\naMEtok
                \noexpand\romannumeral\noexpand ##1\noexpand\endcsname}}%
\else
\def\selectspecificfont#1#2#3{\naMEtok={#1}\nUMtok={#3}
    \nmtok={#1\romannumeral #2}
    \def\T{\uppercase{#1 }}%
    \expandafter\xdef\csname I\the\nmtok\endcsname{\isk{\the\nUMtok}}
    \expandafter\xdef\csname\the\naMEtok\endcsname ##1;{%
                \noexpand\csname F\the\naMEtok
                \noexpand\romannumeral\noexpand ##1\noexpand\endcsname
                \noexpand\csname I\the\naMEtok
                \noexpand\romannumeral\noexpand ##1\noexpand\endcsname}}%
\fi

\let\ssf=\selectspecificfont
%
\skewchar\teni='177 \skewchar\seveni='177 \skewchar\fivei='177
\skewchar\tensy='60 \skewchar\sevensy='60 \skewchar\fivesy='60
%
\setbox0=\hbox{\tenex B} \p@renwd=\wd0 % width of the big left (
%
%
\message{monospace, }
\newif\if*msp   \*mspfalse
\if*CMS
\def\monospace{%
  \global\*msptrue                   % changed to global 6/27/86 bth
  \sfs{monofont}{defaultmono}{default}
  \defaultmono
  \gdef\underscore##1{{\italicfont ##1}}%
  \global\let\us=\underscore
  \special{fonts=10cpi}
  \raggedbottom
  \global\paragraphskip{0pt}
  \global\paragraphindent{36pt}
  \gdef\tilde{\ifmmode\mathaccent"707E%
               \else \char'176{}\fi}%
  \gdef\_{\char'137{}}%
  \gdef\}{\ifmmode \rbrace
          \else \char'175{}\fi}%
  \gdef\{{\ifmmode \lbrace
          \else\char'173{}\fi}%
  \gdef\\{\ifmmode \delimiter"26E30F%
          \else\char'134{}\fi}%
  \gdef\neg{\char'136{}}%
  \gdef\ellipsis##1{{\def\U{\message{<TEXT1> Error! Only 3 or 4 are valid for ellipsis. Command ignored.}}
    \ifcase ##1\U\or\U\or\U%
      \or .~.~.
      \or .~.~.~.
      \else\U\fi}}%
 
  \tableofcontentsformat{% added 1/26/87 Guenther
     \toctitle{\centerline{\bd Table of Contents}
               \vs{1\bl}}
     \figuretoctitle{\newpage
                     \centerline{\bd List of Figures}
                     \line{Figure \rt{Page}}}
     \tabletoctitle{\newpage
                    \centerline{\bd List of Tables}
                    \line{Table \rt{Page}}}
     }% end table of contents format
 
  \global\let\el=\ellipsis
  \asisformat{\skipbefore{1\bl}\everyasis{\leftindent{0pt}}\skipafter{1\bl}}
  \blockquoteformat{\skipbefore{1\bl}\everyblockquote{\rm\leftindent{36pt}\rightindent{36pt}}\skipafter{1\bl}}
  \figureformat{\titleformat{\bqb\bd\hp Figure \figurenumber. \figuretitle \bqe}}
  \tableformat{\titleformat{\vs{\bl}\cl{\bd Table \tablenumber}
                  \cl{\rm\tabletitle}\vs{\bl}}}
  \endnoteformat{\skipbefore{0\bl}\notereferencefont{\rm}\everyendnote{\rm\lin{0pt}}}
  \footnoteformat{\textreferenceposition{down}\textreferencefont{\rm}\textreferencestyle{(1)}
                  \notereferencefont{\rm}\everyfootnote{\rm\pin{.5in}\psk{.5in}\lin{0pt}\rin{0pt}}}
 
   \partformat{\titleformat{\dumpinsertseject\titlepage
                   \hrule height0pt depth0pt \vfil
                   \cl{\bd Part \partnumber}\cl{\bd\parttitle}\np
                   \scn{0}\ssan{0}\ssbn{0}\sscn{0}\ssdn{0}
                   \sfn{0}\stn{0}\sfnn{0}\senn{0}}}% end part format
   \indexformat1{\everyindex{\rm}}
   \indexformat2{\everyindex{\rm}}
   \indexformat3{\everyindex{\rm}}
   \chapterformat{\titleformat{\dumpinsertseject\cl{\bd Chapter \chapternumber}\cl{\bd\chaptertitle}\vs{1\bl}
      \ssan{0}\ssbn{0}\sscn{0}\ssdn{0}}}% end chapter format
   \prefaceformat{\titleformat{\dumpinsertseject\cl{\bd\prefacetitle}
      \vs{1\bl}\ssan{0}\ssbn{0}\sscn{0}\ssdn{0}}}% end preface format
   \appendixformat{\titleformat{\dumpinsertseject
      \cl{\bd Appendix \appendixnumber}\cl{\bd\appendixtitle}\vs{1\bl}
      \scn{0}\ssan{0}\ssbn{0}\sscn{0}\ssdn{0}\sfn{0}\stn{0}}}% end appendix format
   \subheadaformat{\titleformat{\removelastskip\goodbreak\vs{2\bl}
      \bd\nin\subheadatitle\par\nobreak\vs{1\bl}\nobreak
      \ssbn{0}\sscn{0}\ssdn{0}}}% end subheadaformat markup
   \subheadbformat{\titleformat{\removelastskip\goodbreak\vs{2\bl}
      \it\nin\subheadbtitle\par\nobreak\vs{1\bl}\nobreak
      \sscn{0}\ssdn{0}}}% end subheadbformat markup
   \subheadcformat{\titleformat{\removelastskip\goodbreak\vs{2\bl}
      \nin\subheadctitle\par\nobreak\vs{1\bl}\nobreak\ssdn{0}}}% end subheadc format markup
   \subheaddformat{\titleformat{\goodbreak{\it \subheaddtitle.}}}% end subheadd markup
   \runningheadformat{\bothpages{\line{\rm\lft{}\ctr{}\rt{\pagenumber}}
      \vs{1\bl}}}% end runningheadformat markup
}% END monospace markup definition
\else
	\def\monospace{\message{<TEXT1> monospace fonts are not available. Use
		typewritter fonts instead.}}
\fi
\let\msp=\monospace
%
\def\sl{\message{<TEXT1> Warning! The slanted font is not in font sets. Only tensl is used.}\tensl}%
\message{more misc, }
%
%    Ellipsis command 10/22/85
%
\def\ellipsis#1{{\def\U{\message{<TEXT1> Error! Only 3 or 4 are valid for ellipsis. Command ignored.}}
   \ifcase #1\U\or\U\or\U%
      \or \ifmmode\mathinner{\ldotp\ldotp\ldotp}
            \else$\mathinner{\ldotp\ldotp\ldotp}$\fi
      \or \ifmmode\mathinner{\ldotp\ldotp\ldotp\ldotp}
            \else\removelastskip$\ldotp\ldotp\ldotp\ldotp$\fi
      \else\U\fi}}%
\let\el=\ellipsis
%
%    dumpinsertseject is plain.tex \dosupereject with and \else added
%
\def\dumpinsertseject{\ifnum\insertpenalties>\z@ % something is being held over
                           \line{}\kern-\topskip\nobreak\vfill\supereject
                         \else \newpage
                         \fi}% END dumpinsertseject markup definition
\let\die=\dumpinsertseject
\message{page format, }
%
\newif\if*tempif
%
%    Pageformat command
%
\newdimen\pg*l       \pg*l=11in      % page length
\newdimen\pg*t       \pg*t=0in       % top margin set for 1in origin
\newdimen\pg*b       \pg*b=2in       % bottom margin set for 1in origin
\newdimen\pg*w       \pg*w=8.5in     % page width
\newdimen\pg*r       \pg*r=2in       % right margin set for 1in,
\newdimen\*lmar      \*lmar=0.2in    % left margin set for 1in
%                                      Note: TEX origin at 1in,1in
\newif\if*cropmarks  \*cropmarksfalse
\newdimen\pg*a       \pg*a=0in
\hsize=6.3in         \hoffset=0.2in
\vsize=9in           \voffset=0in
%
\def\pageformat#1{{\par
    \def\pagelength##1{\global\pg*l=##1
                       \cpt*vs}%
    \def\topmargin##1{\global\pg*t=##1
                      \global\advance\pg*t by- 1in   % set margin 1in,1in
                      \cpt*vs}%
    \def\bottommargin##1{\global\pg*b=##1
                      \global\advance\pg*b by 1in    % set margin 1in,1in
                      \cpt*vs}%
    \def\pagewidth##1{\global\pg*w=##1\cpt*hs}%
    \def\rightmargin##1{\global\pg*r=##1
                        \global\advance\pg*r by 1in  % set margin 1in,1in
                        \cpt*hs}%
    \def\leftmargin##1{\global\*lmar=##1
                       \global\advance\*lmar by -1in % set margin 1in,1in
                       \cpt*hs}%
    \def\bindingadjust##1{\global\pg*a=##1\cpt*hs}%
    \def\galleywidth##1{\global\pg*w=##1 
                       \global\advance\pg*w by\*lmar
         \global\advance\pg*w by\pg*r \cpt*hs}%
    \def\cropmarks##1{\global\*cropmarksfalse
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U  \global\*cropmarkstrue
                 \else \ifx \T\V \global\*cropmarksfalse
                       \else \message{<TEXT1> Warning, argument to cropmarks in     
                         pageformat is not "yes" or "no". "no" will be assumed}
                         \*cropmarksfalse
                 \fi\fi}%
	#1}}% End pageformat markup definition
\let\pf=\pageformat
%
% set page text size, compute hsize
%
\def\cpt*hs{% COMPUTE HORIZONTAL SIZE
    \global\hoffset=\*lmar
    \global\hsize=\pg*w              % added global 11/11/86 bth
    \global\advance\hsize by-\pg*r   % ""
    \global\advance\hsize by-\*lmar  % ""
    \global\*txtw=\hsize}%             added for multi column routines
%
% set page text size, vsize
%
\def\cpt*vs{% COMPUTE VERTICAL SIZE
    \global\voffset=\pg*t
    \global\vsize=\pg*l
    \global\advance\vsize by-\pg*t
    \global\advance\vsize by-\pg*b
    \if*title \global\advance \voffset by \tp*sk % lines from titlepage
              \global\advance \vsize by -\tp*sk % from titlepage
    \fi
    \global\*txth=\vsize}%             added for multi column routines
%
%   left center right
%
\def\lft#1{#1\hfill}
\def\ctr#1{\hfill #1\hfill}
\def\rt#1{\hfill #1}
%
\message{running heads, }
%
%  Page numbers
%
\def\setpagenumber#1{\global\pageno=#1}%
\let\spn=\setpagenumber
\def\pagenumber{\ifnum \pageno<0 \romannumeral-\pageno
                       \else \number\pageno\fi}%
\let\pn=\pagenumber
%
\def\rule{\vskip 1\baselineskip\hrule}%
%
%  Running heads
%
\newif\if*title
%
\newtoks\rh*r     \rh*r={\line{\twelvept\rt{\pagenumber}}\vs{\bl}}
\newtoks\rh*l     \rh*l={\line{\twelvept\rt{\pagenumber}}\vs{\bl}}
\newtoks\rf*r     \rf*r={}
\newtoks\rf*l     \rf*l={}
%
\def\runningheadformat#1{{%
    \def\*ttitle##1{\setbox\A=\vbox{##1}%
                    \D=\ht\A
                    \advance\D by -1in
                    \ifdim \D>\pg*t
                           \global\pg*t=\D
                           \global\advance\pg*t by 12pt
                           \advance\D by 1in
                           \message{<TEXT1> Warning, the top margin you
                                  have specified is less than the
                                  running top title. The top margin will
                                  be changed to \the\D}
                           \cpt*vs
                    \fi
                    \if*tempif \global\rh*l={\hrule width\hsize
                                             height0pt depth0pt ##1}
                    \else \global\rh*r={\hrule width\hsize
                                        height0pt depth0pt ##1}\fi
                   }% end *ttitle definition
    \def\evenpages##1{\*tempiftrue\*ttitle{##1}}%
    \def\oddpages##1{\*tempiffalse\*ttitle{##1}}%
    \def\bothpages##1{\*tempiftrue\*ttitle{##1}
                      \*tempiffalse\*ttitle{##1}}%
    \relax
 #1
 }}% END runningheadformat markup definition
\let \rhf = \runningheadformat
%
\def\runningfootformat#1{{%
    \def\*btitle##1{\setbox\A=\vbox{##1}%
                    \D=\ht\A
                    \advance\D by 1in
                    \ifdim \D>\pg*b
                           \global\pg*b=\D
                           \global\advance\pg*b by 12pt
                           \advance\D by -1in
                           \message{<TEXT1> Warning, the bottom  margin
                           you have specified is less than height of the
                           running bottom title.
                           The bottom margin will be
                           changed to \the\D}
                           \cpt*vs
                    \fi
                    \if*tempif \global\rf*l={##1}
                         \else \global\rf*r={##1}\fi
                }% end of bottomline
    \def\evenpages##1{\*tempiftrue\*btitle{##1}}%
    \def\oddpages##1{\*tempiffalse\*btitle{##1}}%
    \def\bothpages##1{\*tempiftrue\*btitle{##1}
                      \*tempiffalse\*btitle{##1}}%
    \relax
 #1}}% END runningfootformat markup definition
\let \rff = \runningfootformat
%
\newdimen\tp*sk       \tp*sk=1in
\newtoks\tp*fl      \tp*fl={}
\def\titlepageformat#1{{%
    \def\titleleadskip##1{\global\tp*sk=##1}%
    \def\titlefootline##1{\global\tp*fl={##1}}%
    \relax
    #1
    \titlepage}} %end of titlepageformat
\let \tpf = \titlepageformat
%
\def\titlepage{\global\*titletrue
               \cpt*vs}%
\let\tp=\titlepage
\def\notitlepage{\global\*titlefalse
                 \cpt*vs}%
\let\ntp=\notitlepage
%
\message{output, }
%
%   Output changed to permit binding adjust
%
\output={\*mkpg}
%
\def\*mkpg{\*badj
           \plainoutput
           \if*title \notitlepage\fi
           \ifnum\*pcount>0 \*blkpg\fi}% insert blank page
%
\def\plainoutput{\shipout\vbox{\*setcrops{\vbox{%
               \makeheadline
               \pagebody
               \makefootline}}}
          \advancepageno
          \ifnum\outputpenalty>-\@MM
               \else\dosupereject\fi}
%
\def\*setcrops#1{\setbox\A=\vbox{#1}
     \if*cropmarks 
       \D=\wd\A
       \advance\D by 15pt
       \vbox{\hsize=\the\D
          \offinterlineskip\psk{0pt}\pin{0pt}
          \hbox to \D{\vrule width 5pt height .1pt depth 0pt
                         \hfill
                      \vrule width 5pt height .1pt depth 0pt}
          \hbox to \D{\vrule height 5pt width .1pt depth 0pt
                    \hfill
                    \vrule height 5pt width .1pt depth 0pt}
	  \vs{\the\pg*t}
          \vs{3pt}
          \hbox to \D{\hfill\box\A\hfill}
          \vs{3pt}
          \hbox to \D{\vrule width .1pt height 5pt  depth 0pt
                    \hfill
                    \vrule width .1pt height 5pt  depth 0pt}
          \hbox to \D{\vrule width 5pt height .1pt depth 0pt
                         \hfill
                         \vrule width 5pt height .1pt depth 0pt}}     
	\else \box\A\fi}
%
\def\makeheadline{% headline set for multiple and single column modes
    \if*title%  Do nothing if its a title page
    \else \setbox\A=\vbox{\hsize=\the\*txtw % hsize added to allow
    \ifodd\pageno\the\rh*r %                 headline to print the
    \else\the\rh*l\fi} %                     full width in multi
    \vbox to 0pt{\vskip-\ht\A\box\A\vss} %   column mode
    \fi} % This could replace the TEXT1@@ definition
%
\def\makefootline{\if*title 
                \if*cropmarks \vbox{\hsize=\the\*txtw\the\tp*fl\vss}
                  \else\vbox to 0pt{\hsize=\the\*txtw\the\tp*fl\vss}\fi
          \else\if*cropmarks \vbox{\hsize=\the\*txtw\ifodd\pageno\the\rf*r
                                  \else\the\rf*l\fi\vss}
                  \else\vbox to 0pt{\hsize=\the\*txtw\ifodd\pageno\the\rf*r
                                  \else\the\rf*l\fi\vss}\fi % hsize added for multi column mode
           \fi} % This could replace the TEXT1@@ definition
%
\def\*badj{\ifdim\pg*a=\z@ % do nothing if binding adjust absent
           \else
              \ifodd\pageno % Binding adjust markup (revised 2/03/87
                \global\hoffset=\*lmar % offset equals left margin value
                \global\advance\hoffset by\pg*a % plus binding adjust
             \else
                \global\hoffset=\*lmar % offset equals left margin value
                \global\advance\hoffset by-\pg*a % plus binding adjust
          \fi\fi}% end binding adjust markup
\message{more misc, }
%
%     linebreak
%
\def\linebreak{\null\hfil\break}
\let\lbr=\linebreak
\let\toclinebreak=\linebreak
\let\toclbr=\linebreak
%
%  Horizontal skip
%
\def\horizontalspace#1{\null\hskip#1\relax}%
\let\hs=\horizontalspace
%
% skip down
%
\def\verticalspace#1{\vskip #1\relax}%
\let\vs=\verticalspace
%
\def\verticalspacekeep#1{\par
                        \hbox{\vbox{\vskip #1\relax}}}%
\let\vsk=\verticalspacekeep
%
%    raggedright (as TeX basic)
%
\newdimen\r*sk       \r*sk=0pt       % dimension to save right skip
\def\rightragged{\par \r*sk=\rightskip   \*rrtrue
    \if*msp \rightskip=\r*sk plus10em
            \spaceskip=1em \xspaceskip=1em
    \else  \rightskip=\r*sk plus2em\relax
           \spaceskip=.3333em \xspaceskip=.5em
           \fi}
\let\rr=\rightragged
%
%    leftragged
%
\newdimen\l*sk    \l*sk=0pt          % dimension to save left skip
\def\leftragged{\par %
    \l*sk=\leftskip
    \spaceskip=.35em
    \xspaceskip=.55em
    \parfillskip=0pt
    \leftskip=\l*sk plus2em\relax}
\let\lr=\leftragged
%
\newif\if*rr   \*rrfalse
\def\justify{\par
             \rightskip=\r*sk
             \*rrfalse
             \leftskip=\l*sk
             \spaceskip=0pt \xspaceskip=0pt
             \parfillskip=0pt plus1fil\relax}
\let\ju=\justify
%
%    spacing
%
\def\singlespace{\par\baselineskip=\*isk}
\let\ssp=\singlespace
\def\doublespace{\par\baselineskip=2\*isk}
\let\dsp=\doublespace
%
%     paragraph
%
\let\paragraph=\par
\def\paragraphindent#1{\parindent=#1}
\let\pin=\paragraphindent
\def\paragraphskip#1{\parskip=#1}
\let\psk=\paragraphskip
%
%  noindent
%
\let\nin=\noindent
%
%  hanging paragraph macro
%
\newdimen\*hin          \*hin=24pt
\def\hangingindent#1{\*hin=#1}
\let\hin=\hangingindent
%
\def\hangingparagraph{\par
                      \hangindent=\*hin
                      \hangafter=1
                      \noindent}
\let\hp=\hangingparagraph
\newif\if*mnr     \*mnrfalse        % left/right margin note indicator
\newtoks\e*mn     \e*mn={\tenpt\rr} % every margin note tokens
\newtoks\*mnw     \*mnw={54pt}      % margin note width tokens
\newtoks\*mngut   \*mngut={6pt}     % margin note gutter tokens
\message{margin note, }
%
%           Margin Note markup
%
\def\marginnoteformat#1{% MARGINAL NOTE FORMAT
    \def\position##1{% "left" or "right" margin note check
       \edef\T{##1}%
       \edef\U{left}%
       \edef\V{right}%
       \ifx \T\U \global\*mnrfalse   % left margin notes true
       \else\ifx \T\V \global\*mnrtrue % right margin notes true
            \else\global\*mnrfalse   % default, improper entry
               \write16{<TEXT1> You must specify "left" or "right" in %
                      the marginnoteformat markup. Left is the default.}%
       \fi\fi}% end margin note check
    \def\notewidth##1{\global\*mnw={##1}}% note width variable
    \def\notegutter##1{\global\*mngut={##1}}% gutter width variable
    \def\everymarginnote##1{\global\e*mn={##1}}% token variable
    #1}% insert arguments, END marginnoteformat
\let\mnf=\marginnoteformat           % set marginnoteformat abbreviation
%
\long\def\marginnote#1{% BEGIN MARGIN NOTE MACRO
    \if*CG 
        \special{MARGINNOTE=true} % added 6/30/87 jkw for 8600 line numbering
	\fi
    \ifvmode\leavevmode\fi           % can't use vadjust in vertical mode
    \bgroup                          % begin margin note routine
    \def\rightragged{\r*sk=\rightskip   \*rrtrue
        \if*msp \rightskip=\r*sk plus10em %
           \spaceskip=1em \xspaceskip=1em %
        \else \advance\rightskip by 0pt plus1fil\relax %
           \spaceskip=.35em \xspaceskip=.55em %
        \fi}% par removed from TEXT1 version %
    \let\rr=\rightragged             %
%
    \tolerance=6000                  % increase line-breaking tolerance
    \hbadness=6000                   % increase warning tolerance
    \strut                           % sets line depth for vadjust
    \D=\dp\strutbox                  % capture depth of current line
    \the\e*mn                        % every margin note tokens
    \strut                           % sets strut to margin note font
    \parskip=0pt                     % cancel any paragraph skip
    \if*mnr                          % right margin notes true
       \vadjust{                     % make whats'it in text
       \rlap{\smash{                 % rightlap, make note depth zero
       \hskip\hsize                  % skip to right margin
       \hskip\the\*mngut             % make gutter
       \vtop{\hsize=\the\*mnw        % set reference point, new hsize
       \kern-\D                      % kern depth of current text line
       \kern-\ht\strutbox            % kern height of margin note text
       \nin#1}}}}%                   % input margin note text
    \else                            % left margin notes true
       \vadjust{                     % make whats'it in text
          \llap{\smash{              % leftlap, make note depth zero
          \vtop{\hsize=\the\*mnw     % gather vertical material with
          \kern-\D                   % kern depth of current text line
          \kern-\ht\strutbox         % kern height of margin note text
          \nin#1}%                     reference point at the top
          \hskip\the\*mngut}}}%        make margin note gutter
    \fi                              %
    \egroup                          % end margin notes routine
    \ignorespaces}% END margin note macro
\let\mn=\marginnote
%
\message{labels, }
%
% labeled definition macro
%
\newdimen\la*w   \la*w=1in         % Label width
\newtoks\la*g    \la*g={1em}       % Label gutter
\newtoks\la*s    \la*s={1\bl}      % Skip before label
\newtoks\la*f    \la*f={\rm}       % Label font
%
\long\def\label#1{\par\vskip\the\la*s
             \setbox\A=\vtop{\hsize=\la*w
                                  \leftskip=0pt
                                  \rightskip=0pt plus2em
                                  \tolerance=1600
                                  \noindent
                                  \the\la*f
                                  #1}%
             \hangindent=\la*w
             \advance \hangindent by \the\la*g
             \hangafter=1
             \noindent
             \setbox0=\hbox{\rlap{\box\A}}\ht0=0pt\dp0=0pt\box0%
             \hskip\la*w
             \hskip\the\la*g
             \ignorespaces}
\let\la=\label
%
\def\labelformat#1{{\def\skipbefore##1{\global\la*s={##1}}%
      \def\labelwidth##1{\global\la*w=##1}%
      \def\gutter##1{\global\la*g={##1}}%
      \def\everylabel##1{\global\la*f={##1}}%
      #1}}% End labelformat
\let\laf=\labelformat
%
\message{indents, }
%
%     leftindent
%
\newif\if*ok
\newif\if*zero
\def\leftindent#1{\par
                  \*zerofalse
                  \*okfalse
                  \e*p#1\end%
                  \if*zero \leftskip 0pt \fi
                  \advance \leftskip by #1
                  \l*sk=\leftskip   % l*sk used in justify reset
                  }%
\let\lin=\leftindent
%
\def\rightindent#1{\par
                   \*zerofalse  \*okfalse
                   \e*p#1\end%
                   \if*zero \rightskip 0pt \fi
                   \advance \rightskip by #1
                   \if*rr\rr\fi
                   \r*sk=\rightskip}% r*sk used in justify reset
\let\rin=\rightindent
%
%  \e*p will determine if the parm value passed to \leftindent
%  or \rightindent is to be relative to the previous indent, which means a
%  "+" or "-" will appear in front of the indent value. If no "+" or "-",
%  then the indent is to be absolute from the original left margin.
%
\def\e*p#1{\ifx #1\end \let \next = \relax%     e*p => Evaluate Parameter
    \else \if*ok \let \next = \e*p
        \else \global\*oktrue
              \ifx #1+ \let \next = \e*p
                   \else \ifx #1- \let \next = \e*p
                         \else \*zerotrue
                               \let \next = \e*p
    \fi\fi\fi\fi \next}
%
\message{block quotes, }
%
%              Blockquote
%
\newskip\bq*sb   \bq*sb = 6pt     % Default skip before
\newskip\bq*sa   \bq*sa = 6pt     % Default skip after
\newtoks\bq*f    \bq*f={\tenpt\leftindent{24pt}\rightindent{24pt}}
%
\def\blockquoteformat#1{{%
        \def\everyblockquote##1{\global\bq*f={##1}}%
        \def\skipbefore##1{\global\bq*sb=##1\relax}%
        \def\skipafter##1{\global\bq*sa=##1\relax}%
        #1}} %end of blockquoteformat
\let\bqf=\blockquoteformat
%
\def\blockquotebegin{\par\vskip\bq*sb\relax\begingroup
                     \the\bq*f }
\let\bqb=\blockquotebegin
\def\blockquoteend{\par\endgroup\vskip\bq*sa\relax}
\let\bqe=\blockquoteend
%
\message{footnotes, }
%
%
%
%                            Footnote
%
%    The "tfn" prefixed values are for the reference in the text of
%    the document.
%
\newif\if*tfn*dnum        \*tfn*dnumfalse    %"1." style
\newif\if*tfn*unum        \*tfn*unumtrue     %"1" style
\newif\if*tfn*pnum        \*tfn*pnumfalse    %"(1)" style
\newif\if*tfn*dlet        \*tfn*dletfalse    % "a." style
\newif\if*tfn*ulet        \*tfn*uletfalse    % "a"  style
\newif\if*tfn*plet        \*tfn*pletfalse    % "(a)" style
\newif\if*tfn*rbe         \*tfn*rbefalse     % reference after word
\newif\if*tfnupchar       \*tfnupchartrue    %
\newtoks\*tfn*rfont       \*tfn*rfont={\tenpt\rm}
%
%    The "nfn" prefixed values are for the reference as it is formatted
%    at the bottom of the page.
%
\newif\if*nfn*dnum        \*nfn*dnumtrue      %"1." style
\newif\if*nfn*unum        \*nfn*unumfalse     %"1" style
\newif\if*nfn*pnum        \*nfn*pnumfalse     %"(1)" style
\newif\if*nfn*dlet        \*nfn*dletfalse     % "a." style
\newif\if*nfn*ulet        \*nfn*uletfalse     % "a" style
\newif\if*nfn*plet        \*nfn*pletfalse     % "(1)" style
\newif\if*nfnupchar       \*nfnupcharfalse    % reference is not superscript
\newtoks\*nfn*rfont       \*nfn*rfont={\tenpt\rm}
\newtoks\*nfng            \*nfng={1em}
%
\newif\if*fn*llap         \*fn*llaptrue
\newtoks\fn*f
\newcount\fn*num
\newdimen\fn*div    \fn*div=2in
\newskip\fn*sadiv       \fn*sadiv=2.6pt  %default skip after divider
\newskip\fn*sbdiv       \fn*sbdiv=6pt  %default skip before divider
%
\def\footnotenumber{{\if*tfn*dnum \the\fn*num      % "1." style
                \else\if*tfn*unum \the\fn*num      % "1" style
                \else\if*tfn*pnum \the\fn*num      % "(1)" style
                \else\l*alphatrue \a*c{\fn*num}    % "a.", "a", and "(a)"
                  \fi\fi\fi
                  \removelastskip}}
%
\def\setfootnotenumber#1{\fn*num=#1}
\let\sfnn=\setfootnotenumber
%
\skip\footins=15pt plus 3pt minus 2pt
\fn*f={\tenpt\pin{20pt}\lin{0in}}
%
\def\footnoteformat#1{{%
  \def\everyfootnote##1{\global\fn*f{##1}}%
  \def\textreferencestyle##1{%
             \global\*tfn*dnumfalse
             \global\*tfn*unumfalse
             \global\*tfn*pnumfalse
             \global\*tfn*dletfalse
             \global\*tfn*uletfalse
             \global\*tfn*pletfalse
             \edef\T{##1}%
             \edef\U{(1)}%
             \edef\V{1}%
             \edef\Y{1.}%
             \edef\W{(a)}%
             \edef\X{a}%
             \edef\Z{a.}%
             \ifx\T\U \global\*tfn*pnumtrue
                 \else\ifx\T\V \global\*tfn*unumtrue
                 \else\ifx\T\Y \global\*tfn*dnumtrue
                 \else\ifx\T\W \global\*tfn*plettrue
                 \else\ifx\T\X \global\*tfn*ulettrue
                 \else\ifx\T\Z \global\*tfn*dlettrue
                 \else \message{<TEXT1> Error! textreferencestyle ##1
                             is not a valid style. Statement ignored.}
       \fi\fi\fi\fi\fi\fi}%   end reference style
   \def\textreferencefont##1{\global\*tfn*rfont{##1}}%
   \def\textreferenceplacement##1{\global\*tfn*rbefalse
                       \edef\T{##1}%
                       \edef\U{before}%
                       \edef\V{after}%
       \ifx\T\U \global\*tfn*rbetrue
           \else\ifx\T\V \global\*tfn*rbefalse
           \else \message{<TEXT1> Error! textreferenceplacement ##1
                          is invalid. Statement ignored.}
       \fi\fi}
   \def\textreferenceposition##1{\global\*tfnupcharfalse
                       \edef\T{##1}%
                       \edef\U{up}%
                       \edef\V{down}%
       \ifx\T\U \global\*tfnupchartrue
           \else\ifx\T\V \global\*tfnupcharfalse
           \else \message{<TEXT1> Error! textreferenceposition ##1
                          has an invalid parameter. Statement ignored.}
       \fi\fi}
  \def\notereferencestyle##1{
             \global\*nfn*dnumfalse
             \global\*nfn*unumfalse
             \global\*nfn*pnumfalse
             \global\*nfn*dletfalse
             \global\*nfn*uletfalse
             \global\*nfn*pletfalse
             \edef\T{##1}%
             \edef\U{(1)}%
             \edef\V{1}%
             \edef\Y{1.}%
             \edef\W{(a)}%
             \edef\X{a}%
             \edef\Z{a.}%
             \ifx\T\Y \global\*nfn*dnumtrue
                 \else\ifx\T\U \global\*nfn*pnumtrue
                 \else\ifx\T\V \global\*nfn*unumtrue
                 \else\ifx\T\W \global\*nfn*plettrue
                 \else\ifx\T\X \global\*nfn*ulettrue
                 \else\ifx\T\Z \global\*nfn*dlettrue
                 \else \message{<TEXT1> Error! notereferencestyle ##1
                             is not a valid style. Statement ignored.}
        \fi\fi\fi\fi\fi\fi}%   end reference style
   \def\notereferencefont##1{\global\*nfn*rfont{##1}}%
   \def\notereferenceposition##1{\global\*nfnupcharfalse
                       \edef\T{##1}%
                       \edef\U{up}%
                       \edef\V{down}%
       \ifx\T\U \global\*nfnupchartrue
           \else\ifx\T\V \global\*nfnupcharfalse
           \else \message{<TEXT1> Error! notereferenceposition ##1
                          has an invalid parameter. Statement ignored.}
       \fi\fi}%
   \def\skipbeforedivider##1{\global\fn*sbdiv=##1\relax}%
   \def\footnotedivider##1{\global\fn*div=##1\relax}%
   \def\notereferencegutter##1{\global\*nfng={##1}}%
   \def\skipafterdivider##1{\global\fn*sadiv=##1\relax}%
   #1
   \relax
   \skip\footins=0pt plus 3pt minus 2pt
   \global\advance\skip\footins by \fn*sbdiv\relax%
   \global\advance\skip\footins by \fn*sadiv\relax%
}} % end of footnoteformat
\let\fnf=\footnoteformat
%
\def\autofootnote{\global\advance\fn*num by 1
    \l*alphatrue
    \xdef\I{%
          \if*tfn*unum \the\fn*num%
          \else \if*tfn*ulet \a*c{\the\fn*num}%
          \else \if*tfn*plet (\a*c{\the\fn*num})%
          \else \if*tfn*pnum (\the\fn*num)%
          \else \if*tfn*dlet \a*c{\the\fn*num}.%
          \else \if*tfn*dnum \the\fn*num.%
          \fi\fi\fi\fi\fi\fi}%
    \def\K{%
          \if*nfn*unum \the\fn*num%
          \else \if*nfn*ulet \a*c{\the\fn*num}%
          \else \if*nfn*plet (\a*c{\the\fn*num})%
          \else \if*nfn*pnum (\the\fn*num)%
          \else \if*nfn*dlet \a*c{\the\fn*num}.%
          \else \if*nfn*dnum \the\fn*num.%
          \fi\fi\fi\fi\fi\fi}%
%
    \let\@sf=\empty
    \ifhmode\edef\@sf{\spacefactor=\the\spacefactor}\fi
    \def\J{{\the\*tfn*rfont
           \if*tfnupchar \raise.7ex\hbox{\the\*tfn*rfont\I}%
                        \else {\I}\fi}}%
    \if*tfn*rbe \@sf\J\ignorespaces%
              \else\unskip\unskip\unskip\unskip\J\@sf\fi
    \def\M{{\the\*nfn*rfont
           \if*nfnupchar \raise.7ex\hbox{\K}%
                        \else {\K}\fi}}%
  \vfootnote{\M}}
\let\afn=\autofootnote
%
%        vfootnote redefined to include fn*f features
%        The addition of hsize=txtw in vfootnote for flexibleformat allows the
%
%        footnote to print across the full text width at the page bottom.
%
%        Footstrut redefined to baselineskip for consistent spacing in footnote
%
%
\def\footnoterule{\vskip-\fn*sadiv\hrule width\fn*div\vskip\fn*sadiv\relax}
%
%          redefined from PLAIN TEX to baselineskip. PLAIN TEX
%          used the height of a ten point strutbox
%
\def\vfootnote#1{% Vfootnote revised 11/6/86
    \insert\footins\bgroup
    \if*fix %                          if fixed mode do nothing to footnote
    \else\hsize=\*txtw\fi %            else print footnote across full width of page
   \interlinepenalty\interfootnotelinepenalty
   \setbox\strutbox=\hbox{\vrule height 1.8ex depth .6ex width 0pt}%
   \splittopskip\ht\strutbox %          top baseline for broken footnotes
   \splitmaxdepth\dp\strutbox
   \floatingpenalty\@MM
   \leftskip\z@skip
   \rightskip\z@skip
   \spaceskip\z@skip
   \xspaceskip\z@skip
   \the\fn*f
   \def\T{\parindent}% For some odd and unknown reason this def is needed
   \ifdim\the\parindent>0pt \global\*fn*llaptrue
      \else \ifdim\the\leftskip>0pt \global\*fn*llaptrue
      \else \global\*fn*llapfalse\fi\fi
   \leavevmode
   \if*fn*llap  \hbox to 0pt{\hss{#1\hskip\the\*nfng}}%
      \else \hbox{#1\hskip\the\*nfng}\fi%
  \ignorespaces
  \footstrut\futurelet\next\fo@t}% END vfootnote markup definition
%
\def\footstrut{\vbox to\baselineskip{}}
%
\message{endnotes, }
%
%                            Endnote
%
%    The "ten" prefixed values are for the reference in the text of
%    the document.
%
\newif\if*ten*num        \*ten*numtrue      % "[1]", "1" and "(1)" styles
\newif\if*ten*let        \*ten*letfalse     % "a" and "(a)" styles
\newif\if*ten*paren      \*ten*parenfalse   % "(1)" and "(a)" styles
\newif\if*ten*sb         \*ten*sbtrue       % "[1]" style
\newif\if*tenupchar      \*tenupcharfalse   % reference is not superscripted by
\newtoks\*tenrfont       \*tenrfont={\tenpt\rm}
%
%    The "nen" prefixed values are for the reference as it is formatted
%    at the end of a chapter or the end of the document.
%
\newif\if*nen*num        \*nen*numtrue      % "[1]", "1", "1." and "(1)" styles
\newif\if*nen*let        \*nen*letfalse     % "a" and "(a)" styles
\newif\if*nenll*per      \*nenll*pertrue    % "1." style
\newif\if*nen*paren      \*nen*parenfalse   % "(1)" and "(a)" styles
\newif\if*nen*sb         \*nen*sbfalse      % "[1]" style
\newif\if*nenupchar      \*nenupcharfalse   % reference isn't superscripted
\newtoks\*nenrfont       \*nenrfont={\tenpt\rm}
\newdimen\*neng          \*neng=1em
%
\newtoks\*enpar
\newcount\en*n
\newskip\en*s            \en*s=4pt
%
%
\def\endnotenumber{{\if*ten*num \the\en*n      % all numeric styles
                \else\l*alphatrue \a*c{\en*n}  % all alpha styles
                  \fi
                  \removelastskip}}
%
\def\setendnotenumber#1{\en*n=#1}
\let\senn=\setendnotenumber
%
\*enpar={\tenpt\pin{0in}\lin{1.2em}}
%
\def\endnoteformat#1{%
 {\def\everyendnote##1{\global\*enpar{##1}}%
  \def\textreferencestyle##1{%
             \global\*ten*numfalse
             \global\*ten*letfalse
             \global\*ten*parenfalse
             \global\*ten*sbfalse
             \edef\T{##1}%
             \edef\U{[1]}%
             \edef\V{(1)}%
             \edef\W{1}%
             \edef\X{(a)}%
             \edef\Y{a}%
             \ifx\T\U \global\*ten*numtrue \global\*ten*sbtrue              % st
                 \else\ifx\T\V \global\*ten*numtrue \global\*ten*parentrue  % st
                 \else\ifx\T\W \global\*ten*numtrue                         % st
                 \else\ifx\T\X \global\*ten*lettrue \global\*ten*parentrue  % st
                 \else\ifx\T\Y \global\*ten*lettrue                         % st
                 \else \message{<TEXT1> Error! textreferencestyle ##1
                             is not a valid style. Statement ignored.}
           \fi\fi\fi\fi\fi}%   end reference style
   \def\textreferencefont##1{\global\*tenrfont{##1}}%
   \def\textreferenceposition##1{\global\*tenupcharfalse
                       \edef\T{##1}%
                       \edef\U{up}%
                       \edef\V{down}%
       \ifx\T\U \global\*tenupchartrue
           \else\ifx\T\V \global\*tenupcharfalse
           \else \message{<TEXT1> Error! textreferenceposition ##1
                          has an invalid parameter. Statement ignored.}
       \fi\fi}
  \def\notereferencestyle##1{
             \global\*nen*numfalse
             \global\*nen*letfalse
             \global\*nen*parenfalse
             \global\*nenll*perfalse
             \global\*nen*sbfalse
             \edef\T{##1}%
             \edef\U{[1]}%
             \edef\V{(1)}%
             \edef\W{1}%
             \edef\X{(a)}%
             \edef\Y{a}%
             \edef\Z{1.}%
             \ifx\T\Z \global\*nen*numtrue \global\*nenll*pertrue        % style
                 \else\ifx\T\U \global\*nen*numtrue \global\*nen*sbtrue     % st
                 \else\ifx\T\V \global\*nen*numtrue \global\*nen*parentrue  % st
                 \else\ifx\T\W \global\*nen*numtrue                         % st
                 \else\ifx\T\X \global\*nen*lettrue \global\*nen*parentrue  % st
                 \else\ifx\T\Y \global\*nen*lettrue                         % st
                 \else \message{<TEXT1> Error! notereferencestyle ##1
                             is not a valid style. Statement ignored.}
           \fi\fi\fi\fi\fi\fi}%   end reference style
   \def\notereferencefont##1{\global\*nenrfont{##1}}%
   \def\notereferenceposition##1{\global\*nenupcharfalse
                       \edef\T{##1}%
                       \edef\U{up}%
                       \edef\V{down}%
       \ifx\T\U \global\*nenupchartrue
           \else\ifx\T\V \global\*nenupcharfalse
           \else \message{<TEXT1> Error! notereferenceposition ##1
                          has an invalid parameter. Statement ignored.}
       \fi\fi}%
   \def\notereferencegutter##1{\global\*neng=##1}%
   \def\skipbefore##1{\global\en*s=##1}%
   \relax
   #1}} % end of footnoteformat
\let\enf=\endnoteformat
%
\newlinechar=`\^^J
\newhelp\aenhelp{relax
   You may continue if you wish, but I'd be surprised
   if your job^^J
   finished without any errors when you print the endnotes. }
%
\def\err@#1{\errmessage{TEXT1 error: #1}}
\def\*aenerr{\errhelp=\aenhelp
    \catcode`@=11
    \errmessage{Results are unpredictable
                 when you use autoendnote with asisbegin.
                 Type h for more help}}%
\def\autoendnote{\global\advance\en*n by 1
    \if*aib \*aenerr \fi
    \l*alphatrue
    \edef\I{%
          \if*ten*paren (\unskip\fi
          \if*ten*sb [\unskip\fi
          \if*ten*num \the\en*n\fi
          \if*ten*let \a*c{\the\en*n}\fi
          \if*ten*paren \unskip)\fi
          \if*ten*sb \unskip]\fi}%
  \let\@sf=\empty
  \ifhmode \edef\@sf{\spacefactor=\the\spacefactor}%
     \else \let\@sf=\empty\fi
  \unskip\unskip
  \if*tenupchar \raise.7ex\hbox{\the\*tenrfont\I}\@sf%
          \else {\the\*tenrfont\I}\@sf\fi%
    \edef\J{%
          \if*nen*paren (\unskip\fi
          \if*nen*sb [\unskip\fi
          \if*nen*num \the\en*n\fi
          \if*nen*let \a*c{\the\en*n}\fi
          \if*nenll*per \unskip.\fi
          \if*nen*paren \unskip)\fi
          \if*nen*sb \unskip]\fi}%
  \en*o
  \immediate\write\en*f{\par%
      \the\*enpar%
      \noexpand\ENP{\the\*nenrfont\J}}%
  \en*w}
\let\aen=\autoendnote
%
%
\def\ENP#1{\indent\en*i{%
                    \if*nenupchar \raise.7ex\hbox{\the\*nenrfont#1}%
                    \else {\the\*nenrfont#1}\fi}}%
%
\def\en*i#1{\hbox to 0pt{\hss{#1}\hskip\*neng}\ignorespaces}
%
\newwrite\en*f
\newtoks\*endlbl
\if*PC
	\*endlbl={text1xx.end}
  \else
	\*endlbl={text1xx.endnotes}
\fi

\def\en*o{\immediate\openout\en*f=\the\*endlbl
             \immediate\write\en*f{\the\*enpar}%
             \edef\T{\par\vskip\the\en*s\relax}%
             \immediate\write\en*f{\T}%
             \global\def\en*o{}%
             }
%
\long\def\en*w#1{{\def\rm{\noexpand\rm}\def\it{\noexpand\it}%
   \def\underscore{\noexpand\us}\let\us=\underscore%
   \def\bd{\noexpand\bd}\def\cc{\noexpand\cc}\def\tt{\noexpand\tt}%
   \def\c{\noexpand\c}\def\L{\noexpand\L}\def\AA{\noexpand\AA}%
   \def\d{\noexpand\d}\def\O{\noexpand\O}\def\t{\noexpand\t}%
   \def\b{\noexpand\b}%
   \immediate\write\en*f{#1}}%
}% end definition of en*w
%
\def\printendnotes{\immediate\closeout\en*f%
   \begingroup%
   \input text1xx.endnotes%
   \par%
   \endgroup%
   \global\def\en*o{\immediate\openout\en*f=text1xx.endnotes%
                 \immediate\write\en*f{\the\*enpar}%
                 \edef\T{\par\vskip\the\en*s\relax}%
                 \immediate\write\en*f{\T}%
                 \global\def\en*o{}}%
   \setendnotenumber{0}}%
\let \pen=\printendnotes
%
\message{set command, }
%
%
\def\set#1#2{\l*alphafalse
\ifx#2\appendixnumber
    \edef\T{\the\*ap*num}%
    \E=\*ap*st%
 \else\ifx#2\chapternumber
           \edef\T{\the\*ch*num}%
           \E=\*ch*st%
 \else\ifx#2\endnotenumber
           \edef\T{\the\en*n}%
           \if*ten*num         \E=1%            % all numeric styles
             \else\l*alphatrue \E=2%            % all alpha styles
                  \fi%
 \else\ifx#2\figurenumber
           \edef\T{\the\fi*n}%
           \E=1%
 \else\ifx#2\footnotenumber
           \edef\T{\the\fn*num}%
           \if*tfn*dnum        \E=1%            % "1." style
             \else\if*tfn*unum \E=1%            % "1" style
             \else\if*tfn*pnum \E=1%            % "(1)" style
             \else\l*alphatrue \E=2%            % "a.", "a", and "(a)"
                  \fi\fi\fi%
 \else\ifx#2\partnumber
           \edef\T{\the\*pt*num}%
           \E=\*pt*st%
 \else\ifx#2\pagenumber
           \ifnum  \pageno<0 \edef\T{\romannumeral-\pageno}%
             \else \edef\T{\number\pageno}\fi%
           \E=1%
 \else\ifx#2\subheadanumber
           \edef\T{\the\*sa*num}%
           \E=\sa*st%
 \else\ifx#2\subheadbnumber
           \edef\T{\the\*sb*num}%
           \E=\sb*st%
 \else\ifx#2\subheadcnumber
           \edef\T{\the\*sc*num}%
           \E=\sc*st%
 \else\ifx#2\subheaddnumber
           \edef\T{\the\*sd*num}%
           \E=\sd*st%
 \else\ifx#2\tablenumber
           \edef\T{\the\ta*n}%
           \E=1%
 \else\message{<TEXT1> Error! You've entered a number I know nothing
       about. I'm going to ignore it and try to proceed.}%
           \E=0%
  \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi%
\null                           % So, why is this needed??
\ifcase\E                       % NOP
   \or                          % set to a digit or lower case roman
      \expandafter\xdef\csname#1\endcsname{\T}%
   \or                          % set to a letter (upper or lower)
      \expandafter\xdef\csname#1\endcsname{{\a*c{\T}}}%
   \or                          % set to an uppercase roman numeral
      \expandafter\xdef\csname#1\endcsname{%
            \uppercase\expandafter{\romannumeral\T}}%
                       \fi}%
%
\message{centering, }
%
%   CENTERLINE                                          Rev.  9/6/88 drg
%
% Centerline with single and multiple line capabilities
\newif\if*afn*cl
\def\centerline#1{\par % Begin centerline markup
    \*afn*clfalse
    \B={}
    \N=0
    \bgroup
    \parindent=\z@ \relax            % zero indent
    \parfillskip=0pt plus1fil \relax % infinite stretch
    \everypar{\null\hskip0pt plus1fil\relax} % add infinite glue
    \def\linebreak{\hskip0pt plus1fil\relax\break
                   \null\hskip0pt plus1fil\relax}%
    \let\lbr=\linebreak
    \let\toclinebreak=\space
    \let\toclbr=\space
    \justify
    \let\*vfn=\vfootnote
    \let\*afn=\autofootnote
    \def\vfootnote##1##2{\edef\T{\the\B\noexpand\vfootnote{##1}{##2}}
               \global\B=\expandafter{\T}}
    \def\autofootnote{\global\*afn*cltrue
          \global\advance\N by 1   % count the notes done
          \*afn}
    \let\afn=\autofootnote
    \let\*fn=\footnote
    \def\footnote##1{\global\*afn*cltrue \*fn{##1}}
    \setbox\A=\vbox{#1\par % added to make skip with multiple lines
                      \global\C=\baselineskip
                      \setbox0=\hbox{(}
                      \global\advance\C by-\ht0}% end vbox
    \global\advance\fn*num by -\N    %subtract the number of notes done
    \let\autofootnote=\*afn \let\afn=\autofootnote
    \let\footnote=\*fn
    \let\vfootnote=\*vfn
    \ifdim\ht\A>\baselineskip \else \C=\z@ \fi
    \line{\hss\vbox{\vskip\C#1\par}\hss}% print centered lines
    \egroup
    \if*afn*cl           % then there were footnotes in the \cl
       \the\B
       \fi
    }% End centerline markup
\let\cl=\centerline
%
%   CENTER MULTIPLE LINES
%
\newif\if*ctrl                       % centerline indicator
\*ctrlfalse
\def\centerlinesbegin{\par\global\*ctrltrue
    \begingroup\pin{0pt}\psk{0pt}\leftskip=0pt plus1fil
    \parfillskip=0pt \rightskip=0pt plus1fil\obeylines\ignorespaces}%
\let\clb=\centerlinesbegin
\def\centerlinesend{\endgroup\par}
\let\cle=\centerlinesend
%
%   rightline      par added to PLAIN TEX macro
%
\long\def\rightline#1{\par\line{\hss#1}}
\let\rl=\rightline
%
%   right align multiple lines
%
\def\rightlinesbegin{\par\begingroup\parskip=0pt\parfillskip=0pt
    \leftskip=0pt plus1fil\obeylines}%
\let\rlb=\rightlinesbegin
\def\rightlinesend{\endgroup\par}%
\let\rle=\rightlinesend
%
\message{asis, }
%
%                 As is  or format off
%
\newskip\*aisb  \*aisb = 6pt     % Default skip before
\newskip\*aisa  \*aisa = 6pt     % Default skip after
\newtoks\*aif   \*aif={\leftindent{0in}}
\newif\if*aib   \*aibfalse           % centerline indicator
%
\def\asisformat#1{{%
  \def\everyasis##1{\global\*aif{##1}}%
  \def\skipbefore##1{\global\*aisb=##1\relax}%
  \def\skipafter##1{\global\*aisa=##1\relax}%
  \relax
 #1}} % end of asisformat
\let\aif=\asisformat
%
%                 As is  or format off
\def\asisbegin{\par\*aibtrue\vskip\*aisb\relax\nointerlineskip
    \begingroup
    \let\*afn=\autofootnote          % save definition of autofootnote
               \def\leftindent##1{%
                     \*zerofalse \*okfalse
                     \e*p##1\end%
                     \if*zero \leftskip 0pt \fi
                     \advance \leftskip by ##1}%
               \let\lin=\leftindent
%
    \def\autofootnote{\endgroup      % end asis format
        \futurelet\next\ck*chr}%       pick next character, then check the pick
    \let\afn=\autofootnote           % reset abbreviation for autofootnote
    \def\ck*chr{\ifcat\bgroup        % if left brace
                   \noexpand\next    % do nothing
                    \let\next\gather % next equals gather
                 \else               % no brace present
                     \let\next\re*group\fi % stop if no brace encountered
          \next}%
    \def\gather{\*afn                % call normal autofootnote
                \bgroup              % furnish left brace, read group
                \aftergroup\re*group % reset asis format
                \let\next}%            eat curly brace in text
                                     % group ends at text right curly brace
    \def\re*group{\*asisb}%            restore asis group
%
   \def\*asisb{\begingroup
               \def\singlespace{\baselineskip=\*isk}%
               \let\ssp=\singlespace
               \def\doublespace{\baselineskip=2\*isk}%
               \let\dsp=\doublespace
               \def\par{\leavevmode\endgraf}%
               \parskip0pt\parindent0pt
               \the\*aif
               \setupverbatim}\*asisb}
 {\obeyspaces\gdef {\ }}
\def\obeyspaces{\@vobeyspaces}
{\catcode`\ =\active\gdef\@vobeyspaces{\catcode`\ \active\let \@xobeysp}}
\def\@xobeysp{\leavevmode\penalty10000\ }
\def\setupverbatim{\obeylines
                   \obeyspaces }
\let\aib=\asisbegin
\def\asisend{\endgroup\endgroup\vskip\*aisa\relax\*aibfalse}
\let\aie=\asisend
%
\message{box macros, }
%
%	Start of boxes
%
\font\dtscr=dt
%
%     Draw boxes
%
\newdimen\db*m            \db*m=3pt       % drawbox mat size
\newdimen\db*s            \db*s=.4pt      % drawbox rule size
\newdimen\db*sh		  \db*sh=0pt      % drawbox shadow size
\newdimen\db*om           \db*om=0pt      % drawbox outer mat size 
\newdimen\db*os           \db*os=0pt      % drawbox outer rule size
\newcount\db*ps           \db*ps=0        % drawbox percent of screen
%
\long\def\drawbox#1{\*box{\db*m}{\db*s}{\db*sh}{\db*om}{\db*os}{\db*ps}{#1}}
\let\db=\drawbox
%
\def\drawboxformat#1{{%
  \def\boxmat##1{\global\db*m=##1\relax}%
  \def\boxrule##1{\global\db*s=##1\relax}%
  \def\boxshadow##1{\global\db*sh=##1\relax}%
  \def\outerboxmat##1{\global\db*om=##1\relax}%
  \def\outerboxrule##1{\global\db*os=##1\relax}%
  \def\screen##1{\ifnum##1>64
			\message{<TEXT1> Error. Screen can only be 0 through 64}
			\global\db*ps=0
	 	 \else\ifnum##1<0
			\message{<TEXT1> Error. Screen can only be 0 through 64}
			\global\db*ps=0
		 \else \global\db*ps=##1\relax\fi\fi}%
  #1}} % end of drawboxformat
\let\dbf=\drawboxformat
%
\def\drawboxrulesize#1{\dbf{\boxrule{#1}}
  \message{<TEXT1> Warning: Use drawboxformat instead of drawboxrulesize}}
\let\dbrs=\drawboxrulesize
\def\drawboxmat#1{\dbf{\boxmat{#1}}
  \message{<TEXT1> Warning: Use drawboxformat instead of drawboxmat}}
\let\dbm=\drawboxmat
%
%     Paragraph boxes
%
\newdimen\pb*m            \pb*m=3pt       % paragraphbox mat size
\newdimen\pb*s            \pb*s=.4pt      % paragraphbox rule size
\newdimen\pb*sh		  \pb*sh=0pt      % paragraphbox shadow size
\newdimen\pb*om           \pb*om=0pt      % paragraphbox outer mat size 
\newdimen\pb*os           \pb*os=0pt      % paragraphbox outer rule size
\newcount\pb*ps           \pb*ps=0        % paragraphbox percent of screen
%
\long\def\paragraphbox#1{\par\hbox{%
	\*box{\pb*m}{\pb*s}{\pb*sh}{\pb*om}{\pb*os}{\pb*ps}{\vbox{%
                    \advance \hsize by -2\pb*m%
                    \advance \hsize by -2\pb*s%
   	  	    \advance \hsize by -2\pb*om%
	  	    \advance \hsize by -2\pb*os%
                    \hrule width \hsize height 0pt depth 0pt%
		    #1}}}}
\let\pb=\paragraphbox
%
\def\paragraphboxformat#1{{%
  \def\boxmat##1{\global\pb*m=##1\relax}%
  \def\boxrule##1{\global\pb*s=##1\relax}%
  \def\boxshadow##1{\global\pb*sh=##1\relax}%
  \def\outerboxmat##1{\global\pb*om=##1\relax}%
  \def\outerboxrule##1{\global\pb*os=##1\relax}%
  \def\screen##1{\ifnum##1>64
			\message{<TEXT1> Error. Screen can only be 0 through 64}
			\global\pb*ps=0
	 	 \else\ifnum##1<0
			\message{<TEXT1> Error. Screen can only be 0 through 64}
			\global\pb*ps=0
		 \else \global\pb*ps=##1\relax\fi\fi}%
  #1}} % end of paragraphboxformat
\let\pbf=\paragraphboxformat

%  parameter list for *box:
%	#1 = boxmat size   	#5 = outer boxrule   
% 	#2 = boxrule size       #6 = screen percent
%	#3 = box shadow size    #7 = value to be boxed
%	#4 = outer boxmat 
%
%	Uncoment these 2 lines if using the boxes outside of TEXT1
% 		\newbox\A
% 		\newdimen\D
%		\newcount\E
%
\long\def\*box#1#2#3#4#5#6#7{%
\ifdim #5>0pt  		% only if doing a "framed" box
	  \setbox\A=\vbox{\*box{#1}{#2}{#3}{0pt}{0pt}{#6}{#7}}%
          \*box{#4}{#5}{#3}{0pt}{0pt}{#6}{\box\A}%
  \else%
    \setbox\A=\vbox{\hrule height#2  		    % draw left side
        \hbox{\vrule width#2\hskip#1                % draw the top
           \vbox{\vskip#1
              \hbox{#7}
              \vskip#1}\hskip#1\vrule width#2}      % draw the bottom
        \hrule height#2}                            % draw the right side
    \ifdim #3=0pt \*scr{#6}{\box\A}		    % print if not a shadow
	\else   \D=\ht\A
		\advance \D by -#3
	  	\vbox{\hbox{\vrule width #3 height \D depth 0pt
		            \*scr{#6}{\copy\A}}
		      \hrule width \wd\A height #3 depth 0pt}
    \fi
  \fi}

%	#1 = Screen percent
%	#2 = box to be printed

\def\*scr#1#2{\ifnum#1=0 #2
	\else \setbox\A=\vbox{#2}
	      \D=\ht\A
	      \advance \D by \dp\A
	      \E=#1%
	      \advance \E by 48%
	      \hbox{\vbox{\vbox to \D{\leaders
		       	\hbox to \wd\A{\leaders\hbox{\dtscr\char\E}\hfill}
			\vfill}
	       	\vskip -\D
	        \box\A}}     
	\fi
}
%
%	End of boxes
%
\message{more misc, }
%
%   page skip
%
\def\newpage{\vfil\break}% changed from vfill to vfil 11/4/86 bth
\let\np=\newpage
%
%   emptypage
%
\def\emptypage{\global\advance\*pcount by1}% produces empty pages
\let\ep=\emptypage
%
\def\*blkpg{ % BLANK PAGE MACRO, produces the empty page
    \loop %                            checks the number of empty pages
       \*badj %                        check for binding adjust
       \shipout\vbox{\*setcrops{\vbox{
                     \makeheadline   % shipout page with headline
                     \vbox to\*txth{\vfil} % and  fooline only
                     \makefootline}}}
       \global\advance\*pcount by\m@ne % decrement empty page counter
       \advancepageno                % advance the page number
    \ifnum\*pcount>0                 % check for empty pages
    \repeat}% END, empty page macro
%
\message{enumeration macros, }
%
%   List Level Macros
%
\newcount\ll*n             % Current list level number
\newcount\*toklimit
\newcount\*countlimit
\newcount\ll*stb           % list style start
\newcount\ll*cs            % list*enum*value*start
\newcount\ll*cmps          % list compare start
\newcount\ll*cmpe
\newcount\ll*lc            % Last level called
\*toklimit = 188           % Positions 224-253 are used for the 30 table column justification
                           % Positions 199-223 are used for the 25 different list level styles
                           % Tokens below 199 are available for \newtoks use.
                           % Token 190 is the build token
                           % 191-197 is the list level formats, level 1-7
                           % 198 is the bullet format
%
\*countlimit = 236         % Counters 244-250 are the styles for the 7 list levels
                           % Counters 237-243 are the enum counters for the 7 list levels
                           % Counters below 237 are available for \newcount use.
%
\ll*stb = 244              % Counters 244-250 correspond to the 7 list level styles,
                           %         value is index into tokens 199-223
\ll*cs = 237               % Counters 237-243 correspond to the 7 list level enum values.
\ll*cmps = 199             % Where to start in the \toks values for the 25 different list level styles
\ll*cmpe = 223             % Where to stop in the \toks values for the 25 different list level styles
%
\count244 = 1      % style "1."
\count245 = 4      % style "a."
\count246 = 7      % style "i."
\count247 = 2      % style "1)"
\count248 = 5      % style "a)"
\count249 = 8      % style "i)"
\count250 = 3      % style "(1)"
%
\newskip\ll*sb     \ll*sb = 0pt     % Default is no \vskip
\newskip\ll*sa     \ll*sa = 0pt       % Default is no \vskip
%
\toks191={\rm\leftindent{.5in}\gutter{1em}}      % level 1 indent is 5 characters initially
\toks192={\rm\leftindent{.8in}\gutter{1em}}      % level 2 indent
\toks193={\rm\leftindent{1.1in}\gutter{1em}}     % level 3 indent
\toks194={\rm\leftindent{1.4in}\gutter{1em}}     % level 4 indent
\toks195={\rm\leftindent{1.7in}\gutter{1em}}     % level 5 indent
\toks196={\rm\leftindent{2in}\gutter{1em}}       % level 6 indent
\toks197={\rm\leftindent{2.3in}\gutter{1em}}     % level 7 indent
\toks198={\rm\leftindent{+.5in}\gutter{1em}}     % bullets
%
                           % The 25 different List level styles:
\toks199 = {1.}            % Style 1
\toks200 = {1)}            %       2
\toks201 = {(1)}           %       3
\toks202 = {a.}            %       4
\toks203 = {a)}            %       5
\toks204 = {(a)}           %       6
\toks205 = {i.}            %       7
\toks206 = {i)}            %       8
\toks207 = {(i)}           %       9
\toks208 = {I.}            %      10
\toks209 = {I)}            %      11
\toks210 = {(I)}           %      12
\toks211 = {A.}            %      13
\toks212 = {A)}            %      14
\toks213 = {(A)}           %      15
\toks214 = {1]}            %      16
\toks215 = {[1]}           %      17
\toks216 = {a]}            %      18
\toks217 = {[a]}           %      19
\toks218 = {i]}            %      20
\toks219 = {[i]}           %      21
\toks220 = {I]}            %      22
\toks221 = {[I]}           %      23
\toks222 = {A]}            %      24
\toks223 = {[A]}           %      25
%
\newif\if*check    % True unless done parsing \listformat
\newif\ifll*lp
\newif\ifll*rp
\newif\if*lsqb
\newif\if*rsqb
\newif\ifll*per
\newif\ifll*dig
\newif\ifl*alpha
\newif\if*u*alpha
\newif\if*l*roman
\newif\if*u*roman
\newif\ifll*nil
%
\ll*niltrue
%
\outer\def\newtoks{\alloc@5\toks\toksdef\*toklimit}
\outer\def\newcount{\alloc@0\count\countdef\*countlimit}
%
%
%  Macros for producing enumerated list levels.
%
%
\def\listformat#1{{\begingroup%
          \def\liststyle##1{\par\N = 1
                            \toks190 = {}
                            \Z##1\end}%
          \def\Z##1{\ifx ##1\end \Y
                                 \let \next = \relax
                    \else \ifnum \N > 7
                                 \message{<TEXT1> Error! Too many list levels specified, 7 is max.
                                          Statement ignored.}
                                 \let \next = \Z
                          \else \ifx ##1, \Y
                                          \advance \N by 1
                                          \toks190 = {}
                                          \let \next = \Z
                                \else \toks190 = \expandafter{\the\toks190 ##1}
                                      \let \next = \Z
                   \fi\fi\fi\next}%
          \def\Y{\*tempiffalse
                 \*checktrue
                 \E = \ll*cmps
                 \loop \ifnum \E > \ll*cmpe
                              \*checkfalse
                              \*tempiftrue
                       \else  \edef\T{\the\toks190}%
                              \edef\U{\the\toks\E}%
                              \ifx\T\U
                                        \*checkfalse
                                        \F = \ll*stb
                                        \advance \F by -1
                                        \advance \F by \N
                                        \count\F = \E
                                        \advance \count\F by -\ll*cmps
                                        \global\advance \count\F by 1
                        \fi\fi
                   \if*check% Then
                              \advance \E by 1
                   \repeat
             \if*tempif \message{<TEXT1> Error! \the\toks190 is an invalid list
                                             level style. It will be ignored}
                 \fi}%
          \def\skipbefore##1{\global\ll*sb = ##1\relax}%
          \def\skipafter##1{\global\ll*sa = ##1\relax}%
          \def\everylistlevel##1##2{\ifcase ##1
                \or \global\toks191 = {##2}
                \or \global\toks192 = {##2}
                \or \global\toks193 = {##2}
                \or \global\toks194 = {##2}
                \or \global\toks195 = {##2}
                \or \global\toks196 = {##2}
                \or \global\toks197 = {##2}
                \fi}%
          \def\everybullet##1{\global\toks198 = {##1}}%
          \relax
          #1
          \endgroup}}
%
\let \lif = \listformat
%
\def\listbegin{\vskip\ll*sb\relax
               \ll*nilfalse
               \begingroup
               \global\ll*lc = 0
               \ll*ini1
 }
\let\lib=\listbegin
%
\def\listend{\vskip\ll*sa\relax
             \endgroup
             \ll*niltrue
}
\let\lie=\listend
%
\def\listlevel#1{\par
                 \ifll*nil \message{<TEXT1> Warning, listbegin was not
                                    specified. The left margin indent will be set to zero.}
                                \else \if*dbl \else \if*tpl
       % If in multiple columns, don't end the group. Do so otherwise
                                      \else \endgroup
                                            \begingroup
                                            \fi\fi
                                      \fi
                 \*tempiftrue                           % Usually not quite so pessimistic
                 \ifcat 1#1 \ifnum #1 < 8 \*tempiffalse % OK if \listlevel1-\listlevel7
                     \fi\fi
                 \if*tempif \message{<TEXT1> Warning, invalid list level "#1",
                                                 listlevel1 will be used instead.}
                                     \listlevel1
                      \else \E = #1
                            \global\ll*n = \E
                            \advance \E by 1
                            \ll*ini\E
                            \par
                            \ll*fmt
                            \noindent
                            \txt*in{\ll*p{#1}}
                      \fi
}
\let \lil = \listlevel
%
\def\txt*in#1{\hbox to 0pt{\hss{#1}\hskip\*gut}\ignorespaces}
%
\def\ll*fmt{\*gut=1em
                  \ifcase \the\ll*n
                            \or \the\toks191
                            \or \the\toks192
                            \or \the\toks193
                            \or \the\toks194
                            \or \the\toks195
                            \or \the\toks196
                            \or \the\toks197
                            \fi}
%
\def\listresume{% rev. 7/6/87
    \if*start*bul\global\advance\ll*n by 1\global\*start*bulfalse\fi
                                     % account for bulleted list ffems
    \ifnum \ll*n < 2 \lin{0pt}
                     \global\ll*n = 1
               \else \global\advance \ll*n by -1
                     \ll*fmt
                     \fi
                \noindent\ignorespaces}
%
\let\lir=\listresume
%                              Evaluate Style
\def\e*s{%
    \global\ll*lpfalse
    \global\ll*rpfalse
    \global\*lsqbfalse
    \global\*rsqbfalse
    \global\ll*perfalse
    \global\ll*digfalse
    \global\l*alphafalse
    \global\*u*alphafalse
    \global\*l*romanfalse
    \global\*u*romanfalse
    \ifcase \count\F
            \or \global\ll*digtrue \global\ll*pertrue                        % Style  1
            \or \global\ll*digtrue \global\ll*rptrue                         %        2
            \or \global\ll*digtrue \global\ll*rptrue \global\ll*lptrue       %        3
            \or \global\l*alphatrue \global\ll*pertrue                       %        4
            \or \global\l*alphatrue \global\ll*rptrue                        %        5
            \or \global\l*alphatrue \global\ll*rptrue \global\ll*lptrue      %        6
            \or \global\*l*romantrue \global\ll*pertrue                      %        7
            \or \global\*l*romantrue \global\ll*rptrue                       %        8
            \or \global\*l*romantrue \global\ll*rptrue \global\ll*lptrue     %        9
            \or \global\*u*romantrue \global\ll*pertrue                      %       10
            \or \global\*u*romantrue \global\ll*rptrue                       %       11
            \or \global\*u*romantrue \global\ll*rptrue \global\ll*lptrue     %       12
            \or \global\*u*alphatrue \global\ll*pertrue                      %       13
            \or \global\*u*alphatrue \global\ll*rptrue                       %       14
            \or \global\*u*alphatrue \global\ll*rptrue \global\ll*lptrue     %       15
            \or \global\ll*digtrue \global\*rsqbtrue                         %       16
            \or \global\ll*digtrue \global\*rsqbtrue \global\*lsqbtrue       %       17
            \or \global\l*alphatrue \global\*rsqbtrue                        %       18
            \or \global\l*alphatrue \global\*rsqbtrue \global\*lsqbtrue      %       19
            \or \global\*l*romantrue \global\*rsqbtrue                       %       20
            \or \global\*l*romantrue \global\*rsqbtrue \global\*lsqbtrue     %       21
            \or \global\*u*romantrue \global\*rsqbtrue                       %       22
            \or \global\*u*romantrue \global\*rsqbtrue \global\*lsqbtrue     %       23
            \or \global\*u*alphatrue \global\*rsqbtrue                       %       24
            \or \global\*u*alphatrue \global\*rsqbtrue \global\*lsqbtrue     %       25
            \fi}
 
%
\def\ll*ini#1{\*start*bulfalse
               \ifnum #1 < 7 \N = #1
                             \advance \N by -1
                             \loop \ifnum \N < 7         % Loop max of 7 times
                                          \E = \N
                                          \advance \E by \ll*cs
                                          \global\count\E = 0
                                          \advance \N by 1
                                          \repeat
                             \fi}           % else don't initialize when \lil7
%
\def\ll*p#1{%
           \E = #1
           \advance \E by \ll*cs
           \advance \E by -1                 % \E is the listlevel value counter
           \F = \E
           \advance \F by 7
           \global\advance \count\E by 1     % Increment the list level counter
     %
     % If this level is same as previous level, no need to re-evaluate
     % the style to be used.
     %
           \ifnum \ll*lc = #1
                  \else \e*s
                        \global\ll*lc = #1
                  \fi
     %
     % Print the prefix punctuation
     %
           \ifll*lp  (\unskip                    % Styles 3, 6, 9, 12, 15
              \else \if*lsqb [\unskip            % Styles 17, 19, 21, 23, 25
                   \fi\fi
     %
     % Print the listlevel value, i.e. "1", "a", "A", "I", or "i".
     %
           \ifll*dig                            % Then its a style using digits
                          \number\count\E       % Print the number
                          \unskip               % To get rid of any following extra spaces
                  \else \ifl*alpha              % Then its a style with lower case letters
                          \a*c{\count\E}        % Print the lower case letters
                          \unskip               % To get rid of any following extra spaces
                  \else \if*u*alpha             % Then its a style with upper case letters
                          \a*c{\count\E}        % Print uppercase alpha
                          \unskip               % To get rid of any following extra spaces
                  \else \if*l*roman             % Then its a style with lower case roman numerals
                          \romannumeral\count\E % Print the lower case roman numeral
                          \unskip               % To get rid of any following extra spaces
                  \else \if*u*roman             % Print upper case roman numeral
                          \uppercase\expandafter{\romannumeral\count\E}
                          \unskip               % To get rid of any following extra spaces
                  \else \message{<TEXT1> Error! Something is awry in the listlevel style. Call a consultant.}
                  \fi\fi\fi\fi\fi
     %
     % Print the suffix punctuation
     %
           \ifll*per .\unskip             % Styles 1, 4, 7, 10, 13
              \else \ifll*rp )\unskip     % Styles 2, 3, 5, 6, 8, 9, 11, 12, 14, 15
                 \else \if*rsqb ]\unskip  % Styles 16, 17, 18, 19, 20, 21, 22, 23, 24, 25
           \fi\fi\fi
}
     %
     % This macro will convert an integer into a letter. In Appendix F of the
     % TeXbook you will see that octal character '141 is the small letter "a".
     % Octal 141=Decimal 97, Therefore, add 96 to value of listlevel counter.
     % For example, 1="a", 2="b", etc. The macro will also change 27="aa", 28="ab", etc.
     %
\def\a*c#1{%
  \ifnum #1 < 27 \G = #1%                 % Then its a single letter a-z
          \advance \G by 96%              % See the font table in App. F
          \ifl*alpha%                     % Then its a lower case style
                  \char\G%                % Print the character a-z
            \else \advance \G by -32%
                  \char\G%                % Print the character A-Z
            \fi%
    \else \G = #1%                        % else its "AA" or greater
          \divide \G by 26%               % This holds the first character
          \Q = #1%                        % Get ready to compute second letter
          \R = #1%
          \divide \R by 26%
          \multiply \R by 26%
          \ifnum #1 = \R%
                   \advance \G by -1%
                   \Q = 26%
             \else \advance \Q by -\R%
                   \fi%
          \a*c{\G}%                       % Get the first character a-z
          \unskip%
          \a*c{\Q}%                       % Get the second letter
          \fi}                            % End of \a*c
%
%  for setting the list level number other than sequential
%
\def\slln#1#2{{\E=#1
	     \advance \E by -1
	     \advance \E by \ll*cs
	     \global\count\E = #2}} 
\let\setlistlevelnumber=\slln
%
%  Bullets
%
\newif\if*start*bul
\newdimen\*bul*dim
\mathchardef\*bullet="220F
\def\bullet{% bullet defined for both math and text modes, rev. 6/25/87
    \ifmmode \*bullet                % math mode bullet
       \else                         % text or list bullet
          \ifll*nil                  % no list in progress, text bullet
             \leftskip = 0pt
             {\if*msp{*}\else\sy\char"0F\fi}
             \else                   % list in progress, list bullet
                \the\toks198
                \if*start*bul \lin{\*bul*dim}
                   \else \*bul*dim = \leftskip
                      \*start*bultrue \fi  % end starting bullet
                \par\noindent
                \txt*in{{\if*msp{*}\else\sy\char"0F\fi}}
             \fi % end list in progress check
       \fi % end math mode bullet check
}% end bullet
\let \bul=\bullet
%
%
%    The \gutter macro is actually used for several macros, \bul, \lil, etc.
%
\newdimen\*gut
\def\gutter#1{\*gut=#1}
\message{end of enumeration macros, }
\message{TOC, }
%
%    Macros for doing Table of Contents, Heads, Subheads, Tables, and Figures
%
\newtoks\*TCt   \*TCt={\cl{\twelvept\bd Table of Contents}\vs{1\bl}}
\newtoks\*ptf   \*ptf={\vs{1\bl}\cl{Part \partnumber}\cl{\parttitle}%
                        \vs{1\bl}\nin Part \partnumber \leader \pagenumber}
\newtoks\*ctf    \*ctf={\hangingchapternumber \chaptertitle \leader \pagenumber}
\newtoks\*atf    \*atf={\hangingappendixnumber \appendixtitle \leader \pagenumber}
\newtoks\*prtf   \*prtf={\nin \prefacetitle \leader \pagenumber}
\newtoks\*satf   \*satf={\leftindent{.5in}\nin \subheadatitle \leader \pagenumber}
\newtoks\*sbtf   \*sbtf={\leftindent{1in}\nin \subheadbtitle \leader \pagenumber}
\newtoks\*sctf   \*sctf={\leftindent{1.5in}\nin \subheadctitle \leader \pagenumber}
\newtoks\*sdtf   \*sdtf={\leftindent{2in}\nin \subheaddtitle \leader \pagenumber}
\newtoks\*btf    \*btf={\nin\bibtitle \leader \pagenumber}
\newtoks\*ftf    \*ftf={\hangingnumber{\figurenumber.} \figuretitle \leader \pagenumber}
\newtoks\*ftt    \*ftt={\newpage\cl{\twelvept\bd List of Figures}\line{Figure\hfill Page}}
\newtoks\*ttf    \*ttf={\hangingnumber{\tablenumber.}  \tabletitle\leader \pagenumber}
\newtoks\*ttt    \*ttt={\newpage\cl{\twelvept\bd List of Tables}\line{Table\hfill Page}}
\newtoks\*figt   \*figt={\bqb\tenpt\bd\hp Figure \figurenumber. \rm\figuretitle \bqe}
\newtoks\*tabt   \*tabt={\vs{\bl}\cl{\twelvept\bd Table \tablenumber}%
                         \cl{\twelvept\tabletitle}\vs{\bl}}
\newtoks\*partt  \*partt={\dumpinsertseject\titlepage
                          \hrule height 0pt depth 0pt\vfil
                          \cl{\twelvept\bd Part \partnumber}
                          \cl{\twelvept\bd\parttitle}
                          \vs{.5\tp*sk}
                          \np
                          \scn{0}\ssan{0}\ssbn{0}\sscn{0}\ssdn{0}
                          \sfn{0}\stn{0}\sfnn{0}\senn{0}
                          }%
\newtoks\*chapt  \*chapt={\dumpinsertseject
                          \cl{\twelvept\bd Chapter \chapternumber}%
                          \cl{\twelvept\bd\chaptertitle}
                          \vs{1\bl}
                          \ssan{0}\ssbn{0}\sscn{0}\ssdn{0}
                          }
\newtoks\*appt   \*appt={\dumpinsertseject %
                         \cl{\twelvept\bd Appendix \appendixnumber}
                         \cl{\twelvept\bd\appendixtitle}
                         \vs{1\bl}
                         \scn{0}\ssan{0}\ssbn{0}\sscn{0}
                         \ssdn{0}\sfn{0}\stn{0}
                         }
\newtoks\*pret   \*pret={\dumpinsertseject %
                         \cl{\twelvept\bd\prefacetitle}
                         \vs{1\bl}
                         \ssan{0}\ssbn{0}\sscn{0}\ssdn{0}
                         }%
\newtoks\*subat  \*subat={\removelastskip\goodbreak
                          \vs{2\bl}
                          \nin\twelvept\bd\subheadatitle\par\nobreak
                          \vs{1\bl}\nobreak
                          \ssbn{0}\sscn{0}\ssdn{0}
                          }
\newtoks\*subbt  \*subbt={\removelastskip\goodbreak
                          \vs{2\bl}
                          \nin\twelvept\it\subheadbtitle\par\nobreak
                          \vs{1\bl}\nobreak
                          \sscn{0}\ssdn{0}
                          }
\newtoks\*subct  \*subct={\removelastskip\goodbreak
                          \vs{2\bl}
                          \nin\twelvept\subheadctitle\par\nobreak
                          \vs{1\bl}\nobreak
                          \ssdn{0}
                          }
\newtoks\*subdt   \*subdt={\goodbreak\twelvept\it\subheaddtitle.}
%
\newif\if*cont*chap   \*cont*chapfalse
\newif\if*TC*fig     \*TC*figtrue
\newif\if*TC*tab     \*TC*tabtrue
\newif\if*TC*prt     \*TC*prttrue
\newif\if*TC*chp     \*TC*chptrue
\newif\if*TC*app     \*TC*apptrue
\newif\if*TC*pre     \*TC*pretrue
\newif\if*TC*sha     \*TC*shatrue
\newif\if*TC*shb     \*TC*shbtrue
\newif\if*TC*shc     \*TC*shcfalse
\newif\if*TC*shd     \*TC*shdfalse
\newif\if*TCaopen    \*TCaopenfalse
\newif\if*TCbopen    \*TCbopenfalse
\newif\if*TCcopen    \*TCcopenfalse
%
\newdimen\*ch*hi     \*ch*hi=.25in
\newdimen\*ap*hi     \*ap*hi=.25in
\newdimen\fi*hi      \fi*hi=.25in
\newdimen\ta*hi      \ta*hi=.25in
%
\newcount\fi*n          \fi*n=0
\newcount\ta*n          \ta*n=0
\newcount\*pt*num       \*pt*num=0
\newcount\*pt*st        \*pt*st=1
\newcount\*ch*num       \*ch*num=0
\newcount\*ch*st        \*ch*st=1
\newcount\*ap*num       \*ap*num=0
\newcount\*ap*st        \*ap*st=2
\newcount\*sa*num       \*sa*num=0
\newcount\sa*st         \sa*st=1
\newcount\*sb*num       \*sb*num=0
\newcount\sb*st         \sb*st=1
\newcount\*sc*num       \*sc*num=0
\newcount\sc*st         \sc*st=1
\newcount\*sd*num       \*sd*num=0
\newcount\sd*st         \sd*st=1
%
\newwrite\TC*fa
\newwrite\TC*fb
\newwrite\TC*fc
%                        putincontents last modified 12/6/91
\def\notintoc#1{#1}
\newtoks\*toclbla
\newtoks\*toclblb
\newtoks\*toclblc
\if*PC
	\*toclbla={text1xx.tc1}
	\*toclblb={text1xx.tc2}
	\*toclblc={text1xx.tc3}
\else
	\*toclbla={text1xx.toc1}
	\*toclblb={text1xx.toc2}
	\*toclblc={text1xx.toc3}
\fi

\long\def\putincontents#1#2{\begingroup\ifcase #1 % Putincontents markup
 	  \message{<TEXT1> Warning, request for Contents entry other than
                      1, 2, or 3. Contents 1 will be assumed.}
             \putincontents1{#2}
       \or \if*TCaopen      % Do nothing if open, else open it
              \else \immediate\openout\TC*fa=\the\*toclbla
                    \immediate\write\TC*fa{\the\*TCt}%
                    \global\*TCaopentrue
              \fi
	   \*defnoexpands
           \edef\T{\leftskip=0pt #2}%
           \edef\next{\write\TC*fa{\T\par}}%
           \next\relax
       \or \if*TCbopen      % Do nothing if open, else open it
              \else \immediate\openout\TC*fb=\the\*toclblb
                    \immediate\write\TC*fb{\the\*ftt}%
                    \global\*TCbopentrue\fi 
	   \*defnoexpands
           \edef\T{#2}%
           \edef\next{\write\TC*fb{\T\par}}%
           \next\relax
       \or \if*TCcopen      % Do nothing if open, else open it
              \else \immediate\openout\TC*fc=\the\*toclblc
                    \immediate\write\TC*fc{\the\*ttt}%
                    \global\*TCcopentrue\fi
	   \*defnoexpands
           \edef\T{#2}%
           \edef\next{\write\TC*fc{\T\par}}%
           \next\relax
       \else \message{<TEXT1> Warning, request for Contents entry other than
                      1, 2, or 3. Contents 1 will be assumed.}
             \putincontents1{#2}
       \fi\endgroup}% End putincontents markup
\let\pic=\putincontents

\def\*defnoexpands{%
           \def\AA{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\AA}%
           \def\aa{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\aa}%
           \def\appendixnumber{\noexpand\noexpand\noexpand\san{\the\*ap*num}%
                               \noexpand\noexpand\noexpand\appendixnumber}%
           \def\autoendnote##1{}%
           \let\aen=\autoendnote%
           \def\autofootnote##1{}%
           \let\afn=\autofootnote%
           \def\bullet{\noexpand\noexpand\noexpand\bullet}%
           \let\bul=\bullet%
           \def\centerline##1{\noexpand\noexpand\noexpand\noexpand\noexpand%
               \noexpand\noexpand\centerline{##1}}%
           \let\cl=\centerline%
           \def\chapternumber{\noexpand\noexpand\noexpand\scn{\the\*ch*num}%
                              \noexpand\noexpand\noexpand\chapternumber}%
           \def\dag{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\dag}%
           \def\ddag{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\ddag}%
           \def\eightteenpt{\noexpand\noexpand\noexpand\eightteenpt}%
           \def\fourteenpt{\noexpand\noexpand\noexpand\fourteenpt}%
           \def\hangingappendixnumber{\noexpand\noexpand\noexpand%
			       \hangingappendixnumber{\the\*ap*num}}%
           \def\hangingchapternumber{\noexpand\noexpand\noexpand%
			       \hangingchapternumber{\the\*ch*num}}%
           \def\hangingindent##1{\noexpand\noexpand\noexpand%
				\hangingindent{##1}}%
           \let\hin=\hangingparagraph%
           \def\hangingnumber##1{\noexpand\noexpand\noexpand\HFN{##1}}%
           \def\hangingparagraph{\noexpand\noexpand\noexpand\hangingparagraph}%
           \let\hp=\hangingparagraph%
           \def\justify{\noexpand\noexpand\noexpand\noexpand\noexpand\justify}%
           \let\ju=\justify%
           \def\leavevmode{\noexpand\noexpand\noexpand\leavevmode}%
           \def\leftindent##1{\leftskip=##1}%
           \let\lin=\leftindent%
           \let\linebreak=\space%
           \let\lbr=\space%
           \def\neg{\noexpand\noexpand\noexpand\noexpand\noexpand\neg}%
           \def\notintoc##1{}%
           \def\pagenumber{\noexpand\pagenumber}%
           \def\pn{\noexpand\pagenumber}%
           \def\par{\endgraf}%
           \def\paragraph{\endgraf}%
           \def\partnumber{\noexpand\noexpand\noexpand\sptn{\the\*pt*num}%
                           \noexpand\noexpand\noexpand\partnumber}%
           \def\subheadanumber{\noexpand\noexpand\noexpand\ssan{\the\*sa*num}%
                               \noexpand\noexpand\noexpand\subheadanumber}%
           \def\subheadbnumber{\noexpand\noexpand\noexpand\ssbn{\the\*sb*num}%
                               \noexpand\noexpand\noexpand\subheadbnumber}%
           \def\subheadcnumber{\noexpand\noexpand\noexpand\sscn{\the\*sc*num}%
                               \noexpand\noexpand\noexpand\subheadcnumber}%
           \def\subheaddnumber{\noexpand\noexpand\noexpand\ssdn{\the\*sd*num}%
                               \noexpand\noexpand\noexpand\subheaddnumber}%
           \def\tenpt{\noexpand\noexpand\noexpand\tenpt}%
           \def\tilde{\noexpand\noexpand\noexpand\noexpand\noexpand\tilde}%
           \def\toclinebreak{\noexpand\noexpand\noexpand\toclinebreak}%
           \def\toclbr{\noexpand\noexpand\noexpand\toclinebreak}%
           \def\twelvept{\noexpand\noexpand\noexpand\twelvept}%
           \def\underscore##1{\noexpand\noexpand\noexpand\noexpand\noexpand%
               \noexpand\noexpand\underscore{##1}}%
           \let\us=\underscore%
           \def\\{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\\}%
           \def\{{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\{}%
           \def\}{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\}}%
           \def\_{\noexpand\noexpand\noexpand\noexpand\noexpand%
		\noexpand\noexpand\_}%
}
%
\def\tableofcontentsformat#1{{%
      \def\continuechapter##1{\global\*cont*chapfalse
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U \global\*cont*chaptrue
                 \else \ifx \T\V   % Not continue chapter
                       \else \message{<TEXT1> Warning, argument to
                                      continuechapter is not "yes" or "no".
                                      "no" will be assumed}
                 \fi\fi}%
      \def\toctitle##1{\global\*TCt={##1}}%
      \def\parttocformat##1{\global\*ptf={##1}}%
      \def\chaptertocformat##1{\global\*ctf={##1}}%
      \def\hangingchapterindent##1{\global\*ch*hi=##1}%
      \def\appendixtocformat##1{\global\*atf={##1}}%
      \def\hangingappendixindent##1{\global\*ap*hi=##1}%
      \def\prefacetocformat##1{\global\*prtf={##1}}%
      \def\subheadatocformat##1{\global\*satf={##1}}%
      \def\subheadbtocformat##1{\global\*sbtf={##1}}%
      \def\subheadctocformat##1{\global\*sctf={##1}}%
      \def\subheaddtocformat##1{\global\*sdtf={##1}}%
      \def\bibliographytocformat##1{\global\*btf={##1}}%
      \def\figuretoctitle##1{\global\*ftt={##1}}%
      \def\figuretocformat##1{\global\*ftf={##1}}%
      \def\hangingfigureindent##1{\global\fi*hi=##1}%
      \def\tabletoctitle##1{\global\*ttt={##1}}%
      \def\tabletocformat##1{\global\*ttf={##1}}%
      \def\hangingtableindent##1{\global\ta*hi=##1}%
   #1}}
\let\tocf=\tableofcontentsformat
%          		tableofcontents last modified on 12/6/91
\def\tableofcontents#1{%
      \edef\T{}\edef\U{#1}\ifx\T\U\E=-3\else\E=#1\fi
      \dumpinsertseject
      \setpagenumber{\E}
      \immediate\closeout\TC*fa
      \begingroup
      \def\noexpand{}
      \def\centerline##1{\par % Begin centerline markup
         \bgroup
         \parindent=0pt \relax           % zero indent
         \parfillskip=0pt plus1fil \relax
         \everypar{\null\hskip0pt plus1fil\relax} % add infinite glue
         \def\linebreak{\hskip0pt plus1fil\relax\break
                        \null\hskip0pt plus1fil\relax}%
         \let\toclinebreak=\linebreak  % linebreak is a space in text1xx.
         \let\toclbr=\linebreak        % toc1, toclbr available in toc
         \justify
         \setbox\A=\vbox{##1\par % figure skip for multiple centerline
                         \global\C=\baselineskip
                         \setbox0=\hbox{(}
                         \global\advance\C by-\ht0}% end vbox
      \line{\hss\vbox{\vskip\C##1\par}\hss} %
         \egroup
      }% End centerline markup
      \let\cl=\centerline
      \justify
      \parfillskip=0pt
      \rightskip=0pt plus 5em
      \input \the\*toclbla
      \endgraf
      \leftskip=0pt
      \if*TCbopen     % True only if figures were used.
                   \immediate\closeout\TC*fb
                   \input \the\*toclblb
                   \fi
      \if*TCcopen     % True only if tables were used.
                   \immediate\closeout\TC*fc
                   \input \the\*toclblc
                   \fi
      \endgroup}
\let\toc=\tableofcontents
%
\message{part, }
%
\long\def\partformat#1{{%
      \def\numberingstyle##1{\global\*pt*st=1
              \edef\T{##1}%
              \edef\U{1}%
              \edef\V{A}%
              \edef\W{I}%
              \ifx \T\U     % then style=1, the default
                   \else \ifx \T\V \global\*pt*st=2
                         \else \ifx \T\W \global\*pt*st=3
                               \else \message{<TEXT1> Warning, numbering style
                                              in the partformat command is
                                              invalid. Style 1 will be assumed.}
                   \fi\fi\fi}%
      \long\def\titleformat##1{\global\*partt={##1}}%
      \def\incontents##1{\global\*TC*prttrue
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U              % Already true
                 \else \ifx \T\V \global\*TC*prtfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in partformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    #1}}
\let\paf=\partformat
%
\def\parttitle{}
\def\part#1{\par % Part revised 11/5/86
    \global\def\parttitle{#1}%
    \global\advance \*pt*num by 1
    \bgroup
       \let\toclinebreak=\space      % prevent linebreak in title
       \let\toclbr=\space            % break in contents only
       \the\*partt                   % This prints the title in the text
    \egroup
    \par
    \D=\lastskip
    \removelastskip
    \if*TC*prt \putincontents1{\the\*ptf}\fi
    \ignorespaces
    \vs{\D}
}% END
%
\def\partnumber{{\ifcase \*pt*st
                    \or \the\*pt*num
                    \or \l*alphafalse
                        \a*c{\*pt*num}
                    \or \uppercase\expandafter{\romannumeral\the\*pt*num}
                    \fi}}
%
\def\setpartnumber#1{\global\*pt*num=#1}%
% \spn is setpagenumber
\let\sptn=\setpartnumber
%
\message{chapter, }
%
\long\def\chapterformat#1{{%
      \def\numberingstyle##1{\global\*ch*st=1
              \edef\T{##1}%
              \edef\U{1}%
              \edef\V{A}%
              \edef\W{I}%
              \ifx \T\U     % then style=1, the default
                   \else \ifx \T\V \global\*ch*st=2
                         \else \ifx \T\W \global\*ch*st=3
                               \else \message{<TEXT1> Warning, numbering style
                                              in the chapterformat command is
                                              invalid. Style 1 will be assumed.}
                   \fi\fi\fi}%
      \long\def\titleformat##1{\global\*chapt={##1}}%
      \def\incontents##1{\global\*TC*chptrue%
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U              % Already true
                 \else \ifx \T\V \global\*TC*chpfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in chapterformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    #1}}
\let\chf=\chapterformat
%
\def\chaptertitle{}
\def\chapter#1{\par 
    \global\def\chaptertitle{#1}%
    \global\advance \*ch*num by 1
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\*chapt                   % prints the title in the text
    \egroup
    \D=\lastskip
    \removelastskip
    \if*TC*chp \putincontents1{\the\*ctf}\fi
    \ignorespaces
    \vs{\D}
}% END chapter markup definition
%
\def\chapternumber{{\ifcase \*ch*st
                       \or \the\*ch*num
                       \or \l*alphafalse
                           \a*c{\*ch*num}
                       \or \uppercase\expandafter{\romannumeral\the\*ch*num}
                       \fi
                    \removelastskip}}
\let\chap=\chapter
%
\def\hangingchapternumber#1{\*ch*num=#1\laf{\labelwidth{\*ch*hi}}
    \label{\hskip\*ch*hi\llap{\chapternumber.}}}
%
\def\setchapternumber#1{\global\*ch*num=#1}%
\let\scn=\setchapternumber
%
\message{appendix,}
%
\long\def\appendixformat#1{{%
      \def\numberingstyle##1{\global\*ap*st=2
              \edef\T{##1}%
              \edef\U{1}%
              \edef\V{A}%
              \edef\W{I}%
              \ifx \T\U \global\*ap*st=1
                   \else \ifx \T\V \global\*ap*st=2
                         \else \ifx \T\W \global\*ap*st=3
                               \else \message{<TEXT1> Warning, numbering style
                                              in the appendixformat command is
                                              invalid. Style 2 will be assumed.}
                   \fi\fi\fi}%
      \long\def\titleformat##1{\global\*appt={##1}}%
      \def\incontents##1{\global\*TC*apptrue
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U              % Already true
                 \else \ifx \T\V \global\*TC*appfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in appendixformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    #1}}
\let\apf=\appendixformat
%
\def\appendixtitle{}
\def\appendix#1{% Appendix revised 11/3/86 (added toclinebreak)
    \global\def\appendixtitle{#1}%
    \global\advance \*ap*num by 1
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\*appt                    % prints the appendix title
    \egroup
    \D=\lastskip
    \removelastskip
    \if*TC*app \putincontents1{\the\*atf}\fi
    \ignorespaces
    \vs{\D}
}% END appendix markup definition
%
\def\appendixnumber{{\ifcase \*ap*st
                       \or \the\*ap*num
                       \or \l*alphafalse
                           \a*c{\*ap*num}
                       \or \uppercase\expandafter{\romannumeral\the\*ap*num}
                       \fi
                     \removelastskip}}
\let\app=\appendix
%
\def\hangingappendixnumber#1{\*ap*num=#1\laf{\labelwidth{\*ap*hi}}
    \label{\hskip\*ap*hi\llap{\appendixnumber.}}}
%
\def\setappendixnumber#1{\global\*ap*num=#1}%
\let\san=\setappendixnumber
%
\message{preface,}
%
\long\def\prefaceformat#1{{%
      \long\def\titleformat##1{\global\*pret={##1}}%
      \def\incontents##1{\global\*TC*pretrue
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U              % Already true
                 \else \ifx \T\V \global\*TC*prefalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in prefaceformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    #1}}
\let\prf=\prefaceformat
%
\def\prefacetitle{}
\def\preface#1{% Preface revised 11/3/86 (added toclinebreak)
    \global\def\prefacetitle{#1}%
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\*pret                    % prints the title in the text
    \egroup
    \D=\lastskip
    \removelastskip
    \if*TC*pre \putincontents1{\the\*prtf}\fi
    \ignorespaces
    \vs{\D}
}% END preface markup definition
\let\pre=\preface
%
\message{subheads,}
%
\long\def\subheadaformat#1{{%
      \def\numberingstyle##1{\global\sa*st=1
              \edef\T{##1}%
              \edef\U{1}%
              \edef\V{A}%
              \edef\W{I}%
              \ifx \T\U     % then style=1, the default
                   \else \ifx \T\V \global\sa*st=2
                         \else \ifx \T\W \global\sa*st=3
                               \else \message{<TEXT1> Warning, numbering style
                                              in the subheadaformat command is
                                              invalid. Style 1 will be assumed.}
                   \fi\fi\fi}%
      \long\def\titleformat##1{\global\*subat={##1}}%
      \def\incontents##1{\global\*TC*shatrue
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U              % Already true
                 \else \ifx \T\V \global\*TC*shafalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in subheadaformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    #1}}
\let\shaf=\subheadaformat
%
\def\subheadatitle{}
\def\subheada#1{% 
    \global\def\subheadatitle{#1}%
    \global\advance \*sa*num by 1
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\*subat                    %  prints the title in the text
    \egroup
    \ifvmode \D=\lastskip \removelastskip
	\else \D=0pt\fi
    \if*TC*sha \putincontents1{\the\*satf}\fi
    \ifdim\D>0pt\vs{\D}\else\ignorespaces\fi%
}% END subheada markup definition
%
\def\subheadanumber{{\ifcase \sa*st
                       \or \the\*sa*num
                       \or \l*alphafalse
                           \a*c{\*sa*num}
                       \or \uppercase\expandafter{\romannumeral\the\*sa*num}
                       \fi
                     \removelastskip}}
\let\sha=\subheada
%
\def\setsubheadanumber#1{\global\*sa*num=#1}%
\let\ssan=\setsubheadanumber
%
\long\def\subheadbformat#1{{%
      \def\numberingstyle##1{\global\sb*st=1
              \edef\T{##1}%
              \edef\U{1}%
              \edef\V{A}%
              \edef\W{I}%
              \ifx \T\U     % then style=1, the default
                   \else \ifx \T\V \global\sb*st=2
                         \else \ifx \T\W \global\sb*st=3
                               \else \message{<TEXT1> Warning, numbering style
                                              in the subheadbformat command is
                                              invalid. Style 1 will be assumed.}
                   \fi\fi\fi}%
      \long\def\titleformat##1{\global\*subbt={##1}}%
      \def\incontents##1{\global\*TC*shbtrue
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U              % Already true
                 \else \ifx \T\V \global\*TC*shbfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in subheadbformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    #1}}
\let\shbf=\subheadbformat
%
\def\subheadbtitle{}
\def\subheadb#1{% 
    \global\def\subheadbtitle{#1}%
    \global\advance \*sb*num by 1
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\*subbt                   % This  prints the title in the text
    \egroup
    \ifvmode \D=\lastskip \removelastskip
	\else \D=0pt\fi
    \if*TC*shb \putincontents1{\the\*sbtf}\fi
    \ignorespaces
    \ifdim\D>0pt\vs{\D}\else\ignorespaces\fi
}% END subheadb markup definition
%
\def\subheadbnumber{{\ifcase \sb*st
                       \or \the\*sb*num
                       \or \l*alphafalse
                           \a*c{\*sb*num}
                       \or \uppercase\expandafter{\romannumeral\the\*sb*num}
                       \fi
                     \removelastskip}}
\let\shb=\subheadb
%
\def\setsubheadbnumber#1{\global\*sb*num=#1}%
\let\ssbn=\setsubheadbnumber
%
\long\def\subheadcformat#1{{%
      \def\numberingstyle##1{\global\sc*st=1
              \edef\T{##1}%
              \edef\U{1}%
              \edef\V{A}%
              \edef\W{I}%
              \ifx \T\U     % then style=1, the default
                   \else \ifx \T\V \global\sc*st=2
                         \else \ifx \T\W \global\sc*st=3
                               \else \message{<TEXT1> Warning, numbering style
                                              in the subheadcformat command is
                                              invalid. Style 1 will be assumed.}
                   \fi\fi\fi}%
      \long\def\titleformat##1{\global\*subct={##1}}
      \def\incontents##1{\global\*TC*shcfalse
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U \global\*TC*shctrue
                 \else \ifx \T\V \global\*TC*shcfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in subheadcformat is not "yes" or "no".
                                      "no" will be assumed.}
                 \fi\fi}%
    #1}}
\let\shcf=\subheadcformat
%
\def\subheadctitle{}
\def\subheadc#1{% 
    \global\def\subheadctitle{#1}%
    \global\advance \*sc*num by 1
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
      \the\*subct                    % prints the title in the text
    \egroup
    \ifvmode \D=\lastskip \removelastskip
	\else \D=0pt\fi
    \if*TC*shc \putincontents1{\the\*sctf}\fi
    \ignorespaces
    \ifdim\D>0pt\vs{\D}\else\ignorespaces\fi
}% END subheadc markup
%
\def\subheadcnumber{{\ifcase \sc*st
                       \or \the\*sc*num
                       \or \l*alphafalse
                           \a*c{\*sc*num}
                       \or \uppercase\expandafter{\romannumeral\the\*sc*num}
                       \fi
                     \removelastskip}}
\let\shc=\subheadc
%
\def\setsubheadcnumber#1{\global\*sc*num=#1}%
\let\sscn=\setsubheadcnumber
%
\long\def\subheaddformat#1{{%
      \def\numberingstyle##1{\global\sd*st=1
              \edef\T{##1}%
              \edef\U{1}%
              \edef\V{A}%
              \edef\W{I}%
              \ifx \T\U     % then style=1, the default
                   \else \ifx \T\V \global\sd*st=2
                         \else \ifx \T\W \global\sd*st=3
                               \else \message{<TEXT1> Warning, numbering style
                                              in the subheaddformat command is
                                              invalid. Style 1 will be assumed.}
                   \fi\fi\fi}%
      \long\def\titleformat##1{\global\*subdt={##1}}%
      \def\incontents##1{\global\*TC*shdfalse
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U \global\*TC*shdtrue
                 \else \ifx \T\V \global\*TC*shdfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in subheaddformat is not "yes" or "no".
                                      "no" will be assumed.}
                 \fi\fi}%
    #1}}
\let\shdf=\subheaddformat
%
\def\subheaddtitle{}
\def\subheadd#1{% 
    \global\def\subheaddtitle{#1}%
    \global\advance \*sd*num by 1
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\*subdt                   % This  prints the title in the text
    \egroup
    \ifvmode \D=\lastskip \removelastskip
	\else \D=0pt\fi
    \if*TC*shd \putincontents1{\the\*sdtf}\fi
    \ignorespaces
    \ifdim\D>0pt\vs{\D}\else\ignorespaces\fi
}% END subheadd markup definition
%
\def\subheaddnumber{{\ifcase \sd*st
                       \or \the\*sd*num
                       \or \l*alphafalse
                           \a*c{\*sd*num}
                       \or \uppercase\expandafter{\romannumeral\the\*sd*num}
                       \fi
                     \removelastskip}}
\let\shd=\subheadd
%
\def\setsubheaddnumber#1{\global\*sd*num=#1}%
\let\ssdn=\setsubheaddnumber
%
\message{figures,}
%
%                       FIGURE MARKUP, bth 8/25/86
% Figure altered to allow alignments and other text markups within the
% arguments of figure and allow the immediate print feature (nofloat).
% Footnoting and multiple columns allowed in nofloat format only.
% Floating figures use top insert which uses a vbox that cancels any
% footnoting or multiple column setting. When \fullpage or \halfpage
% are used they must be the only argument in position one.
%
%
%              Figureformat revised on 4/5/88, drg
%
\catcode`* = 11
\catcode`@ = 11
\newif\if*fp \*fpfalse               % fullpage, used in figure
\newif\if*hp \*hpfalse               % halfpage, "            "
\newcount\fi*pos \fi*pos=1           % 1=\float,2=\nofloat,3=\midfloat,4=\keep
\newtoks\fi*sb     \fi*sb={1\bl}
\newtoks\fi*sa     \fi*sa={1\bl}
\def\figureformat#1{{%
    \def\skipbefore##1{\global\fi*sb={##1}}%
    \def\position{% printing position of figure, floating or nonfloating
        \def\nofloat{\global\fi*pos=2} % prints immediate
        \def\keep{\global\fi*pos=4}    % prints immediate, but on same pg
        \def\midfloat{\global\fi*pos=3}% uses midinsert
        \def\float{\global\fi*pos=1}}  % uses topinsert, the default
    \long\def\titleformat##1{\global\*figt={##1}}%
    \def\incontents##1{\global\*TC*figtrue
        \edef\T{##1}%
        \edef\U{yes}%
        \edef\V{no}%
        \ifx \T\U                % Already true
        \else \ifx \T\V \global\*TC*figfalse
              \else \message{<TEXT1> Warning, argument to
                     incontents in figureformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    \def\skipafter##1{\global\fi*sa={##1}}%
    #1}}% End figure format markup
\let\fif=\figureformat
%
\newif\if*tpreset                    % titlepage reset for figure markup
\*tpresetfalse                       % no reset necessary
%
%    Figure revised on 10/4/89, drg
%
\def\figuretitle{}
\def\figure{\futurelet\next\*fga}
\def\*fga{\ifcat\bgroup\noexpand\next \let\next\*fgb
    \else\let\next\*fgc\fi \next}
\def\*fgb{\global\setbox\A=\vbox\bgroup\aftergroup\*fgd\let\next}
\def\*fgc#1{\*fge{#1}}
\def\*fgd{\*fge{\box\A}}
\long\def\*fge#1#2{\par % Begin figure markup definition
    \gdef\figuretitle{#2}%
    \global\advance \fi*n by 1       % figure number
    \begingroup                      % trap null setting for lets
    \let\fullpage=\null              % make fullpage non-printable
    \let\halfpage=\null              % make halfpage non-printable
    \let\toclinebreak=\space         % prevent break in title
    \let\toclbr=\space               % prevent break in title
%      for value of \fi*pos: 1=\float,2=\nofloat,3=\midfloat,4=\keep
    \ifcase\fi*pos
      \or                            % BEGIN TOPINSERT FIGURES
       \if*fp                        % full page topinsert figure
          \if*title\*tpresettrue\notitlepage\fi % account for titlepage
          \topinsert                 % floating figures are topinserts
          \if*TC*fig \putincontents2{\the\*ftf}\fi
          \vbox to\vsize{\vrule width0pt\relax
             \vfil#1\the\*figt}
          \endinsert
          \if*tpreset\titlepage\*tpresetfalse\fi % reset titlepage
       \else\if*hp                   % half page topinsert figure
               \topinsert
               \if*TC*fig \putincontents2{\the\*ftf}\fi
               \vbox to.5\vsize{\vrule width0pt \relax
                   \vskip\the\fi*sb\relax
                    \vfil#1\the\*figt
                    \vskip\the\fi*sa\relax}
               \endinsert
                   \else              % variable size floating figure
                      \topinsert
                      \if*TC*fig \putincontents2{\the\*ftf}\fi
                      \vskip\the\fi*sb\relax
                      #1\the\*figt
                      \vskip\the\fi*sa\relax
                      \endinsert
       \fi\fi                        % end float full and half page check
      \or                            % BEGIN IMMEDIATE FIGURES
       \if*fp                        % FULL PAGE IMMEDIATE FIGURE
          \np                        % figure won't fit on current page
          \if*TC*fig \putincontents2{\the\*ftf}\fi % send to contents
          \vrule width0pt \relax     % prevent fil from going away
          \vfill\the\*figt           % fill to figure title
          \break                     % insures break at end of insert
       \else
          \if*hp                     % HALF PAGE IMMEDIATE FIGURE
             \dimen\D=.5\vsize       % depth check for half page figure
             \advance\dimen\D by\topskip % add topskip to .5 vsize
             \ifdim\pagetotal>\dimen\D\np\fi % won't fit on current page
             \vbox to.49\vsize{\vrule width0pt % keep skip
                \vfil\relax          % skip all but title height to
                #1\the\*figt         % print figure title
                \vskip\the\fi*sa\relax} % print half page figure title
             \if*TC*fig \putincontents2{\the\*ftf}\fi
          \else                      % VARIABLE SIZE IMMEDIATE FIGURE
             \vrule width0pt \relax  % prevent skip from going away
             \vskip\the\fi*sb\relax
             #1\the\*figt
             \vskip\the\fi*sa\relax
             \if*TC*fig \putincontents2{\the\*ftf}\fi
             \fi% End of check at half page
       \fi          % End of check at full page
      \or                            % BEGIN MIDINSERT FIGURES
       \if*fp                        % full page midinsert figure
          \if*title\*tpresettrue\notitlepage\fi % account for titlepage
          \topinsert                 % use topinsert for full page only
          \if*TC*fig \putincontents2{\the\*ftf}\fi
          \vbox to\vsize{\vrule width0pt\relax
             \vfil#1\the\*figt}
          \endinsert
          \if*tpreset\titlepage\*tpresetfalse\fi % reset titlepage
       \else\if*hp                   % half page midinsert figure
               \midinsert
               \if*TC*fig \putincontents2{\the\*ftf}\fi
               \vbox to.5\vsize{\vrule width0pt \relax
                   \vskip\the\fi*sb\relax
                    \vfil#1\the\*figt
                    \vskip\the\fi*sa\relax}
               \endinsert
                   \else              % variable size floating figure
                      \midinsert
                      \if*TC*fig \putincontents2{\the\*ftf}\fi
                      \vskip\the\fi*sb\relax
                      #1\the\*figt
                      \vskip\the\fi*sa\relax
                      \endinsert
       \fi\fi                        % end float full and half page check
      \or                            % BEGIN IMMEDIATE KEEP FIGURES
       \if*fp                        % FULL PAGE IMMEDIATE FIGURE
          \np                        % figure won't fit on current page
          \if*TC*fig \putincontents2{\the\*ftf}\fi % send to contents
          \vrule width0pt \relax     % prevent fil from going away
          \vfill\the\*figt           % fill to figure title
          \break                     % insures break at end of insert
       \else
          \if*hp                     % HALF PAGE IMMEDIATE FIGURE
             \dimen\D=.5\vsize       % depth check for half page figure
             \advance\dimen\D by\topskip % add topskip to .5 vsize
             \ifdim\pagetotal>\dimen\D\np\fi % won't fit on current page
             \vbox to.49\vsize{\vrule width0pt % keep skip
                \vfil\relax          % skip all but title height to
                #1\the\*figt         % print figure title
                \vskip\the\fi*sa\relax} % print half page figure title
             \if*TC*fig \putincontents2{\the\*ftf}\fi
          \else                      % VARIABLE SIZE IMMEDIATE FIGURE
             \vrule width0pt \relax  % prevent skip from going away
             \vskip\the\fi*sb\relax
             \vbox{#1\the\*figt
             \vskip\the\fi*sa\relax}
             \if*TC*fig \putincontents2{\the\*ftf}\fi
             \fi% End of check at half page
       \fi          % End of check at full page
       \fi          % End of case statement
    \endgroup                        % end trap for null settings
    \global\*fpfalse                        % reset full page
    \global\*hpfalse                        % reset half page
}% End figure markup
\let\fig=\figure                     % abbreviation for figure markup
%
\def\fullpage{\global\*fptrue}%               used in figure markup
\def\halfpage{\global\*hptrue}%               used in figure markup
%
\def\figurenumber{\the\fi*n}%
%
\def\HFN#1{\laf{\labelwidth{\fi*hi}}\label{#1}}%
%
\def\setfigurenumber#1{\global\fi*n=#1}%
\let\sfn=\setfigurenumber
%
%      Redefined from PLAIN TEX
%
\def\topinsert{\@midfalse\p@gefalse\t*ptrue\@ins}
%
\def\midinsert{%                       redefine from plain tex
    \@midtrue
    \if*fix %                          don't change meaning in fixed mode
    \else %                         change midinsert to topinsert in flex mode
       \if*dbl\global\@midfalse\fi % leave old meaning in single column mode
       \if*tpl\global\@midfalse\fi %
    \fi\@ins} %
%
\def\@ins{\par\begingroup
    \if*fix                          % do nothing in fixed mode
    \else\ift*p\hsize=\*txtw\fi\fi   % ift*p hsize of insert set
    \setbox0=\vbox\bgroup}           % insert set to full page width
%
%        Tables
%
\def\tableformat#1{{%
      \long\def\titleformat##1{\global\*tabt={##1}}%
      \def\incontents##1{\global\*TC*tabtrue
            \edef\T{##1}%
            \edef\U{yes}%
            \edef\V{no}%
            \ifx \T\U                % Already true
                 \else \ifx \T\V \global\*TC*tabfalse
                       \else \message{<TEXT1> Warning, argument to
                                      incontents in tableformat is not "yes" or "no".
                                      "yes" will be assumed.}
                 \fi\fi}%
    #1}}
\let\taf=\tableformat
%
\def\tabletitle#1{{% Tabletitle revised 11/3/86 (added toclinebreak)
    \def\tabletitle{#1}%
    \global\advance \ta*n by 1
    \par
    \bgroup
       \let\toclinebreak=\space
       \let\toclbr=\space
       \the\*tabt                    % prints the title in the text
    \egroup
    \par
    \D=\lastskip
    \removelastskip
    \if*TC*tab \putincontents3{\the\*ttf}\fi
    \ignorespaces
    \vs{\D}
}}% END tabletitle markup definition
\let\tat=\tabletitle
%
\def\tablenumber{\the\ta*n}
\def\HTN#1{\laf{\labelwidth{\ta*hi}}\label{#1}}
%
\def\settablenumber#1{\global\ta*n=#1}%
\let\stn=\settablenumber
%
\message{8600 macros,}
%
%     Macros specific for the 8600 (JKW) revision 11/25/86
%
\newskip\evenmar
\newskip\oddmar
\evenmar=0pt
\oddmar=0pt
\def\evenpagemargin#1{{\setbox0=\hbox{\global\evenmar=#1 pt}}
                      \special{even_page_margin=\the\evenmar}}%
\let\epm=\evenpagemargin
\def\oddpagemargin#1{{\setbox0=\hbox{\global\oddmar=#1 pt}}
                     \special{odd_page_margin=\the\oddmar}}%
\let\opm=\oddpagemargin
\def\linenumberfont#1{\B={#1}
                      \special{line_number_font=\the\B}}%
\let\lnf=\linenumberfont
\def\poplevel#1{\B={#1}
                \special{pop_level=\the\B}}%
\let\ppl=\poplevel
\def\lineinterval#1{\B={#1}
                    \special{line_interval=\the\B}}%
\let\lint=\lineinterval
\def\numberinglines#1{\special{numbering_lines=#1}}%
\let\numl=\numberinglines
\def\countinglines#1{\special{counting_lines=#1}}%
\let\coul=\countinglines
\def\printingnumbers#1{\special{printing_numbers=#1}}%
\let\prin=\printingnumbers
\def\linefootnotereference{\special{line_footnote_reference}}%
\let\lfnr=\linefootnotereference
%
\message{ more misc,}
%
%     To be able to use PLAIN.TEX math code
%
\def\plaintexmathon{%
   \catcode`\$=3\relax
   \catcode`@=12\relax}
\let\dollarmathon=\plaintexmathon
\def\atmathon{%
   \catcode`\$=12\relax
   \catcode`@=3\par}
%
\message{multiple columns,}
%
\outer\def\bye{\par\onecolumn\vfill\supereject\end} % redefined from PLAIN.TEX
%                                      to close multiple column routines
%
%          MULTIPLE COLUMNS
%          Brian Harvey 1/20/85
%
%     Macros to be imbedded into TEXT1 to drive the multiple column
%     routines FLEXCOL and FIXCOL.
%
\newbox\*lftcol                      % left column box, fixed column mode, TeXbook name
\newbox\*midcol                      % center column, fixed column mode, TeXbook name
\newbox\*ppage                       % page accummulated before multicolumn, partialpage, flex
\newcount\*pcount                    % counter for empty page macro, keeps track of the
\*pcount=0                           % number of empty page calls
\newdimen\*bigch                     % Twc=2vise, Thc=3vsize---bigcolumnheight
\newdimen\*txtw                      % textwidth, stores full hsize for multicolumn mode
\let\galleywidth=\*txtw              % create galleywidth = text width
\newdimen\*txth                      % textheight, stores page height for multicolumn mode
\*txtw=\hsize                        % initialize full page text width for multicolumn mode
\*txth=\vsize                        % initialize full text height for multicolumn mode
\newif\ift*p                         % ift*p required to check for midinsert in flex mode
\newif\if*dbl                        % double column indicator
\*dblfalse                           % set double column format indicator false
\newif\if*tpl                        % triple column indicator
\*tplfalse                           % set triple column format indicator false
\newif\if*fix                        % format indicator (fixed if true, otherwise flexible)
\newif\if*norule                     % used to suppress rules in output routines
\newif\if*plain                      % check for plain.tex, plainoutput
\*plaintrue                          % set plain format indicator true
\newtoks\*twcw                       % width for twocolumns
\newtoks\*thcw                       % width for threecolumns
\newtoks\*twcgut                     % gutter for twocolumns
\newtoks\*thcgut                     % gutter for threecolumns
\newtoks\*clrw                       % rule width between multiple columns
\newtoks\*mskb                       % skip before multicolumn format
\newtoks\*mska                       % skip after multicolumn format
\*twcw={.48\*txtw}                   % initialize column and gutter default widths
\*thcw={.31\*txtw}
\*twcgut={.04\*txtw}
\*thcgut={.035\*txtw}
\*clrw={0.0pt}                       % initialize between column rule width
\*mskb={6pt plus 3pt minus 2pt}      % initialize skips before and after multiple columns:
\*mska={6pt plus 3pt minus 2pt}      % used in multiple column flex mode only
 
\def\fixedformat{\global\*fixtrue}   % calls fixed format file
\let\fixf=\fixedformat
\global\*fixfalse                    % sets up flex format
%
\def\multicolumnformat#1{% format macro for both fixed and flexible, texblock is multicol
    \def\twocolumnwidth##1{\global\*twcw={##1}}%
    \def\threecolumnwidth##1{\global\*thcw={##1}}%
    \def\twocolumngutter##1{\global\*twcgut={##1}}%
    \def\threecolumngutter##1{\global\*thcgut={##1}}%
    \def\columnrulewidth##1{\global\*clrw={##1}}%
    \def\skipbefore##1{\global\*mskb={##1}}% flex mode only
    \def\skipafter##1{\global\*mska={##1}}% flex mode only
    #1\*txtwck}% END, multicol format
\let\mcf=\multicolumnformat
%
%          COLUMN WIDTH CHECK FOR MULTIPLE COLUMN ROUTINES
%
\def\*txtwck{% check column width and gutters against hsize
    \dimen@=\the\*twcw
    \dimen@=2\dimen@
    \dimen1=\the\*twcgut
    \advance\dimen@ by\dimen1
    \ifdim\dimen@ > \*txtw         % if greater than current pagewidth
       \dimen1=\dimen@
       \advance\dimen1 by-\*txtw
       \advance\dimen@ by -\*txtw
       \ifdim\dimen@ > 1pt % only warn if over 1pt
          \immediate\write16{%
          <TEXT1> Warning! The column and gutter widths specified%
          for two columns are wider than the current pagewidth by%
          \the\dimen1 . }
          \fi
    \else\ifdim\dimen@ < \*txtw   % if less than current pagewidth
       \dimen1=\*txtw
       \advance\dimen1 by-\dimen@
       \advance\dimen@ by -\*txtw
       \multiply\dimen@ by -1
       \ifdim\dimen@ > 1pt  % Only warn if over 1pt difference
          \immediate\write16{%
          <TEXT1> Warning! The column and gutter widths specified%
          for two columns are shorter than the current pagewidth by%
          \the\dimen1 . }
          \fi
       \fi\fi
%
    \dimen@=\the\*thcw               % width of each column, three columns
    \dimen@=3\dimen@                 % three columns
    \dimen1=\the\*thcgut             % width of the gutters
    \dimen1=2\dimen1                 % two gutters in three columns
    \advance\dimen@ by\dimen1        % add columns and gutters together
    \ifdim\dimen@ > \*txtw           % if greater than current pagewidth
       \dimen1=\dimen@
       \advance\dimen1 by-\*txtw
       \advance\dimen@ by -\*txtw
       \ifdim\dimen@ > 1pt % only warn if over 1pt
          \immediate\write16{%
          <TEXT1> Warning! The column and gutter widths specified%
          for three columns are wider than the current pagewidth by%
          \the\dimen1 . }
          \fi
    \else\ifdim\dimen@ < \*txtw   % if less than current pagewidth
       \dimen1=\*txtw
       \advance\dimen1 by-\dimen@
       \advance\dimen@ by -\*txtw
       \multiply\dimen@ by -1
       \ifdim\dimen@ > 1pt  % Only warn if over 1pt difference
          \immediate\write16{%
          <TEXT1> Warning! The column and gutter widths specified%
          for three columns are shorter than the current pagewidth by%
          \the\dimen1 . }
          \fi
       \fi\fi
    } % END, widthcheck
%
\newif\if*start*mc  \*start*mcfalse
\def\twocolumns{% TWOCOLUMNS set-up macro
    \if*fix \input fixcol            % input fixed format file
       \immediate\write-16{% write to log file only
       <TEXT1> Fixed format for multiple columns in effect. }
       \gdef\twocolumns{\*fixtwc}%     redefine twocolumns, fixed mode
       \gdef\threecolumns{\*fixthc}%   redefine threecolumns, fixed mode
    \else \input flexcol             % input flex format file
       \immediate\write-16{%           write to log file only
       <TEXT1> Flexible format for multiple columns in effect. }
       \gdef\twocolumns{\*flextwc}%    redefine twocolumns, flex mode
       \gdef\threecolumns{\*flexthc}\fi% redefine threecolumns, flex mode
   \twocolumns
   \global\let\twc=\twocolumns       % to current meaning of twocolumns
   \global\let\thc=\threecolumns     % to current meaning of threecolumns
}% END twocolumns markup
%
\let\twc=\twocolumns
%
\def\threecolumns{% THREECOLUMNS set-up macro
    \*start*mctrue
    \if*fix \input fixcol            % input fixed format file
       \immediate\write-16{%           write to log file only
       <TEXT1> Fixed format for multiple columns active. }
       \gdef\twocolumns{\*fixtwc}%     redefine twocolumns, fixed mode
       \gdef\threecolumns{\*fixthc}%   redefine threecolumns, fixed mode
    \else \input flexcol             % input flex format file
       \immediate\write-16{%           write to log file only
        <TEXT1> Flexible format for multiple columns active. }
       \gdef\twocolumns{\*flextwc}%    redefine twocolumns, flex mode
       \gdef\threecolumns{\*flexthc}\fi% redefine threecolumns, flex mode
   \threecolumns
   \global\let\twc=\twocolumns       % to current meaning of twocolumns
   \global\let\thc=\threecolumns     % to current meaning of threecolumns
}% End threecolumns markup
%
\let\thc=\threecolumns
%
\let\onecolumn=\null                 % Empty definition for single format
\let\oc=\onecolumn
%
\let\newcolumn=\newpage
\let\nc=\newpage
\newif\if*nc    \*ncfalse            % true if \nc was used in mult cols
%
\global
\newhelp\balerrhelp{onecolumn The best approach to solve this problem
    is to shorten the text by a line. You could also add or delete a
    paragraph or change the column size. }%
%
\message{index macros,}
%
%                     Here are the macros necessary for doing an index
%
\newtoks\*ixarc     \*ixarc={case=no}                % IndeX A Respect Case
\newcount\*ixpn                                      % Page number type: 0,2,4,6, or 9
\newtoks\*ixast     \*ixast={style=3}                % IndeX A STyle
\newtoks\*ixald     \*ixald={leadering=no}           % IndeX A LeaDering
\newtoks\*ixabr     \*ixabr={\vs{1\bl}}              % IndeX A BReak
\newtoks\*ixasea    \*ixasea={1em}                   % IndeX A SubEntry 1
\newtoks\*ixaseb    \*ixaseb={2em}                   % IndeX A SubEntry   2
\newtoks\*ixaev     \*ixaev={\tenpt}          % Index A every time
\newtoks\*ixahp     \*ixahp={1.5em}                  % Index A hang indent
\newtoks\*ixbrc     \*ixbrc={case=no}                % IndeX B Respect Case
\newtoks\*ixbst     \*ixbst={style=3}                % IndeX B STyle
\newtoks\*ixbld     \*ixbld={leadering=no}           % IndeX B LeaDering
\newtoks\*ixbbr     \*ixbbr={\vs{1\bl}}              % IndeX B BReak
\newtoks\*ixbsea    \*ixbsea={1em}                   % IndeX B SubEntry 1
\newtoks\*ixbseb    \*ixbseb={2em}                   % IndeX B SubEntry 2
\newtoks\*ixbev     \*ixbev={\tenpt}          % Index B every time
\newtoks\*ixbhp     \*ixbhp={1.5em}                  % Index B hang indent
\newtoks\*ixcrc     \*ixcrc={case=no}                % IndeX C Respect Case
\newtoks\*ixcst     \*ixcst={style=3}                % IndeX C STyle
\newtoks\*ixcld     \*ixcld={leadering=no}           % IndeX C LeaDering
\newtoks\*ixcbr     \*ixcbr={\rule\vs{1\bl}}         % IndeX C BReak
\newtoks\*ixcsea    \*ixcsea={1em}                   % IndeX C SubEntry 1
\newtoks\*ixcseb    \*ixcseb={2em}                   % IndeX C SubEntry 2
\newtoks\*ixcev     \*ixcev={\tenpt}          % Index C every time
\newtoks\*ixchp     \*ixchp={1.5em}                  % Index C hang indent
%
\newcount\*ixlvl    \*ixlvl=1                        % IndeX LeVeL
%
\long\def\indexformat#1#2{{\ifnum #1>3 \message{<TEXT1> Error! Only three indices
                                        allowed. Level 1 will be used.}
                                \*ixlvl=1
                          \else \*ixlvl=#1\fi
   \def\respectcase##1{\edef\T{yes}
                       \edef\U{no}
                       \edef\V{##1}
                       \ifx \T\V \B={case=yes}
                            \else \B={case=no}
                                  \ifx \U\V             % Already set
                                       \else\message{<TEXT1> Error!! Case respect not "yes"
                                                      or "no" in indexformat. "no" will be used.}
                             \fi\fi
                       \ifcase \*ixlvl \or \global\*ixarc=\B
                                       \or \global\*ixbrc=\B
                                       \or \global\*ixcrc=\B
                             \fi}
   \def\style##1{\edef\T{paragraph}
                 \edef\U{dash}
                 \edef\V{indent}
                 \edef\W{##1}
                 \ifx \T\W \B={style=1}             % paragraph style
                      \else \ifx \U\W \B={style=2}  % dash style
                            \else \B={style=3}      % indented style
                                  \ifx \V\W                % Already done
                                       \else \message{<TEXT1> Error!! Style invalid in indexformat.
                                                      "indented" will be used.}
                      \fi\fi\fi
                       \ifcase \*ixlvl \or \global\*ixast=\B
                                       \or \global\*ixbst=\B
                                       \or \global\*ixcst=\B
                             \fi}
   \def\leadering##1{\edef\T{yes}
                     \edef\U{no}
                     \edef\V{##1}
                     \ifx\T\V \B={leadering=yes}
                        \else \B={leadering=no}
                              \ifx\U\V
                                      \else \message{<TEXT1> Error!! Only "yes" and "no" can
                                                    be used in the indexformat. "no" will be assumed.}
                              \fi\fi
                     \ifcase \*ixlvl \or \global\*ixald=\B
                                     \or \global\*ixbld=\B
                                     \or \global\*ixcld=\B
                             \fi
           }
   \long\def\everyletterbreak##1{\ifcase \*ixlvl \or \global\*ixabr={##1}
                                                 \or \global\*ixbbr={##1}
                                                 \or \global\*ixcbr={##1}
                              \fi}
   \def\everyindex##1{\ifcase \*ixlvl \or \global\*ixaev={##1}
                                      \or \global\*ixbev={##1}
                                      \or \global\*ixcev={##1}
                              \fi}
   \def\everyhang##1{\ifcase \*ixlvl \or \global\*ixahp={##1}
                                     \or \global\*ixbhp={##1}
                                     \or \global\*ixchp={##1}
                              \fi}
   \def\indentsubentry##1##2{\R = ##1
                       \ifnum ##1<1 \message{<TEXT1> Error!! Subentry level number in indexformat
                                             may only be 1 or 2. 1 will be used.}
                                    \R = 1
                              \else \ifnum ##1>2 \message{<TEXT1> Error!! Subentry level number in indexformat
                                             may only be 1 or 2. 1 will be used.}
                                    \R = 1
                              \fi\fi
                     \ifcase \R \or \ifcase \*ixlvl \or \global\*ixasea={##2}
                                                    \or \global\*ixbsea={##2}
                                                    \or \global\*ixcsea={##2}
                                                \fi
                                    \or \ifcase \*ixlvl \or \global\*ixaseb={##2}
                                                        \or \global\*ixbseb={##2}
                                                        \or \global\*ixcseb={##2}
                                                \fi
                              \fi}
   #2}}
\let\ixf=\indexformat
\newwrite\*ixfilea                    % IndeX FILE A
\newwrite\*ixfileb                    % IndeX FILE B
\newwrite\*ixfilec                    % IndeX FILE C
\newif\if*ixaopen   \*ixaopenfalse    % IndeX file A OPEN?
\newif\if*ixbopen   \*ixbopenfalse    % IndeX file B OPEN?
\newif\if*ixcopen   \*ixcopenfalse    % IndeX file C OPEN?
\def\*openixfile#1{\ifcase #1 \or
            \immediate\openout\*ixfilea=text1xx.ix1%
            \global\*ixaopentrue
            \immediate\write\*ixfilea{\the\*ixarc}%
            \immediate\write\*ixfilea{\the\*ixast}%
            \immediate\write\*ixfilea{\the\*ixald}%
  \or       \immediate\openout\*ixfileb=text1xx.ix2%
            \global\*ixbopentrue
            \immediate\write\*ixfileb{\the\*ixbrc}%
            \immediate\write\*ixfileb{\the\*ixbst}%
            \immediate\write\*ixfileb{\the\*ixbld}%
  \or       \immediate\openout\*ixfilec=text1xx.ix3%
            \global\*ixcopentrue
            \immediate\write\*ixfilec{\the\*ixcrc}%
            \immediate\write\*ixfilec{\the\*ixcst}%
            \immediate\write\*ixfilec{\the\*ixcld}%
  \fi}
{\catcode`\$=12
\global\def\index#1#2{{\global\*ixpn = 2
                \def\subentry##1##2{${$}se##1##2{$}}%
                \def\bdpn{\global\*ixpn = 0}%
                \def\uspn{\global\*ixpn = 4}%
                \def\itpn{\global\*ixpn = 6}%
                \def\blindentry##1{\global\*ixpn = 9}%
                \def\sortas##1{${$}sa##1{$}}%
                \def\dagger{ \noexpand\dagger}%
                \def\ddagger{ \noexpand\ddagger}%
                \def\\{\noexpand\\}%
                \def\{{\noexpand\{}%
                \def\}{\noexpand\}}%
                \def\_{\noexpand\_}%
                \def\@{\noexpand\@}%
                \def\S{\noexpand\S}%
                \def\P{\noexpand\P}%
                \def\L{\noexpand\L}%
                \def\AA{\noexpand\AA}%
                \def\neg{\noexpand\neg}%
                \def\tilde{\noexpand\tilde}%
                \def\vbar{\noexpand\vbar}%
                \def\roman{\noexpand\rm}\let\rm=\roman%
                \def\bold{\noexpand\bd}\let\bd=\bold%
                \def\italic{\noexpand\it}\let\it=\italic%
                \def\typewriter{\noexpand\tt}\let\tt=\typewriter%
                \def\caps{\noexpand\cc}\let\cc=\caps%
                \def\mathitalic{\noexpand\mi}\let\mi=\mathitalic%
                \def\symbol{\noexpand\sy}\let\sy=\symbol%
                \def\extension{\noexpand\ex}\let\ex=\extension%
                \def\bolditalic{\noexpand\bi}\let\bi=\bolditalic%
                \setbox0=\vbox{\hsize=100in#2}%
                \def\bdpn{}%
                \def\uspn{}%
                \def\itpn{}%
                \def\blindentry##1{${$}be##1{$}}%
                \*ixlvl = #1
                \ifcase #1 \message{<TEXT1> Error!! You can only have index level 1, 2, or 3.
                                     Index level 1 will be used.}
                            \*ixlvl = 1
                            \or\or\or%           % These levels are ok
                      \else \message{<TEXT1> Error!! You can only have index level 1, 2, or 3.
                                     Index level 1 will be used.}
                            \*ixlvl = 1
                        \fi%
                \edef\*ixtoken{#2}%
                \edef\temp{\*ixtoken}%
                \ifcase \*ixlvl  \or\if*ixaopen\else\*openixfile1\fi% Open the file if not done yet
                                   \immediate\write\*ixfilea{{\the\*ixpn}{\the\pageno}{\pagenumber}\*ixtoken}%
                                 \or \if*ixbopen \else \*openixfile2 \fi % Open the file if not done yet
                                   \immediate\write\*ixfileb{{\the\*ixpn}{\the\pageno}{\pagenumber}\*ixtoken}%
                                 \or \if*ixcopen \else \*openixfile3 \fi % Open the file if not done yet
                                   \immediate\write\*ixfilec{{\the\*ixpn}{\the\pageno}{\pagenumber}\*ixtoken}%
                                 \fi}\ignorespaces}
}% End math cat code change
\def\everyletterbreak#1#2{\def\nextletter{#2}
                          \ifcase #1 \or \the\*ixabr
                                     \or \the\*ixbbr
                                     \or \the\*ixcbr
                              \fi}
\def\everyindex#1{\ifcase \*ixlvl \or \the\*ixaev
                                  \or \the\*ixbev
                                  \or \the\*ixcev
                              \fi}
\def\indentsubentry#1#2{\par\penalty5000\hp
                     \ifcase #2 \or \ifcase #1 \or \hs{\the\*ixasea}
                                               \or \hs{\the\*ixbsea}
                                               \or \hs{\the\*ixcsea}
                                                \fi
                                \or \ifcase #1 \or \hs{\the\*ixaseb}
                                               \or \hs{\the\*ixbseb}
                                               \or \hs{\the\*ixcseb}
                                                \fi
                              \fi}
\let\ix=\index
\let\*ix=\printindex
\def\printindex#1{%\*ix#1 used only when printindex is a hardcoded command
                  \ifcase #1 \or \input text1xx.ix1
                             \or \input text1xx.ix2
                             \or \input text1xx.ix3
                             \fi}
%
\message{wrap it up...}
%
\def\@{\char'100{}}%
%
%   and set default values
%
\hfuzz=1pt
\parindent=24pt          \parskip=0pt plus 3pt minus 0pt
\normalbottom
\pageno=0
\catcode`* = 12
% The END