TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a set of equations where some are coupled with a brace and some text. I want all the equations aligned. Something like the following ASCII art:

 S = LR

 L = Ls  \
          |  for s in {a, b}
Rs = sR  /

I tried this:

S &= LR \\
L &= L_s\\
R_s &= sR
\;\;\right\}\;\;\text{for } s \in \{a, b\}\\

But it doesn't compile (because & is not expected inside a gather* environment). Is it possible to do this?

share|improve this question
Replace gather* with aligned. Remark: NO *. – zeroth Apr 24 '12 at 12:48
@zeroth: if I do that, the equations outside the aligned don't align with the ones inside. – Max Apr 25 '12 at 8:44
@cmhughes: thanks, I'll take a look at that – Max Apr 25 '12 at 8:45
@Max, yes that is correct, sorry for my misguiding. – zeroth Apr 25 '12 at 8:56
up vote 10 down vote accepted

A simple way would be:



S &= LR \\
L &= L_s\\
R_s &= sR
\end{split}\quad\Bigg\}\,\,\text{for } s \in \{a, b\}


enter image description here

share|improve this answer
The only thing I'd change is to use \bigg instead of \Bigg. Of course, that's entirely subjective. :-) – Mico Apr 24 '12 at 13:39
In my actual document, there are more than two equations inside the brace, so \Bigg is not big enough. I guess I have to mess around with vphantoms and the like to get bigger? – Max Apr 25 '12 at 8:43
@Max: you can then use stretchable delimiters and a rule with no width and desired height: \begin{align*} S &= LR \\begin{split} L &= L_s\R_s &= sR\T_s &= sT \end{split} \quad\left.\rule{0pt}{1.5\baselineskip}\right\rbrace\,\,\text{for } s \in \{a, b\} \end{align*} (sorry about the poor code formatting, but comments are not the best place to write code). – Gonzalo Medina Apr 25 '12 at 13:35
Is there any way where the size of the brace is automatically calculated? – Wauzl Apr 29 '14 at 18:49

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.