[texhax] problem with align environment

Lars Madsen daleif at imf.au.dk
Wed Feb 18 00:26:30 CET 2009


Don Gingrich wrote:
> This one is a bit strange since the problem manifests
> as an error in the *second* use of the environment
> even though it looks like the real problem is in the
> *first* use of the environment. It's no a showstopper
> since pdflatex eventually sorts out something that
> works after generating 8 error messages.
> 
> I've tried to include enough information -- and hopefully
> not too much. The information abut setup and packages,
> possibly even order of packages, seemed likely to be
> significant.
> 
> I've tried plain LaTeX on the source and it barfs
> all over the place, so AFAIK it needs to be pdflatex.
> 
> Also, note that I have inherited the code from someone
> else. While looking at the following Boolean algebra
> in the text, (which was originally done in \tt with
> a stack of $...$ markers) I concluded that it would
> look a lot better in a proper math environment.
> Align looked like the best choice, but I could be
> wrong in this conclusion.
> 
> Thanks for looking at this -- my current theory is
> that my problem may have something to do with comments
> in text that then go back into math mode in the align
> section that runs from line 465-473, but I cannot see 
> any obvious solution -- when I tried fiddling this,
> the whole thing "blew up"
> 
> Thanks again,
> -Don
> 
> 
> 
> the code: (line numbers in [square brackets] )
> -------------------------------------------------
> 
> \begin{align*}      % [465]
> Z &= A.B.C + A.\overline{B}.(\overline{\overline{A}.\overline{C}})  && \text{; de Morgan's theorem} \\
>  &= A.B.C + A.\overline{B}.(\overline{\overline{A}} + \overline{\overline{C}})  &&\text{ ; }A = \overline{\overline{A}} \\
>  &= A.B.C + A.\overline{B}.(A + C) && \text{ } \\
>  &= A.B.C + A.\overline{B}.A + A.\overline{B}.C && \text{; multiply out} \\
>  &= A.B.C + A.\overline{B} + A.\overline{B}.C &&  \text{; since } A.A = A \\
>  &= A.C(B + \overline{B}) + A.\overline{B}  && \text{; common factor}  AC, B + \overline{B} = 1\\
>  &= A.C + A.\overline{B} \\
> \end{align*}   % [473]
> 
> 
> 
> \subsubsection{Simplification example}
> 
> Trace the operations of the following example, and make sure that you can relate each
> operation to the rules above.
> 
> \begin{align*}  % [482]
>         Z &= \overline{(\overline{A}.\overline{B} + C)} + (B.C) \\
>           &= (\overline{\overline{A}.\overline{B}}.\overline{C}) + B.C    \\
>           &= (\overline{\overline{A}} + \overline{\overline{B}}).$\overline{C} + BC \\
>           &= (A + B).\overline{C} + B.C \\
>           &= A.\overline{C} + B.\overline{C} + B.C \\
>           &= A.\overline{C} + B.(\overline{C} + C)\\
>           &= A.\overline{C} + B \\
> \end{align*}  % [490 ]
> 

couldn't you provide a shorter minimal example, and one that could just 
be copied and pasted into our own systems?

Anyway why is there a $ in the second align?

I haven't tried your code, but try removing that $ and please post a 
smaller minimal example.

/daleif



More information about the texhax mailing list