# Why does the $\LaTeX$ cases environment not work?

In the last few days I have twice tried to use \cases in $\LaTeX$ and gotten nowhere. Why does it not work?

Or, if it does, how does it work?

• Would you be so kind as to show how it's not working? That is, is it rendering incorrectly or just not at all? – Aarthi Oct 10 '12 at 23:14
• It's rendering incorrectly. I can't get multiple lines even when I use \\ to separate them. – Peter Flom Oct 10 '12 at 23:18

Care to share an example, below taken from here appears to be displaying correctly for me here on meta.

\begin{equation*} |x|= \begin{cases} x & \text{if $x≥0$,} \\ -x &\text{if $x\le 0$.} \end{cases} \end{equation*}

Code used to generate this:

\begin{equation*}
|x|=
\begin{cases} x & \text{if $x≥0$,}
\\
-x &\text{if $x\le 0$.}
\end{cases}
\end{equation*}