Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

On the wikipedia page: http://en.wikipedia.org/wiki/LaTeX, the first example is

\begin{align}
E &= mc^2                              \\
m &= \frac{m_0}{\sqrt{1-\frac{v^2}{c^2}}}
\end{align}

May I ask what does the &=do? Why is the ampersand needed?

share|improve this question
    
Welcome to TeX.sx! –  Papiro Jun 28 '13 at 11:22

2 Answers 2

up vote 19 down vote accepted

It means that the equations will be aligned at this point, just before the = sign. Placing the & before the = (or other operator) ensures correct spacing around the operator.

Here you have an example (ignore the actual mathemetics, I've just randomly added some numbers for displaying propuses)

\begin{align}
E*3*2*3 &= mc^2                              \\
m &= \frac{m_0}{\sqrt{1-\frac{v^2}{c^2}}}
\end{align}

enter image description here

and without the &:

\begin{align}
E*3*2*3 = mc^2                              \\
m = \frac{m_0}{\sqrt{1-\frac{v^2}{c^2}}}
\end{align}

enter image description here

share|improve this answer
1  
you might want to note that placing the & before the = (or other operator) ensures correct spacing around the operator. –  barbara beeton Jun 28 '13 at 14:35

They are not a combined symbol & is the alignment point in align just as it is in tabular It marks the division of the row into cells which are then stacked vertically. The second cell in each of those rows happens to start with = so Tex will typeset the rows with the = one directly above the other,

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.