LaTeX basics
Math mode
LaTeX has two primary modes of operation—text and math modes. Both are equally important when using LaTeX as a typesetting system; however, since the main purpose of Aurora is editing equations, the math mode is the one you will probably use most often. Thus, when you see Aurora initializing equations it creates to “$ $” or “\[ \]” and placing the caret in between, it does so to enter the math mode.
Spaces and line breaks are typically ignored by LaTeX and doubly so in math mode, because it can generally infer proper placement from the mathematical expression alone.
Inline versus display equations
LaTeX distinguishes formulas that are a part of a sentence, such as the following gratuitous display of Greek symbols
, from formulas that stand by themselves, such as the Schrödinger equation below:
|
|
The former are called inline equations, whereas the latter are display equations.
For Aurora, the most important differences between the two lie in the sizes of certain operators (fractions, sum, integrals, and so on) and the placement of limits in expressions. Simply put, LaTeX tries to fit inline equations into a single line of text, but lets display equations claim as much space as they need:
| “$ $” (inline) | $\lim_{x \to 0} \frac{\sin x}{x} = 1$ |
|
| “\[ \]” (display) | \[\lim_{x \to 0} \frac{\sin x}{x} = 1\] |
|
When creating a new equation using the “Insert equation” button on the Aurora toolbar or the “Insert Object…” command, Aurora initializes the formula in inline mode. To change the mode, simply change the dollar signs to \[ and \] or the other way around.
Commands
All the LaTeX commands—and that includes special symbols as
well—begin with the backslash symbol \.
For example, to insert the
sign into a formula, you might enter
\pm.
Many commands accept arguments, which go right after the command’s name.
For example, an argument to the command that places a line over an expression
(\overline) would be the expression to place that line over:
\overline{A} gives
.
Note that the curly braces in the example above are not strictly necessary, because the argument is only one character long. However, to make editing less error-prone, it is common to write braces even when they could be omitted.
Occasionally, a command may accept optional arguments—\sqrt,
for example. These are given in square brackets right after the command name:
\sqrt[3]{xy}
produces
.