为什么这个等式没有左对齐?

为什么这个等式没有左对齐?

我想知道为什么方程式的所有多行都没有左对齐?我尝试使用对齐,但方程式太长,我无法将其拆分。

 \documentclass[11pt,a4paper,oneside]{report} 
 \usepackage[T1]{fontenc}
 \usepackage{fouriernc}
 \usepackage{mathtools}
 \usepackage{amsthm}
 \usepackage{amsfonts}
 \usepackage{amssymb}
 \begin{document}
 \begin{eqnarray*}
 N =&\frac{\theta _{1}-\theta _{2}}{f}\left( \left( \theta _{1}+\theta
 _{2}+t\right) x-fy\right) \frac{\theta _{1}-\theta _{3}}{f}\left( \left(
 \theta _{1}+\theta _{3}+t\right) x-fy\right) \frac{\theta _{2}-\theta _{3}}{f%
 }\left( \left( \theta _{2}+\theta _{3}+t\right) x-fy\right)  \\
=&\frac{\left( \theta _{1}-\theta _{2}\right) \left( \theta _{1}-\theta
_{3}\right) \left( \theta _{2}-\theta _{3}\right) }{f^{3}}\left( \left(
\theta _{1}+\theta _{2}+t\right) x-fy\right) \left( \left( \theta
_{1}+\theta _{3}+t\right) x-fy\right) \left( \left( \theta _{2}+\theta
_{3}+t\right) x-fy\right)  \\
=&\frac{\sqrt{discr\left( \phi \right) }}{f^{3}}\left( \left( \theta
_{1}+\theta _{2}+t\right) x-fy\right) \left( \left( \theta _{1}+\theta
_{3}+t\right) x-fy\right) \left( \left( \theta _{2}+\theta _{3}+t\right)
x-fy\right) \\
=&\sqrt{discr\left( \phi \right) }\left( \frac{t^{3}-2pt^{2}+\left(
p^{2}+q\right) t+\left( r-qp\right) }{f^{3}}x^{3}-\frac{3t^{2}-4pt+\left(
p^{2}+q\right) }{f^{2}}x^{2}y+\frac{3t-2p}{f}xy^{2}-y^{3}\right) 
\end{eqnarray*}

和输出

在此处输入图片描述

使用\begin{align*}方程超出了边距

在此处输入图片描述

答案1

您有太多无用的\left\right。您还应该使用split而不是eqnarray*。可以使用 来管理分数,\tfrac从而使其更小。

\documentclass[11pt,a4paper,oneside]{report} 
\usepackage[T1]{fontenc}
\usepackage{fouriernc}
\usepackage{mathtools}
\usepackage{amsthm}
\usepackage{amsfonts}
\usepackage{amssymb}

\begin{document}

\begin{equation*}
\begin{split}
N
&= \tfrac{\theta_{1}-\theta_{2}}{f}
     ((\theta_{1}+\theta_{2}+t) x-fy)\,
   \tfrac{\theta_{1}-\theta_{3}}{f}
     ((\theta_{1}+\theta_{3}+t) x-fy)\,
   \tfrac{\theta_{2}-\theta_{3}}{f}
     (( \theta_{2}+\theta_{3}+t) x-fy)
\\
&= \tfrac{(\theta_{1}-\theta_{2})(\theta_{1}-\theta_{3})(\theta_{2}-\theta_{3})}{f^{3}}
     ((\theta_{1}+\theta_{2}+t) x-fy)\,
     ((\theta_{1}+\theta_{3}+t) x-fy)\,
     ((\theta_{2}+\theta_{3}+t) x-fy)
\\
&= \tfrac{\sqrt{\mathit{discr}(\phi)}}{f^{3}}
     ((\theta_{1}+\theta_{2}+t) x-fy)\,
     ((\theta_{1}+\theta_{3}+t) x-fy)\,
     ((\theta_{2}+\theta_{3}+t)x-fy)
