2

I want to type aligned equations

x = a    
y = b
z = c

I only know two ways of achieving this. One is using \begin{align}, the other is by using \begin{cases} wrapped within a \begin{equations}.

Is there any other way to achieve aligned equations?

4
  • 1
    align is the most used one. Your second approach sounds ugly.
    – Sigur
    Nov 24, 2018 at 21:05
  • It mostly depends on what you're trying to achieve.
    – egreg
    Nov 24, 2018 at 21:07
  • You also have alignat, which lets you control the spacing between alignment columns , and flalign.
    – Bernard
    Nov 24, 2018 at 21:31
  • the amsmath package offers align, flalign, alignat, as top level environemnts, or inside equation aligned or alignedat depending if you want one equation number or 3. Don't use cases for such a display. Nov 24, 2018 at 21:59

1 Answer 1

3

enter image description here

\documentclass{article}

\usepackage{amsmath}

\begin{document}

align
\begin{align}
x &= a \\
y &= b \\
z &= c  
\end{align}

alignat
\begin{alignat}{1}
x &= a \\
y &= b \\
z &= c  
\end{alignat}

flalign
\begin{flalign}
x &= a \\
y &= b \\
z &= c  
\end{flalign}

equation/aligned
\begin{equation}
\begin{aligned}
x &= a \\
y &= b \\
z &= c  
\end{aligned}  
\end{equation}


equation/alignedat
\begin{equation}
\begin{alignedat}{1}
x &= a \\
y &= b \\
z &= c  
\end{alignedat}  
\end{equation}

equation/cases
\begin{equation}
f(x)=\begin{cases}
-1 &x = a \\
0 &y = b \\
1 &z = c  
\end{cases}  
\end{equation}

\end{document}

There are more examples in amsldoc.pdf (texdoc amsmath in texlive)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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