Please my first theorem which I want it to be Theorem 1.1 happens to be in Chapter 2 and as thus it reads Theorem 2.1 as opposed what I want. I mean Theorem 1.1, please how can I change this? By always defining what I want in the theorem number and sections.
-
2The (composed) number after “Theorem” is supposed to help readers into finding it. What would be the meaning of the first 1, given that the theorem is in chapter 2?– egregMay 14 at 16:15
-
I'm working for someone and he claims since it is the first theorem to appear in the project, it should be tagged Theorem 1.1 despite it appearing on the second chapter.– MemristorMay 14 at 16:22
-
And what about the following theorems?– egregMay 14 at 16:27
-
2@Memristor -- 1.1 doesn't make any sense. Just a single number, 1, would make sense, and then just number equations consecutively through the document. Maybe you could try some logical persuasion.– barbara beetonMay 14 at 16:28
-
@egreg. The following theorems can then follow as Theorem 1.2, Theorem 1.3, . . . in that order.– MemristorMay 14 at 20:15
1 Answer
This is completely illogical, but the customer's always right. 😉
\documentclass{book}
\usepackage{amsthm}
\newcommand{\thechapterminusone}{\the\numexpr\value{chapter}-1\relax}
\newtheorem{theorem}{Theorem}[chapter]
\renewcommand{\thetheorem}{\thechapterminusone.\arabic{theorem}}
\begin{document}
\chapter{First}
\chapter{Second}
\begin{theorem}\label{test}
Some people have weird requirements.
\end{theorem}
\begin{proof}
See the numbering of theorem~\ref{test}.
\end{proof}
\end{document}
Just remove the definition of \thetheorem
if logic becomes active again.
-
Thank you so much, sir. So, how will the Lemma, Examples and the rest will now go? May 15 at 9:34
-
@Memristor It depends on whether they're numbered autonomously or share the counter with theorems.– egregMay 15 at 10:28
-
-
@Memristor If you are satisfy with the answer, then kindly accept it by clicking the
tick
mark symbol Jun 14 at 5:15