2009年8月15日 星期六

Theorem envirenment

作者: hantis (呢呢是豬) 看板: Hantis
標題: [隨寫] Technical Notes: theorem enviorenment
時間: Sat Aug 15 22:52:59 2009


   Example, Lemma, Exercise,...
   這些都是 theorem environment
   大部分的shell都內定讓他們用同一個counter
   所以不加設定的話會 Example 1, Lemma 2, Exercise 3, ...
   但是我們通常會希望
   Example 1, Example 2, ..., Lemma 1, Lemma 2, ...

   要獨立count的只需在preamble的地方稍作修改
   例如要讓Example獨立count則
   \newtheorem{example}[theorem]{Example}
                                          擦掉即可

   有時候我們甚至希望以章節來重設某個theorem environment的counter
   例如想要以section為單位來得到
   Exercise 1.1, Exercise 1.2, ...
   則除了跟上面一樣擦掉[theorem]之外
   在最後面加上[section]
   所以變成
   \newtheorem{exercise}{Exercise}[section]

沒有留言:

張貼留言