I have an equation that is split into 4 lines using amsmath
's split
environment. How can I annotate individual lines with a text comment such that the comments are themselves left-justified and aligned? So what I want is (without the equation number):
lhs = some term (comment1)
+ another term
+ yet another term (comment2)
+ final term (comment3)
In principle, left-justified and aligned comments can be obtained with the alignat
environment, of course. However, while I can select which of the lines get numbered using \notag
so I get a single equation number, the number won't be vertically centered (because I have an even number of lines).
I've searched for solutions for a while but have come up empty. The following MWE is incomplete because it does not contain the left-justified and aligned comments:
\documentclass{minimal}
\usepackage{amsmath}
\begin{document}
\begin{equation}
\begin{split}
\alpha & = \alpha_0 \\
& + \beta^2 (H-\sqrt{f/g})
\end{split}
\end{equation}
\end{document}
Thanks for any help.
Best Answer
You can use
aligned
oralignedat{2}
, and take into account or not the widths of the comments: