12

我希望在 align* 环境中具有类似 \multicolumn 的效果,如下面的代码片段(不起作用)所示。即,我希望文本与最左边的列对齐,但它不应该影响等式的对齐特性。\intertext{...} 不幸的是,即使等式居中,也会将所有内容刷新到左边距。

    \begin{align*}
      1 & 2 & 3 & 4 & 5 \\
      \multicolumn{5}{l}{Some text that I want to appear here..} \\
      %\intertext{Some text that I want to appear here} \\
      7 & 8 & 9 & 10 & 11 & 12
    \end{align*}

我该如何做到这一点?

提前谢谢了!

4

2 回答 2

7

\begin{align*}
  1 & 2 & 3 & 4 & 5 \\
  \omit\rlap{Some text that I want to appear here...}\\
  7 & 8 & 9 & 10 & 11 & 12
\end{align*}

一般来说,作为\multicolumnalign-like 环境的替代品,可以尝试使用\multispan,但在这种情况下,它似乎严重干扰了对齐。

于 2010-11-22T19:06:16.327 回答
5

显然在数学模式下,用于水平对齐的命令 \llap 和 \rlap 不起作用。包 mathtools 提供了 \mathllap 和 \mathrlap,它们在那里工作。

来源:这篇文章

于 2012-03-05T05:00:46.473 回答