\\
&= \sqrt{\mathit{discr}(\phi)}
   \left(
     \tfrac{t^{3}-2pt^{2}+(p^{2}+q) t+(r-qp)}{f^{3}}x^{3}-
     \tfrac{3t^{2}-4pt+(p^{2}+q)}{f^{2}}x^{2}y+
     \tfrac{3t-2p}{f}xy^{2}-y^{3}
   \right)
\end{split}
\end{equation*}

\end{document}

在此处输入图片描述

答案2

以下是我的排版方式:

\documentclass{report}

\usepackage{amsmath}
\DeclareMathOperator{\discr}{discr}

\begin{document}

\noindent Let
\begin{equation*}
  g_{i,j}
  = (\theta_{i} + \theta_{j} + t)x - fy.
\end{equation*}
Then
\begin{align*}
  N
  &= \frac{\theta_{1} - \theta_{2}}{f}g_{1,2} \cdot
     \frac{\theta_{1} - \theta_{3}}{f}g_{1,3} \cdot
     \frac{\theta_{2} - \theta_{3}}{f}g_{2,3}\\
  &= \frac{(\theta_{1} - \theta_{2})
           (\theta_{1} - \theta_{3})
           (\theta_{2} - \theta_{3})}{f^{3}}
     \cdot g_{1,2} \, g_{1,3} \, g_{2,3}\\
  &= \frac{\sqrt{\discr(\phi)}}{f^{3}}
     \cdot g_{1,2} \, g_{1,3} \, g_{2,3}\\
  &= \sqrt{\discr(\phi)}
     \biggl(\frac{t^{3} - 2pt^{2} + (p^{2} + q)t + (r - qp)}{f^{3}}x^{3}\\
   &\hphantom{{}= \sqrt{\discr(\phi)}\biggl(}
    - \frac{3t^{2} - 4pt + (p^{2} + q)}{f^{2}}x^{2}y
    + \frac{3t - 2p}{f}xy^{2} - y^{3}\biggr)
\end{align*}

\end{document}

输出

请注意,我根本没有使用任何\left/\right结构。另外,下划线前的空格是不必要的,discr应该(可能)是一个数学运算符,并且eqnarray环境不太好

答案3

根据评论中的建议,您可以按如下所示进行编码

\documentclass[11pt,a4paper,oneside]{report} 
\usepackage[T1]{fontenc}
\usepackage{fouriernc}
\usepackage{mathtools}
\usepackage{amsthm}
\usepackage{amsfonts}
\usepackage{amssymb}
\begin{document}

\begin{align*}
N &=\frac{\theta _{1}-\theta _{2}}{f}\left( \left( \theta _{1}+\theta
 _{2}+t\right) x-fy\right) \frac{\theta _{1}-\theta _{3}}{f}\left( \left(
 \theta _{1}+\theta _{3}+t\right) x-fy\right) \frac{\theta _{2}-\theta _{3}}{f%
 }\left( \left( \theta _{2}+\theta _{3}+t\right) x-fy\right)  \\
&=\frac{\left( \theta _{1}-\theta _{2}\right) \left( \theta _{1}-\theta
_{3}\right) \left( \theta _{2}-\theta _{3}\right) }{f^{3}}\left( \left(
\theta _{1}+\theta _{2}+t\right) x-fy\right) \left( \left( \theta
_{1}+\theta _{3}+t\right) x-fy\right) \left( \left( \theta _{2}+\theta
_{3}+t\right) x-fy\right)  \\
&=\frac{\sqrt{discr\left( \phi \right) }}{f^{3}}\left( \left( \theta
_{1}+\theta _{2}+t\right) x-fy\right) \left( \left( \theta _{1}+\theta
_{3}+t\right) x-fy\right) \left( \left( \theta _{2}+\theta _{3}+t\right)
x-fy\right) \\
&=\sqrt{discr\left( \phi \right) }\left( \frac{t^{3}-2pt^{2}+\left(
p^{2}+q\right) t+\left( r-qp\right) }{f^{3}}x^{3}-\frac{3t^{2}-4pt+\left(
p^{2}+q\right) }{f^{2}}x^{2}y+\frac{3t-2p}{f}xy^{2}-y^{3}\right) 
\end{align*}

\end{document}

输出:

左调整

相关内容