我想您明白我想做什么,但我不知道如何将等号完全对齐,同时仍保留垂直省略号。
Assume $\displaystyle \sum_{i=1}^{n}\alpha _{i}^{i}=\sum_{i=1}^{n}\beta _{i}^{i}$ for $j=1,\ldots,k-1$. By definition,
\begin{align}
\alpha_{1}+\alpha_{2}+\ldots+\alpha_{n} &= \beta_{1}+\beta_{2}+\ldots+\beta_{n}\\
\alpha_{1}^2+\alpha_{2}^2+\ldots+\alpha_{n}^2 &= \beta_{1}^2+\beta_{2}^2+\ldots+\beta_{n}^2\\
\vdots+\vdots+\ldots+\vdots &= \vdots+\vdots+\ldots+\vdots\\
\alpha_{1}^{k-1}+\alpha_{2}^{k-1}+\ldots+\alpha_{n}^{k-1}&= \beta_{1}^{k-1}+\beta_{2}^{k-1}+\ldots+\beta_{n}^{k-1}
\end{align}
答案1
我建议使用alignat
在等号和加号处对齐的环境。您也可以使用\
或\quad
等来\vdots
对齐它们。
举个例子,也许用&
得比必要的还多:
\begin{alignat}{6}
\alpha_{1}&+\alpha_{2}&&+\ldots&&+\alpha_{n} &&= \beta_{1}&&+\beta_{2}&&+\ldots+\beta_{n}\\
\alpha_{1}^2&+\alpha_{2}^2&&+\ldots&&+\alpha_{n}^2 &&= \beta_{1}^2&&+\beta_{2}^2&&+\ldots+\beta_{n}^2\\
\vdots\ &+\ \vdots&&+\ldots&&+\ \vdots &&= \ \vdots&&+\ \vdots&&+\ldots+\ \vdots
\end{alignat}
答案2
\documentclass[a4paper]{article}
\usepackage{amsmath,calc}
\newcommand{\xalpha}[3][\alpha]{%
\makebox[\widthof{$\alpha^{k-1}$}]{$#1_{#2}^{#3}$}}
\newcommand{\xbeta}[3][\beta]{%
\makebox[\widthof{$\beta^{k-1}$}]{$#1_{#2}^{#3}$}}
\newcommand{\lvdots}{\smash{\raisebox{-.5ex}{$\vdots$}}}
\begin{document}
\begin{gather}
\xalpha{1}{}+\xalpha{2}{}+\ldots+\xalpha{n}{} =
\xbeta{1}{}+\xbeta{2}{}+\ldots+\xbeta{n}{}\\
\xalpha{1}{2}+\xalpha{2}{2}+\ldots+\xalpha{n}{2} =
\xbeta{1}{2}+\xbeta{2}{2}+\ldots+\xbeta{n}{2}\\
\xalpha[\lvdots]{}{}+\xalpha[\lvdots]{}{}+\ldots+\xalpha[\lvdots]{}{} =
\xbeta[\lvdots]{}{}+\xbeta[\lvdots]{}{}+\ldots+\xbeta[\lvdots]{}{}\\
\xalpha{1}{k-1}+\xalpha{2}{k-1}+\ldots+\xalpha{n}{k-1} =
\xbeta{1}{k-1}+\xbeta{2}{k-1}+\ldots+\xbeta{n}{k-1}
\end{gather}
\end{document}
\xalpha
我通过和将所有加数设置为相同宽度,将实际加数置于与或\xbeta
一样宽的框中。需要稍微降低一点。\alpha^{k-1}
\beta^{k-1}
\vdots
人们可能会使用更复杂的宏,考虑到所有半线都是同一类型。