summaryrefslogtreecommitdiff
path: root/info/yet-another-guide-latex2e/Yet-Another-Guide-LaTeX2e_v1.tex
blob: 2609d2994729ade11b61810e34c9f00da2129a57 (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
\documentclass[12pt, a4paper]{article}
\usepackage{setspace} 

\usepackage{booktabs}
\usepackage{multirow}

\usepackage[pdftex]{graphicx}
\usepackage[dvipsnames]{xcolor}

\usepackage[french, ngerman, australian]{babel}
\usepackage{hyphenat}
\hyphenation{}

\usepackage[useregional, showdow]{datetime2}

\usepackage[TS1,T1]{fontenc}

\usepackage[left=1in, top=1in, bottom=1.25in, right=1in, headheight=18pt]{geometry}
\usepackage{fancyhdr}
\pagestyle{fancy}
\lhead{}
\chead{}
\rhead{\thepage}
\lfoot{}
\cfoot{}
\rfoot{}
\renewcommand{\headrulewidth}{0.0pt}
\renewcommand{\footrulewidth}{0.0pt}

\usepackage[title, toc]{appendix}

%opening
\title{
Yet Another Guide \\
to \\
\LaTeXe \\ 
{\Large v1.0} \\}

\author{Michael P. Morris \footnote {Copyright \copyright  2020--2022  M. P. Morris. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License". Any error reports for this work can be sent to the author at \texttt{mmorris1k@gmail.com}.} \\ 
\texttt{{\footnotesize mmorris1k@gmail.com}}} 

\date{\today}

\usepackage[pdftex, colorlinks=true, allcolors=Blue]{hyperref}


\hypersetup{pdfinfo={
 		Title={Yet Another Guide to LaTeX2e. v1.0},
		Author={Michael P. Morris},
		Subject={LaTeX2e},
		Keywords={Latex2e; Guide}
}}

\begin{document}

\maketitle
\thispagestyle{empty}

\begin{abstract}
This document is a short guide to using \LaTeXe\ to typeset high quality documents. It focuses on users of Windows 10 and TeX Live 2022 and guides the reader through installation, some of \LaTeXe's conventions, and creating the front matter, body and end matter of a document. The appendices contain a list of useful facilities not covered in this document and a list of helpful resources.
\end{abstract}



%\clearpage
\pagenumbering{roman}
\tableofcontents

\clearpage
\listoffigures

\clearpage
\listoftables

\clearpage
\pagenumbering{arabic}

\section{Introduction}

LaTeX (pronounced \emph{lah-tek}) is a markup language designed to typeset high quality documents. It was created by Donald Knuth who generously released it into the public domain. It is freely available from the Comprehensive TeX Archive Network (\textsc{ctan}) at \texttt{\url{www.ctan.org}}. Since it’s release it has been greatly added to, and as of this writing there are currently over 6200 add-on packages from over 2800 contributors. The most recent version is \LaTeXe and LaTeX 3 is under development. 

This document grew from my own efforts to become a proficient LaTeX user. It is not a comprehensive guide to using LaTeX. It is aimed at giving an overview of the elements of how to mark up a document and then compile it into either postscript or \textsc{pdf} format in English. It is a very bare bones outline of LaTeX and only touches on it's possibilities. The best source of information for additional functionality is the package documentation and there are also a number of very comprehensive published guides. The reference list contains several useful references. A more comprehensive list, and a helpful list of texts on typography is also available from the \TeX User Group at \url{www.tug.org/books/}. 

This document focuses on the Windows 10 operating system and the TeX Live 2022 distribution. Users of \textsc{unix}-alike or Mac systems should consult their documentation for issues specific to them. There are a large number of packages and some of them overlap in functionality. There are multiple options for citation systems, for document templates and for fonts. The recommendations made in this document reflect my own experiences and prejudices. Anyone else's mileage may vary.

A previous version of this document was titled `Getting Started with \LaTeXe'. The name has been changed as it was too similar to other documents relating to LaTeX. Previous versions of this document illustrated the Pro\TeX distribution. This was retired in 2022, so the focus was changed to \TeX Live 2022. This is the most current distribution available at the time of writing. \\

Finally, I'd like to mention The TeX Users Group, of which I am a member. This is a not-for-profit group for those interested in LaTeX. Membership is inexpensive and members are sent \textsc{tug}boat, the Journal of the Tex Users Group, three times a year, and the TeX Collection on \textsc{dvd} annually. This is a good way of keeping up with developments and changes to TeX distributions. \\

The author is very interested in hearing about errors and suggestions for improvements, especially code that doesn't function as advertised. Reports can be sent to the author at \texttt{\color{Blue}mmorris1k@gmail.com}.  



\clearpage

\section{Installation}

\LaTeXe is freely available from \texttt{\url{www.ctan.org}} in two main distributions: 


\begin{itemize}
\item TeX Live is cross platform and will install on \textsc{unix}-alike, Mac and Windows systems.\\
	
\item MacTeX is aimed at Mac OS users.\\
	
\end{itemize}


This document illustrates TeX Live and is mainly aimed at users of Windows 10. The most current version of this, as of this writing, is Tex Live 2022. This can be downloaded in a number of ways from \textsc{ctan}. For Windows 10 an installer, which is about 20mb in size, may be downloaded and launched. It is also available as an \texttt{iso} file for those who burn their own DVD's. This is is a large file: about 4.3gb. TeX Live is also available on \textsc{dvd} as part of the \TeX Collection. This is distributed by the Tex User Group to members every year, and is available from the \textsc{tug} store at \url{www.tug.org/store/} along with stickers and other merchandise. \\

For those who are installing from DVD, the first step is to open it and click on \texttt{index.html}. This contains links to installation documentation in 14 different languages. It provides instructions for Windows 7 and above, Mac OS X and GNU/Linux systems. \\

After it is installed, the next step for Windows 10 users is to place it in the Windows search path. This will allow Windows to find it if it is run from the command line. To do this, go to the Control Panel:


\begin{flushleft}
\texttt{Control Panel $\rightarrow$ System and Security $\rightarrow$ System $\rightarrow$ Advanced System Settings $\rightarrow$ Environmental Variables $\rightarrow$ Path in the User Variables box $\rightarrow$ Edit}
\end{flushleft}


Then navigate to the directory containing the binary files, those with a \texttt{.exe} extension, and add it to the path. The default location for Tex Live 2022 is: 

{\small
\begin{verbatim}
C:\texlive\2022\bin\win32
\end{verbatim}
}

\subsection{Package Management}

A large part of LaTeX is made up of individual packages that add functionality. \textsc{ctan} currently has over 6200 packages from over 2800 contributors. These provide additional features, fonts, document templates and documentation. TeX Live provides the TeX Live Shell to help manage them. This provides facilities for updating packages and installing new packages. The TeX Live Shell can be accessed from the Windows 10 desktop by clicking 


\begin{flushleft}
\texttt{Windows Start} $\rightarrow$ \texttt{TeX Live 2022} $\rightarrow$ \texttt{TLShell TeX Live Manager}
\end{flushleft}

After the gui interface is loaded, the first thing to select is a package repository. These are world wide online sites that mirror the \texttt{ctan} main site and it will be the source of upgrades and new packages. To select one near you, select:

\begin{flushleft}
\texttt{Options $\rightarrow$ Repositories}
\end{flushleft}

A box will appear with options to select \texttt{Any CTAN mirror}, \texttt{Specific mirror} or \texttt{Local directory}. Select a source, then click the \texttt{Save and Load} box.  

When the manager appears, it will contain a section called Package List. This has options to list \texttt{Installed}, \texttt{Not installed}, \texttt{All} and \texttt{Updatable} packages. To add packages or check for updates, a \textsc{ctan} mirror will need to be loaded. The TeX Live Shell will contact this site to compare your installation with the \texttt{ctan}. If you have already selected one with \texttt{options}, click on 

\begin{flushleft}
\texttt{File $\rightarrow$ Load repository}
\end{flushleft}

To check for packages that are not yet installed, click \texttt{Not Installed} and a list of all the packages not installed on your system will appear. To install them, click the \textopenbullet next to the package name so that it changes to a tick, then click \texttt{Install marked}. \\

To update currently installed packages, select \texttt{Updatable} and if any updates are found, they will appear as a list. As with installing new packages, select the packages and click \texttt{Update marked}. They will be downloaded and installed automatically. \\

Following the package installation or update, the file name database must to be updated so that LaTeX can find the updated package/s. To do this, go to the console Menu, click on 


\begin{flushleft}
\texttt{\texttt{Actions $\rightarrow$ Regenerate filename database}}
\end{flushleft}


If new fonts have been installed, the fontmap files have to be refreshed as well. To do this, go to the console Menu, click on 


\begin{flushleft}
\texttt{Actions $\rightarrow$ Regenerate fontmaps}
\end{flushleft}


\begin{flushleft}
When this is finished, the package database also needs to be updated: 
\end{flushleft}


\begin{flushleft}
\texttt{Tasks $\rightarrow$ Update package database}
\end{flushleft}


A number of packages must be present on your system so that you can use the examples in this document. These are listed in Table 1. Their presence may be checked by clicking the \texttt{Not installed} option of the Package List section of the TeX Live Shell. This will list available packages that are not yet installed. 

If any of the required packages are missing, they can be installed using the instructions above. Some packages require access to additional packages and these must be present on your system as well: \texttt{ragged2e}, for instance, requires the packages \texttt{everysel} and \texttt{footmisc}. BibLaTeX, which automatically generates references and reference lists, has 12 additional packages, not including style packages!


\begin{table}[h]
\begin{center}
\begin{tabular}{ll}
\toprule[1.0pt]
\LaTeXe    & Bib\LaTeX                                               \\
\midrule[0.5pt]
\texttt{babel}       &  \texttt{babel v3.9r or above or polygossia}  \\
\texttt{booktabs}    &  \texttt{biber}                               \\
\texttt{datetime2}   &  \texttt{csquotes}                            \\
\texttt{everysel}    &  \texttt{etoolbox}                            \\
\texttt{fancyhdr}    &  \texttt{etex}                                \\
\texttt{fontenc}     &  \texttt{ifthen}                              \\
\texttt{footmisc}    &  \texttt{keyval}                              \\
\texttt{geometry}    &  \texttt{kvoptions}                           \\
\texttt{graphicx}    &  \texttt{logreq}                              \\
\texttt{hyphenat}    &  \texttt{pdftexcmds v0.27 or above}           \\
\texttt{multirow}    &  \texttt{url}                                 \\    
\texttt{ragged2e}    &  \texttt{xpatch}                              \\
\texttt{setspace}    &                                               \\
\texttt{xcolor}      &                                               \\
\texttt{xmp}         &                                               \\
            &  Bibliographical Styles                      \\
            &  \texttt{biblatex-apa}                       \\
            &  \texttt{biblatex-chicago}                   \\
            &  \texttt{biblatex-mla}                       \\
            &  \texttt{biblatex-vancouver}                 \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Required and recommended packages}
\end{center}
\end{table}


\subsection{Additional Software}

The software listed below is helpful for managing LaTeX projects. An editor makes marking up a text file and compiling it much simpler, and a reference manager helps with automatically generated references and citations. Two freely available editors are TeX studio and Kile. TeX studio is available from: 

\begin{flushleft}
\texttt{\url{www.texstudio.org}}
\end{flushleft}

Kile is another popular choice with similar functionality to TeXstudio. It has a preview feature which shows how your document will look after it is compiled. It is available from:

\begin{flushleft}
\texttt{\url{www.kile.sourceforge.io/}}
\end{flushleft}

A reference manager is helpful for scholarly writing because it can keep all the references in a single place, and if the references and reference list is are to be generated automatically, it forms a database that the generator can refer to. Jabref imports 15 reference formats and links to full text documents on the web. It is freely available from:

\begin{flushleft}
\texttt{\url{www.jabref.org}}
\end{flushleft}

Zotero is also freely available and supports a large number of reference formats. It allows users to add pdf's, images and web pages to its databases and users can add their own annotations to each entry:

\begin{flushleft}
\texttt{\url{www.zotero.org}}
\end{flushleft}


A fundamental requirement for LaTeX is a viewer so that typesetters can view the results of their labours. There are a large number of viewers for \textsc{pdf} files. Sumatra \textsc{pdf} is a free and popular choice. The latest version is available from:


\begin{flushleft}
\texttt{\url{www.sumatrapdfreader.org/free-pdf-reader}}
\end{flushleft}


GSView is a free postscript viewer for Windows. It requires Ghostscript which is installed automatically by TeX Live. GSview v5.0 is available from: 

\begin{flushleft}
\texttt{\url{www.ghostgum.com.au/software/gsview.htm}}
\end{flushleft}


LaTeX handles a limited range of graphic formats so an image converter is useful. Image Magic is freely available and reads and writes over 200 graphic formats. It is available from: 

\begin{flushleft}
\texttt{\url{www.imagemagick.org/script/index.php}}
\end{flushleft}

\clearpage


\section{Running \LaTeXe}
LaTeX is run from the command line by navigating to the project folder and then run on a marked-up text file. These have a \texttt{.tex} extension. To run it on a file named \texttt{TestFile.tex}: 


\begin{flushleft}
\texttt{latex TestFile.tex}
\end{flushleft}


\begin{flushleft}
This produces a \textsc{dvi} file called \texttt{TestFile.dvi} that can be converted to postscript with \texttt{dvips}: 
\end{flushleft}


\begin{flushleft}
\texttt{dvips TestFile.dvi}
\end{flushleft}


\begin{flushleft}
If \textsc{pdf} format is preferred, use \textsc{pdf}latex:
\end{flushleft}


\begin{flushleft}
\texttt{pdflatex TestFile.tex}
\end{flushleft}


It is convenient to run this from a \textsc{gui} interface. In TeXstudio, load a marked-up text file then go to 


\begin{flushleft}
\texttt{Tools $\rightarrow$ Commands $\rightarrow$ LaTeX or PDFLaTeX}
\end{flushleft}


\begin{flushleft}
and it will run automatically. In Kile, go to 
\end{flushleft}
 
 
\begin{flushleft}
\texttt{Build $\rightarrow$ Compile $\rightarrow$ LaTeX or PDFLaTeX }
\end{flushleft}



\clearpage


\section{Project Management}

The first step in creating a document with LaTeX is to write the text and save it as a plain text file into a project directory created specifically for that project. This text file is then marked up so that when it is compiled it becomes a formatted postscript or \textsc{pdf} document. The normal suffix for this file is \texttt{.tex}. During compilation, LaTeX will produce several other files and having a unique project directory will help keep all of them together. This directory should also contain any graphic files and reference databases so that LaTeX can find them.


\subsection{Postscript vs \textsc{pdf}}

One of the first things to consider is if the document is to be produced in postscript or Portable Document Format (\textsc{pdf}). Postscript is the `gold standard’ for printed documents and produces the highest quality files for printing. \textsc{pdf} supports hypertext links and live connections to websites and are somewhat smaller than postscript files. Postscript documents require no specific instructions. \textsc{pdf} files have options for file metadata and hyperlinks and these require \textsc{pdf}LaTeX. See the section on \textsc{pdf} document compilation below for how to include these in your document.


\clearpage



\section{LaTeX Conventions}

LaTeX documents have two parts: the preamble and the document text. The preamble defines the document's global properties such as the template for the document, paper size, fonts and margins and loads packages that contain functions that will be used to format the text. The first command is \texttt{\textbackslash documentclass[options]\{TemplateName\}}  Packages are loaded with the \texttt{\textbackslash usepackage[Options]\{PackageName\}} command. The required package name is placed between the curly braces and a list of options separated by commas are listed between square brackets: 

{\small
\begin{verbatim}
\documentclass[Option1, Option2]{TemplateName} 	
\usepackage[Option1, Option2]{PackageName}
\end{verbatim}
}

After the preamble comes the document text. This is contained inside the \texttt{document} environment and includes the text, graphs, tables, lists etc. 

The simplest document uses LaTeX's default settings and requires only that the document class be specified and that the text be placed in the \texttt{document} environment. The following creates an article class document with everything else left at the default settings:

{\small
\begin{verbatim}
\documentclass{article} 
\begin{document} 

Document Text Here

\end{document}
\end{verbatim}
}


\subsection{Commands}

Commands in LaTeX begin with a \texttt{\textbackslash}. This is one of LaTeX's special characters and alerts LaTeX that the following is an instruction rather than text. This is followed by a command and the object of the command is often placed between curly braces: \texttt{\textbackslash Command\{Object\}}. To format a section of text in italics, the \texttt{\textbackslash textit\{\}} command tells LaTeX that the text inside the curly braces is to be formatted in italics:


\begin{verbatim}
\textit{Lorem ipsum dolor sit amet, consectetur adipiscing elit.}	
\end{verbatim} 


\begin{flushleft}
produces
\end{flushleft}


\begin{flushleft}
\textit{Lorem ipsum dolor sit amet, consectetur adipiscing elit.}
\end{flushleft}


Commands are also used to select special characters. This can include LaTeX's control characters, symbols and diacritics. \$ is one of LaTeX's control characters. It informs LaTeX that the following code is to be executed in Math mode. A \texttt{\textbackslash} must be added to tell LaTeX that it should be processed as text: \texttt{\textbackslash \$} produces \texttt{\$}. Commands for all of LaTeX's control characters are in Table 8.

It is always a good idea to annotate your code. Annotations can be added to LaTeX code by starting comment lines with a \texttt{\%}. This will stop LaTeX from attempting to run it and returning an error message:


{\small
\begin{verbatim}
% This is a comment.
\end{verbatim}
}

\clearpage



\section{Preamble}


Every LaTeX document has a preamble which contains instructions regarding document template, page size and other options that will affect it as a whole. It is the first part of any document and goes before the body of the text. The first line of the preamble is:


{\small
\begin{verbatim}
\documentclass[Options]{DocumentTemplate}
\end{verbatim}
}


This specifies the template for the document. The base options are \texttt{article}, \texttt{book}, \texttt{letter} or \texttt{report}. There are a wide range of templates and some organisations produce their own. If one of these is required, it is named here and will be loaded when the document is compiled. After the template is selected, options define font size, paper size, number of columns and whether it is to be printed on one side of the page or two. 

LaTeX's defaults are: a 10pt font size, a paper size of 8.5'' x 11'', which is the US standard letter size, portrait orientation, a separate title page for the report class but not the others, typesetting in one column, and printing on one side of the page only. All these can be customised. A summary of commands and options are outlined in Tables 2 and 3.

\begin{table}[h]
\small
\begin{center}
\begin{tabular}{ll}
\toprule[1.0pt]
Option               &  Command \\
\midrule[0.5pt]
Document Type        &  \texttt{letter, article, report, book} \\
Typeface Size (pts)  &  \texttt{10, 11, 12} \\
Title Page           &  \texttt{titlepage, notitlepage} \\
Columns              &  \texttt{onecolumn, twocolumn} \\
Layout               &  \texttt{oneside, twoside} \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Document class options}
\end{center}
\end{table}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lll}
\toprule[1.0pt]
Size   &   Measurement(mm)   &   Command \\
\midrule[0.5pt]
A4         &  210 x 297  &     \texttt{a4paper}   \\
A5         &  148 x 210  &     \texttt{a5paper}   \\
B5         &  176 x 250  &     \texttt{b5paper}   \\
Executive  &  185 x 267  &     \texttt{executivepaper}   \\
Legal      &  216 x 356  &     \texttt{legalpaper}   \\
Letter     &  216 x 279  &     \texttt{letterpaper}   \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Paper sizes}
\end{center}
\end{table}


