Latex: How can I create nested lists which look this 1.1, 1.1.1, 1.1.2, 1.2

How can I create lists which look this:

1. Topic
1.1 First Subtopic
1.2 Second Subtopic

I tried using the enumeration list

\begin{enumerate}
\item Topic
\begin{enumerate}
\item First Subtopic
\item Second Subtopic
\end{enumerate}
\end{enumerate}

But the output looks like:

1. Topic
  (a) First Subtopic
  (b) Second Subtopic

So how can I get the list? Is there another list evironment or maybe an extra package?


Solution 1:

You can use enumitem package:

\documentclass{article}
\usepackage{enumitem}
\begin{document}

\begin{enumerate}
  \item Topic
  \begin{enumerate}[label*=\arabic*.]
    \item First Subtopic
    \item Second Subtopic
    \begin{enumerate}[label*=\arabic*.]
      \item First Sub-Subtopic
      \item Second Sub-Subtopic
    \end{enumerate}
  \end{enumerate}
\end{enumerate}

\end{document}

See the catalog entry for enumitem for more.

Solution 2:

See: http://www.giss.nasa.gov/tools/latex/ltx-222.html

The numbering style for the enumeration is determined by the commands, \labelenumi, \labelenumii, etc., for the nested levels. These may be redefined with the \renewcommand command.

For example, to use upper case letters for the first level and lower case letters for the second level of enumeration:

\renewcommand{\labelenumi}{\Alph{enumi}}
\renewcommand{\labelenumii}{\alph{enumii}}

And here: http://www.mackichan.com/index.html?techtalk/484.htm~mainFrame

... The concrete commands would be

\renewcommand{\labelenumi}{\arabic{enumi}.} 
\renewcommand{\labelenumii}{\arabic{enumi}.\arabic{enumii}}

Or, if you think your content qualifies as sections, use something like:

\section{Name}
...
\subsection{Subtopic}
...
\subsubsection{Yet another nesting}
...

Solution 3:

No need to use any additional package

\begin{enumerate}
   \item[1.] Topic
   \begin{enumerate}
       \item[1.1] First Subtopic
       \item[1.2] Second Subtopic
    \end{enumerate}
\end{enumerate}