我想对齐多个拆分环境。到目前为止,我已经检查了这些答案,但没有一个能解决问题。如何在等号处对齐两个分割环境?,如何通过分割方程获得两个对齐点和多重比对
我希望下面的代码中的所有=
符号都对齐,同时每个符号都有单独的数字。但是,我不确定我是否采取了正确的方法。提前谢谢您。
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\begin{document}
\begin{align}
\begin{split}
Y^{\text{I}}_{n} &= \alpha_{i} + \delta X_{1,n} \\
& +X_{2,int} \times[
\beta_{1} +
\beta_{2} z_{1} +
\beta_{3} z_{2} +
\beta_{4} z_{3} \\
& +\beta_{5} z_{1} z_{2} +
\beta_{6} z_{1} z_{3} +
\beta_{7} z_{2} z_{3} ]\\
& +X_{3,int} \times[
\gamma_{1} +
\gamma_{2} z_{1} +
\gamma_{3} z_{2} +
\gamma_{4} z_{3} \\
& + \gamma_{5} z_{1} z_{2} +
\gamma_{6} z_{1} z_{3} +
\gamma_{7} z_{2} z_{3} ]\\
\end{split}\\
\begin{split}
Y^{\text{II}}_{int} &= \alpha_{i} +\delta X_{1,n} \\
& + X_{2,n}\times\exp[ \mu_{1} + \sigma_{1} u_{1}] - X_{2,n}\times\exp[\eta_{1} + \sigma_{2} u_{2}]
\end{split} \\
\begin{split}
Y^{\text{III}}_{n} &= \alpha_{i} + \delta X_{1,n} \\
& + \exp[\mu_{1} +
\mu_{2} z_{1} +
\mu_{3} z_{2} +
\mu_{4} z_{3} + \sigma_{1} u_{1}]\times X_{2,n}\\
& + \exp[\eta_{1} +
\eta_{2} z_{1,n} +
\eta_{3} z_{2,n} +
\eta_{4} z_{3,n} + \sigma_{2} u_{2}]\times X_{3,n}
\end{split}
\end{align}
\end{document}
答案1
split
非常敏感\\
,并且在第一次分裂结束时你有一个额外的。
改变
\gamma_{7} z_{2} z_{3} ]\\
到
\gamma_{7} z_{2} z_{3} ]
或者进行一些小调整
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\begin{document}
\begin{align}
\begin{split}
Y^{\mathrm{I}}_{n} ={}& \alpha_{i} + \delta X_{1,n} \\
& +X_{2,int} \times[
\beta_{1} +
\beta_{2} z_{1} +
\beta_{3} z_{2} +
\beta_{4} z_{3} \\
& +\beta_{5} z_{1} z_{2} +
\beta_{6} z_{1} z_{3} +
\beta_{7} z_{2} z_{3} ]\\
& +X_{3,int} \times[
\gamma_{1} +
\gamma_{2} z_{1} +
\gamma_{3} z_{2} +
\gamma_{4} z_{3} \\
& + \gamma_{5} z_{1} z_{2} +
\gamma_{6} z_{1} z_{3} +
\gamma_{7} z_{2} z_{3} ]
\end{split}\\
\begin{split}
Y^{\mathrm{II}}_{\mathrm{int}} ={}& \alpha_{i} +\delta X_{1,n} \\
& + X_{2,n}\times\exp[ \mu_{1} + \sigma_{1} u_{1}] - X_{2,n}\times\exp[\eta_{1} + \sigma_{2} u_{2}]
\end{split} \\
\begin{split}
Y^{\mathrm{III}}_{n} ={}& \alpha_{i} + \delta X_{1,n} \\
& + \exp[\mu_{1} +
\mu_{2} z_{1} +
\mu_{3} z_{2} +
\mu_{4} z_{3} + \sigma_{1} u_{1}]\times X_{2,n}\\
& + \exp[\eta_{1} +
\eta_{2} z_{1,n} +
\eta_{3} z_{2,n} +
\eta_{4} z_{3,n} + \sigma_{2} u_{2}]\times X_{3,n}
\end{split}
\end{align}
\end{document}
答案2
除了 David 的回答之外,我还会这样做
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\begin{document}
\begin{align}
\begin{split}
Y^{\mathrm{I}}_{n} = {} & \alpha_{i} + \delta X_{1,n} \\
& +X_{2,int} \times[
\beta_{1} +
\beta_{2} z_{1} +
\beta_{3} z_{2} +
\beta_{4} z_{3} \\
& +\beta_{5} z_{1} z_{2} +
\beta_{6} z_{1} z_{3} +
\beta_{7} z_{2} z_{3} ]\\
& +X_{3,int} \times[
\gamma_{1} +
\gamma_{2} z_{1} +
\gamma_{3} z_{2} +
\gamma_{4} z_{3} \\
& + \gamma_{5} z_{1} z_{2} +
\gamma_{6} z_{1} z_{3} +
\gamma_{7} z_{2} z_{3} ]
\end{split}
\\
\begin{split}
Y^{\mathrm{II}}_{int} = {} & \alpha_{i} +\delta X_{1,n} \\
& + X_{2,n}\times\exp[ \mu_{1} + \sigma_{1} u_{1}] - X_{2,n}\times\exp[\eta_{1} + \sigma_{2} u_{2}]
\end{split}
\\
\begin{split}
Y^{\mathrm{III}}_{n} = {} & \alpha_{i} + \delta X_{1,n} \\
& + \exp[\mu_{1} +
\mu_{2} z_{1} +
\mu_{3} z_{2} +
\mu_{4} z_{3} + \sigma_{1} u_{1}]\times X_{2,n}\\
& + \exp[\eta_{1} +
\eta_{2} z_{1,n} +
\eta_{3} z_{2,n} +
\eta_{4} z_{3,n} + \sigma_{2} u_{2}]\times X_{3,n}
\end{split}
\end{align}
\end{document}
这里我们移动+
对齐方式,使其不低于 ,=
因为这样看起来很糟糕。我也\text
用替换了\mathrm
。为什么,尝试\itshape
在 之前添加\begin{align}
!