10

Because I'm not a native speaker and I'm sure so far noone understood it I will try to explain it in simple words... I'm writing a thesis for my bachelor so it's just around 30 pages... Now I made a definition for some commands like this:

\newtheorem{theo}{Theorem}[chapter]

\newtheorem{lema}{Lemma}[chapter]

\theoremstyle{definition}
\newtheorem{defin}{Definition}[chapter]

\theoremstyle{plain}
\newtheorem{cor}{Corollar}[chapter]

This works great; However e.g. if I'm in chapter 2 and use commands like this:

\cor
\cor
\defin
\lema

it counts like this:

Corollar 2.1 
Corollar 2.2
Definition 2.1
Lemma 2.1

However it doesn't make sense to start an own numbering for corollar, definiton, lemma etc. because the thesis is very short and for this reason it would be more confusing than helping; So I want it to be like this:

Corollar 2.1 
Corollar 2.2
Definition 2.3
Lemma 2.4

Any idea how to do that?

1
  • 1
    Incindental to your question, but you should be writing \begin{cor}...\end{cor}. Just putting \cor is roughly equivalent to \begin{cor} but will leave with an unclosed group. Dec 15, 2015 at 8:32

1 Answer 1

7

As explained there you can try this :

\usepackage{amsthm}
\theoremstyle{plain}
\newtheorem{theo}{Theorem}[chapter] % reset theorem numbering per chapter

\theoremstyle{definition}
\newtheorem{defin}[theo]{Definition} % definition numbers are dependent on theorem numbers
\newtheorem{lema}[theo]{Lemma} % same for  Lemmas
\newtheorem{cor}[theo]{Corollar}% same for Corollars
2
  • What do I do, when I do not have theorems but only would like to have section depending numbered definitions?
    – baxbear
    Nov 9, 2021 at 15:18
  • You could try something like \renewcommand{\thedef}{\arabic{section}.\arabic{defin}} as suggested here : tex.stackexchange.com/questions/63231/… for theorems Nov 10, 2021 at 19:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.