# an unexpected result in LaTeX

Dr Alan Litchfield alan at alphabyte.co.nz
Wed Jul 7 23:51:10 CEST 2021

Fascinating!

Learn something new (old!) all the time.

Thank
Alan

> On 8/07/2021, at 9:31 AM, barbara beeton <bnb at tug.org> wrote:
>
> One of the features of the line-breaking code \\ is the ability to
> add an option -- enclosed in [brackets] as the recognized syntax --
> following the \\.  The required content is a dimension, such as [2pt].
>
> That is what you have inadvertently stumbled upon.
>
> To protect against this misunderstanding, insert an empty group {}
> or \relax after \\ if the next thing is to be an "ordinary" bracketed
> expression.
>
> This can also happen in some situations in the first line (such as
> in a table), so you probably want to become familiar with this
> concept and the proper method of repair.
> 						-- bb
>
> On Wed, 7 Jul 2021, Kevin Cahill wrote:
>
>> The code
>>
>> \boldsymbol [ \c_b, \c_c \boldsymbol ]^\dag
>> ={} [ \c_c^\dag, \c_b^\dag ]
>> = \left\{
>> \begin{array}{ll}
>> - \boldsymbol [ \c_b, \c_c \boldsymbol ] &
>> \mbox{ for } b, c = 1, 2, 3 \\
>> \boldsymbol [ \c_b, \c_c \boldsymbol ] &
>> \mbox{ if } b \mbox{ or } c = 0 .
>> \end{array}
>> \right .
>>
>> works, but the nearly identical code
>>
>> \boldsymbol [ \c_b, \c_c \boldsymbol ]^\dag
>> ={} [ \c_c^\dag, \c_b^\dag ]
>> = \left\{
>> \begin{array}{ll}
>> - \boldsymbol [ \c_b, \c_c \boldsymbol ] &
>> \mbox{ for } b, c = 1, 2, 3 \\
>> [ \c_b, \c_c ] &
>> \mbox{ if } b \mbox{ or } c = 0 .
>> \end{array}
>> \right .
>>
>> does not;
>> the error message is
>> 418:  Illegal unit of measure (pt inserted).