Split-like environment inside cases environment
Well, I'd follow amsmath's suggestion to use aligned instead of split:
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\[
\text{left hand side} =
\begin{cases}
\!\begin{aligned}%[b]
& \text{a very long expression} \\
& + \text{that continues on the next line}
\end{aligned} & \text{1st condition} \\%[1ex]
\text{short expression} & \text{2nd condition}
\end{cases}
\]
\end{document}
Does this yield the output you want? (Note that the \!
in front of aligned
is needed since that environment adds a \,
we have to cancel out.)
EDIT: If you want to achieve alignment and spacing as Niel suggests (@Niel: I would want that; good catch), then just remove the two %
in the code.
Here is an alternative construction to Hendrik's, which aligns the 1st condition
with the bottom-most line of the long expression (which I would suggest as good practise generally for readability). I also add vertical space between the two formulae to make it easier to separate the two visually.
\documentclass{article} \usepackage{amsmath} \begin{document} \[ \text{left hand side} = \left\{ \begin{aligned} & \text{a very long expression} \\ & + \text{that continues on the next line} && \text{1st condition} \\[1ex] & \text{short expression} && \text{2nd condition} \end{aligned} \right. \] \end{document}
I omit the cases
environment here, as all of the alignment work that it does is now better performed by aligned
. The alignment tabs are chosen to get uniform alignment of the conditions, and left-alignment for everything involved; they can be changed to obtain right-alignment where desired.