在 ieeeconf 中定制定理、引理、定义等

在 ieeeconf 中定制定理、引理、定义等

我正在使用以下ieeeconf基于的模板:

\documentclass[letterpaper, 10 pt, conference]{ieeeconf}  % Comment this line out if you need a4paper

\IEEEoverridecommandlockouts                              % This command is only needed if 
                                                          % you want to use the \thanks command
\overrideIEEEmargins                                      % Needed to meet printer requirements.

\usepackage{graphics} % for pdf, bitmapped graphics files
\usepackage{epsfig} % for postscript graphics files
\usepackage{mathptmx} % assumes new font selection scheme installed
\usepackage{times} % assumes new font selection scheme installed
\usepackage{amsmath} % assumes amsmath package installed
\usepackage{amssymb}  % assumes amsmath package installed

\newtheorem{thm}{Theorem}[section]
\newtheorem{lem}[thm]{Lemma}
\newtheorem{prop}[thm]{Proposition}
\newtheorem{cor}{Corollary}
\newtheorem{defn}{Definition}[section]
\newtheorem{conj}{Conjecture}[section]
\newtheorem{exmp}{Example}[section]
\newtheorem{rem}{Remark}

\title{\LARGE \bf
My Title*
}

\author{Guy$^{1}$
\thanks{*This work was not supported by any organization}% <-this % stops a space
\thanks{$^{1}$Guy is with Hell,
        {\tt\small [email protected]}}%
}

\begin{document}

\maketitle
\thispagestyle{empty}
\pagestyle{empty}

\begin{abstract}

ABSTRACT

\end{abstract}

\section{INTRODUCTION}


\begin{thm}
My theorem is blaw.
\proof Here is the proof.
\end{thm}

\begin{lem}
My lemma is blaw.
\proof Here is the proof.
\end{lem}

\begin{defn}
Look at my definition.
\end{defn}

\begin{thebibliography}{99}

\bibitem{c1} G. O. Young, ÒSynthetic structure of industrial plastics (Book style with paper title and editor),Ó    in Plastics, 2nd ed. vol. 3, J. Peters, Ed.  New York: McGraw-Hill, 1964, pp. 15Ð64.


\end{thebibliography}

\end{document}

正如您可以编译 MWE 一样,我不喜欢我的逻辑环境的形成和风格,我想将它们更改为如下所示的内容:

enter image description here

enter image description here

(所有环境都需要用粗体表示,并用数字表示。引理和定理必须以黑色方块结尾,等等。)

\newtheoremstyle{plain}但是当我尝试使用包自定义样式时amsthm,会出现以下错误:

!LaTeX 错误:命令 \proof 已定义。

更新 1:添加\let\proof\relax并没有导致无错误的编译。

更新 2:@egreg 的回答仍然会在我的计算机上引发错误,如下所示:

enter image description here

更新 3:这是我的IEEEconf日志文件中的版本:Document Class: ieeeconf 2016/4/23 revision V1.6b by Pradeep Misra

答案1

  1. 类名IEEEconf第一部分大写。ieeeconf在 Windows 上可以调用它,但在其他系统上则不行

  2. 这个epsf包不应该在新文档中使用。如果会议上的人告诉你要这么做,那他们就落后了二十年。

  3. 不要在任何文档中使用。像论点中的\bf格式说明只会让文字编辑感到厌烦。\LARGE\title

  4. times之后加载mathptmx是多余的(甚至可能是危险的)。

  5. \IEEEoverridecommandlockouts并且\overrideIEEEmargins在的当前版本中没有定义IEEEconf

  6. amsthm在课堂上加载IEEEconf是完全没问题的。

主要问题是你如何调用proof:它不应该是

\begin{thm}
My theorem is blaw.
\proof Here is the proof.
\end{thm}

\begin{thm}
My theorem is blaw.
\end{thm}
\begin{proof}
Here is the proof.
\end{proof}

这是一个经过修改以便可编译的示例。

\documentclass[letterpaper, 10pt, conference]{IEEEconf}

\usepackage{graphicx}
\usepackage{mathptmx}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{amsthm}

\renewcommand{\qedsymbol}{$\blacksquare$}

\newtheorem{thm}{Theorem}[section]
\newtheorem{lem}[thm]{Lemma}
\newtheorem{prop}[thm]{Proposition}
\newtheorem{cor}{Corollary}
\newtheorem{conj}{Conjecture}[section]
\theoremstyle{definition}
\newtheorem{defn}{Definition}[section]
\newtheorem{exmp}{Example}[section]
\newtheorem{rem}{Remark}

\title{My Title*}

\author{Guy$^{1}$
\thanks{*This work was not supported by any organization}% <-this % stops a space
\thanks{$^{1}$Guy is with Hell, {\tt\small [email protected]}}%
}

\begin{document}

\maketitle
\thispagestyle{empty}
\pagestyle{empty}

\begin{abstract}

ABSTRACT

\end{abstract}

\section{INTRODUCTION}


\begin{thm}
My theorem is blaw.
\end{thm}
\begin{proof}
Here is the proof.
\end{proof}

\begin{lem}
My lemma is blaw.
\end{lem}
\begin{proof}
Here is the proof.
\end{proof}

\begin{defn}
Look at my definition.
\end{defn}

\begin{thebibliography}{99}

\bibitem{c1} G. O. Young, ÒSynthetic structure of industrial plastics (Book style with paper title and editor),Ó    in Plastics, 2nd ed. vol. 3, J. Peters, Ed.  New York: McGraw-Hill, 1964, pp. 15Ð64.


\end{thebibliography}

\end{document}

enter image description here

答案2

我遇到了完全相同的问题。我的解决方案是\let\proof\relax \let\endproof\relax在之前添加\usepackage{amsthm}

边注: 官方版本IEEE 通讯可以在纸广场。这个版本似乎IEEEconf 2009/04/05 v1.4 IEEE Computer Society 8.5x11只针对计算机科学协会,而且风格与我所指的版本不同。在文件中ieeeconf.cls有一个部分叫做环境您可以在其中看到正在定义的命令。

相关内容