TeX - LaTeX Asked on December 6, 2020
documentclass{article}
usepackage{lipsum}
usepackage{multicol}
usepackage{nccmath}
begin{document}
setlength{columnseprule}{0.4pt}
begin{multicols}{2}
begin{equation} a = a end{equation}
columnbreak % why does this columnbreak insert vspace?
begin{equation} a = a end{equation}
end{multicols}
begin{multicols}{2}
begin{equation} a = a end{equation}
begin{equation} a = a end{equation}
end{multicols}
end{document}
Inserting an empty line in-front of the columnbreak
makes it look the same.
Answered by josh on December 6, 2020
You can set, locally, multicolsep
to 0pt. However, it would be simpler to use tabularx
: I propose to define a newcolumn type with cells contents automatically in the equation environment, making the typing very simple:
documentclass{article}
usepackage{lipsum}
usepackage{multicol}
usepackage{nccmath}
usepackage{tabularx}
makeatletter
newcommand*{compress}{@minipagetrue}
makeatother
newcolumntype{E}{@{}>{compressequation}X<{endequation}@{}}
begin{document}
lipsum[11]
setlength{columnseprule}{0.4pt}
{setlength{multicolsep}{0pt}
begin{multicols}{2}
begin{equation} a = a end{equation}
columnbreak % why does this columnbreak insert vspace?
begin{equation} a = a end{equation}
end{multicols}
begin{multicols}{2}
begin{equation} a = a end{equation}
begin{equation} a = a end{equation}
end{multicols}
}
vspace{4ex}
{centeringbelowdisplayskip=0pt
begin{tabularx}{textwidth}{@{}E@{enspace}|@{enspace}E@{}}
a = a & a = a [-1ex]
a = a & a = a
end{tabularx}
}
end{document}
Answered by Bernard on December 6, 2020
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP