小节标题中的粗体符号

小节标题中的粗体符号

我在我的文本中使用以下命令,没有问题,但它在小节标题中不起作用,

\boldsymbol{\mathrm{tr}}

\documentclass[10pt, twocolumn, twoside, journal]{IEEEtran}
\usepackage{amsmath, amsfonts, amssymb, color, enumerate, amsthm, graphicx, arydshln, algorithm}
\begin{document}
\section{Main}
My contents ...
\subsection{Trace ($\boldsymbol{\mathrm{tr}}(W_c)$)}
\end{document}

答案1

我不会做“tr”大胆的IEEEtran文档类不会将子节级标题排版为粗体;那么,为什么要对公式的某些部分使用粗体呢?相反,我会定义(并使用)一个名为的数学运算符\tr

在此处输入图片描述

如果你只是必须排版“tr”大胆的,我建议你\DeclareMathOperator{\tr}{tr}改为\DeclareMathOperator{\tr}{\mathbf{tr}}

\documentclass[10pt, twocolumn, twoside, journal]{IEEEtran}
\usepackage{amsmath, amssymb, xcolor, enumerate, 
            amsthm, graphicx, arydshln, algorithm}
\DeclareMathOperator{\tr}{tr}
\usepackage{newtxtext,newtxmath} % optional

\begin{document}
\section{Main}
My contents \dots
\subsection{Trace of the Controllability Gramian Matrix, $\tr(W_{\!c})$}
\end{document}

相关内容