The following code creates an article class document with A4 sized paper and a 12-point font. The other options will stay at their default settings:


{\small
\begin{verbatim}
\documentclass[12pt, a4paper]{article}
\end{verbatim}
}


\begin{flushleft}
After the document type is defined, packages that will be used are loaded with
\end{flushleft}


{\small
\begin{verbatim}
\usepackage[Options]{PackageName}
\end{verbatim}
}

The first package is \texttt{setspace}. This package supports single, one-and-a-half and double spacing with \texttt{\textbackslash singlespacing}, \texttt{\textbackslash onehalfspacing} and \texttt{\textbackslash doublespacing}. This will change the spacing of the entire document, but figures, tables and footnotes will be unaffected. \texttt{setspace} is loaded in the preamble and the required spacing is specified in the document text after \texttt{\textbackslash begin\{document\}}. LaTeX's default spacing is single spaced:


{\small
\begin{verbatim}
\documentclass[a4paper]{article}
\usepackage{setspace}
. . .
\begin{document}
\doublespacing
. . . 
\end {document} 
\end{verbatim}
}


The next package is \texttt{graphicx} which is part of the `graphics' bundle. It provides facilities to include graphics in documents with it's \texttt{\textbackslash includegraphics\{\}} command. 


{\small
\begin{verbatim}
\usepackage{graphicx} 
\end{verbatim}
}


\texttt{xcolor} provides support for coloured text, text background, page colour or a coloured box surrounding text. This is especially helpful for \textsc{pdf} documents that contain hot links as they can be highlighted. If no options are specified, 19 colours are available. Options \texttt{dvipsnames}, \texttt{svgnames} and \texttt{x11names} provide 68, 151 and 317 colours respectively. Colours and their designations for each of these options are provided in \texttt{xcolour's} documentation (Kern, 2021). If specific colours are required, this package can produce them in rgb and cmyk format. The following loads \texttt{xcolor} with \texttt{dvipsnames} to provide 68 colour choices:  


\begin{verbatim}
\usepackage[dvipsnames]{xcolor}
\end{verbatim}


The \texttt{babel} package supports hyphenation for justified text and has facilities for about 200 languages. This includes three dialects of English: \texttt{english} refers to American and Canadian, \texttt{UKenglish} refers to British, and \texttt{australian} refers to Australian and New Zealand English. If the document contains text in multiple languages, all of them should be listed as options. There may be multiple options for each language: English has three and German, two. Consult the documentation for details on each one. The language listed last is the document’s main language:

{\small
\begin{verbatim}
\usepackage[french, ngerman, australian]{babel}
\end{verbatim}
}

This loads French, German and Australian English with Australian being the document's main language. To swap to one of the other languages in the text, use \texttt{\textbackslash select language\{LanguageName\}} for blocks of text such as paragraphs, and \texttt{\textbackslash foreignlanguage \{LanguageName\}\{Text\}} for text that is part of a paragraph: 


{\small
\begin{verbatim}
Text in English.
\selectlanguage{french}
Texte en Francais. 
\selectlanguage{australian}
Returns to Australian English.
\end{verbatim}
}


\begin{flushleft}
or
\end{flushleft}


{\small
\begin{verbatim}
\foreignlanguage{french}{Texte en Francais.}
\end{verbatim}
}


If LaTeX doesn't hyphenate words properly, they will run into the right-hand margin. To fix this, a list of troublesome words can be listed with the \texttt{hyphenat} package and it's \texttt{\textbackslash hyphenation\{\}} command. These words are placed in hyphenation's curly braces divided into syllables with a -. For example, `hyphenate' is defined as \texttt{hy-phen-ate} and preamble is \texttt{pre-am-ble}: 


{\small
\begin{verbatim}
\usepackage[french, ngerman, australian]{babel}
\usepackage{hyphenat}
\hyphenation{hy-phen-ate pre-am-ble}
\end{verbatim}
}


\begin{flushleft}
Dates can be added with datetime2. This package is loaded with 
\end{flushleft}


{\small
\begin{verbatim}
\usepackage{datetime2}
\end{verbatim}
}

\begin{flushleft}
and the date itself inserted in the text with 
\end{flushleft}

{\small
\begin{verbatim}
\today
\end{verbatim}
}

This will add the date the document was compiled in \textsc{yyyy-mm-dd} format so it will look like 2020-09-19. The format can be changed with the \texttt{useregional} option. This will set the date format so that it matches the language specified when \texttt{babel} was loaded. The \texttt{babel} example above specifies Australian English and will format the timestamp to \textsc{dd mm yyyy}. To add the day of the week, add the \texttt{showdow} option:


{\small
\begin{verbatim}
\usepackage[useregional, showdow]{datetime2}
\end{verbatim}
}


The \texttt{fontenc} package gives access to the glyphs of language. This is done through what LaTeX refers to as encodings. The default, and LaTeX's original encoding option, is \texttt{OT1}. This gives access to glyphs for the English alphabet. Unfortunately, this encoding doesn’t allow hyphenation of accented characters that appear in non-English latin alphabets. If the document is in English this doesn’t matter, but if the document contains glyphs from other latin alphabets, the encoding should be changed to \texttt{T1}. This has a wider range of glyphs. LaTeX provides encodings for a range of languages: Cyrillic, African Latin, Vietnamese, Greek, Armenian etc. If text for languages in alphabets other than latin are included in your document, encodings for these will have to be loaded as well. For more on this, see Mittelbach, et al (2016). 

TS1 is a coding that gives access to symbols. This can be loaded at the same time as the font encoding(s). The required encodings are specified in options. To load both T1 and TS1 encodings:


{\small
\begin{verbatim}
\usepackage[TS1, T1]{fontenc}
\end{verbatim}
}


LaTeX's default setting for text alignment is justified with both edges of the text block aligned evenly. If the text block should be left aligned with a ragged right side, \texttt{ragged2e} will format the text as this for the entire document with the \texttt{document} option. To use this package, two additional packages should be present on your LaTeX installation. These are \texttt{everysel} and \texttt{footmisc}. The following loads \texttt{ragged2e} and sets the document text alignment to left aligned with a ragged right side:

{\small
\begin{verbatim}
\usepackage[document]{ragged2e}
\end{verbatim}
}

The next line loads the font for the document. If it is not defined, it will default to Computer Modern, which is LaTeX's original font. LaTeX provides a wide range of fonts with an option to install more if required. This example loads Latin Modern with the package name \texttt{lmodern}. 

{\small
\begin{verbatim}
\usepackage{lmodern}
\end{verbatim}
}

\begin{flushleft}
Table 4 contains a short font sampler and package names. 
\end{flushleft}




\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lll}
\toprule[1.0pt]
Font Name               & Package Name         & Sample Text \\
\midrule[0.5pt]
Avant Garde             & \texttt{avant}	   & \fontfamily{pag}\selectfont Lorem ipsum dolor sit amet \\
Bookman                 & \texttt{bookman}	   & \fontfamily{pbk}\selectfont Lorem ipsum dolor sit amet \\
Charter                 & \texttt{charter}	   & \fontfamily{bch}\selectfont Lorem ipsum dolor sit amet \\ 
Courier                 & \texttt{courier}     & \fontfamily{pcr}\selectfont Lorem ipsum dolor sit amet \\ 
Computer Modern         & \texttt{cmodern}	   & \fontfamily{cmr}\selectfont Lorem ipsum dolor sit amet \\
Helvetica               & \texttt{helvet}      & \fontfamily{phv}\selectfont Lorem ipsum dolor sit amet \\
Latin Modern            & \texttt{lmodern}	   & \fontfamily{lmr}\selectfont Lorem ipsum dolor sit amet \\
New Century Schoolbook  & \texttt{newcent}	   & \fontfamily{pnc}\selectfont Lorem ipsum dolor sit amet \\
Palatino                & \texttt{mathpazo}    & \fontfamily{ppl}\selectfont Lorem ipsum dolor sit amet \\
Times New Roman         & \texttt{mathptmx}    & \fontfamily{ptm}\selectfont Lorem ipsum dolor sit amet \\
Utopia                  & \texttt{utopia}      & \fontfamily{put}\selectfont Lorem ipsum dolor sit amet \\
\bottomrule[1.0pt]		
\end{tabular}
\caption{A short font sampler}
\end{center}
\end{table}


Margins can be adjusted from the defaults with the \texttt{geometry} package. The left, right, top, and bottom margins can all be specified with this, and an allowance made for binding if the document is to be bound. It accepts units in millimetres, centimetres, points, and inches (mm, cm, pt, in). The options are listed in Table 5.

\begin{table}[h]
\small
\begin{center}
\begin{tabular}{ll}
\toprule[1.0pt]
Option & Comment \\
\midrule[0.5pt]
\texttt{left}          & Left Margin \\
\texttt{right}         & Right Margin \\
\texttt{top}           & Top Margin \\
\texttt{bottom}        & Bottom Margin \\
\texttt{bindingoffset} & Add space for binding \\
\texttt{headheight}    & Changes the size of the header \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Geometry options}
\end{center}
\end{table}


If headers and footers are contained in the document, LaTeX may sometimes return an error message to say that the headheight is too small. This can be corrected with the \texttt{\textbackslash headheight} option. For this document I have set the headheight to $1.5\times$ the point size of the text for a headheight of 18pt. The header is designed to hold a single line of text, but can be adjusted to accommodate multiple lines. The following code sets the left margin at 1.5 inches, the right margin at 1 inch, the top margin at 1 inch, the bottom margin at 1.75 inches and the height for the header to 18 point:


{\small
\begin{verbatim}
\usepackage[left=1.5in, right=1.0in, top=1.0in, bottom=1.75in, 
headheight=18pt]{geometry}
\end{verbatim}
}


The page margins can be changed mid-document with \texttt{\textbackslash newgeometry\{\}}. It reverts to the original settings with\texttt{ \textbackslash restore\{geometry\}}. The \texttt{\textbackslash newgeometry\{\}} command has the same options as those used by geometry in the preamble:


{\small
\begin{verbatim}
\newgeometry{left=0.5in, right=0.5in, top=0.5in, bottom=0.5in}
\end{verbatim}
}


\begin{flushleft}
This changes the margins to a uniform 0.5 inches. To change it back:
\end{flushleft}


{\small
\begin{verbatim}
\restore{geometry}
\end{verbatim}
}


Headers and footers are handled by the \texttt{fancyhdr} package. This package provides header and footer placement to the left, centre and right and customizable lines for both headers and footers. The pagestyle should be changed to fancy if this package is used:


{\small
\begin{verbatim}
\usepackage{fancyhdr}
\pagestyle{fancy}
\end{verbatim}
}


There are six locations available: left, centre and right headers and footers. The location and contents of each header or footer is specified as:


{\small
\begin{verbatim}
\lhead{Left Top}
\chead{Centre Top}
\rhead{Right Top}
\lfoot{Bottom Left}
\cfoot{Bottom Centre}
\rfoot{Bottom Right}
\end{verbatim}
}


The text of the header or footer is contained between the curly braces. These can contain page numbers and dates generated using \texttt{\textbackslash thepage} and \texttt{\textbackslash today} respectively. Decorative lines can be added to both headers and footers with 

{\small
\begin{verbatim}
\renewcommand{headrulewidth}{0.5pt}
\renewcommand{footrulewidth}{0.5pt}
\end{verbatim}
}

This will place lines that are 0.5 points wide beneath the header and above the footer. Line weights can be increased and decreased between 0.0 and 1.0. A line weight of 0.0pt produces no lines. \\

The following code loads \texttt{fancyhdr} and places a running header or title top left, page numbers top right, today’s date stamp bottom left and decorative lines 0.5 points thick below the footer and above the header:

{\small
\begin{verbatim}
\usepackage{fancyhdr}
\pagestyle{fancy}
\lhead{Running Header or Title.}
\chead{}
\rhead{\thepage}
\lfoot{\today}
\cfoot{}
\rfoot{}
\renewcommand{\headrulewidth}{0.5pt}
\renewcommand{\footrulewidth}{0.5pt}
\end{verbatim}
}

\clearpage



\section{Text}

The body of the text for LaTeX documents is enclosed in the document environment:


{\small
\begin{verbatim}
\begin{document}
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus. \\
\end{document}
\end{verbatim}
}


Either a blank line between two sections of text, or \texttt{\textbackslash par}, denotes a paragraph break and \texttt{\textbackslash \textbackslash} starts a new line.

Page breaks can be inserted with, \texttt{\textbackslash newpage} or \texttt{\textbackslash clearpage}. \texttt{\textbackslash clearpage} is preferred if the document contains chapters or sections with tables or figures. This will place them at the end of their section if LaTeX is unable to place them in the text.


\subsection{Fonts and Styles}

The base font and size for LaTeX documents is loaded in the preamble. Font styles, such as \textbf{bold} or \textit{italic} can be changed in the body of the text. A list of font styles and their commands are contained in Table 6. These can be changed in two ways. The first is to insert the text in curly braces following a command. This

{\small
\begin{verbatim}
\textit{Lorem ipsum dolor sit amet . . .}
\end{verbatim}
}

\begin{flushleft}
formats the text between the curly braces in italics as
\end{flushleft}
 
\begin{flushleft}
\textit{Lorem ipsum dolor sit amet . . . }
\end{flushleft}
 

