Subequation labeling inside an “aligned” environment

I can align several equations inside a single brace with the following code.

\left\lbrace \begin{aligned} k \cdot E &= 0 \\ k \cdot B &= 0 \end{aligned} \right.


And I know how to use subequation numbering when I don't put the brace.

\begin{subequations}
\begin{align}
k \cdot E &= 0 \\
k \cdot B &= 0
\end{align}
\end{subequations}


But I do not manage to do both. The following code compiles but does not produce the expected result.

\left\lbrace \begin{subequations} \begin{aligned} k \cdot E &= 0 \\ k \cdot B &= 0 \end{aligned} \end{subequations} \right.


Expected:

     / k . E = 0     (10a)
{
\ k . D = 0     (10b)


Actual result:

     / k . E = 0
{                 (11)
\ k . D = 0


And there is nothing with the tag 10.

If I move the subequations outside (that is, in order: subequations, equation, \left, aligned), then I get the single tag (10).

If I move subequations inside aligned, it does not compile.

Use empheq (but first think again if you really need separate numbers):

\documentclass{article}
\usepackage{amsmath}
\usepackage{empheq}

\begin{document}
\setcounter{equation}{9} % just for the example

\begin{subequations}
\begin{empheq}[left=\empheqlbrace]{align}
k \cdot E &= 0 \\
k \cdot B &= 0
\end{empheq}
\end{subequations}

\end{document}


• Thank you! How does it play with cleveref and hyperef? – Niriel Oct 31 '14 at 9:41
• @Niriel Since it internally uses amsmath, there should be no problem, but as I rarely use cleveref I can't say. Please report any problem. – egreg Oct 31 '14 at 9:57