[Univ of Cambridge] [Dept of Engineering]
next up previous contents
Next: Maths and Postscript fonts Up: Maths Previous: Packages

   
Fine tuning

It's generally a good idea to keep punctuation outside math mode; LATEX's normal handling of spacing around punctuation is suspended during maths. Sometimes you might want to adjust the spacing in a formula (e.g., you might want to add space before dx). Use these symbols :-

a\, b ($a\, b$) thin space
a\> b ($a\> b$) medium space
a\; b ($a\; b$) thick space
a\! b ($a\! b$) negative thin space

Long math expressions aren't broken automatically unless you use the breqn package, which is still a little experimental. In an eqnarray environment you may want to break a long line manually. You can do this by putting

y & = & a + b \nonumber \\
  &   & + k
to give
y = a + b  
    + k (4)

but the spacing around the `+' on the 2nd line is wrong because LATEX thinks it's a unary operator. You can fool LATEX into treating it as a binary operator by inserting a hidden character.
y & = & a + b \nonumber \\
  &   & \mbox{} + k
gives
y = a + b  
    $\displaystyle \mbox{} + k$ (5)

You can use the \lefteqn construction to format long expressions so that continuation lines are differently indented.

\begin{eqnarray}
\lefteqn{x+ iy=}\\
 & & a + b + c + d + e + f + g + h + i + j + k +\nonumber\\
 & & l + m \nonumber
\end{eqnarray}


x+ iy=
    a + b + c + d + e + f + g + h + i + j + k +  
    l + m  

If you want more vertical spacing around a line you can create an invisible vertical "struct" in LaTeX. \rule[-.3cm]{0cm}{1cm} creates a box of width 0, height 1cm which starts .3cm below the usual line base. By adjusting these values you should be able to create as much extra space below/above the maths as you like. $A \over B$ and is created by

$A \over B$  \rule[-.3cm]{0cm}{1cm}{and}


next up previous contents
Next: Maths and Postscript fonts Up: Maths Previous: Packages
Tim Love
1999-08-05