W3cubDocs

/LaTeX

\subsection

Synopsis, one of:

\subsection{title}
\subsection*{title}
\subsection[toc-title]{title}

Start a subsection. The standard LaTeX classes article, book, and report all have this command.

This produces a subsection.

We will show that there are more functions than Turing machines and that
therefore some functions have no associated machine.

\subsection{Cardinality} We will begin with two paradoxes that
dramatize the challenge to our intuition posed by comparing the sizes of
infinite sets.

For the standard LaTeX classes book and report the default output is like ‘1.2.3 title’ (for chapter 1, section 2, subsection 3), alone on its line and flush left, in boldface and a larger type (the type size is \large). The same holds in article except that there are no chapters in that class so it looks like ‘2.3 title’.

The * form shows title. But it does not show the subsection number, does not increment the subsection counter, and produces no table of contents entry.

The optional argument toc-title will appear as the subsection title in the table of contents (see Table of contents etc.). If it is not present then title will be there. This shows the full text in the title of the subsection,

\subsection[$\alpha,\beta,\gamma$ paper]{\textit{The Origin of
  Chemical Elements} by R.A.~Alpher, H.~Bethe, and G.~Gamow}

but only ‘α,β,γ paper’ on the contents page.

For determining which sectional units are numbered and which appear in the table of contents, the level number of a subsection is 2 (see Sectioning/secnumdepth and see Sectioning/tocdepth).

The paragraph that follows the subsection title is not indented, as is a standard typographical practice. One way to get an indent is to use the package indentfirst.

There are a number of ways to change the behavior of the \subsection command. One is the \@startsection command (see \@startsection). There are also many packages on CTAN that address this, including titlesec. See the documentation but the example below gives a sense of what they can do.

\usepackage{titlesec}   % in preamble
\titleformat{\subsection}[runin]
  {\normalfont\normalsize\bfseries}  % format of the title
  {\thesubsection}                   % label
  {0.6em}                            % space between label and title
  {}                                 % before-code hook

That puts the subsection number and title in the first line of text.

© 2007–2018 Karl Berry
Public Domain Software
http://latexref.xyz/_005csubsection.html