
다음 MWE에서는 A와 B 행렬이 완벽하게 정렬됩니다. 그러나 행렬 C는 오른쪽으로 정렬됩니다. 왼쪽으로 정렬하는 방법은 무엇입니까?
\begin{multline}
A=
\begin{bmatrix}
0 & 1 & 0 & \cdots & 0\\
0 & 0 & 1 & \cdots & 0 \\
\vdots & \vdots & \vdots & \ddots & \vdots\\
0 & 0 & 0 & \cdots & 1 \\
-q_{0}&-q_{1}&-q_{2}&\cdots&-q_{n-1}
\end{bmatrix}
,\,\,
B=
\begin{bmatrix}
0 \\
0 \\
\vdots \\
b_e
\end{bmatrix}
\\
C =
\begin{bmatrix}
1 &b_1/b_0 &\cdots &b_{n-1}/b_0
\end{bmatrix}
\end{multline}
답변1
행 행렬이 상단 블록을 기준으로 중앙에 위치하도록 할 수 있습니다.
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{equation}
\begin{gathered}
A=\begin{bmatrix}
0 & 1 & 0 & \cdots & 0\\
0 & 0 & 1 & \cdots & 0 \\
\vdots & \vdots & \vdots & \ddots & \vdots\\
0 & 0 & 0 & \cdots & 1 \\
-q_{0}&-q_{1}&-q_{2}&\cdots&-q_{n-1}
\end{bmatrix}
,\quad
B=\begin{bmatrix} 0 \\ 0 \\ \vdots \\ b_e \end{bmatrix}
\\[2ex]
C = \begin{bmatrix} 1 & b_1/b_0 & \cdots & b_{n-1}/b_0 \end{bmatrix}
\end{gathered}
\end{equation}
\end{document}
등호를 정렬하려면 다음을 사용하십시오 aligned
.
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{equation}
\begin{aligned}
A&=\begin{bmatrix}
0 & 1 & 0 & \cdots & 0\\
0 & 0 & 1 & \cdots & 0 \\
\vdots & \vdots & \vdots & \ddots & \vdots\\
0 & 0 & 0 & \cdots & 1 \\
-q_{0}&-q_{1}&-q_{2}&\cdots&-q_{n-1}
\end{bmatrix}
,\quad
B=\begin{bmatrix} 0 \\ 0 \\ \vdots \\ b_e \end{bmatrix}
\\[2ex]
C&=\begin{bmatrix} 1 & b_1/b_0 & \cdots & b_{n-1}/b_0 \end{bmatrix}
\end{aligned}
\end{equation}
\end{document}
답변2
align*
대신 사용하십시오 multiline
. 일부 정렬 탭을 추가합니다.
언급했듯이 multiline
정렬이 제공되지 않습니다. 나는 그 의도가 마치 긴 방정식의 연속인 것처럼 두 번째 줄을 오른쪽 정렬하는 것이라고 추측합니다.
\documentclass{article}
\usepackage{amsmath}
%\usepackage{unicode-math}
\begin{document}
\begin{align*}
A&=
\begin{bmatrix}
0 & 1 & 0 & \cdots & 0\\
0 & 0 & 1 & \cdots & 0 \\
\vdots & \vdots & \vdots & \ddots & \vdots\\
0 & 0 & 0 & \cdots & 1 \\
-q_{0}&-q_{1}&-q_{2}&\cdots&-q_{n-1}
\end{bmatrix}
,\,\,
B=
\begin{bmatrix}
0 \\
0 \\
\vdots \\
b_e
\end{bmatrix}
\\[8pt]
C &=
\begin{bmatrix}
1 &b_1/b_0 &\cdots &b_{n-1}/b_0
\end{bmatrix}
\end{align*}
\end{document}
또한 대신 \,\,
를 으로 대체하면 행렬 &
앞에 간격이 더 추가됩니다 B
.