Some Helpful TeX Hints

LaTeX is a complicated typesetting program. Here are some hints and links to other macros or programs to make writing a LaTeX document easier.

1. Running text

2. Math

Mathematical expressions that are part of the running text are delimited by a single dollar sign ($), e.g., $\pi r^2$ yields #r2. To get the appropriately sized superscript or subscript in the roman font, use the \rm command, e.g., $J_{\rm HF}(t)$ produces JHF(t).

Displayed equations can be delimited in several ways. See the User Guide for details on display equation markup.

While it is possible for authors to assign their own equation numbers, it is easier to let LaTeX number them automatically. By default, LaTeX will number equations sequentially from the beginning of the paper to the end.

3. Cross-referencing

Cross-referencing equations, tables, and figures in text depends upon the use of "keys," which are defined by the user. The \label command is used to define cross-reference keys for LaTeX; \ref is used to refer to them. Keys are simply text strings that serve to label equations, tables, and figures, so that they may be referred to symbolically in the text. For sections and the like, place \label commands immediately after the markup command that starts the structure being referenced. For figure and table captions, place the \label command \caption, \tablecaption, or \figcaption , e.g.,

\tablecaption{This is a caption.\label{tab1}}

Do not put references to page numbers in your paper.

LaTeX keeps track of autonumbered counters and cross-reference information by maintaining an auxiliary file in the same working directory as the source file. The auxiliary file will have an extension of .aux. This file should not be deleted, since subsequent LaTeX processing uses the auxiliary data to resolve references, etc.

The auxiliary file mechanism makes it necessary to run LaTeX on a given source file more than once to ensure that the cross-reference information has been properly resolved. When changes are made that affect the number or the placement of equations, tables, and the like. LaTeX will issue a warning message that advises the user to "rerun to get cross-references right," in which case, LaTeX should be run again.

4. Useful External Packages