# Thread: Lining up the equals sign on several lines of workings.

1. ## Lining up the equals sign on several lines of workings.

Hi all,

How do I get the equals sign to line up under each other like they would when writing by hand.

Example:

$1000x=100y$
$10x=y$

Another example:

$x=10-8$
$=2$

It would be nice if the equals were lined up.

Cheers all.

2. ## Re: Lining up the equals sign on several lines of workings.

\begin{align*} \cos (2x) &= \cos^2(x)-\sin^2(x) \\ &=1-2\sin^2(x) \\ &= 2\cos^2(x)-1 \end{align*}
gives

\begin{align*} \cos (2x) &= \cos^2(x)-\sin^2(x) \\ &=1-2\sin^2(x) \\ &= 2\cos^2(x)-1 \end{align*}

3. ## Re: Lining up the equals sign on several lines of workings.

Hi there,

I had a little trouble getting your method to work for me. I was however able to achieve it using the tabbing environment. Once I get a bit better with LaTeX I will return to your suggested method, but for now I can carry on with the tabbing method.

Many thanks.

4. ## Re: Lining up the equals sign on several lines of workings.

Originally Posted by Srengam

$1000x=100y$
$10x=y$

Another example:
$x=10-8$
$=2$
\begin{align*} 1000x &= 100y \\ 10x &=y\end{align*}
\begin{align*} 1000x &= 100y \\ 10x &=y\end{align*}

\begin{align*} x &= 10-8 \\ &=2\end{align*}
\begin{align*} x &= 10-8 \\ &=2\end{align*}