如何才能使 A 组和 B 组之间的水平线更粗,而不会干扰括号?为了实现这一点,我是否需要使用其他方法来获取括号?
\documentclass[11pt]{article}
\usepackage{amsmath,tabularx,ragged2e}
\newcolumntype{C}[1]{>{\Centering}m{#1}}
\begin{document}
\[
\begin{array}{r}
\begin{tabular}{|C{24pt}!{\vrule width1pt}C{20pt}|C{20pt}|}
\hline
a&b&c\\ \noalign{\hrule height1pt}
\end{tabular}\\
\llap{\hbox{group A}}
\left\{
\begin{tabular}{|C{24pt}!{\vrule width1pt}C{20pt}|C{20pt}|}
1&2&3\\\hline
4&5&6\\\hline
\end{tabular}
\right.\kern-\nulldelimiterspace\\
\llap{\hbox{group B}}
\left\{
\begin{tabular}{|C{24pt}!{\vrule width1pt}C{20pt}|C{20pt}|}
7&8&9\\\hline
7&8&9\\\hline
\end{tabular}
\right.\kern-\nulldelimiterspace
\end{array}
\]
\end{document}
答案1
使用包Xhline
中定义的makecell
:
\documentclass[11pt]{article}
\usepackage{amsmath}
\usepackage{ragged2e}
\usepackage{makecell,tabularx} % <---
\newcolumntype{C}[1]{>{\Centering}m{#1}}
\begin{document}
\[
\begin{array}{r}
\begin{tabular}{|C{24pt}!{\vrule width1pt}C{20pt}|C{20pt}|}\hline
a&b&c\\
\Xhline{1pt} % <---
\end{tabular}\\
\llap{\hbox{group A}}\left\{\begin{tabular}{|C{24pt}!{\vrule width1pt}C{20pt}|C{20pt}|}
1&2&3\\ \hline
4&5&6\\ \Xhline{1pt} % <---
\end{tabular}\right.\kern-\nulldelimiterspace\\
\llap{\hbox{group B}}\left\{\begin{tabular}{|C{24pt}!{\vrule width1pt}C{20pt}|C{20pt}|}
7&8&9\\\hline
7&8&9\\\hline
\end{tabular}\right.\kern-\nulldelimiterspace
\end{array}
\]
\end{document}