1

I am using the thmtools and thm-restate packages so that I can restate theorems and propositions. I use the \declaretheorem command as follows:

\declaretheorem[name=Theorem, numberwithin=section]{theorem}
\declaretheorem[name=Proposition, numberwithin=section]{proposition}

However, in the document I do not have propositions and theorems having the same counter. For instance, as the code currently is, I will end up with output like this:

Proposition 1.1

Proposition 1.2

Theorem 1.1

However, I want it to be like:

Proposition 1.1

Proposition 1.2

Theorem 1.3.

How do I do this?

1 Answer 1

2

In the thmtools documentation (§ 3.2 Known keys to \declaretheorem) we find

sibling Value: a counter name. The theorem will use this counter for numbering. Usually, this is the name of another theorem environment.
numberlike (Same as sibling.)
sharenumber (Same as sibling.)

You can thus use the sibling key:

\documentclass{article}

\usepackage{thmtools}
\declaretheorem[name=Theorem,numberwithin=section]{theorem}
\declaretheorem[name=Proposition,sibling=theorem]{proposition}

\begin{document}

\section{Text}
\begin{proposition}
Foo.
\end{proposition}
\begin{proposition}
Bar.
\end{proposition}
\begin{theorem}
Baz.
\end{theorem}

\end{document}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .