I'm working a document that has one (very large) chapter, in which theorems, lemmas, etc. are numbered with subsubsection, i.e. the start of the document has the command


However, the document also has some short chapters, in which theorems etc. are numbered with subsection. At the moment, the only way I can do this is to also define a theorem_ at the beginning of the document:


and use theorem sometimes and theorem_ other times. This seems like an ugly hack, and I'd love it if there were some way I could use \begin{theorem}...\end{theorem} throughout the document, and use some command at the start of each chapter to determine whether theorems were numbered with subsection or subsubsection. Is this possible?

1 Answer 1


You could use


immediately before the chapter you wish you change.

% arara: pdflatex







Changing the numbering convention part way through a document could cause confusion to your reader. How many theorems do you have? Does the numbering need to go so deep? Just some thoughts :)

  • 1
    Otherwise you can use \counterwithin{theorem}{subsection} from the package chngcntr. Commented Sep 5, 2013 at 17:34
  • I'm well aware that changing the numbering convention could cause confusion - the problem is, I don't have control over the numbering. And the document is ~150 pages, so yes, the numbering does need to that deep. Thanks for this nice solution though! Commented Sep 5, 2013 at 22:25
  • In the OP's intention, theorem shares the subsubsection counter, it's not subordinate to it. So there's no \thetheorem
    – egreg
    Commented Sep 5, 2013 at 22:25
  • @egreg thanks for pointing that out. in which case karlkoeller's idea seems more appropriate
    – cmhughes
    Commented Sep 6, 2013 at 0:55

You must log in to answer this question.

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