如何为大型矩阵添加换行符?我的矩阵太大,右侧可能会被淹没

如何为大型矩阵添加换行符?我的矩阵太大,右侧可能会被淹没

在此处输入图片描述

\documentclass{article}

\begin{document}
\[\left(
\begin{array}{ccccc}
 0 & 0 & 1 & 0 & 0 \\
 0 & 0 & 0 & 1 & 0 \\
 \frac{\epsilon  m_w^2 x_t}{6 \epsilon ^2-7 \epsilon +2} & 0 & 0 & 0 & 0 \\
 0 & \frac{\epsilon  m_w^2 \left(x_t-1\right){}^2}{\left(6 \epsilon ^2-7 \epsilon
   +2\right) \left(x_t+1\right)} & \frac{2 (\epsilon -1)}{(3 \epsilon -2)
   \left(x_t+1\right)} & \frac{2 (\epsilon -1) x_t}{(3 \epsilon -2)
   \left(x_t+1\right)} & -\frac{2 (\epsilon -1) m_w^2 x_t}{(3 \epsilon -2)
   \left(x_t+1\right)} \\
 0 & -\frac{\epsilon  \left(\epsilon ^3+\epsilon ^2+\epsilon -2\right)
   \left(x_t-1\right)}{\left(6 \epsilon ^5-\epsilon ^4+\epsilon ^3+\epsilon ^2-5
   \epsilon +2\right) \left(x_t+1\right)} & \frac{-2 \epsilon ^4 x_t+3 \epsilon 
   \left(x_t-1\right)-2 x_t+2}{\left(3 \epsilon ^4+\epsilon ^3+\epsilon
   ^2+\epsilon -2\right) m_w^2 \left(x_t-1\right) x_t \left(x_t+1\right)} &
   \frac{-2 \epsilon ^4 x_t+3 \epsilon  \left(x_t-1\right)-2 x_t+2}{\left(3
   \epsilon ^4+\epsilon ^3+\epsilon ^2+\epsilon -2\right) m_w^2 \left(x_t-1\right)
   \left(x_t+1\right)} & \frac{2 \epsilon ^4 x_t-3 \epsilon  x_t+2 x_t+3 \epsilon
   -2}{\left(3 \epsilon ^4+\epsilon ^3+\epsilon ^2+\epsilon -2\right)
   \left(x_t-1\right) \left(x_t+1\right)} \\
\end{array}
\right)\]
\end{document}

答案1

跟进@daleif 的评论和建议:如果你想给自己一个半体面的机会,让你的读者真正费心仔细查看这 9 个分数表达式,你最好将它们分开显示,按照下面显示的答案的想法说。

请注意,可以用 来表示和a_{44};类似地,和可以表示为 的函数。(您的读者可能会很高兴得知这一点。)a_{45}a_{43}a_{54}a_{55}a_{53}

我肯定会删除所有 21 个 [!] 对\left\right大小指令,尤其是因为它们没有任何用处;但它们确实弄乱了间距。在下面的代码中,我还将 env align*. 封装在一个spreadlines环境中,以将 env. 行之间的行距增加到align*默认值的 6pt。

在此处输入图片描述

\documentclass{article}
\usepackage{mathtools} % for 'spreadlines' env; load 'amsmath' automatically
\allowdisplaybreaks % allow page breaks in long display-math env.s
\begin{document}
\[
A=
\begin{pmatrix}
 0 & 0      & 1 & 0 & 0 \\
 0 & 0      & 0 & 1 & 0 \\
 a_{31} & 0 & 0 & 0 & 0 \\
 0 & a_{42} & a_{43} & a_{44} & a_{45} \\
 0 & a_{52} & a_{53} & a_{54} & a_{55} 
\end{pmatrix}
\]
where 
%% Increase spacing between lines 
%% (increase value of "\jot" from 3pt to 6pt)
\begin{spreadlines}{6pt} 
\begin{align*}
a_{31} &= \frac{\epsilon m_w^2 x_t}{6\epsilon^2-7\epsilon +2} \\
a_{42} &= \frac{\epsilon m_w^2 (x_t-1){}^2}{(6\epsilon^2-7\epsilon +2) (x_t+1)} \\
a_{43} &= \frac{2 (\epsilon -1)}{(3\epsilon -2)(x_t+1)} \\
a_{44} %&= \frac{2 (\epsilon -1) x_t}{(3\epsilon -2) (x_t+1)}  \\*
       &=  a_{43}x_t\\
a_{45} %&= -\frac{2 (\epsilon -1) m_w^2 x_t}{(3\epsilon -2)(x_t+1)} \\*
       &= -m_w^2 a_{44}\\
a_{52} &= -\frac{\epsilon (\epsilon^3+\epsilon^2+\epsilon -2) (x_t-1)}{(6\epsilon^5-\epsilon^4+\epsilon^3+\epsilon^2-5\epsilon +2) (x_t+1)} \\
a_{53} &= \frac{-2\epsilon^4 x_t+3\epsilon (x_t-1)-2 x_t+2}{(3\epsilon^4+\epsilon^3+\epsilon^2+\epsilon -2) m_w^2 (x_t-1) x_t (x_t+1)} \\
a_{54} %&= \frac{-2\epsilon^4 x_t+3\epsilon (x_t-1)-2 x_t+2}{(3\epsilon^4+\epsilon^3+\epsilon^2+\epsilon -2) m_w^2 (x_t-1)(x_t+1)} \\*
       &= a_{53}x_t \\
a_{55} %&= \frac{-(2\epsilon^4 x_t+3\epsilon (x_t-1)-2 x_t+2)}{(3\epsilon^4+\epsilon^3+\epsilon^2+\epsilon -2)(x_t-1) (x_t+1)} \\*
       &= -m_w^2 a_{54}
\end{align*} 
\end{spreadlines}
\end{document}

相关内容