2

I thought I'd come across a solution for my question but surprisingly (to me) I did not. I hoped an example would have been in https://en.wikibooks.org/wiki/LaTeX/Advanced_Mathematics but maybe it needs updating...

Anyway, borrowing from Werner's solution, Sub-numbering equations within array I tried to get the very last result (which I kind of did, but the spacing is horrible).

How do I attain the last result in a way that looks good? I note that the order of loading packages was important, i.e. empheq then cases

\documentclass{article}
\usepackage{empheq}
\usepackage{cases}% http://ctan.org/pkg/cases


\begin{document}

\begin{subnumcases}{x=}
  a + b \\
  c + d \\
  e + f
\end{subnumcases}


\begin{equation}
\epsilon_{(3,2)} = \left\{ \begin{array}{lcr}
  x(z) &=& z^2 - 2\,v \\
  y(z) &=& z^3 - 3\,v\,z \\
  t_1 &=& 3\,v^2
\end{array} \right.
\end{equation}

\begin{subnumcases}{\epsilon_{(2,3)}=}
  x(z) = z^2 - 2\,v \label{eq1asfsafs} \\
  y(z) = z^3 - 3\,v\,z \label{eqjfdklsafjasfkasjf}\\
  t_1 = 3\,v^2 \label{ejfklasjfkldsjafkl}
\end{subnumcases}

\begin{subequations}
\label{fdjfdsadadasad}
\begin{empheq}[left={x=}\empheqlbrace]{align}
   x(z) &=& z^2 - 2\,v \label{eq1asfsafs} \\
   y(z) &=& z^3 - 3\,v\,z \label{eqjfdklsafjasfkasjf}\\
   t_1 &=& 3\,v^2 \label{ejfklasjfkldsjafkl}
\end{empheq}
\end{subequations}



\end{document}

I've been using lualatex if that matters...

Attempt...

2
  • 1
    In the fourth group, replace the three instances of &=& with &= -- the former is appropriate for performing alignment in array settings, whereas the latter is for align settings. A separate suggestion: get rid of all instances of \, -- they aren't needed.
    – Mico
    Nov 21, 2017 at 3:02
  • Thanks! Minor wish - can I have something like \begin{array}{lcr} effect, easily?
    – nate
    Nov 21, 2017 at 3:05

1 Answer 1

2

You're using & incorrectly inside an align-like environment:

enter image description here

\documentclass{article}

\usepackage{empheq}

\begin{document}

\begin{equation}
  \setlength{\arraycolsep}{0pt}
  \epsilon_{(3,2)} = \left\{ \begin{array}{ l l }
    x(z) &{}= z^2 - 2\,v \\
    y(z) &{}= z^3 - 3\,v\,z \\
    t_1  &{}= 3\,v^2
  \end{array} \right.
\end{equation}

\begin{subequations}
  \begin{empheq}[left={x=}\empheqlbrace]{align}
     x(z) &= z^2 - 2\,v \\
     y(z) &= z^3 - 3\,v\,z \\
      t_1 &= 3\,v^2
  \end{empheq}
\end{subequations}

\end{document}

align has a right-left alignment using a single &.

1
  • Nice to have both methods!
    – nate
    Nov 21, 2017 at 3:15

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .