Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

It seems the amsmath \raisetag macro does not work in combination with the alignedat environment. See the MWE below:

\documentclass{article}
\usepackage{amsmath}
\begin{document}
  \begin{equation}
    \begin{alignedat}{3}
      \text{line 1} &\quad&& \text{is long, very long, really very long, unbelievably long, really it is such}\\
      \text{line 2} &&& \text{is short}
    \end{alignedat}
    \raisetag{\baselineskip} % <--- seems to do nothing!
  \end{equation}
\end{document}

Is it possible to fix or work around this?

share|improve this question

3 Answers 3

up vote 3 down vote accepted

it seems to me that \raisetag should work here. it works with split:

\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{equation}
  \begin{split}
    \text{line 1} &\quad \text{is long, very long, really very long, unbelievably long, really it is such}\\
    \text{line 2} &\quad \text{is short}
  \end{split}
\raisetag{\baselineskip}
\end{equation}
\end{document}

output of example code

i will enter a bug report, but can't offer any promises about when it might get looked at (or fixed).

share|improve this answer

Set the content using a regular align, adding \nonumber to the first part of the equation:

enter image description here

\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{align}
  \text{line 1} &\quad \text{is long, very long, really very long, unbelievably long, really it is such} \nonumber \\
  \text{line 2} &\quad \text{is short}
\end{align}
\end{document}

amsmath.dtx alludes to this somewhat, but I'm not entirely sure whether it's related to your situation:

Note that according to the current uses of \raise@tag in e.g., \place@tag@gather, no adjustment occurs if the tag falls in its normal position; i.e., \raisetag has no effect unless the tag has already been shifted off-line.

share|improve this answer
    
it seems to me that \raisetag should work here. there were some bug reports in the '90s, but the examples submitted were outside the intended scope, and the file was closed. i've just tested this with split and it works there. i will post an answer with that information. –  barbara beeton Mar 28 at 16:51

If you want the equation number be centred wrt the group of lines, the best is to use the multlined environment, from the mathtools package. Here is an example that shows the difference with split in such a context, with different way of aligning. Btw, with alignat, you don't have to repeat the quad separator between two groups:

    \documentclass{article}
    \usepackage{mathtools}
    \begin{document}
      \begin{equation}
        \begin{alignedat}{2}
           & \text{line 1} & \quad & X \begin{multlined}[t]
            \text{is long, very long, really }\\\text{very long, unbelievably long, really it is such}
          \end{multlined}\\
           & \text{line 1A} & & X \,\text{is short}
        \end{alignedat}
      \end{equation}
      \bigskip
      \begin{equation}
        \begin{alignedat}{2}
           \text{line 1} & \quad & X & \begin{multlined}[t]
            \text{is long, very long, really }\\\text{very long, unbelievably long, really it is such}
          \end{multlined}\\
           \text{line 1A} & &X &\, \text{is short}
        \end{alignedat}
      \end{equation}
      \bigskip
      \begin{equation}
        \begin{alignedat}{2}
          \text{line 1} & \quad & X & \begin{split}
            \text{is long, very long, really }\\\text{very long, unbelievably long, really it is such}%
          \end{split}
          \\
          \text{line 1A} & \quad & X &\, \text{is short}
        \end{alignedat}
      \end{equation}
    \end{document} 

enter image description here

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.