When using the LaTeX class siamltx
(from the SIAM page) together with amsthm (which I need for its theoremstyle
command), I'm getting the error message
! LaTeX Error: No counter 'Theorem' defined.
The following code reproduces the error.
\documentclass{siamltex}
\let\proof\relax
\let\endproof\relax
\usepackage{amsthm}
\begin{document}
\begin{theorem}
dasdas
\end{theorem}
\end{document}
Any way around this?
Best Answer
This class already defines the theorem environment, but
amsthm
redefines some (but not all) of the internal commands used in that definition (notably\@thm
). This completely messes things up. For this reason,amsthm
cannot be loaded undersiamltex.cls
. Sometimes, loading the package before the document class works. This can be done withUnfortunately, the reverse problem occurs:
siamltex
redefines an internal macro ofamsthm
's version of thetheorem
environment (\@begintheorem
) and messes it up.The only work-around is not to use these two together. The class defines the various theorem-like environments already, as well as the
proof
environment, and does so in the ways the SIAM publishers chose, so there seems to be no reason foramsthm
.