3. Typesetting Mathematics

Society for Industrial and Applied Mathematics eBooks · 1997

3.1 Examples The file example.tex on page 6 includes some simple mathematical typesetting. You will notice that mathematical symbols appear in an italic-like font; compare the correct form x, a, produced by $x$, $a$, with the regular roman type x, a. Single dollar signs enclose an in-line mathematical expression, whereas the delimiters \[ and \] are used for unnumbered, displayed equations. Some common mathematical symbols and the commands used to produce them are given in Table 3.1. A mathematical symbol may be negated by preceding it with the ot command. Thus, $ ot<, ot\subset, ot|$ produces ≮, ⊄, ∤. The commands e, giving ≠, and otin, giving ≠, are already provided. Mathematical functions such as “log” and “sin” are, by convention, typeset in standard roman type. This makes expressions easier to read; compare sin x, cosh y with sinx, coshy. The former used the correct $\sin x, \cosh y$ and the latter, $sin x, cosh y$. Table 3.2 shows the built-in functions available in LATEX. You may need another function, such as “diag”, which is not available. In this case you can use the \mathrm command to produce roman type in a mathematical expression. For example, $\mathrm{diag} (1,2,3, \ldots, 20)$ gives diag(l, 2, 3,…, 20). Math fonts are discussed further on pages 22 and 30. The ellipsis “…” in the previous expression was produced using \ldots. Notice that the dots are aligned with the base of the characters. Another form, “⋯”, is produced by \cdots, which may only be used in math mode. This is more appropriate for use with +, −, = as in . Examples of vertical and diagonal ellipses are given on page 26.

Read the paper · More papers on PaperTik