[Tex/LaTex] First column of multicols introduces an unwanted vertical space when first element is displaymath

multicolspacingvertical alignment

Code:

\documentclass{article}
\usepackage{multicol}

\begin{document}
\begin{multicols}{3}
  \[ \rho^1 = \left(\begin{array}{ccccc}1&2&3&4&5\\2&4&5&1&3\end{array}\right) \]
  \[ \rho^2 = \left(\begin{array}{ccccc}1&2&3&4&5\\4&1&3&2&5\end{array}\right) \]
  \[ \rho^3 = \left(\begin{array}{ccccc}1&2&3&4&5\\1&2&5&4&3\end{array}\right) \]
  \[ \rho^4 = \left(\begin{array}{ccccc}1&2&3&4&5\\2&4&3&1&5\end{array}\right) \]
  \[ \rho^5 = \left(\begin{array}{ccccc}1&2&3&4&5\\4&1&5&2&3\end{array}\right) \]
  \[ \rho^6 = \left(\begin{array}{ccccc}1&2&3&4&5\\1&2&3&4&5\end{array}\right) \]
\end{multicols}
\end{document}

Output:

output

Can I remove the vertical space in the first column?

Best Answer

It isn't actually vertical space it is a horizontal box of paragraph text. You always get this if you start a paragraph with display math (which is why you should never do it). If you start display math in vertical mode TeX recovers by starting a paragraph then inserting the paragraph indentation box and horizontal \parfillskip glue then breaking the partial paragraph.

What this means is that you can do

\begin{multicols}{3}\noindent

To avoid the problem, but really you shouldn't be in the situation anyway.

enter image description here