This is useful for single words or sentences, but for blocks of text an environment is convenient:
 
 
{\small
\begin{verbatim}
\{begin{itshape}
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus. Curabitur eu est et leo feugiat auctor vel quis lorem. \\
\end{itshape}
\end{verbatim}
}
 
\begin{flushleft}
This produces:
\end{flushleft}
 
\begin{flushleft}
\begin{itshape}
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, ultrices in porttitor	in, accumsan non quam. Nam consectetur porttitor rhoncus. Curabitur eu est et leo feugiat auctor vel quis lorem.
\end{itshape}
\end{flushleft}


Fonts can be made larger or smaller from {\tiny Tiny} to {Normal Size} to {\Huge Huge} in a similar way. Table 7 gives commands for resizing fonts. \\


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lll}
\toprule[1.0pt]
Style         & Command                                &  Sample                \\
\midrule[0.5pt]
Roman         & \texttt{\textbackslash textrm\{\}}     & \textrm{Roman}         \\
Sans Serif    & \texttt{\textbackslash textsf\{\}}     & \textsf{Sans Serif}    \\
Typewriter    & \texttt{\textbackslash texttt\{\}}     & \texttt{Typewriter}    \\ 
Italics       & \texttt{\textbackslash textit\{\}}     & \textit{Italics}       \\
Boldface      & \texttt{\textbackslash textbf\{\}}     & \textbf{Boldface}      \\
Small Caps    & \texttt{\textbackslash textsc\{\}}     & \textsc{Small Caps}    \\
Underline     & \texttt{\textbackslash underline\{\}}  & \underline{Underline}  \\
Emphasis      & \texttt{\textbackslash emph\{\}}       & \emph{Emphasis}        \\
Slanted       & \texttt{\textbackslash textsl\{\}}     & \textsl{Slanted}       \\    		
\bottomrule[1.0pt]
\end{tabular}
\caption{Text styles}
\end{center}
\end{table}



\begin{table}{h}
\small
\begin{center}
\begin{tabular}{lc}
\toprule[1.0pt]
Command & Sample \\
\midrule[0.5pt]
\texttt{\textbackslash tiny\{\}}          &  \tiny{Lorem ipsum dolor sit amet}         \\
\texttt{\textbackslash scriptsize\{\}}    &  \scriptsize{Lorem ipsum dolor sit amet}   \\
\texttt{\textbackslash footnotesize\{\}}  &  \footnotesize{Lorem ipsum dolor sit amet} \\
\texttt{\textbackslash small\{\}}         &  \small{Lorem ipsum dolor sit amet}        \\
\texttt{\textbackslash normalsize\{\}}    &  \normalsize{Lorem ipsum dolor sit amet}   \\
\texttt{\textbackslash large\{\}}         &  \large{Lorem ipsum dolor sit amet}        \\
\texttt{\textbackslash Large\{\}}         &  \Large{Lorem ipsum dolor sit amet}        \\
\texttt{\textbackslash LARGE\{\}}         &  \LARGE{Lorem ipsum dolor sit amet}        \\
\texttt{\textbackslash huge\{\}}          &  \huge{Lorem ipsum dolor sit amet}         \\
\texttt{\textbackslash Huge\{\}}          &  \Huge{Lorem ipsum dolor sit amet}         \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Font sizes}
\end{center}
\end{table}



