获取左对齐方程

获取左对齐方程

我怎样才能使这个等式左对齐?

\begin{equation}
\beta_1=(n_{20}+n_{02})
\\
\beta_2={(n_{20}-n_{02})^2}+4{n_{11}}^2
\\
\beta_3={(n_{30}-3n_{12})^2}+{(3n_{21}-n_{03})^2}
\\
\beta_4={(n_{30}+n_{12})^2}+{(n_{21}-n_{03})^2}
\\
\beta_5=(n_{30}-3n_{12})(n_{30}+n_{12})[{(n_{30}+n_{12})^2}-3{(n_{21}+n_{03})^2}]+(3n_{21}-n_{03})(n_{21}+n_{03})[3{(n_{30}+n_{12})^2}-{(n_{21}+n_{03})^2}
\\
\beta_6=(n_{20}-n_{02})[{(n_{30}+n_{12})^2}-{(n_{21}+n_{03})^2}]+4n_{11}(n_{30}+n_{12})(n_{21}+n_{03})
\\
\beta_7=(3n_{21}-n_{03})(n_{30}+n_{12})[{(n_{30}+n_{12})^2}-3{(n_{21}+n_{03})^2}]-(n_{30}+3n_{12})(n_{21}+n_{03})[3{(n_{30}+n_{12})^2}-{(n_{21}+n_{03})^2}]
\label{Eq:momentsHU}
\end{equation}

答案1

它无法工作:equation适用于单行方程。如果您只想要一个方程编号,请使用aligned来自amsmath,位于alignedequation。最长的方程必须再次拆分,您可以使用 来执行此操作multlined

\documentclass[a4paper, 11pt]{book}
\usepackage[utf8]{inputenc}
\usepackage[showframe]{geometry}
\usepackage{mathtools}

\begin{document}

\begin{equation}
  \begin{aligned}
    \beta_1 & =(n_{20}+n_{02})
    \\
    \beta_2 & ={(n_{20}-n_{02})^2}+4{n_{11}}^2
    \\
    \beta_3 & ={(n_{30}-3n_{12})^2}+{(3n_{21}-n_{03})^2}
    \\
    \beta_4 & ={(n_{30}+n_{12})^2}+{(n_{21}-n_{03})^2}
    \\
    \beta_5 & =\!\begin{multlined}[t]
    (n_{30}-3n_{12})(n_{30}+n_{12})[{(n_{30}+n_{12})^2}-3{(n_{21}+n_{03})^2}]
    \\+(3n_{21}-n_{03})(n_{21}+n_{03})[3{(n_{30}+n_{12})^2}-{(n_{21}+n_{03})^2}
    \end{multlined}
    \\
    \beta_6 & =(n_{20}-n_{02})[{(n_{30}+n_{12})^2}-{(n_{21}+n_{03})^2}]+4n_{11}(n_{30}+n_{12})(n_{21}+n_{03})
    \\
    \beta_7 & =\!\begin{multlined}[t]
    (3n_{21}-n_{03})(n_{30}+n_{12})[{(n_{30}+n_{12})^2}-3{(n_{21}+n_{03})^2}]\\ -(n_{30}+3n_{12})(n_{21}+n_{03})[3{(n_{30}+n_{12})^2}-{(n_{21}+n_{03})^2}]
    \end{multlined}
    \label{Eq:momentsHU}
  \end{aligned}
\end{equation}

\end{document} 

在此处输入图片描述

答案2

我只需使用align*(包含\usepackage{amsmath}在您的序言中)进行设置,并在适当的位置中断长行。您也可以考虑使用flalign*

在此处输入图片描述

\documentclass{article}
\usepackage{amsmath}
\begin{document}

\begin{align*}
  \beta_1 &= (n_{20} + n_{02}) \\
  \beta_2 &= (n_{20} - n_{02})^2 + 4 n_{11}^2 \\
  \beta_3 &= (n_{30} - 3n_{12})^2 + (3n_{21} - n_{03})^2 \\
  \beta_4 &= (n_{30} + n_{12})^2 + (n_{21} - n_{03})^2 \\
  \beta_5 &= (n_{30} - 3n_{12})(n_{30} + n_{12})[(n_{30} + n_{12})^2 - 3(n_{21} + n_{03})^2] + {} \\
          &\phantom{{}={}} \qquad (3n_{21} - n_{03})(n_{21} + n_{03})[3(n_{30} + n_{12})^2 - (n_{21} + n_{03})^2 \\
  \beta_6 &= (n_{20} - n_{02})[(n_{30} + n_{12})^2 - (n_{21} + n_{03})^2] + 4n_{11}(n_{30} + n_{12})(n_{21} + n_{03}) \\
  \beta_7 &= (3n_{21} - n_{03})(n_{30} + n_{12})[(n_{30} + n_{12})^2 - 3(n_{21} + n_{03})^2] - {} \\
          &\phantom{{}={}} \qquad (n_{30} + 3n_{12})(n_{21} + n_{03})[3(n_{30} + n_{12})^2 - (n_{21} + n_{03})^2]
\end{align*}

\end{document}

答案3

这或多或少与以下问题相同:左对齐公式。您可以使用flalign环境或者documentclass用选项加载您的fleqn

相关内容