Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

LaTeX Numbering Problems

  1. Dec 14, 2009 #1
    Hi. I'm writing a project and am using a template latex document with the idea being that i don't have to worry about the preamble etc and also so that includes important stuff automatically like university and degree name etc.

    anyway, in my preamble i have:

    \newtheorem{lemma}{Lemma}
    \newtheorem{theorem}[lemma]{Theorem}
    \newtheorem{corollary}[lemma]{Corollary}
    \theoremstyle{definition}
    \newtheorem{definition}[lemma]{Definition}
    \theoremstyle{remark}
    \newtheorem{remark}[lemma]{Remark}
    \newtheorem{example}[lemma]{Example}

    and i have been using the definition environment of this and it's working fine except for the numbering. for example in section 1.1 of my document i have definition 1, definition 2 and definition 3. then i go to section 1.2 and get definition 4. this is going to be a long project so by the time i finish i'll be getting things like definition 80!

    i think it would look more professional (tell me if you disagree though!) if i could get the definitions in section 1.1 to be definition 1.1.1, definition 1.1.2 and deifnition 1.1.3 and then in section 1.2 have definition 1.2.1

    does anybody know how to do this?

    all help appreciated
    thanks
     
  2. jcsd
  3. Dec 14, 2009 #2

    cristo

    User Avatar
    Staff Emeritus
    Science Advisor

    Try this: \numberwithin{equation}{section} in your preamble. Not sure whether that will work for theorems, though...
     
  4. Dec 14, 2009 #3
    hey. thanks for the reply. it works for tidying up the numbering of my equations but the definitions are still unchanged. any other recommendations?

    cheers.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: LaTeX Numbering Problems
  1. LaTeX problem (Replies: 8)

  2. Problems with LaTeX (Replies: 4)

Loading...