Latex: Numbered Subsubsections

LaTex lets you break the document down into chapters, sections, subsections, subsubsections and paragraphs. By default subsubsections and paragraphs are not numbered or included in the table of contents. Sometimes this might be desirable. However, I usually find that in cases when I do not need them numbered, I usually never use them (ie. my documents are broken down by chapter, section, and subsection only). At other times, when I desire more granularity, I actually want subsubsections to show up in the TOC and have distinctive headings and numbers.

To enable this you will need to put 2 lines of code somewhere in your preamble:

\setcounter{secnumdepth}{3}
\setcounter{tocdepth}{3}

The first line enables numbering of subsubsections. The second line includes subsubsections in the table of contents.

Btw, if you need to break down your document even more you can switch 3 to 4 in these lines to enable numbering for paragraphs.

[tags]latex, subsubsection, paragraph, section, numbering, tex[/tags]

This entry was posted in programming and tagged . Bookmark the permalink.



27 Responses to Latex: Numbered Subsubsections

  1. Shimul BANGLADESH Mozilla Firefox Windows says:

    your subsubsection was helpful

    And the whole blog is good

    Totally great

    Good job

    :D

    Reply  |  Quote
  2. Alice CANADA Mozilla Firefox Windows says:

    This was totally helpful! Thanks so much :)

    Reply  |  Quote
  3. Dweia DENMARK Mozilla Firefox Linux says:

    Very useful! I found I needed to number my subsubsection and this was just the thing! Thanks!

    Reply  |  Quote
  4. Sandro ITALY Mozilla Firefox Windows says:

    Good job!! Thanks

    Reply  |  Quote
  5. Volpe ITALY Mozilla Firefox Mac OS says:

    Thank you, this was very helpful :)

    Reply  |  Quote
  6. Maya Aviv ISRAEL Mozilla Firefox Windows says:

    thank you. it was very useful.
    Maya
    M.Sc student at Tel-Aviv university.

    Reply  |  Quote
  7. nachiket INDIA Mozilla Firefox Windows says:

    Thanks a lot. It solved my problem

    Reply  |  Quote
  8. Ne GERMANY Internet Explorer Windows says:

    Thank you very much. It is helpful to me.

    Reply  |  Quote
  9. Mohammed khalid SAUDI ARABIA Safari Windows says:

    Thanks a lot. I was looking for this info.

    Reply  |  Quote
  10. wa GERMANY Mozilla Firefox Windows says:

    thanks! helped me out

    Reply  |  Quote
  11. Yen CZECH REPUBLIC Mozilla Firefox Windows says:

    Hi, thanks a lot ;-)
    After that my subsubsection are “lettered” instead of numbered in TOC. There is a chance to change it to number?
    Example:
    I have \subsubsection (Hello) and it appears in TOC like
    5.1.2 Greetings
    b) Hello

    And I need it like: 5.1.2.1 Hello :-/

    I do not use \Chapter level, my first level is \Section…

    Thanks for any help :-)

    Reply  |  Quote
  12. Pingback: Let’s Learn LaTex: Part 2 « Terminally Incoherent WordPress

  13. Yen CZECH REPUBLIC Mozilla Firefox Windows says:

    Thanks,
    I spend more time with uncle google :-) and after that I checked our diploma report for sure but there I found info about leveling for thesis and everything is alright.
    But I appreciate that, thanks again. :-)

    Reply  |  Quote
  14. artem CZECH REPUBLIC Internet Explorer Windows says:

    Very helpful. Thanks a lot! :-)

    Reply  |  Quote
  15. Daniel SWEDEN Mozilla Firefox Linux says:

    Very helpful. It was what I was looking for. Thanks

    Reply  |  Quote
  16. shyam UNITED STATES Google Chrome Windows says:

    Thanks a lot for such useful information

    Reply  |  Quote
  17. Sebnem Er TURKEY Google Chrome Windows says:

    Thanks a million… very clear instructions…

    Reply  |  Quote
  18. santi novani JAPAN Internet Explorer Windows says:

    thanks a lot. it was very helpful

    Reply  |  Quote
  19. Student NORWAY Google Chrome Windows says:

    Thanks a lot! :)

    Reply  |  Quote
  20. Matt UNITED KINGDOM Mozilla Firefox Linux says:

    Great! Thanks :)

    Reply  |  Quote
  21. Liviu ROMANIA Google Chrome Mac OS says:

    Hey, thanks.
    Great post: short and straight to the point.
    That’s the answer I’ve been looking for. Got my problem solved now.

    Reply  |  Quote
  22. D Mandal Mozilla Firefox Windows says:

    Dear All,
    I am facing problem in getting correct Figure No. in Latex. I am using the following code for subfigures:

    \begin{figure}[htpb]
    \centering
    \subfloat[$1$mm]{\label{fig:LIT1}\includegraphics[width=0.22\textwidth  ]{LIT_1mm}}
    \hfill
    \subfloat[$3$mm]{\label{fig:LIT3}\includegraphics[width=0.22\textwidth  ]{LIT_3mm}}
    \hfill
    \subfloat[$5$mm]{\label{fig:LIT5}\includegraphics[width=0.22\textwidth  ]{LIT_5mm}}
    \hfill
    \subfloat[$10$mm]{\label{fig:LIT10}\includegraphics[width=0.22\textwid th]{LIT_10mm}}
    \caption{Photographs of Li$_2$TiO$_3$ pebbles.}
    \label{fig:packingLIT}
    \end{figure}

    and the following code for Figures without sub-figures,

    \begin {figure}[htbp]
    \centering
    \includegraphics[width=0.95\textwidth  ]{TG_Li2CO3_f}
    \caption{TG-DTA curves of Li$_2$CO$_3$ decomposition. Temperature was ramped at $10^oC/$min.}
    \label{fig:TGLi2CO3}
    \end{figure}

    I want somebody’s help,

    D. Mandal
    IndiaD Mandal wrote:

    Previewed comment:
    Dear All,
    I am facing problem in getting correct Figure No. in Latex. I am using the following code for subfigures:
    \begin{figure}[htpb]
    \centering
    \subfloat[$1$mm]{\label{fig:LIT1}\includegraphics[width=0.22\textwidth  ]{LIT_1mm}}
    \hfill
    \subfloat[$3$mm]{\label{fig:LIT3}\includegraphics[width=0.22\textwidth  ]{LIT_3mm}}
    \hfill
    \subfloat[$5$mm]{\label{fig:LIT5}\includegraphics[width=0.22\textwidth  ]{LIT_5mm}}
    \hfill
    \subfloat[$10$mm]{\label{fig:LIT10}\includegraphics[width=0.22\textwid th]{LIT_10mm}}
    \caption{Photographs of Li$_2$TiO$_3$ pebbles.}
    \label{fig:packingLIT}
    \end{figure}
    and the following code for Figures without sub-figures,
    \begin {figure}[htbp]
    \centering
    \includegraphics[width=0.95\textwidth  ]{TG_Li2CO3_f}
    \caption{TG-DTA curves of Li$_2$CO$_3$ decomposition. Temperature was ramped at $10^oC/$min.}
    \label{fig:TGLi2CO3}
    \end{figure}
    I want somebody’s help,
    D. Mandal
    India

    Reply  |  Quote
  23. Eduardo Oportus Safari Mac OS says:

    Thank You so much! It was very helpful.

    Reply  |  Quote
  24. Marcus Mozilla Firefox Ubuntu Linux says:

    thank you! So simple and good :)

    Reply  |  Quote
  25. Marcus Mozilla Firefox Ubuntu Linux says:

    @ santi novani:
    You are using Internet Explorer?

    Reply  |  Quote
  26. Torben Google Chrome Linux says:

    Good job, thanks sir!

    Reply  |  Quote
  27. James MEXICO Google Chrome Windows says:

    Thank you!!!!!

    Reply  |  Quote

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>