4

How to right-side annotate a bracketed-together set of items in the align environment, cases sub-environment?

E.g. how to put an annotation such as "(Fermat)" where the following code would put a number for the equation pair:

\begin{align}
\begin{cases}
first equation\\
second equation\\
\end{cases}
 \end{align}

? (I realise to get rid of the number, I have to change align to align*)

1
  • 2
    Please consider to upvote answers you find useful.
    – lockstep
    Jan 21 '12 at 18:27
3

if you're using amsmath, don't bother adding *; instead, put \tag{Fermat} just before \end{align} and that will be placed where the equation number usually goes.

actually, you should just use equation instead of align since cases is a single entity.

you also don't need (or want) the second \\ before \end{cases}.

1
  • Thanks. tag{Fermat} before \end{align} - shortest solution of all so far! :) Jan 21 '12 at 18:26
1

You could be use rcases from the mathtools package, or you could use the \left. \right\} with amsmath (already included by the mathtools package) to obtain the curly brace on the right, and use \tag to add the annotation:

\documentclass{article}
\usepackage{mathtools}

\begin{document}
\begin{align}
\begin{rcases}
 first equation\\ \tag{Fermat}
 second equation\\
\end{rcases}
\end{align}
%
\begin{align}
\left.
\begin{aligned}
  first equation\\ 
  second equation\\
\end{aligned}
\right\} \tag{Fermat}
\end{align}
\end{document}
1
  • Thanks for this, but where should I put the annotation? Jan 21 '12 at 18:17
1

Automatic number of any line in a math environment can be overridden by a \tag command:

\begin{equation}
\label{eq:fermat}\tag{Fermat}
\begin{cases}
first equation\\
second equation
\end{cases}
\end{equation}

In this way the tag will go in place of the equation number. If you want instead to add also the annotation, which might be even better,

\begin{equation}
\label{eq:fermat}
\begin{cases}
first equation\\
second equation
\end{cases}
\qquad\text{(Fermat)}
\end{equation}

Don't use align when you're not doing an alignment (the surrounding spacing is excessive) and don't use a final \\ in amsmath environments (that causes an erroneous vertical space).

3
  • 1
    with amsmath, don't need \text with \tag since it's not in math mode. Jan 21 '12 at 18:21
  • Thanks! (I am doing an alignment, but dropped it for this minimal example). I've now used \label{eq:fermat}\tag{Fermat}. Interestingly it works even with align*; the * must take out the number but not what replaces it. Thanks for the `\` tip too. Jan 21 '12 at 18:22
  • Yes, \tag works also in *-environments. With \eqref{eq:fermat} you'll get the tag, of course, that is, (Fermat).
    – egreg
    Jan 21 '12 at 18:24

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.