1

I am using the following setup to add comments to the right of aligned equations.

\documentclass{amsart}
\usepackage{lipsum}

\newcommand{\comment}[1]{\text{\footnotesize{#1}}}
\newcommand{\blurb}[2]{\begin{minipage}{#1} \footnotesize #2 \end{minipage}}


\begin{document}

\lipsum[1]

\begin{align*}
1 &= 2 \\
3 &= 4 && \comment{\lipsum[1]} \\
5 &= 6 && \blurb{4in}{\lipsum[1]}
\end{align*}

\end{document}

It produces the following:

enter image description here

Currently, if I have a comment that is too long to keep the equation group within the text width (as in the comment for $3 = 4$), I use the blurb command I defined and manually tweak the minipage width until it's acceptable (as in the comment for $5=6$). (Maybe a better criterion for "acceptable" would be the largest minipage width that allows the entire equation group to sit within the text width; this is often what I end up doing because of space constraints with long equations and comments.)

Is there some automation so that I don't have to manually tweak my too-long comments to blurbs? A solution as described in the question title seems unlikely because it would need a width parameter to define a minipage, but the contents of the minipage determine what that width parameter should be. But maybe there's another way to achieve the same result.

0 Answers0