If \texttt{xcolor} is loaded, fonts, font backgrounds and pages can be re-coloured. \texttt{\{\textbackslash color \{ColorName\}\{Text\}} changes the colour of text inside the curly braces. To change it to red:

{\small
\begin{verbatim}
\color{red} Lorem ipsum dolor sit amet, consectetur adipiscing elit.
\end{verbatim}
}

\begin{flushleft}
produces:
\end{flushleft}


\begin{flushleft}
{\color {red} Lorem ipsum dolor sit amet, consectetur adipiscing elit.}
\end{flushleft}


\begin{flushleft}
\texttt{\textbackslash colorbox\{\}} changes the background colour, in this case to Sea Green:
\end{flushleft}

{\small
\begin{verbatim}
{\colorbox {SeaGreen}{Lorem ipsum dolor sit amet Lorem ipsum dolor 
sit amet}}	
\end{verbatim}
}

\begin{flushleft}
produces
\end{flushleft}


\begin{flushleft}
{\colorbox {SeaGreen}{Lorem ipsum dolor sit amet Lorem ipsum dolor sit amet}}
\end{flushleft}


\begin{flushleft}
Both can be changed by specifying the background colour and the text colour:
\end{flushleft}


\begin{verbatim}
\colorbox{SkyBlue}{\color{Red} Lorem ipsum dolor sit amet}	
\end{verbatim}


\begin{flushleft}
produces:
\end{flushleft}


\begin{flushleft}
\colorbox{SkyBlue}{\color{Red} Lorem ipsum dolor sit amet}
\end{flushleft}



\subsection{Special Characters}


The following symbols are used by LaTeX as part of it's programming instructions so require marking up if they are to be placed in a document as text:

\begin{center}
\{ \} \% \& \$ \_ \# \textbackslash \~{} \^{} \\
\end{center}


These and the commands to produce them along with a range of other common symbols are in Table 8. \\

Quotation marks are produced by using the \texttt{\textasciigrave} and \texttt{\textquotesingle} keys or \texttt{\textbackslash textquoteleft} and \texttt{\textbackslash textquoteright}: \texttt{\textasciigrave Word'} produces `Word'. For double quotes, use two of each or \texttt{\textbackslash textquotedblleft and \textbackslash textquotedblright} : \texttt{\textasciigrave \textasciigrave Word''} produces ``Word''. The \texttt{\textasciigrave} key is located at the top left of the keyboard below the \texttt{esc} key. The \texttt{\textquotesingle} symbol is the usual single quotation mark. The \textquotedbl\ key on the keyboard is not used. Three dashes are available: the hyphen (\texttt{\textminus} produces -: `The syllables of hyphenate are hy-phen-ate') the en dash for ranges (\texttt{\textminus \textminus} produces --: 1939--45)  and the em dash for punctuation (\texttt{\textminus \textminus \textminus} produces ---: `Your profundities --- My truisms'). 


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{llll}
\toprule[1.0pt]
Symbol & Command & Symbol & Command \\
\midrule[0.5pt]
\{     &    \texttt{\textbackslash \{ }  &  ---  &  \texttt{\textminus \textminus \textminus or \textbackslash textemdash}  \\
			
\}     &     \texttt{\textbackslash \}}    &   \textasciigrave  &  \small \texttt{\textbackslash asciigrave}  \\
			
\%     &      \texttt{\textbackslash \%}    &   \textasciiacute  & \texttt{\textbackslash textasciiacute}  \\
			
\&     &      \texttt{\textbackslash \& }   &  \textasciibreve  &  \texttt{\textbackslash textasciibreve}  \\
			
\$     &      \texttt{\textbackslash \$ or \textbackslash textdollar}    &  \textbullet  &   \texttt{\textbackslash textbullet}  \\
			
\_     &     \texttt{\textbackslash \_}    &  \textopenbullet  &  \texttt{\textbackslash textopenbullet}  \\
			
\#     &      \texttt{\textbackslash \#}    &  \textellipsis  &  \texttt{\textbackslash textellipsis}  \\
			
\textbackslash   & \texttt{\textbackslash textbackslash}  & \textasteriskcentered  & \texttt{\textbackslash textasteriskcentered}  \\
			
\~{}   &     \texttt{\textbackslash \textasciitilde\{\} }  &  \textdagger  &  \texttt{\textbackslash textdagger} \\
			
\^{}   &      \texttt{\textbackslash \textasciicircum\{\} }  &  \textdaggerdbl  &  \texttt{\textbackslash textdaggerdbl}  \\		
			
\textquoteleft     &     \texttt{\textbackslash textquoteleft or \textasciigrave}  &  \textparagraph  & \texttt{\textbackslash textparagraph}  \\
			
\textquoteright  &  \texttt{\textbackslash textquoteright or \textquotesingle}  & \textsection  & \texttt{\textbackslash textsection}  \\
			
\textquotedblleft  &     \texttt{\textbackslash textquotedblleft or \textasciigrave \textasciigrave}  & \texttildelow & \texttt{\textbackslash texttildelow}  \\
			
\textquotedblright  &    \texttt{\textbackslash textquotedblright or \textquotesingle \textquotesingle}  &  \textasciitilde  & \texttt{\textbackslash textasciitilde}  \\
			
--     &      \texttt{\textminus \textminus or \textbackslash textendash}  &  
\textperiodcentered  & \texttt{\textbackslash textperiodcentered} \\

\textsterling  &  \texttt{\textbackslash textsterling} &  \texteuro  &  \texttt{\textbackslash texteuro} \\

\textcent  &  \texttt{\textbackslash textcent}  & \textyen  &  \texttt{\textbackslash textyen} \\

\textdegree  &  \texttt{\textbackslash textdegree} & \textcelsius  &  \texttt{\textbackslash textcelsius} \\

\textcopyleft  &  \texttt{\textbackslash textcopyleft} & \texttrademark  &  \texttt{\textbackslash texttrademark} \\
  
\texttimes  & \texttt{\textbackslash texttimes} &  \textdiv  & \texttt{\textbackslash textdiv} \\

\textminus  &  \texttt{\textbackslash textminus} &  \textgreater  &  \texttt{\textbackslash textgreater} \\
   
\textless  &  \texttt{\textbackslash textless}  &  \textcopyright  &  \texttt{\textbackslash textcopyright} \\ 
\bottomrule[1.0pt]
\end{tabular}
\caption{Special characters and some common symbols}
\end{center}
\end{table}			

This list is a very small sample of the symbols available in LaTeX. Scott Pakin maintains `The Comprehensive LaTeX Symbol List' which provides a list of over 18,000 symbols. This list is freely available from \textsc{ctan}. A link is provided in the Reference section.


\subsection{Accents and Non-Latin Glyphs}

Most glyphs that have diacritics in latin alphabets, such as German \"{A} \"{a}; \"{O} \"{o}, \"{U} \"{u}, Spanish \~{n}, Polish \k{A} \k{a}, \'{C} \'{c}, \k{E} \k{e}, \'{N} \'{n}, etc can be represented by using the commands in Table 9. LaTeX also provides non-latin glyphs for the alphabets that have them, such as the German Eszett \ss\ and Scandinavian O-Slash \O\ or \o.\ These can be produced by the commands in Table 10. Table 11 contains commands for some punctuation marks such as the guillemots, Spanish \textexclamdown\ and \textquestiondown\ and base quotes \quotedblbase.\ Some of these glyphs combine with the following word automatically so it can be challenging to represent them as single letters if this is required. The code \texttt{\textbackslash ss is a German letter} might compile as `\ss is a German letter'. This may be fixed by inserting a \texttt{\textbackslash} after \texttt{\textbackslash ss}: \texttt{\textbackslash ss\textbackslash\ is a German letter} compiles as `\ss\ is a German letter'.  

\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lll}
\toprule[1.0pt]
Diacritic          & Code                          & Example         \\
\midrule[0.5pt]
Acute             & \texttt{\textbackslash \'{}\{\}}  & {\Large \'{a}}  \\
Breve             & \texttt{\textbackslash u\{\}}  & {\Large \u{a}}  \\
Caron / Ha\v{c}ek & \texttt{\textbackslash v\{\}}  & {\Large \v{a}}  \\
Cedilla           & \texttt{\textbackslash c\{\}}  & {\Large \c{a}}  \\
Circumflex        & \texttt{\textbackslash \^{}\{\}} & {\Large \^{a}} \\
Dot               & \texttt{\textbackslash .\{\}}  & {\Large \.{a}}  \\
Grave             & \texttt{\textbackslash \textquotesingle\{\}}  & {\Large \`{a}}  \\
Hungarian Umlaut  & \texttt{\textbackslash  H\{\}} & {\Large \H{o}}  \\
Macron            & \texttt{\textbackslash =\{\}}  & {\Large \={a}}  \\
Ogonek            & \texttt{\textbackslash k\{\}}  & {\large \k{a}}  \\
Tilde             & \texttt{\textbackslash $\sim$\{\}}  & {\Large \~{a}}  \\
Umlaut            & \texttt{\textbackslash "\{\}}  & {\Large \"{a}}  \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Common diacritics}
\end{center}
\end{table}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lll}
\toprule[1.0pt]
Name &            Upper Case & Lower Case \\
\midrule[0.5pt]
\textbf{German} & & \\
Eszett          & & \texttt{\textbackslash ss} \ss  \\
& & \\
\textbf{Polish} & & \\
Barred L       & \texttt{\textbackslash L}     \L     &  \texttt{\textbackslash l}     \l \\
& &  \\
\textbf{Scandinavian}    & &\\
Ash      & \texttt{\textbackslash AE}          \AE    & \texttt{\textbackslash ae}     \ae   \\
Eth      & \texttt{\textbackslash dh}          \DH    & \texttt{\textbackslash dh}     \dh   \\
OE ligature & \texttt{\textbackslash OE}       \OE    & \texttt{\textbackslash oe}     \oe   \\
O-Slash  & \texttt{\textbackslash O}           \O     & \texttt{\textbackslash o}      \o    \\
Ring-A   & \texttt{\textbackslash r\{A\}}      \r{A}  & \texttt{\textbackslash r\{a\}} \r{a} \\
Thorn    & \texttt{\textbackslash TH}          \TH    & \texttt{\textbackslash th}     \th   \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Some non-latin alphabetical glyphs}
\end{center}
\end{table}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lll}
\toprule[1.0pt]
Name                    & Symbol            & Command \\
\midrule[0.5pt]
Double Guillemot: Left  & \guillemetleft    & \texttt{\textbackslash guillemetleft}    \\ 
Double Guillemot: Right & \guillemetright   & \texttt{\textbackslash guillemetright}   \\
Single Guillemot: Left  & \guilsinglleft    & \texttt{\textbackslash guilsinglleft}    \\
Single Guillemot: Right & \guilsinglright   & \texttt{\textbackslash guilsinglright}   \\
Exclamation Down        & \textexclamdown   & \texttt{\textbackslash textexclamdown}   \\
Question Mark Down      & \textquestiondown & \texttt{\textbackslash textquestiondown} \\
Base quote: Double      & \quotedblbase     & \texttt{\textbackslash quotedblbase}     \\
Base Quote: Single      & \quotesinglbase   & \texttt{\textbackslash quotesinglbase}   \\
Elipsis                 & \textellipsis     & \texttt{\textbackslash textellipsis}     \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Punctuation marks}
\end{center}
\end{table}


\clearpage



\section{Body}


\subsection{Sectioning}

Sectioning is the division of a document into parts, chapters, sections, subsections, subsubsections, paragraphs, and subparagraphs. These divisions are available for all LaTeX document classes, apart from letter. Chapters are not available for article class documents. Sectioning commands have the same format as text formatting commands: \texttt{\textbackslash SectionType\{SectionTitle\}}. LaTeX numbers them automatically and the text of the \texttt{SectionTitle} will appear in the Table of Contents. The following creates two sections, each with two subsections:

{\small
\begin{verbatim}
\section{Section 1} 
\subsection{1A}
\subsection{1B} 

\section{Section 2}
\subsection{2A}
\subsection{2B} 
\end{verbatim}
}

\subsection{Environments}

Environments are used in the body of the document to define a particular behaviour. These range from abstracts, tables, and figures, lists and sections of text with differing justification. LaTeX environments are enclosed with \texttt{\textbackslash begin\{EnvironmentName\}} and \texttt{\textbackslash end\{EnvironmentName\}}. A short list of environments is in Table 12:


{\small
\begin{verbatim}
\begin{EnvironmentName} 
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus.\\
\end{EnvironmentName}
\end{verbatim}
}

\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lp{5cm}}
\toprule[1.0pt]
Environment & Description\\
\midrule[0.5pt]
\texttt{abstract}    & Text of a document’s abstract. \\
\texttt{centre}      & Centred text. \\
\texttt{flushleft}   & Left aligned text. \\
\texttt{flushright}  & Right aligned text. \\
\texttt{description} & Labelled lists. \\
\texttt{enumerate}   & Numbered lists. \\
\texttt{itemize}     & Bulleted lists. \\
\texttt{quotation}   & Include quotes. \\
\texttt{verbatim}    & Text in typewriter font that that will appear exactly as typed. \\
\texttt{table}       & Floating tables. \\
\texttt{figure}      & Floating figures. \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Environment options}
\end{center}
\end{table}


The verbatim environment prints it's in a typewriter font with no formatting. If the text isn't broken with a \texttt{<return>}, it produces text in one long line which may run across the page, into the right-hand margin and then off the page entirely. The first 100 digits of $\pi$ may appear on your editor as


{\small
\begin{verbatim}
The first 100 digits of $\pi$: \\
3.14159265358979323846264338327950288419716939937510582097494459
23078164062862089986280348253421170679
\end{verbatim}
}


\begin{flushleft}
but when the document is compiled, it produces:
\end{flushleft}


\begin{flushleft}
The first 100 digits of $\pi$: \\
3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679
\end{flushleft}


This can be fixed by breaking the text into lengths that don't cross into the margins. In this example, it is broken into 25-digit sections with a <return> to signal the end of a line: 


{\small
\begin{verbatim}
The first 100 digits of $\pi$: \\
3.141592653589793238462643 <return>  
38327950288419716939937510 <return>  
58209749445923078164062862 <return>  
089986280348253421170679    
\end{verbatim}
}


\begin{flushleft}
This produces:
\end{flushleft}


\begin{flushleft}
The first 100 digits of $\pi$: \\
3.141592653589793238462643 \\
38327950288419716939937510 \\
58209749445923078164062862 \\
089986280348253421170679 \\
\end{flushleft}



\subsection{Lists}

Lists may be bulleted or numbered and are created with the \texttt{itemize} and \texttt{enumerate} environments respectively. List items are specified with \texttt{\textbackslash item Item Text}. For a bulleted list:


{\small
\begin{verbatim}
\begin{itemize}
\item Item 1
\item Item 2
\item Item 3
\end{itemize}
\end{verbatim}
}

\begin{flushleft}
produces:
\end{flushleft}

\begin{itemize}
\item Item 1
\item Item 2
\item Item 3
\end{itemize}


The symbol denoting each item in a bulleted list can be changed by adding an option after each \texttt{\textbackslash item} command in square brackets:


{\small
\begin{verbatim}
\begin{itemize}
\item[--] Item 1
\item[\textasteriskcentered] Item 2
\item[\textdagger] Item 3
\end{itemize}
\end{verbatim}
}


\begin{flushleft}
produces:
\end{flushleft}


\begin{itemize}
\item[--] Item 1
\item[\textasteriskcentered] Item 2
\item[\textdagger] Item 3
\end{itemize}


\begin{flushleft}
Numbered lists are created by the enumerate environment:
\end{flushleft}

{\small
\begin{verbatim}
\begin{enumerate} 
\item Item 1 
\item Item 2 
\item Item 3 
\end{enumerate}
\end{verbatim}
}

\begin{flushleft}
produces:
\end{flushleft}


\begin{enumerate}
\item Item 1
\item Item 2
\item Item 3
\end{enumerate}



Lists can be nested with additional enumerate commands. Each sub-category is contained within its own enumerate environment.


{\small
\begin{verbatim}
\begin{enumerate} 
\item Item 1 
\begin{enumerate} 
\item Item A 
\item Item B 
\item item C 
\end{enumerate} 
\item Item 2 
\item Item 3 
\end{enumerate} 
\end{verbatim}
}


\begin{flushleft}
produces:
\end{flushleft}


\begin{enumerate}
\item Item 1
\begin{enumerate}
\item Item A
\item Item B
\item Item C
\end{enumerate}
\item Item 2
\item Item 3
\end{enumerate}

\clearpage



\subsection{Tables}
Tables are placed inside their own environment. LaTeX places them so that they don’t break across pages and because their location can vary from the location specified by typesetters, they are referred to as floats. Using \texttt{\textbackslash clearpage} at the end of each document section places any outstanding floats at the end of the section before the new one starts.


\subsubsection{Basic Tables}

Tables are placed within the \texttt{table} environment. LaTeX numbers them automatically and the caption will appear in the List of Tables. \\

Tables consist of two nested environments: \texttt{table}, and \texttt{tabular}. \texttt{\textbackslash begin\{table\}} has an option to help place the table on the page. This can be at the top of the page with \texttt{t}, the bottom of the page with \texttt{b}, here with \texttt{h} and on a separate page of floats with \texttt{p}. These commands don't over-ride LaTeX's formatting rules, but can be enforced a bit more with \texttt{!}. \texttt{\textbackslash begin\{table\}[!h]} places a table at the location of it's code.

The next line justifies the table on the page. This can be \texttt{centre}, \texttt{flushleft} or \texttt{flushright}. 

Instructions relating to the number of columns, their alignment and if there are vertical lines seperating the columns are on the same line as \texttt{\textbackslash begin\{tabular\}} in curly braces. The number of alignment options should match the number of columns. The options are \texttt{l} = left aligned, \texttt{c} = centred and \texttt{r} = right aligned. These will automatically adjust the column width to the contents.

\texttt{ p\{ColumnWidth\}} may be used to define the width of a column. The width may be specified in millimetres (mm), Centimetres (cm), and inches (in). The size of the table's font may be reduced by placing a \texttt{\textbackslash {FontSize}} command after the beginning of the table environment.

Vertical lines are added with a \texttt{|} placed between the alignment commands. This key is located on the keyboard below \texttt{backspace}. Horizontal lines with definable widths are available through the \texttt{booktabs} package. This package offers three commands: \texttt{\textbackslash toprule [Width]}, \texttt{\textbackslash midrule[Width]} and \texttt{\textbackslash bottomrule[Width]}. These commands accept measurements in points (pt), millimetres (mm), centimetres (cm), inches (in) etc. \\

The code below shows the two nesting levels for a table with four columns. The table is placed at it's location in the document code with the \texttt{[h]} option. It is centred on the page with the center environment. Column 1 is left aligned, column 2 centred, column 3 right aligned and column 4 has a user defined width of 5cm. Vertical lines separate columns 1--2, 2--3 and 3--4. A caption is placed at the bottom of the table:


{\small
\begin{verbatim}
\begin{table}[h]
\begin{center}
\begin{tabular}{l|c|r|p{5cm}}
		
{. . . Table Contents . . . }

\end{tabular}	
\caption{Caption text}
\end{center}
\end{table}
\end{verbatim}
}


Table data is placed inside the \texttt{tabular} environment. Each cell is separated with an \texttt{\&}, and the end of each row is specified with \texttt{\textbackslash \textbackslash}. \\

The following example creates a table with four columns and four rows. The first row contains the column headings with lines above and below it with another line at the bottom of the table. These lines are defined in points with the top and bottom lines 1.0 points thick and the middle line 0.5 points thick. Table 13 shows the compiled output. The font size has been slightly reduced with \texttt{\textbackslash small}.


{\small
\begin{verbatim}
\begin{table}[h]
\small
\begin{center}
\begin{tabular}{l|c|r|p{5cm}}
\toprule[1.0pt]
Column 1 & Column 2 & Column 3 & Column 4 \\
\midrule[0.5pt]
Row 1 & Text 2 &  3.157 & Lorem ipsum dolor sit amet, consectetur 
adipiscing elit. \\
Row 2 & Text 2 & 14.930 & Nulla est purus, ultrices in porttitor in, 
accumsan non quam. \\
Row 3 & Text 2 &  0.720 & Nam consectetur porttitor rhoncus. Curabitur 
eu est et leo feugiat auctor vel quis lorem. \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Sample table}
\end{center}
\end{table}	
\end{verbatim}
}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{l|c|r|p{5cm}}
\toprule[1.0pt]
Column 1 & Column 2 & Column 3 & Column 4 \\
\midrule[0.5pt]
Row 1 & Text 2 &  3.157 & Lorem ipsum dolor sit amet, consectetur adipiscing elit. \\
Row 2 & Text 2 & 14.930 & Nulla est purus, ultrices in porttitor in, accumsan non quam. \\
Row 3 & Text 2 &  0.720 & Nam consectetur porttitor rhoncus. Curabitur eu est et leo feugiat auctor vel quis lorem. \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Sample table}
\end{center}
\end{table}


Horizontal lines can be placed across a selection of columns with \texttt{\textbackslash cmidrule}. This command requires the line thickness and the column number/s the line will appear at. 


{\small
\begin{verbatim}
\cmidrule[LineThickness]{ColumnNumbers x-n}
\end{verbatim}
}

The following code produces a table with three columns with headings with horizontal lines. The middle line covers columns 1-2 of the three table columns. The output is Table 14.


{\small
\begin{verbatim}
\begin{table}[h]
\small
\begin{center}	
\begin{tabular}{lll}
\toprule[1.0pt]
Column 1 & Column 2 & Column 3 \\
\cmidrule[0.5pt]{1-2}
Row 1 & Text 1 & Lorem ipsum dolor sit amet \\
Row 2 & Text 2 &  Nulla est purus \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Sample Table: Partial horizontal lines}
\end{center}
\end{table}
\end{verbatim}
}


\begin{table}[h]
\small
\begin{center}	
\begin{tabular}{lll}
\toprule[1.0pt]
Column 1 & Column 2 & Column 3 \\
\cmidrule[0.5pt]{1-2}
Row 1 & Text 1 & Lorem ipsum dolor sit amet \\
Row 2 & Text 2 &  Nulla est purus \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Sample Table: Partial horizontal lines}
\end{center}
\end{table}

Lines can cover any combination of columns. For a single column, specify the column number/s only. Although the line may cover only one column, both the beginning and end columns should still be specified, in this case a line 1 point thick over column 1: 


{\small
\begin{verbatim}
\cmidrule[1.0pt]{1-1}
\end{verbatim}
}


For multiple separated columns on the same row, the command can be used as many times as necessary. To place them in columns 1 and 3--4:


{\small
\begin{verbatim}
\cmidrule[1.0pt]{1-1} \cmidrule[1.0pt]{3-4}
\end{verbatim}
}


\subsubsection{Combining columns}

Columns can be merged with \texttt{\textbackslash multicolumn}. This command requires the number of columns to merge, the alignment of the column text and the text for the merged columns:

\begin{verbatim}
\multicolumn{MergedColumns}{Alignment}{text}
\end{verbatim}

The following code merges columns 1--3 of a four column table with centred text. If the number of merged columns is less than the total number, the extra columns should be signified with a \texttt{\&} and the end of the row should be marked with a \texttt{\textbackslash \textbackslash}. In the example below, only the first three columns are merged, so the fourth should be signified with a \texttt{\&}. The output is in Table 15:


{\small
\begin{verbatim}
\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lcrp{5cm}}
\toprule[1pt]	
\multicolumn{3}{c}{Combined Columns} & \\
Column 1 & Column 2 & Column 3 & Column 4 \\
\midrule[0.5pt]
Row 1 & Text 2 & 3.157  & Lorem ipsum dolor sit amet, consectetur 
adipiscing elit. \\
Row 2 & Text 2 & 14.930 & Nulla est purus, ultrices in porttitor in, 
accumsan non quam. \\
Row 3 & Text 2 & 0.720  & Nam consectetur porttitor rhoncus. Curabitur 
eu est et leo feugiat auctor vel quis lorem. \\
\bottomrule[1pt]
\end{tabular}
\caption{Sample table: Combined columns}
\end{center}
\end{table}
\end{verbatim}
}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lcrp{5cm}}
\toprule[1pt]	
\multicolumn{3}{c}{Combined Columns} & \\
Column 1 & Column 2 & Column 3 & Column 4 \\
\midrule[0.5pt]
Row 1 & Text 2 & 3.157  & Lorem ipsum dolor sit amet, consectetur adipiscing elit. \\
Row 2 & Text 2 & 14.930 & Nulla est purus, ultrices in porttitor in, accumsan non quam. \\
Row 3 & Text 2 & 0.720  & Nam consectetur porttitor rhoncus. Curabitur eu est et leo feugiat auctor vel quis lorem. \\
\bottomrule[1pt]
\end{tabular}
\caption{Sample table: Combined columns}
\end{center}
\end{table}



\subsubsection{Combining Rows}


Rows can also be combined with the \texttt{\textbackslash multirow} command from the \texttt{multirow} package. This command requires the number of rows to be combined, the width, and the text for the multiple row cell. Width may be specified in the same way as a \texttt{p\{\}} alignment with a specified width, or it may be automatically set to it's natural width. LaTeX's natural width is selected by inserting an \texttt{\textasteriskcentered} in the width option:


\begin{verbatim}
\multirow{NumberOfRows}{Width}{Text}
\end{verbatim}

The code below creates a table with three columns. The first column contains three merged rows with the column's width set to natural with an \textasteriskcentered. The second and third columns contain data in the normal way.


{\small
\begin{verbatim}
\begin{table}[h]
\small
\begin{center}
\begin{tabular}{cll}
\toprule[1.0pt]
\multirow{3}{*}{Start Time} & Early    & Topic 1 \\
                            & Mid-day  & Lunch   \\
                            & Late     & Topic 2 \\
\bottomrule[1.0pt]
\end{tabular}
\end{center}
\caption{Sample Table: Combined rows}
\end{table}
\end{verbatim}
}




\begin{table}[h]
\small
\begin{center}
\begin{tabular}{cll}
\toprule[1.0pt]
\multirow{3}{*}{Start Time} & Early    & Topic 1 \\
                            & Mid-day  & Lunch   \\
		                	& Late     & Topic   \\
\bottomrule[1.0pt]
\end{tabular}
\end{center}
\caption{Sample Table: Combined rows}
\end{table}


\subsubsection{Combined Columns and Rows}

Columns and rows can be combined to produce very complex tables. The code below produces a table for seminar times. It combines columns for the headings and rows for the times. The output is Table 17.

{\small
\begin{verbatim}
\begin{table}[h]
\small
\begin{center}
\begin{tabular}{clll}
\toprule[1.0pt]
\multicolumn{4}{c}{Seminar Timetable} \\
\midrule[0.5pt]
\multicolumn{3}{c}{Times} & Titles \\
\midrule[0.5pt]
\multirow{8}{*}{Day} & \multirow{2}{*}{Monday}    & Morning    & Topic 1 \\
                     &                            & Afternoon  & Topic 2 \\
                     &                            &            &         \\
                     & \multirow{2}{*}{Tuesday}   & Morning    & Topic 3 \\
                     &                            & Afternoon  & Topic 4 \\
                     &                            &            &         \\  
                     & \multirow{2}{*}{Wednesday} & Morning    & Topic 5 \\
                     &                            & Afternoon  & Topic 6 \\
\bottomrule[1.0pt]
\end{tabular}
\end{center}
\caption{Sample Table: Combined columns and rows}
\end{table}
\end{verbatim}
}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{clll}
\toprule[1.0pt]
\multicolumn{4}{c}{Seminar Timetable} \\
\midrule[0.5pt]
\multicolumn{3}{c}{Times} & Titles \\
\midrule[0.5pt]
\multirow{8}{*}{Day} & \multirow{2}{*}{Monday}    & Morning    & Topic 1 \\
                     &                            & Afternoon  & Topic 2 \\
                     &                            &            &         \\
                     & \multirow{2}{*}{Tuesday}   & Morning    & Topic 3 \\
                     &                            & Afternoon  & Topic 4 \\
                     &                            &            &         \\  
                     & \multirow{2}{*}{Wednesday} & Morning    & Topic 5 \\
                     &                            & Afternoon  & Topic 6 \\
\bottomrule[1.0pt]
\end{tabular}
\end{center}
\caption{Sample Table: Combined columns and rows}
\end{table}

\clearpage


\subsection{Figures}

The first step in importing graphic files is to place the file in the project directory so that LaTeX can find it. Graphics are placed within documents inside the \texttt{figure} environment. This is a float and the same positioning commands may be used as with tables: \texttt{h}, \texttt{t}, \texttt{b} or \texttt{p}. The placement of the figure on the page can be: \texttt{centre}, \texttt{flushleft} or \texttt{flushright}. The graphic is selected with \texttt{\textbackslash includegraphics}. This command requires the name of the graphic file and has a \texttt{scale} option that tells LaTeX to resize it: 1.0 is the normal size, 0.5 is half size and 2.0 is double size. Captions are added in the same way as tables with \texttt{\textbackslash caption\{\}}.

{\small
\begin{verbatim}
\includegraphics[Sizing]{GraphicFileName}
\end{verbatim}
}

The code below loads an encapsulated postscript file named \texttt{Drawing.eps} as a centred graphic in the \texttt{figure} environment with a caption. The caption text will appear as the figure title in the List of Figures in the front matter. \texttt{\textbackslash includegraphics\{\}} tells LaTeX the name of the graphic file to load and \texttt{scale} specifies whether to reduce or enlarge: 1.0 is original size, 0.5 is half size and 2.0 is double. In this case, the file size is reduced to 50\% of the original which is about 10cm square. The code below produces figure 1. \\
 
 
{\small
\begin{verbatim}
\begin{figure}[h]
\center
\includegraphics[scale=0.5]{Drawing.eps}
\caption{Spiral}
\end{figure}	
\end{verbatim}
}


\begin{figure}[h]
\center
\includegraphics[scale=0.5]{Drawing.eps}
\caption{Spiral}
\end{figure}


\subsubsection{LaTeX and Graphic Formats}


LaTeX works with a quite limited range of graphic formats. Documents in postscript format can only contain graphics in postscript (\texttt{ps}) or encapsulated postscript (\texttt{eps}) formats. Documents created by \textsc{pdf}TeX may contain graphics in \texttt{pdf}, \texttt{png}, \texttt{jpeg} or \texttt{jbig2} formats. If the file is in a different format, it will have to be converted to one of these. A good choice for this is Image Magic. It is freely downloadable and can read and write 200 graphic formats.  \\


There are two types of graphic formats: vector and raster. Vector formats, such as postscript (\texttt{ps}), encapsulated postscript (\texttt{eps}), are based on geometric concepts such as points, lines, and curves. Vector format file sizes are relatively small because the file contains only the instructions for the points, lines and curves that make up the graphic. It is most often used for line art, such as diagrams, graphs, 3D models, etc. It has the advantage that it can be upsampled or downsampled (enlarged or shrunk) without any loss of quality. Postscript is the `gold standard' for printed documents but unfortunately, postscript only works with whole pages. \texttt{eps} works with graphics of any size so this is the preferred format for graphics that are smaller than this. 

Raster graphics are made up of pixels. Each pixel has a value relating to its individual colour attached to it. They are produced by digital cameras, scanners, etc and the file sizes are relatively large. These formats cannot be manipulated, that is resized, rotated, etc without losing information. To avoid this, image processing should be completed before they are inserted into a document and the image sized to the dimensions that it will be printed at. 

If the image is in \texttt{pdf} format, any fonts that it contains should be embedded before it is included in a LaTeX document. This means that a copy of the fonts included in the graphic are included with the image file. If they are not embedded, fonts on the current user's system will be substituted. If they are not the same, the image will not appear as it's creator intended. \\

If the document is to be printed professionally, the printers should be consulted for their requirements. These may include specific file formats, resolution, which is often 300ppi, a colour space, often cmyk or rgb, and colour depth which may be restricted to 8bit. These are best edited with dedicated graphics software. A large number of these are available, both commercial and non-commercial. 


\clearpage


\subsection{Page Numbering}
The default page numbering in LaTeX is Arabic numerals which begin on the first page. Table 18 shows the available styles: 


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lll}
\toprule[1.0pt]
Style  &  Numeral Type  &  Example Text \\
\midrule[0.5pt]
\texttt{arabic}  &  Arabic numerals            &  1, 2, 3, 4, 5      \\
\texttt{roman}   &  Lower-case Roman numerals  &  i, ii, iii, iv, v  \\
\texttt{Roman}   &  Upper-case Roman numerals  &  I, II, III, IV, V  \\
\texttt{alph}    &  Lower-case letters         &  a, b, c, d, e      \\
\texttt{Alph}    &  Upper-case letters         &  A, B, C, D, E      \\
\bottomrule[0.5pt]
\end{tabular}
\caption{Page numbering options}
\end{center}
\end{table}




If the page numbering for the document is to be other than arabic, it can be specified after \texttt{\textbackslash begin\{document\}} with \texttt{\textbackslash pagenumbering\{StyleName\}}:

{\small
\begin{verbatim}
\documentclass[a4paper]{article}

. . .

\begin{document}	
\pagenumbering{StyleName} 

Document Text

\end{document}
\end{verbatim}
}


It is possible to have two styles in a document, for instance lower case Roman numerals for the front matter including the index, Table of Contents, List of Figures, etc, and Arabic numerals for the remainder of the text. 

This is handled with \texttt{\textbackslash pagenumbering\{StyleName\}}. At the beginning of the front matter, insert \texttt{\textbackslash pagenumbering\{roman\}} and when the main matter of the document begins, insert \texttt{\textbackslash pagenumbering\{arabic\}}. If the title page is to be un-numbered, insert \texttt{\textbackslash thispagestyle\{empty\}} following \texttt{\textbackslash maketitle}.  

The following creates an article class document with an un-numbered title page containing an abstract, a Table of Contents, List of Figures and List of Tables on separate pages with Roman numerals and the body text in Arabic numerals.


{\small
\begin{verbatim}
\documentclass[a4paper]{article} 
\title{The Lost Secrets of \LaTeXe}
\author{Albertus Magnus} 

\begin{document}
\maketitle
\thispagestyle{empty}

\begin{abstract} 
Abstract text.
\end{abstract}

\clearpage
\pagenumbering{roman} 
\tableofcontents
\clearpage

\listoffigures
\clearpage

\listoftables
\clearpage

\pagenumbering{arabic}

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus . . . 

\end{document} 
\end{verbatim}
}

\begin{flushleft}
To change the page numbering counter, use \texttt{\textbackslash setcounter\{page\}\{PageNumber\}}. 
\end{flushleft}

{\small
\begin{verbatim}
\pagenumbering{arabic} 
\setcounter{page}{5} 
\end{verbatim}
}

\begin{flushleft}
This changes the page numbering to Arabic and begins the page count at page 5.
\end{flushleft}


\clearpage



\section{Mathematics in LaTeX}

One of LaTeX’s strengths is its facilities for mathematical equations. This is done by either activating math mode, or by using the \texttt{equation} or \texttt{displaymath} environments. 

Math mode is activated by enclosing a mathematical expression within a pair of \texttt{\$}. This is especially useful when an equation is set within text such as when you need to include mathematics, such as the results of a statistical test, in a report:


{\small
\begin{verbatim}
... main effect for the interaction between the factors was significant \$(F(2,
125) = 3.146, p < 0.05, \textbackslash omega\^{}2 = 0.032)\$, though the 
practical significance ...
\end{verbatim}
}


\begin{flushleft}
produces
\end{flushleft}


\begin{flushleft}
. . . main effect for the interaction between the factors was significant $(F(2,125) = 3.146, p < 0.05, \omega^2 = 0.032)$, though the practical significance . . .
\end{flushleft}

\texttt{\^{}} and \texttt{\_} produce superscripts and subscripts respectively, and fractions can be typeset with \texttt{\$\textbackslash frac\{Numerator\}\{Denominator\}\$}. Three quarters is \texttt{\$\textbackslash frac\{3\}\{4\}\$}: $\frac{3}{4}$ and square roots are \texttt{\$\textbackslash sqrt\{16\}\$}: $\sqrt{16}$. Special characters can be created with diacritics: \texttt{\$\textbackslash bar\{X\}\$} produces $\bar{X}$ and \texttt{\$\textbackslash hat\{Y\}\$} produces $\hat{Y}$. 

Summation notation is available with the \texttt{\$\textbackslash sum\$} command which produces the Greek letter $\sum$. The \texttt{\textbackslash limits} command places upper and lower limits. The lower limit of summation is defined with a subscript and the upper limit of summation is defined with a superscript: \texttt{\$\textbackslash sum \textbackslash limits\_\{i=1\}\^{}\{n\}\$} produces $\sum\limits_{i=1}^{n}$. Elements can be added with \texttt{\$x\_i = x\_1 + x\_2 + x\_3 \textbackslash ldots x\_n\$}. This produces

\begin{displaymath}
\sum\limits_{i=1}^{n}x_i = x_1 + x_2 + x_3 \ldots x_n
\end{displaymath}

Some common mathematical symbols and the commands to produce them are shown in Table 19. LaTeX comes with Greek letters in upper and lowercase fonts. It provides all the lower-case letters and some of the upper-case letters. Pakin (2021) recommends that upper case Latin glyphs be used for the missing Greek upper-case letters. A list of these and their commands are in Table 20. 


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{ll}
\toprule[1.0pt]
$a \times b + c - d \div e$  &  \texttt{a \textbackslash times b + c - d \textbackslash div e} \\
$a < b > c$                  &  \texttt{a < b > c}  \\	
$a^2 + b^2 = c^2$            &  \texttt{a\^{}2 + b\^{}2 = c\^{}2}   \\                                         
$y - y_1 = m(x - x_1)$       &  \texttt{y - y\_1 = m(x - x\_1)}  \\
$f'$                         &  \texttt{f'} \\  
$n!$                         &  \texttt{n!} \\             
$\frac{a}{b}$                &  \texttt{\textbackslash frac\{a\}\{b\}} \\ 
$a \choose b$                &  \texttt{a \textbackslash choose b} \\
$\sqrt a$                    &  \texttt{\textbackslash sqrt a} \\                         
$\root n \of {a}$            &  \texttt{\textbackslash root n \textbackslash of \{a\}}  \\     
$\overbrace{abc}$            &  \texttt{\textbackslash overbrace\{\}} \\                         
$\underbrace{abc}$           &  \texttt{\textbackslash underbrace\{\}} \\ 	
$\sum$                       & 	\texttt{\textbackslash sum} \\ 	
$\sum\limits_{i=0}^{\infty}$   &  \texttt{\textbackslash sum \textbackslash limits \_\{i=0\}\{\textbackslash infty\} }\\ 
\bottomrule[1.0pt]
\end{tabular}
\caption{Some common mathematical symbols}
\end{center}
\end{table}



\begin{table}[h]
\small
\begin{center}
\begin{tabular}{llllllllll}
\toprule[1.0pt]
$\Gamma$  &  \texttt{\textbackslash Gamma}  &  $\Delta$ &  \texttt{\textbackslash Delta}  &  $\Theta$ &  \texttt{\textbackslash Theta}  &  $\Lambda$  &  \texttt{\textbackslash Lambda}  &  $\Xi$    &  \texttt{\textbackslash Xi}  \\
			
$\Pi$  &  \texttt{\textbackslash Pi}  &  $\Sigma$    &  \texttt{\textbackslash Sigma}  &  $\Upsilon$  &  \texttt{\textbackslash Upsilon}  &  $\Phi$    &  \texttt{\textbackslash Phi}  &  $\Psi$    &  \texttt{\textbackslash Psi}  \\
			
$\Omega$    &  \texttt{\textbackslash Omega}  \\
			
$\alpha$ &  \texttt{\textbackslash alpha}  &	$\beta$  &  \texttt{\textbackslash beta}  &  $\gamma$  &  \texttt{\textbackslash gamma}  &  $\delta$  &  \texttt{\textbackslash delta}	 &  $\epsilon$  &  \texttt{\textbackslash epsilon}	\\
			
$\zeta$ &  \texttt{\textbackslash zeta}  &  $\eta$  &  \texttt{\textbackslash eta}  &  $\theta$  &  \texttt{\textbackslash theta}  &  $\iota$  &  \texttt{\textbackslash iota}  &  $\kappa$  &  \texttt{\textbackslash kappa}  \\
			
$\lambda$  &  \texttt{\textbackslash lambda}  & 	$\mu$  &  \texttt{\textbackslash mu}  &		$\nu$&  \texttt{\textbackslash nu}  &	$\xi$&  \texttt{\textbackslash xi}  &	$\pi$&  \texttt{\textbackslash pi}  \\	
			
$\rho$  &  \texttt{\textbackslash rho}  &  $\sigma$  &  \texttt{\textbackslash sigma}  &  $\tau$  &  \texttt{\textbackslash tau}  &  $\upsilon$  &  \texttt{\textbackslash upsilon}  &  $\phi$  &  \texttt{\textbackslash phi}  \\
			
$\chi$  &  \texttt{\textbackslash chi}  &  $\psi$   &  \texttt{\textbackslash psi}  &  $\omega$   &  \texttt{\textbackslash omega}  \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Upper and lowercase Greek letters}
\end{center}
\end{table}


Both \texttt{equation} and \texttt{displaymath} environments print one-line equations. The difference between them is that formulae set with \texttt{equation} are numbered:

{\small
\begin{verbatim}
\begin{equation}
\bar{X} = \frac{\Sigma X}{n}
\end{equation}
\end{verbatim}
}


\begin{equation}
\bar{X} = \frac{\Sigma X}{n}
\end{equation}



\begin{verbatim}
\begin{displaymath}
\bar{X} = \frac{\Sigma X}{n}
\end{displaymath}	
\end{verbatim}



\begin{displaymath}
\bar{X} = \frac{\Sigma X}{n}
\end{displaymath}

This is a very short preview of LaTeX's mathematical capabilities. It has extensive facilities for matrices and functions and symbols and diacritics. For documentation on mathematics and symbols in LaTeX, see Berry (2021) and for a comprehensive list of symbols, see Pakin (2021).


\clearpage



\section{Front Matter}

\subsection{Title Pages}

Title pages are defined in the final part of the preamble with \texttt{\textbackslash title\{\}}, \texttt{\textbackslash author\{\}} and \texttt{\textbackslash date\{\}}. The current date can be placed inside \texttt{\textbackslash date\{\}} with \texttt{\textbackslash today}, or a date can be entered manually. The title page is created with \texttt{\textbackslash maketitle} which follows \texttt{\textbackslash begin\{document\}}:

{\small
\begin{verbatim}
\documentclass[a4paper]{article}

\title{The Lost Secrets of \LaTeXe} 
\author{Albertus Magnus} 
\date{\today} 

\begin{document} 
\maketitle

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus . . . 

\end{document} 
\end{verbatim}
}


\subsection{The Abstract}

Abstracts are created by the abstract environment:

{\small
\begin{verbatim}
\begin{abstract}
	
Lorem ipsum dolor sit amet . . .

\end{abstract} 
\end{verbatim}
}


The abstract can appear on the title page or on a page of its own by inserting pagebreaks following \texttt{\textbackslash maketitle} and after the end of the abstract environment. This example places the abstract on a page of its own after the title page: 

{\small
\begin{verbatim}
\documentclass[a4paper]{article}

\title{The Lost Secrets of \LaTeXe} 
\author{Albertus Magnus} 
\date{\today} 

\begin{document} 
\maketitle
\clearpage
\begin{abstract} 
\Lorem ipsum dolor sit amet . . .
\end{abstract} 

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus . . . 

\end{document}  
\end{verbatim}
}


\subsection{Table of Contents, List of Figures and List of Tables.}

The Table of Contents, List of Figures and List of Tables are inserted with:


{\small
\begin{verbatim}
\tableofcontents

\listoffigures

\listoftables
\end{verbatim}
}

A page break after each command will place them on separate pages. LaTeX will generate these automatically and number them when the document is compiled from the sectioning commands and the figure and table captions. 

The following creates a document with a title page containing the title and abstract, a Table of Contents, List of Figures and List of Tables. These are placed on separate pages and numbered in Roman numerals, with the body of the text in Arabic numerals. It is double spaced with a ragged right margin. Page breaks are specified with \texttt{\textbackslash clearpage}:


{\small
\begin{verbatim}
\documentclass[a4paper]{article}

\title{The Lost Secrets of \LaTeXe} 
\author{Albertus Magnus}
\date{\today}

\begin{document}

\maketitle 
\doublespacing

\begin{abstract}

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus . . . 

\end{abstract}
\thispagestyle{empty}
\clearpage
\pagenumbering{roman}
\tableofcontents
\clearpage
\listoffigures
\textbackslash clearpage
\listoftables
\clearpage
\pagenumbering{arabic}

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla est purus, 
ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor 
rhoncus . . . 
\end{verbatim}
}

\clearpage



\section{End Matter}


\subsection{References}
A reference list allows readers to verify sources used by scholars, gives information about the type of source, and allows readers to locate them. Referencing is a fundamental requirement of scholarly writing. In LaTeX, these may be placed in the text manually or generated automatically. 


\subsubsection{Ye Olde Fashioned Way}
References and citations can be inserted into a document manually. A reference list can be added in the appropriate place in the document with \texttt{\textbackslash section\{title\}} command, and the references listed below this. Footnotes can be created by placing \texttt{\textbackslash footnote\{Your Text\}} at the appropriate location in the text. When the document is compiled, the location is numbered with a superscript, and \texttt{Your Text} appears at the bottom of the page. Doing this by hand can be quite laborious and painstaking but it has the advantage that it will match any style requirement.


\subsubsection{Automatically Generated References: Bib\LaTeX}
LaTeX has facilities to generate references and reference lists automatically. BibLaTeX is a modern package for managing references and a wide range of packages with reference styles are available for it from \textsc{ctan}. BibLaTeX requires that several packages be present on your LaTeX installation. These are listed in the `Required Packages' table above. \\

The first step in using LaTeX's automated reference system is to create a reference database for the project. This contains a list of primary, secondary, and tertiary sources used in the document in \texttt{.bib} format and is saved to the project directory so that LaTeX can find it when the document is compiled. Entrys have varying requirements. Database entrys for books require the name/s of the authors, the title, publisher, year of publication, publisher and publishers' address. Articles require authors, title, journal name, year, volume and pages. See BibLaTeX's documentation for specific requirements for each type of reference.

All bibliographical entries require a unique key. LaTeX uses these to match entries in the text with each reference. The type of reference and it's unique key are contained in the first line. The key can be anything, but the first author's surname and year of publication, such as \texttt{Paper10}, is memorable. If the database contains more than one publication by the same author(s) in the same year, they can be uniquely identified by adding a letter: Paper10a, Paper10b, Paper10c. 

It is possible to edit this file manually with a plain text editor if required, though there are a number of reference managers that simplify this process. The section above on Additional Software has several suggestions. A sample database containing an entry for a book and an article is below. These files should be saved in \texttt{.bib} format.


{\small
\begin{verbatim}
@book{Paper10,
author = {A Paper and F Pen and B L K Ink},
title = {Our Book},
publisher = {First Authors Press},
year = {2010},
address = {Booktown} 
}
	
@article{Kliker12,
author = {G Kliker and L Flash},
title = {Photographing Critics},
Journal = {The Journal of Critical Photography},
Year = {2012},
Volume = {12},
pages = {50-60}
}
\end{verbatim}
}



\begin{flushleft}
Table 21 contains a list of reference types supported by BibLaTeX. \\
\end{flushleft}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{ll}
\toprule[1.0pt]
& LaTeX Reference Types \\
\midrule[0.5pt]
& \texttt{article}       \\
& \texttt{book}          \\
& \texttt{booklet}       \\
& \texttt{conference}    \\
& \texttt{inbook}        \\
& \texttt{incollection}  \\
& \texttt{inproceedings} \\
& \texttt{manual}        \\
& \texttt{mastersthesis} \\
& \texttt{misc}          \\
& \texttt{phdthesis}     \\
& \texttt{proceedings}   \\
& \texttt{techreport}    \\
& \texttt{unpublished}   \\
\bottomrule[1.0pt]			
\end{tabular}
\caption{Reference types supported by BibLaTeX}
\end{center}
\end{table}


Citations are placed in the text with \texttt{\textbackslash cite\{\}} or \texttt{\textbackslash parencite\{\}} with the reference key placed between curly braces. \texttt{\textbackslash cite\{Kliker12\}} produces a reference that is something like Kliker and Flash (2012). \texttt{\textbackslash parencite\{Kliker12\}} produces a citation in parentheses (Kliker and Flash, 2012). \\



\begin{verbatim}
Lorem ipsum dolor sit amet, \cite{Kliker12} consectetur adipiscing elit. 
Nulla est purus, ultrices in porttitor in, accumsan non quam. Nam 
consectetur porttitor rhoncus. Curabitur eu est et leo feugiat auctor vel 
quis lorem. Ut et ligula dolor, sit amet consequat lorem 
\parencite{Kliker12}. 
\end{verbatim}

\begin{flushleft}
produces
\end{flushleft}

\begin{flushleft}
Lorem ipsum dolor sit amet, Kliker and Flash (2012) consectetur adipiscing elit. Nulla est purus, ultrices in porttitor in, accumsan non quam. Nam consectetur porttitor rhoncus. Curabitur eu est et leo feugiat auctor vel quis lorem. Ut et ligula dolor, sit amet consequat lorem (Kliker and Flash, 2012). 
\end{flushleft}


A short list of common referencing styles and their packages is listed in Table 22. Additional information on these styles including limitations and incompatibilities is available in each package's documentation. \\

\begin{table}[h]
\small
\begin{center}
\begin{tabular}{p{5cm}l}
\toprule[1.0pt]
Style                                                        & Package Name                \\
\midrule[0.5pt]
American Psychological Association, 7th Edition              &  \texttt{biblatex-apa}      \\  
Chicago Manual of Style, 17th Edition                        &  \texttt{biblatex-chicago}  \\
MLA Handbook for Writers of Research Papers, 9th Edition     &  \texttt{biblatex-mla}      \\
Vancouver Style                                              &  \texttt{vancouver}         \\
\bottomrule[1.0pt]
\end{tabular}
\caption{BibLaTeX citations styles}
\end{center}
\end{table}


\begin{flushleft}
\texttt{biblatex} is loaded in the preamble along with the required citation style. \\
\end{flushleft}

{\small
\begin{verbatim}
\usepackage[style=StyleName]{biblatex} 
\end{verbatim}
} 

\begin{flushleft}
The \texttt{StyleName} \texttt{apa} loads the American Psychological Association, 7th Edition style. \texttt{vancouver} loads the Vancouver style and \texttt{mla} loads the MLA style. There is no need to use the entire package name.
\end{flushleft} 

The \texttt{biblatex-chicago} style package is an exception to this. This package is loaded in place of \texttt{biblatex}, and the format is defined in options. This can be any of BibLaTeX's standard formats: \texttt{numeric}, \texttt{alphabetic}, \texttt{authordate} and \texttt{authortitle}. The following loads \texttt{biblatex-chicago} with the \texttt{authordate} option:


{\small
\begin{verbatim}
\usepackage[authordate]{biblatex-chicago}
\end{verbatim}
}


BibLaTeX requires that a number of packages be present on your LaTeX installation. Two are loaded before biblatex. These are \texttt{babel} and \texttt{csquotes}. The others should be loaded automatically by LaTeX if they are required.

The reference database is loaded next with \texttt{\textbackslash addbibresource\{\}}. This loads the reference database and requires only the name of the database. 

The reference list is placed inside the document environment at the desired location in the text with \texttt{\textbackslash printbibliography}. 

An optional command is \texttt{\textbackslash nocite\{\}}. This allows items that have not been explicitly referred to in the text, but are in the bibliographical database, to be included in the reference list. To include a specific item, it's unique key should be placed inside the curly brackets: \texttt{\textbackslash nocite\{ItemKey\}}. To include all the items in the bibliography, use a \texttt{\textasteriskcentered: \textbackslash nocite\{\textasteriskcentered\}}. \\


The code below loads \texttt{biblatex}, specifies the name of the reference database with \texttt{\textbackslash addbibresource\{Databasename.bib\}} and places the reference list with all the references in the bibliography on a new page:

{\small
\begin{verbatim}
\documentclass[]{article}
 . . .	
\usepackage{babel}
\usepackage{csquotes}
\usepackage[style=CitationStyle]{biblatex}
\addbibresource{DatabaseName.bib}
\begin{document}
	
Document Text.
	
\clearpage	
\nocite{*}
\printbibliography
\end{document}
\end{verbatim}
}


When documents with BibLaTeX citations are compiled, the citation processing package \texttt{biber} must also be run to process and sort the citations and reference list. \\

Referencing styles are regularly revised, new ones appear, and institutions and publications may have their own versions of these. If an automated referencing system is used, the documentation should be consulted for shortcomings and possible incompatibilities with style requirements. 



\subsection{Appendices}

Appendices can be added to documents with the \texttt{appendix} package. This is loaded in the preamble with 


{\small
\begin{verbatim}
\usepackage{appendix}
\end{verbatim}
}

\begin{flushleft}
Options for this package are listed in Table 23:
\end{flushleft}


\begin{table}[h]
\small
\begin{center}
\begin{tabular}{lp{5cm}}
\toprule[1.0pt]
Option             &  Description \\
\midrule[0.5pt]
\texttt{toc}       &  Includes a title in the Table of Contents prior to listing the appendices \\
\texttt{page}      &  Places a title prior to the beginning of the appendices \\
\texttt{title}     &  Adds the name `Appendix' to each appendix title \\
\texttt{titletoc}  &  Does the same to each appendix title in the Table of Contents \\
\texttt{header}    &  Does the same for each page header \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Options for package appendix}
\end{center}
\end{table}


