방정식 한 줄만 표시하려는 경우 정렬 환경과 방정식 환경의 차이점은 무엇입니까?

방정식 한 줄만 표시하려는 경우 정렬 환경과 방정식 환경의 차이점은 무엇입니까?

저는 물리학 문서를 조판하고 있는데 때로는 여러 줄의 방정식을 입력해야 하지만 대부분의 경우 한 줄의 공식만 입력하면 됩니다. 그러면 과 의 차이점이 무엇인지 align전환하는 대신 항상 환경을 사용해도 괜찮을까요 ?alignequation

답변1

그만큼수직의간격은 다르지만 특정 경우에만 눈에 띕니다. 이를 확인하려면 이러한 디스플레이 주위에 텍스트를 넣을 수 있는 가능한 모든 방법을 고려하십시오.

여기에 이미지 설명을 입력하세요

\documentclass{article}
\usepackage{amsmath}
\setlength{\parindent}{0pt}% Just for this example
\begin{document}

Long/long line before/after display:

\begin{minipage}[t]{.5\textwidth}
  Lorem ipsum.
  \begin{equation}
    f(x) = ax^2 + bx + c
  \end{equation}
  Lorem ipsum.
\end{minipage}%
\begin{minipage}[t]{.5\textwidth}
  Lorem ipsum.
  \begin{align}
    f(x) = ax^2 + bx + c
  \end{align}
  Lorem ipsum.
\end{minipage}

\hrulefill

Long/short line before/after display:

\begin{minipage}[t]{.5\textwidth}
  Lorem ipsum.
  \begin{equation}
    f(x) = ax^2 + bx + c
  \end{equation}
  Lrm.
\end{minipage}%
\begin{minipage}[t]{.5\textwidth}
  Lorem ipsum.
  \begin{align}
    f(x) = ax^2 + bx + c
  \end{align}
  Lrm.
\end{minipage}

\bigskip

\hrulefill

\bigskip

Short/long line before/after display:

\begin{minipage}[t]{.5\textwidth}
  Lrm:
  \begin{equation}
    f(x) = ax^2 + bx + c
  \end{equation}
  Lorem ipsum.
\end{minipage}%
\begin{minipage}[t]{.5\textwidth}
  Lrm:
  \begin{align}
    f(x) = ax^2 + bx + c
  \end{align}
  Lorem ipsum.
\end{minipage}

\hrulefill

Short/short line before/after display:

\begin{minipage}[t]{.5\textwidth}
  Lrm:
  \begin{equation}
    f(x) = ax^2 + bx + c
  \end{equation}
  Lrm.
\end{minipage}%
\begin{minipage}[t]{.5\textwidth}
  Lrm:
  \begin{align}
    f(x) = ax^2 + bx + c
  \end{align}
  Lrm.
\end{minipage}

\end{document}

위의 내용은 표시 직전/뒤에 긴/짧은 텍스트 조각의 모든 조합 사용을 보여줍니다. 왼쪽 열은 an의 사용을 나타내고 equation오른쪽 열은 an과 동등한 것을 사용함을 나타냅니다 align. 이는 TeX의 표시 건너뛰기 사용에 영향을 미칩니다.

\abovedisplayskip% If the line ending above the display is not short
\abovedisplayshortskip% ... If the line ending above the display is short
\belowdisplayskip% If the line ending below the display is not short
\belowdisplayshortskip% ... If the line ending below the display is short

줄이 짧은 게 분명해~ 위에 alignequation는 (식 (5) 및 (7)과 관련하여 식 (6) 및 (8) 위의 더 큰 건너뛰기를 비교) 의 것과 다르게 해석됩니다 .

하지만 이것이 전부는 아니며, 위의 이미지는 그런 의미에서 약간 오해의 소지가 있습니다. s가 op 가 아닌 오토톰 minipage에 정렬된 경우[b][t]

여기에 이미지 설명을 입력하세요

건너뛰어도 알 수 있을 거예요아래에align디스플레이 다음 줄이 짧을 경우 다르게 해석됩니다 .


안에 단일 방정식을 사용해도 괜찮습니까 align? 물론, 당신이 그 모습에 만족한다면요. 주변 텍스트를 사용하면 디스플레이 양쪽에 긴("짧지 않은") 줄이 있을 것으로 예상할 수 있으며, 이 경우 위의 방정식 (1)-(4) align와 유사하게 "수행"됩니다 .equation

답변2

의견에 명시된 바와 같이 유일한 차이점은 수식의 간격입니다. equation가능하다면, 그리고 align여러 줄 수식이 있을 때 사용하도록 시도해야 합니다 .

또한: 환경 내부 equation에 오류가 발생하므로 &둘 사이를 변환할 때 주의하세요.

관련 정보