3
\documentclass{article}
\usepackage{amsmath}
\usepackage{cases}
\begin{document}
Cases:
\begin{equation}
\begin{cases}
    N + N/4  \\
    6-W_{|N|}
\end{cases}
\end{equation}
Numcases:
\begin{subnumcases}{}
    N +  N/4  \\
    6-W_{|N|}  
\end{subnumcases}
\end{document}

I would like to have the sub-numbering of subnumcases but with the standard bracket of cases.

  • 1
    You could try https://tex.stackexchange.com/a/165690/, possibly removing the \, after \empheqlbrace. – Marijn Apr 25 '19 at 16:42

3 Answers3

4

You can use empheq which is better than cases for this task:

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

\usepackage{cases}
\begin{document}
\subsubsection*{Cases}
\[
\begin{cases}
    N +  N/4  \\
    6-W_{|N|}  
\end{cases}
\]
\subsubsection*{Numbered cases}
\begin{empheq}[left=\empheqlbrace]{align}
  &  N + N/4  \\
  &  6-W_{|N|}
\end{empheq}
\subsubsection*{Subnumbered cases}
\begin{subequations}
\begin{empheq}[left=\empheqlbrace]{align}
  &  N + N/4  \\
  &  6-W_{|N|}
\end{empheq}
\end{subequations}
\end{document}

enter image description here

You get the same alignment if you use

\[
\left\{
\begin{aligned}
    N +  N/4  \\
    6-W_{|N|}
\end{aligned}
\right.
\]

for the first.

egreg
  • 1,121,712
0

Using for example, numcases instead of cases you will have the standard bracket. See the manual http://mirrors.ibiblio.org/CTAN/macros/latex/contrib/cases/cases.pdf pag. 2. The size is the same of the bracket.

enter image description here

\documentclass{article}
\usepackage{amsmath,verbatim}
\usepackage{cases}
\begin{document}
\begin{verbatim} 
 with numcases:
 \end{verbatim}

\begin{numcases}{}
 N + N/4  \\
 6-W_{|N|}
\end{numcases}
\begin{verbatim} 
with subnumcases:
\end{verbatim}    

\begin{subnumcases}{}
    N +  N/4  \\
    6-W_{|N|}  
\end{subnumcases}
\end{document}
Sebastiano
  • 54,118
0

The literal answer to the question is that {cases} has invisible "struts", and the brace covers the extent of those. With {numcases} the brace only covers the mathematical text (the "ink").

You can make them equal by using

\usepackage[casesstyle]{cases}

This also normalizes the math style for both to be \displaystyle, where the amsmath version, based on {array}, is \textstyle (with compacted fractions and operators).