如何增加表格标题行的宽度并使内容保持在行的中心?

如何增加表格标题行的宽度并使内容保持在行的中心?
\documentclass[11pt]{elsarticle}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{tabularx}
\usepackage{array}
\makeatletter
\newcommand{\thickhline}{%
    \noalign {\ifnum 0=`}\fi \hrule height 1pt
    \futurelet \reserved@a \@xhline
}
\newcolumntype{"}{@{\hskip\tabcolsep\vrule width 1pt\hskip\tabcolsep}}
\makeatother
\begin{document}
    
\begin{table}[ht]
    \caption{Overview of notation} \label{tab:notation_TC} \centering \resizebox{5cm}{!}{% 
        \begin{tabular}{l  l }
            %   {
            \thickhline
            
            \bf Notation & \bf Description \\ [0.75ex]
            \hline
            hey & hello\\
        
            \thickhline
    \end{tabular}}
\end{table} 
\end{document}

在此处输入图片描述

答案1

您可以尝试新的 LaTeX3 包tabularray

\documentclass{article}

\usepackage{caption}
\usepackage{tabularray}

\begin{document}

\begin{table}[ht]
  \caption{Overview of notation}
  \label{tab:notation_TC}
  \centering
  \begin{tblr}{colspec={ll},row{1}={m,1cm,font=\bfseries}}
    \hline[2pt]    
      Notation &  Description \\
    \hline
      Hey      & Hello \\
    \hline[2pt]
  \end{tblr}
\end{table} 

\end{document} 

在此处输入图片描述

答案2

在此处输入图片描述

\documentclass[11pt]{elsarticle} 
\usepackage{booktabs} 
\begin{document} 
\begin{table}[ht] 
\caption{Overview of notation} 
\label{tab:notation_TC} 
\centering  
% \small % uncomment for a smaller font size in the table
\begin{tabular}{ll} 
\toprule 
\bfseries Notation & \bfseries Description\\ 
\midrule 
hey & hello\\ 
\bottomrule 
\end{tabular} 
\end{table}  
\end{document}

相关内容