[NTG-context] \begin{cases} .. \end{cases} in ConTeXt

Brooks Moses bmoses at stanford.edu
Tue Sep 13 02:08:15 CEST 2005

At 04:58 PM 9/12/2005, Brooks Moses wrote:
>At 04:42 PM 9/12/2005, Jilani Khaldi <jilani.khaldi1 at virgilio.it> wrote:
>>I have tried with:
>>.. \stopcases
>>and many others variations but I have got only errors.
>>Any hint?
>Much like the bmatrix environment, the cases environment is an AMSmath 
>package feature, and ConTeXt at present has very few of the direct 
>equivalents to those implemented.  You'll need to make this one up with a 
>Plain TeX \matrix, as well.  (The TeXbook is a pretty good reference for this.)

I should follow my own advice!  As the TeXbook points out, Plain TeX has a 
perfectly good \cases command which is also present in ConTeXt, and which 
you use like this:

   P_{r-j} =
        0                 & if $r-j$ is odd,\cr
        r!(-1)^{(r-j)/2}  & if $r-j$ is even.\cr

Note that, in this version, the text in the second column is _not_ enclosed 
in a \text command; the \cases command handles that automatically.

In any case, the output is identical to the previous version I gave you, 
but this is easier to type.

- Brooks

More information about the ntg-context mailing list