The appendices themselves are placed inside the appendix environment and are sectioned in the same way as the document text. Insert a \texttt{\textbackslash clearpage} before \texttt{\textbackslash begin\{append- ices\}} and before each section to place them on a new page. 

{\small
\begin{verbatim}
\clearpage
\begin{appendices} 
\clearpage	
\section{Appendix 1}
\clearpage
\section{Appendix 2}
\end{appendices}
\end{verbatim}
}




\clearpage



\section{Compiling Documents}

\subsection{Postscript Format}

When the text is marked up, it must be compiled to produce a readable document. LaTeX can produce postscript and \textsc{pdf} files. Postscript is the `Gold Standard’ for printed documents and LaTeX produces these without any special commands in the preamble. These files are compiled by running LaTeX multiple times to resolve the front and back matter, tables and lists. If the document contains references created through BibLaTeX, Biber will also have to be run to sort and resolve these as well. The following scheme is suggested for documents that contain BibLaTeX references. \texttt{biber} can be omitted if they are not present. 


\begin{center}
\texttt{latex} \\
\texttt{biber} \\
\texttt{latex} \\ 
\texttt{latex} \\
\end{center}

This can be done through the command line or an editor’s \textsc{gui} interface. To do this in TeXstudio, go to the Menu: \\

\begin{flushleft}
\texttt{Tools $\rightarrow$ Commands $\rightarrow$ LaTeX} \\
\end{flushleft}

\begin{flushleft}
In Kile: \\
\end{flushleft}

\begin{flushleft}
\texttt{Build $\rightarrow$ Compile $\rightarrow$ LaTeX} \\
\end{flushleft}

\begin{flushleft}
If the document contains BibLaTeX references, \texttt{biber} is in the same menu. \\
\end{flushleft}

This creates a Device Independent (\texttt{.dvi}) file. This intermediate file is then converted to postscript. In TeXstudio: \\


\begin{flushleft}
\texttt{Tools $\rightarrow$ Commands $\rightarrow$ DVI->PS} \\
\end{flushleft}

\begin{flushleft}
In Kile: \\
\end{flushleft}

\begin{flushleft}
\texttt{Build $\rightarrow$ Convert $\rightarrow$ DVItoPS} \\
\end{flushleft}


LaTeX saves the resulting files to the project directory. \texttt{dvi} files can be viewed with \textsc{dviout}, which comes with TeX Live. Click on the \texttt{dvi} file to activate it. Postscript files can be viewed with GSView.

\subsection{PDF Format}

\texttt{.dvi} and postscript files can be converted to \textsc{pdf} format if required using the \texttt{DVI->PDF} or \texttt{PS->PDF} options in TeXstudio or the \texttt{DVItoPDF} or \texttt{PStoPDF} options in Kile. \texttt{pdf} files created this way will not contain any hyperlinks and there will be no metadata attached to the file. \textsc{pdf}LaTeX supports these features so is the recommended way to produce \textsc{pdf} files. 

Hypertext links can be inserted into \textsc{pdf} documents with the \texttt{hyperref} package. This automatically turns all internal references, such as the table of contents and lists of tables and figures, cross references, and citations into active hyperlinks. Clicking on the link will take you to the appropriate place in the text. This should be the last package loaded in the preamble.

By default, text with hyperlinks appear framed in a colour depending on the type of link: citations in green, \textsc{url}'s in magenta and links in red, etc. This can be changed to coloured text by adding \texttt{colorlinks=true} to the options. As with the default colours, this has different colours for each type of link. The \texttt{allcolors} option changes all links to a single colour. This colour can be any from the \texttt{xcolor} option nominated when \texttt{xcolor} was loaded in the preamble. The following code loads \texttt{hyperref} with hyperlinks being flagged with text coloured blue:


{\small
\begin{verbatim}
\usepackage[pdftex, colorlinks=true, allcolours=blue]{hyperref}
\end{verbatim}
}


It is worth specifying a backend driver for this package. This helps configure \texttt{hyperref} to the compiler used for the document. In the case of \textsc{pdf} files, it is \textsc{pdf}LaTeX with the \texttt{pdftex} driver. 

Links to external web pages can be created in the text with \texttt{\textbackslash url\{WebAddress\}}. The following code will create a link to \textsc{ctan}'s homepage at \texttt{www.ctan.org}:

\begin{verbatim}
\url{www.ctan.org}
\end{verbatim}

\begin{flushleft}
It appears as 
\end{flushleft}


\begin{flushleft}
\url{www.ctan.org}
\end{flushleft}


The file metadata can be included with \texttt{\textbackslash hypersetup\{pdfinfo=\{ . . .\}\}}. This contains information regarding the title, author, subject, creation date, modification date and keywords. It can be seen by accessing the document's properties. The following code provides title, author, subject and keywords. 


{\small
\begin{verbatim}
\hypersetup{pdfinfo={
Title={The Lost Secrets of LaTeX2e},
Author={Albertus Magnus},
Subject={LaTeX2e},
Keywords={PDF; Latex2e; Guide}
}}
\end{verbatim}
}


As with postscript documents, \textsc{pdf}LaTeX will have to be run multiple times to resolve the front and back matter, tables, hyperlinks, etc.



\clearpage

\section{References}

\begin{flushleft}
Berry, K (2021) \LaTeXe: An Unofficial Reference Manual. Retrieved from: \\
\texttt{\url{www.latexref.xyz/dev/latex2e.pdf}} \\
\bigskip
Carlisle, D.P. (2021). Packages in the `graphics’ bundle. Retrieved from: \\ \texttt{\url{www.ctan.org/pkg/graphicx}} \\
\bigskip
Clawson, J. (2021). biblatex-mla MLA Style Using Biblatex, Version 2.0. Retrieved from: \\ \texttt{\url{www.ctan.org/pkg/biblatex-mla}} \\
\bigskip
Fussner, D. (2021). The biblatex-chicago package: Style files for biblatex, Version 2.2. Retrieved from: \\ \texttt{\url{www.ctan.org/pkg/biblatex-chicago}} \\
\bigskip
Goosens, M., Mittelbach, F., Rahtz, S., Roegel, D. and Voss, H. (2008) \textit{The LaTeX Graphics Companion}. 2nd Edition. Boston: Addison-Wesley. \\
\bigskip
Kern, U. (2021).Extending LATEX’s color facilities: the xcolor package v2.13. Retrieved from: \\ \texttt{\url{www.ctan.org/pkg/xcolor}} \\
\bigskip
Kime, P. (2021). APA BibLaTeX Style. Citation and References macros for BibLaTeX, Version 9.15. Retrieved from: \\ \texttt{\url{www.ctan.org/pkg/biblatex-apa}} \\
\bigskip
Kime, P., Wemheuer, M., Lehman, P. (2020) The biblatex Package. Programmable Bibliographies and Citations. Retrieved from: \\
\texttt{\url{www.ctan.org/pkg/biblatex}} \\
\bigskip
Lamport, L. (1986) \textit{LaTeX: A Document Preparation System}. 2nd Edition. Boston: Addison-Wesley.\\
\bigskip
Mittelbach, F., Fairbairns, R., Lemberg, W. and the LaTeX Project Team (2016). LaTeX font encodings. Retrieved from:  \\
\texttt{\url{www.ctan.org/pkg/encguide}} \\
\bigskip
Mittelbach, F. and Goosens, M. (2004). \textit{The LaTeX Companion}. 2nd Edition. Boston: Addison-Wesley.\\
\bigskip
Mori, L.F. (2007). Tables in LaTeX2e: Packages and Methods. \textit{The PracTeX Journal}, 1, 1-38.\\
\bigskip
Pakin, S., (2021). \textit{The Comprehensive LaTeX Symbol List}. Retrieved from: \\ \texttt{\url{www.ctan.org/pkg/comprehensive}}\\
\bigskip
Th\'{a}nh, H.T., Rahtz, S., Hagen, H., Henkel, H., Schroder, M. and Berry, K. (2021) \textit{The pdfTeX User Manual}. Revision 849. Retrieved from: \\ 
\texttt{\url{www.ctan.org/pkg/pdftex}} \\
\bigskip
International Committee of Medical Journal Editors (2021). Recommendations for the Conduct, Reporting, Editing, and Publication of Scholarly Work in Medical Journals. Retrieved from: \\ \texttt{\url{http://icmje.org/icmje-recommendations.pdf}} \\

 
\end{flushleft}


\clearpage


\begin{appendices}

\section{Some Additional \LaTeXe Facilities}

LaTeX has a much wider range of functionality than described in this document. Some add-on packages enhance existing facilities and others support music, presentations, and line drawings. Some of these are described in this Appendix.


\paragraph{Languages}
LaTeX has facilities for a wide range of modern languages and supports non-latin alphabets, such as Cyrrilic, and Logosyllabary, Syllabary, Abjad and Abugida writing systems. It also supports a range of extinct languages such as Phonecian, Egyptian Hieroglyphics, Linear B and Runic and provides symbols for the phonetic alphabet.


\paragraph{Line Drawings: PSTricks} 
PSTricks creates line drawings. It can draw mathematical functions, diagrams, and pictures. It creates postscript output, but it is possible to create \textsc{pdf} output with the \texttt{pdftricks} package.


\paragraph{Mathematics: AMS-LaTeX}
AMS Maths is a production of the American Mathematical Society. It provides a range of enhanced mathematical facilities including for LaTeX's standard document classes.


\paragraph{Music}
A range of LaTeX packages support music. It can produce sheet music and sections of scores can be inserted into texts with \texttt{musixtex}. Songbooks can be created with the \texttt{songs} or \texttt{songbook} packages, \texttt{guitar}, \texttt{guitarchordschemes} and \texttt{guitartabs} support the guitar, \texttt{bagpipe} supports bagpipe music and gregorian chant is possible with \texttt{gregoriotex}.


\paragraph{Presentations: Beamer}
Beamer produces presentations. It is a document class that is loaded in the preamble. It is compatible with \textsc{pdf}LaTeX and can create slides and handouts in \textsc{pdf} and supports overlays and hyperlinks.



\clearpage



\section{Resources}

There are many resources for LaTeX. A short list of helpful texts along with documentation for the packages used in this document are in the reference list. In addition to this, there are significant online resources that are regularly updated.


\paragraph{The Comprehensive \TeX Archive Network}
This is the home of \LaTeXe\ and contains distributions, additional packages, and documentation. The `Starting out with \TeX, \LaTeX, and friends' page is a good place to start.

\begin{flushleft}
\texttt{\url{www.ctan.org/starter}}
\end{flushleft} 


\paragraph{The TeX Users Group}
The \TeX Users Group (\textsc{tug}) is a not-for-profit group interested in \TeX. Their website has an informative page for those new to LaTeX: `Getting started with TeX, LaTeX, and friends'. This contains information on installing TeX and LaTeX, links to documentation and sample documents. 


\begin{flushleft}
\texttt{\url{http://tug.org/begin.html}}
\end{flushleft}

\textsc{tug} also hosts the `\LaTeX Font Catalogue'. This is a comprehensive list and sampler of freely available fonts for latin alphabets and documentation on how to use them.

\begin{flushleft}
\texttt{\url{http://tug.org/FontCatalogue/ }}
\end{flushleft}


\paragraph{The \TeX faq }
The \TeX faq addresses questions about \TeX with informative answers on a wide variety of topics.

\begin{flushleft}
\texttt{\url{http://texfaq.org}}
\end{flushleft}


\clearpage


\section{A Sample Script for a Postscript Document}

{\small
\begin{verbatim}
% Document Type, text point size and paper size
\documentclass[12pt, a4paper]{article}

% Line Spacing
\usepackage{setspace} 

% Graphic management with the dvips backend
\usepackage[dvips]{graphicx}

% Colour support with  the dvipsnames colour palette
\usepackage[dvipsnames]{xcolor} 

% Hyphenation for French, German and Australian English
\usepackage[french, ngerman, australian]{babel}
\usepackage{hyphenat}
% A list of words that LaTeX didn't hyphenate properly
\hyphenation{}

% Date formatting in Australian format
\usepackage[useregional, showdow]{datetime2}

% Font and encoding. This loads T1 and TS1 encodings, the Latin Modern 
% font and a ragged right edge for the text block
\usepackage[TS1, T1]{fontenc}
\usepackage[document]{ragged2e}
\usepackage{lmodern}

% Page margins in inches with the geometry package
\usepackage[left=1.5in, right=1.0in, top=1.0in, bottom=1.75in, 
headheight=18pt]{geometry}

% Headers and footers with a running header, page numbering and a 
% left footer containing the date.
\usepackage{fancyhdr}
\pagestyle{fancy}
\lhead{Running Header or Title.}
\chead{}
\rhead{\thepage}
\lfoot{\today}
\cfoot{}
\rfoot{}
\renewcommand{\headrulewidth}{0.5pt}
\renewcommand{\footrulewidth}{0.5pt}

% The document title
\title{The Lost Secrets of \LaTeXe}
% The author(s)
\author{Albertus Magnus}

% Insert today's date	
\date{\today}


% The end of the preamble and the beginning of the document
\begin{document}
	
% Create the title and abstract on the front page with no headers, 
% footers or page numbers.
\maketitle
\thispagestyle{empty}
	
% Insert an abstract
\begin{abstract}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit, 
vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum 
gravida mauris. Nam arcu libero, nonummy eget, consectetuer id, vulputate 
a, magna. Donec vehicula augue eu neque. Pellentesque habitant morbi 
tristique senectus et netus et malesuada fames ac turpis egestas.
\end{abstract}
	
% Create a new page for the Table of Contents and begin numbering the 
% pages in lower case Roman numerals for the front matter.
\clearpage
\pagenumbering{roman}
\tableofcontents
	
% Create a new page for the List of Figures
\clearpage
\listoffigures
	
% Create a new page for the List of Tables
\clearpage
\listoftables
	
% Create a new page to begin the text of the document and begin 
% numbering thepages in Arabic numerals.
\clearpage
\pagenumbering{arabic}
	
% Define line spacing
\doublespacing
	
	
% Document text with sections, a hot link at the end of the first 
% section, a numbered list and a table.
	
\section{Integer sapien est}
	
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit, 
vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum 
gravida mauris. Nam arcu libero, nonummy eget, consectetuer id, 
vulputate a, magna. Donec vehicula augue eu neque. Pellentesque habitant 
morbi tristique senectus et netus et malesuada fames ac turpis egestas. 
Mauris ut leo. Cras viverra metus rhoncus sem. Nulla et lectus 
vestibulum urna fringilla ultrices. Phasellus eu tellus sit amet tortor 
gravida placerat. Integer sapien est, iaculis in, pretium quis, viverra 
ac, nunc. Praesent eget sem vel leo ultrices bibendum. Aenean faucibus. 
Morbi dolor nulla, malesuada eu, pulvinar at, mollis ac, nulla. Curabitur 
auctor semper nulla. Donec varius orci eget risus. Duis nibh mi, congue 
eu, accumsan eleifend, sagittis quis, diam. Duis eget orci sit amet orci 
dignissim rutrum.	
	
% Insert a numbered list
	
\begin{enumerate}
\item Mauris ut est
\item Ut quis purus
\item Sed ac odio
\item Sed vehicula hendrerit sem
\item Duis non odio
\end{enumerate}
	
\subsection{Phasellus adipiscing semper elit}	
	
Nam dui ligula, fringilla a, euismod sodales, sollicitudin vel, wisi. 
Morbi auctor lorem non justo. Nam lacus libero, pretium at, lobortis 
vitae, ultricies et, tellus. Donec aliquet, tortor sed accumsan 
bibendum, erat ligula aliquet magna, vitae ornare odio metus a mi. 
Morbi ac orci et nisl hendrerit mollis. Suspendisse ut massa. Cras nec 
ante. Pellentesque a nulla. Cum sociis natoque penatibus et magnis dis  
parturient montes, nascetur ridiculus mus. Aliquam tincidunt urna. 
Nulla ullamcorper vestibulum turpis. Pellentesque cursus luctus mauris. 
Nulla malesuada porttitor diam. Donec felis erat, congue non, volutpat 
at, tincidunt tristique, libero. Vivamus viverra fermentum felis. Donec 
nonummy pellentesque ante. Phasellus adipiscing semper elit. Proin 
fermentum massa ac quam. Sed diam turpis, molestie vitae, placerat a, 
molestie nec, leo. Maecenas lacinia. Nam ipsum ligula, eleifend at, 
accumsan nec, suscipit a, ipsum. Morbi blandit ligula feugiat magna. 
Nunc eleifend consequat lorem. Sed lacinia nulla vitae enim. 
Pellentesque tincidunt purus vel magna. Integer non enim. Praesent 
euismod nunc eu purus. Donec bibendum quam in tellus. Nullam cursus 
pulvinar lectus. Donec et mi. Nam vulputate metus eu enim. Vestibulum 
pellentesque felis eu massa.
	
Quisque ullamcorper placerat ipsum. Cras nibh. Morbi vel justo vitae 
lacus tincidunt ultrices. Lorem ipsum dolor sit amet, consectetuer 
adipiscing elit. In hac habitasse platea dictumst. Integer tempus 
convallis augue. Etiam facilisis. Nunc elementum fermentum wisi. 
Aenean placerat. Ut imperdiet, enim sed gravida sollicitudin, felis 
odio placerat quam, ac pulvinar elit purus eget enim. Nunc vitae 
tortor. Proin tempus nibh sit amet nisl. Vivamus quis tortor vitae
risus porta vehicula.
	
% Insert a table
\begin{table}[h]
\begin{center}
\begin{tabular}{cll}
\toprule[1.0pt]
1	& Fusce mauris & Vestibulum luctus nibh at lectus \\
2	& Vestibulum diam & Aliquam pellentesque, augue quis sagittis \\
3	& Vestibulum porttitor & Nulla facilisi \\
4	& Morbi fringilla, wisi & In dignissim interdum, justo lectus \\
5	& Cras ac magna & Cras nulla \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Caption text} 
\end{center} 
\end{table}
	
% End of the text and the document.
	
\end{document}	
\end{verbatim}
}


\clearpage



\section{A Sample Script for a \textsc{pdf} Document}

{\small
\begin{verbatim}
% Document Type
\documentclass[12pt, a4paper]{article}

% Line Spacing
\usepackage{setspace} 

% Graphic management with the pdftex backend
\usepackage[pdftex]{graphicx}

% Colour support with  the dvipsnames colour palette
\usepackage[dvipsnames]{xcolor} 

% Hyphenation for French, German and Australian English
\usepackage[french, ngerman, australian]{babel}
\usepackage{hyphenat}
\hyphenation{}

% Date formatting in Australian format
\usepackage[useregional, showdow]{datetime2}

% Font and encoding. This loads T1 and TS1 encodings, the Latin Modern
% font and a ragged right edge for the text block
\usepackage[TS1, T1]{fontenc}
\usepackage[document]{ragged2e}
\usepackage{lmodern}

% Page margins with the geometry package
\usepackage[left=1.5in, right=1.0in, top=1.0in, bottom=1.75in, 
headheight=18pt]{geometry}

% Headers and footers with a running header, page numbering and a 
% left footer containing the date.
\usepackage{fancyhdr}
\pagestyle{fancy}
\lhead{Running Header or Title.}
\chead{}
\rhead{\thepage}
\lfoot{\today}
\cfoot{}
\rfoot{}
\renewcommand{\headrulewidth}{0.5pt}
\renewcommand{\footrulewidth}{0.5pt}

% The document title
\title{The Lost Secrets of \LaTeXe}
% The author(s)
\author{Albertus Magnus}

% Insert today's date	
\date{\today}

% Load hyperref to allow hotlinks in the document. These options load
% the pdf backend and set all links to the colour blue	
\usepackage[pdftex, colorlinks=true, allcolors=Blue]{hyperref}

% Metadata for the PDF file: Title, Author, Subject and Keywords

\hypersetup{pdfinfo={
Title={The Lost Secrets of LaTeXe},
Author={Albertus Magnus},
Subject={LaTeX2e},
Keywords={Latex2e; Guide}
}}


% The end of the preamble and the beginning of the document
\begin{document}
	
% Create the title and abstract on the front page with no headers, 
% footers or page numbers.
\maketitle
\thispagestyle{empty}
	
% Insert an abstract
\begin{abstract}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit, 
vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum 
gravida mauris. Nam arcu libero, nonummy eget, consectetuer id, vulputate 
a, magna. Donec vehicula augue eu neque. Pellentesque habitant morbi 
tristique senectus et netus et malesuada fames ac turpis egestas.	
\end{abstract}
	
% Create a new page for the Table of Contents and begin numbering the 
% pages in lower case Roman numerals for the front matter.
\clearpage
\pagenumbering{roman}
\tableofcontents
	
% Create a new page for the List of Figures
\clearpage
\listoffigures
	
% Create a new page for the List of Tables
\clearpage
\listoftables
	
% Create a new page to begin the text of the document and begin numbering 
% thepages in Arabic numerals.
\clearpage
\pagenumbering{arabic}
	
% Define line spacing
\doublespacing
	
	
% Document text with sections, a numbered list, a table and a hot link
% at the end of the first section.
	
\section{Integer sapien est}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit, 
vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum 
gravida mauris. Nam arcu libero, nonummy eget, consectetuer id, 
vulputate a, magna. Donec vehicula augue eu neque. Pellentesque habitant 
morbi tristique senectus et netus et malesuada fames ac turpis egestas. 
Mauris ut leo. Cras viverra metus rhoncus sem. Nulla et lectus 
vestibulum urna fringilla ultrices. Phasellus eu tellus sit amet tortor 
gravida placerat. Integer sapien est, iaculis in, pretium quis, viverra 
ac, nunc. Praesent eget sem vel leo ultrices bibendum. Aenean faucibus. 
Morbi dolor nulla, malesuada eu, pulvinar at, mollis ac, nulla. Curabitur 
auctor semper nulla. Donec varius orci eget risus. Duis nibh mi, congue 
eu, accumsan eleifend, sagittis quis, diam. Duis eget orci sit amet orci 
dignissim rutrum. \url{www.ctan.org}	


% Insert a numbered list
	
\begin{enumerate}
\item Mauris ut est
\item Ut quis purus
\item Sed ac odio
\item Sed vehicula hendrerit sem
\item Duis non odio
\end{enumerate}
	
\subsection{Phasellus adipiscing semper elit}	
Nam dui ligula, fringilla a, euismod sodales, sollicitudin vel, wisi. 
Morbi auctor lorem non justo. Nam lacus libero, pretium at, lobortis 
vitae, ultricies et, tellus. Donec aliquet, tortor sed accumsan 
bibendum, erat ligula aliquet magna, vitae ornare odio metus a mi. 
Morbi ac orci et nisl hendrerit mollis. Suspendisse ut massa. Cras nec 
ante. Pellentesque a nulla. Cum sociis natoque penatibus et magnis dis  
parturient montes, nascetur ridiculus mus. Aliquam tincidunt urna. 
Nulla ullamcorper vestibulum turpis. Pellentesque cursus luctus mauris. 
Nulla malesuada porttitor diam. Donec felis erat, congue non, volutpat 
at, tincidunt tristique, libero. Vivamus viverra fermentum felis. Donec 
nonummy pellentesque ante. Phasellus adipiscing semper elit. Proin 
fermentum massa ac quam. Sed diam turpis, molestie vitae, placerat a, 
molestie nec, leo. Maecenas lacinia. Nam ipsum ligula, eleifend at, 
accumsan nec, suscipit a, ipsum. Morbi blandit ligula feugiat magna. 
Nunc eleifend consequat lorem. Sed lacinia nulla vitae enim. 
Pellentesque tincidunt purus vel magna. Integer non enim. Praesent 
euismod nunc eu purus. Donec bibendum quam in tellus. Nullam cursus 
pulvinar lectus. Donec et mi. Nam vulputate metus eu enim. Vestibulum 
pellentesque felis eu massa.

Quisque ullamcorper placerat ipsum. Cras nibh. Morbi vel justo vitae 
lacus tincidunt ultrices. Lorem ipsum dolor sit amet, consectetuer 
adipiscing elit. In hac habitasse platea dictumst. Integer tempus 
convallis augue. Etiam facilisis. Nunc elementum fermentum wisi. 
Aenean placerat. Ut imperdiet, enim sed gravida sollicitudin, felis 
odio placerat quam, ac pulvinar elit purus eget enim. Nunc vitae 
tortor. Proin tempus nibh sit amet nisl. Vivamus quis tortor vitae
risus porta vehicula.

	
% Insert a table
\begin{table}[h]
\begin{center}
\begin{tabular}{cll}
\toprule[1.0pt]
1	& Fusce mauris & Vestibulum luctus nibh at lectus \\
2	& Vestibulum diam & Aliquam pellentesque, augue quis sagittis \\
3	& Vestibulum porttitor & Nulla facilisi \\
4	& Morbi fringilla, wisi & In dignissim interdum, justo lectus \\
5	& Cras ac magna & Cras nulla \\
\bottomrule[1.0pt]
\end{tabular}
\caption{Caption text} 
\end{center} 
\end{table}
	
% End of the text and the document.
	
\end{document}	


\end{verbatim}
}


\clearpage



\section{GNU Free Documentation License}

{\footnotesize
\begin{center}
		
Version 1.2, November 2002
		
		
Copyright \copyright 2000,2001,2002  Free Software Foundation, Inc.
		
\bigskip
		
51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
		
\bigskip
		
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
\end{center}
	
	
\begin{center}
Preamble
\end{center}
	
The purpose of this License is to make a manual, textbook, or other	functional and useful document "free" in the sense of freedom: to 	assure everyone the effective freedom to copy and redistribute it,	with or without modifying it, either commercially or noncommercially. 

Secondarily, this License preserves for the author and publisher a way to get credit for their work, while not being considered responsible for modifications made by others.
	
This License is a kind of "copyleft", which means that derivative works of the document must themselves be free in the same sense.  It complements the GNU General Public License, which is a copyleft license designed for free software.
	
We have designed this License in order to use it for manuals for free software, because free software needs free documentation: a free program should come with manuals providing the same freedoms that the	software does.  But this License is not limited to software manuals; it can be used for any textual work, regardless of subject matter or whether it is published as a printed book.  We recommend this License principally for works whose purpose is instruction or reference.
	
	
\begin{center}
1. APPLICABILITY AND DEFINITIONS
\end{center}
	
This License applies to any manual or other work, in any medium, that contains a notice placed by the copyright holder saying it can be distributed under the terms of this License.  Such a notice grants a world-wide, royalty-free license, unlimited in duration, to use that work under the conditions stated herein.  The \textbf{"Document"}, below, refers to any such manual or work.  Any member of the public is a licensee, and is addressed as \textbf{"you"}.  You accept the license if you copy, modify or distribute the work in a way requiring permission under copyright law.
	
A \textbf{"Modified Version"} of the Document means any work containing the Document or a portion of it, either copied verbatim, or with	modifications and/or translated into another language.
	
A \textbf{"Secondary Section"} is a named appendix or a front-matter section of	the Document that deals exclusively with the relationship of the publishers or authors of the Document to the Document's overall subject	(or to related matters) and contains nothing that could fall directly within that overall subject.  (Thus, if the Document is in part a textbook of mathematics, a Secondary Section may not explain any	mathematics.)  The relationship could be a matter of historical	connection with the subject or with related matters, or of legal, commercial, philosophical, ethical or political position regarding them.
	
The \textbf{"Invariant Sections"} are certain Secondary Sections whose titles are designated, as being those of Invariant Sections, in the notice that says that the Document is released under this License.  If a section does not fit the above definition of Secondary then it is not allowed to be designated as Invariant.  The Document may contain zero	Invariant Sections.  If the Document does not identify any Invariant	Sections then there are none.
	
The \textbf{"Cover Texts"} are certain short passages of text that are listed, as Front-Cover Texts or Back-Cover Texts, in the notice that says that the Document is released under this License.  A Front-Cover Text may be at most 5 words, and a Back-Cover Text may be at most 25 words.
	
A \textbf{"Transparent"} copy of the Document means a machine-readable copy, represented in a format whose specification is available to the	general public, that is suitable for revising the document straightforwardly with generic text editors or (for images composed of pixels) generic paint programs or (for drawings) some widely available	drawing editor, and that is suitable for input to text formatters or for automatic translation to a variety of formats suitable for input to text formatters.  A copy made in an otherwise Transparent file format whose markup, or absence of markup, has been arranged to thwart	or discourage subsequent modification by readers is not Transparent. An image format is not Transparent if used for any substantial amount of text.  A copy that is not "Transparent" is called \textbf{"Opaque"}.
	
Examples of suitable formats for Transparent copies include plain ASCII without markup, Texinfo input format, LaTeX input format, SGML or XML using a publicly available DTD, and standard-conforming simple HTML, PostScript or PDF designed for human modification. Examples of transparent image formats include PNG, XCF and JPG.  Opaque formats include proprietary formats that can be read and edited only by proprietary word processors, SGML or XML for which the DTD and/or processing tools are not generally available, and the machine-generated HTML, PostScript or PDF produced by some word processors for output purposes only.
	
The \textbf{"Title Page"} means, for a printed book, the title page itself,	plus such following pages as are needed to hold, legibly, the material this License requires to appear in the title page.  For works in formats which do not have any title page as such, "Title Page" means the text near the most prominent appearance of the work's title, preceding the beginning of the body of the text.
	
A section \textbf{"Entitled XYZ"} means a named subunit of the Document whose title either is precisely XYZ or contains XYZ in parentheses following text that translates XYZ in another language.  (Here XYZ stands for a specific section name mentioned below, such as \textbf{"Acknowledgements"},	\textbf{"Dedications"}, \textbf{"Endorsements"}, or \textbf{"History"}.) To \textbf{"Preserve the Title"}	of such a section when you modify the Document means that it remains a section "Entitled XYZ" according to this definition.
	
The Document may include Warranty Disclaimers next to the notice which states that this License applies to the Document.  These Warranty Disclaimers are considered to be included by reference in this License, but only as regards disclaiming warranties: any other	implication that these Warranty Disclaimers may have is void and has no effect on the meaning of this License.
	
	
\begin{center}
2. VERBATIM COPYING
\end{center}
	
You may copy and distribute the Document in any medium, either commercially or noncommercially, provided that this License, the	copyright notices, and the license notice saying this License applies	to the Document are reproduced in all copies, and that you add no other	conditions whatsoever to those of this License.  You may not use technical measures to obstruct or control the reading or further copying of the copies you make or distribute.  However, you may accept compensation in exchange for copies.  If you distribute a large enough number of copies you must also follow the conditions in section 3.
	
You may also lend copies, under the same conditions stated above, and you may publicly display copies.
	
	
\begin{center}
3. COPYING IN QUANTITY
\end{center}
	
	
If you publish printed copies (or copies in media that commonly have printed covers) of the Document, numbering more than 100, and the Document's license notice requires Cover Texts, you must enclose the copies in covers that carry, clearly and legibly, all these Cover Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on the back cover.  Both covers must also clearly and legibly identify you as the publisher of these copies.  The front cover must present the full title with all words of the title equally prominent and visible.  You may add other material on the covers in addition. Copying with changes limited to the covers, as long as they preserve the title of the Document and satisfy these conditions, can be treated as verbatim copying in other respects.
	
If the required texts for either cover are too voluminous to fit legibly, you should put the first ones listed (as many as fit	reasonably) on the actual cover, and continue the rest onto adjacent pages.
	
If you publish or distribute Opaque copies of the Document numbering more than 100, you must either include a machine-readable Transparent copy along with each Opaque copy, or state in or with each Opaque copy	a computer-network location from which the general network-using public has access to download using public-standard network protocols a complete Transparent copy of the Document, free of added material.	If you use the latter option, you must take reasonably prudent steps, when you begin distribution of Opaque copies in quantity, to ensure that this Transparent copy will remain thus accessible at the stated location until at least one year after the last time you distribute an Opaque copy (directly or through your agents or retailers) of that	edition to the public.
	
It is requested, but not required, that you contact the authors of the	Document well before redistributing any large number of copies, to give them a chance to provide you with an updated version of the Document.
	
	
\begin{center}
4. MODIFICATIONS
\end{center}
	
You may copy and distribute a Modified Version of the Document under the conditions of sections 2 and 3 above, provided that you release	the Modified Version under precisely this License, with the Modified Version filling the role of the Document, thus licensing distribution and modification of the Modified Version to whoever possesses a copy of it.  In addition, you must do these things in the Modified Version:
	
\begin{itemize}
\item[A.] 
Use in the Title Page (and on the covers, if any) a title distinct from that of the Document, and from those of previous versions (which should, if there were any, be listed in the History section of the Document).  You may use the same title as a previous version if the original publisher of that version gives permission.
		
\item[B.]
List on the Title Page, as authors, one or more persons or entities	responsible for authorship of the modifications in the Modified Version, together with at least five of the principal authors of the Document (all of its principal authors, if it has fewer than five), unless they release you from this requirement.
		
\item[C.]
State on the Title page the name of the publisher of the Modified Version, as the publisher.
		
\item[D.]
Preserve all the copyright notices of the Document.
		
\item[E.]
Add an appropriate copyright notice for your modifications adjacent to the other copyright notices.
		
\item[F.]
Include, immediately after the copyright notices, a license notice giving the public permission to use the Modified Version under the terms of this License, in the form shown in the Addendum below.
		
\item[G.]
Preserve in that license notice the full lists of Invariant Sections and required Cover Texts given in the Document's license notice.
		
\item[H.]
Include an unaltered copy of this License.
		
\item[I.]
Preserve the section Entitled "History", Preserve its Title, and add to it an item stating at least the title, year, new authors, and publisher of the Modified Version as given on the Title Page.  If there is no section Entitled "History" in the Document, create one stating the title, year, authors, and publisher of the Document as given on its Title Page, then add an item describing the Modified Version as stated in the previous sentence.
		
\item[J.]
Preserve the network location, if any, given in the Document for public access to a Transparent copy of the Document, and likewise the network locations given in the Document for previous versions it was based on.  These may be placed in the "History" section. You may omit a network location for a work that was published at least four years before the Document itself, or if the original publisher of the version it refers to gives permission.
		
\item[K.]
For any section Entitled "Acknowledgements" or "Dedications", Preserve the Title of the section, and preserve in the section all	the substance and tone of each of the contributor acknowledgements and/or dedications given therein.
		
\item[L.]
Preserve all the Invariant Sections of the Document, unaltered in their text and in their titles.  Section numbers	or the equivalent are not considered part of the section titles.
		
\item[M.]
Delete any section Entitled "Endorsements".  Such a section	may not be included in the Modified Version.
		
\item[N.]
Do not retitle any existing section to be Entitled "Endorsements" or to conflict in title with any Invariant Section.
		
\item[O.]
Preserve any Warranty Disclaimers.
\end{itemize}
	
If the Modified Version includes new front-matter sections or appendices that qualify as Secondary Sections and contain no material copied from the Document, you may at your option designate some or all	of these sections as invariant.  To do this, add their titles to the list of Invariant Sections in the Modified Version's license notice.  These titles must be distinct from any other section titles.
	
You may add a section Entitled "Endorsements", provided it contains	nothing but endorsements of your Modified Version by various	parties--for example, statements of peer review or that the text has	been approved by an organization as the authoritative definition of a standard.
	
You may add a passage of up to five words as a Front-Cover Text, and a passage of up to 25 words as a Back-Cover Text, to the end of the list	of Cover Texts in the Modified Version.  Only one passage of Front-Cover Text and one of Back-Cover Text may be added by (or	through arrangements made by) any one entity.  If the Document already includes a cover text for the same cover, previously added by you or by arrangement made by the same entity you are acting on behalf of,	you may not add another; but you may replace the old one, on explicit permission from the previous publisher that added the old one.
	
The author(s) and publisher(s) of the Document do not by this License give permission to use their names for publicity for or to assert or	imply endorsement of any Modified Version.
	
	
\begin{center}
5. COMBINING DOCUMENTS
\end{center}
	
	
You may combine the Document with other documents released under this License, under the terms defined in section 4 above for modified	versions, provided that you include in the combination all of the Invariant Sections of all of the original documents, unmodified, and list them all as Invariant Sections of your combined work in its license notice, and that you preserve all their Warranty Disclaimers.
	
The combined work need only contain one copy of this License, and multiple identical Invariant Sections may be replaced with a single copy.  If there are multiple Invariant Sections with the same name but different contents, make the title of each such section unique by	adding at the end of it, in parentheses, the name of the original author or publisher of that section if known, or else a unique number. Make the same adjustment to the section titles in the list of Invariant Sections in the license notice of the combined work.
	
In the combination, you must combine any sections Entitled "History" in the various original documents, forming one section Entitled	"History"; likewise combine any sections Entitled "Acknowledgements",	and any sections Entitled "Dedications".  You must delete all sections Entitled "Endorsements".
	
\begin{center}
6. COLLECTIONS OF DOCUMENTS
\end{center}
	
You may make a collection consisting of the Document and other documents released under this License, and replace the individual copies of this License in the various documents with a single copy that is included in	the collection, provided that you follow the rules of this License for	verbatim copying of each of the documents in all other respects.
	
You may extract a single document from such a collection, and distribute it individually under this License, provided you insert a copy of this	License into the extracted document, and follow this License in all other respects regarding verbatim copying of that document.
	
	
\begin{center}
7. AGGREGATION WITH INDEPENDENT WORKS
\end{center}
	
	
A compilation of the Document or its derivatives with other separate and independent documents or works, in or on a volume of a storage or distribution medium, is called an "aggregate" if the copyright resulting from the compilation is not used to limit the legal rights of the compilation's users beyond what the individual works permit. When the Document is included in an aggregate, this License does not apply to the other works in the aggregate which are not themselves	derivative works of the Document.
	
If the Cover Text requirement of section 3 is applicable to these copies of the Document, then if the Document is less than one half of the entire aggregate, the Document's Cover Texts may be placed on covers that bracket the Document within the aggregate, or the electronic equivalent of covers if the Document is in electronic form.	Otherwise they must appear on printed covers that bracket the whole aggregate.
	
	
\begin{center}
8. TRANSLATION
\end{center}
	
	
Translation is considered a kind of modification, so you may distribute translations of the Document under the terms of section 4. Replacing Invariant Sections with translations requires special permission from their copyright holders, but you may include translations of some or all Invariant Sections in addition to the original versions of these Invariant Sections.  You may include a translation of this License, and all the license notices in the Document, and any Warranty Disclaimers, provided that you also include	the original English version of this License and the original versions of those notices and disclaimers.  In case of a disagreement between the translation and the original version of this License or a notice or disclaimer, the original version will prevail.
	
If a section in the Document is Entitled "Acknowledgements", "Dedications", or "History", the requirement (section 4) to Preserve	its Title (section 1) will typically require changing the actual title.
	
	
\begin{center}
9. TERMINATION
\end{center}
	
	
You may not copy, modify, sublicense, or distribute the Document except	as expressly provided for under this License.  Any other attempt to copy, modify, sublicense or distribute the Document is void, and will automatically terminate your rights under this License.  However,	parties who have received copies, or rights, from you under this	License will not have their licenses terminated so long as such parties remain in full compliance.
	
	
\begin{center}
10. FUTURE REVISIONS OF THIS LICENSE
\end{center}
	
	
The Free Software Foundation may publish new, revised versions of the GNU Free Documentation License from time to time.  Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.  See	http://www.gnu.org/copyleft/.
	
Each version of the License is given a distinguishing version number. If the Document specifies that a particular numbered version of this	License "or any later version" applies to it, you have the option of	following the terms and conditions either of that specified version or of any later version that has been published (not as a draft) by the Free Software Foundation.  If the Document does not specify a version number of this License, you may choose any version ever published (not as a draft) by the Free Software Foundation.
	
	
\begin{center}
ADDENDUM: How to use this License for your documents
\end{center}
	
To use this License in a document you have written, include a copy of the License in the document and put the following copyright and	license notices just after the title page:
	
\bigskip
\begin{quote}
Copyright \copyright  YEAR  YOUR NAME.\\
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".
\end{quote}
\bigskip
	
If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts,	replace the "with...Texts." line with this:
	
\bigskip
\begin{quote}
with the Invariant Sections being LIST THEIR TITLES, with the Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
\end{quote}
\bigskip
	
If you have Invariant Sections without Cover Texts, or some other combination of the three, merge those two alternatives to suit the situation.
	
If your document contains nontrivial examples of program code, we recommend releasing these examples in parallel under your choice of free software license, such as the GNU General Public License, to permit their use in free software.

}

\end{appendices}


\end{document}