14

I use \documentclass[12pt, a4paper]{report} for my thesis. I have three parts, each with an abstract. Whenever I put an abstract, the page numbering resets to 1. I would like to continue with the numbering it had before placing the abstract.

Minimum working example:

\documentclass[12pt, a4paper]{report}

\begin{document}
\title{title}
\maketitle
\tableofcontents

\chapter*{Introduction}
\addcontentsline{toc}{part}{Introduction}

 Introduccion

\part{Part 1}
\begin{abstract}
abstract
\end{abstract}

Part1

\part{part 2}
\begin{abstract}
abstract
\end{abstract}

Part2

\part{3}
\begin{abstract}
abstract
\end{abstract}


\end{document}
lockstep
  • 250,273
Juan
  • 141

2 Answers2

11

It depends on the option of the class titlepage. The default setting is titlepage=true. You can do two things:

\documentclass[12pt, a4paper,notitlepage]{report}

Or redefine abstract:

\makeatletter
\renewenvironment{abstract}{%
  \if@twocolumn
    \section*{\abstractname}%
  \else
    \small
    \begin{center}%
      {\bfseries \abstractname\vspace{-.5em}\vspace{\z@}}%
    \end{center}%
    \quotation
  \fi}
  {\if@twocolumn\else\endquotation\fi}
\makeatother
Marco Daniel
  • 95,681
  • Your first suggestion works fine \documentclass[12pt, a4paper,notitlepage]{report} but I get numbering on the title page too. The second option \makeatletter \@titlepagefalse \makeatother does not work for me. – Juan May 10 '11 at 16:07
  • I changed my answer. Sorry – Marco Daniel May 10 '11 at 16:21
  • Could you please explain what the notitlepage option does? – StrawberryFieldsForever Apr 30 '13 at 15:14
  • @StrawberryFieldsForever With this option you decide whether the environment titlepage is used or not`. The environment starts a new page and end this page. It also put in onecolumn mode whether you are working with twocolumn or not. – Marco Daniel Apr 30 '13 at 16:13
1

You can patch the titlepage environment. abstract uses titlepage (if the class option titlepage is set, which it seemingly is for the report class) and titlepage sets the page counter to 1 (in \begin and \end).

\usepackage{etoolbox}
\makeatletter
\patchcmd{\titlepage}{\setcounter{page}\@ne}{}     {}{\PackageError{titlepage}{failed to patch \string\begin{titlepage} to not reset the page counter}{}}
\patchcmd{\endtitlepage}{\setcounter{page}\@ne}{}  {}{\PackageError{titlepage}{failed to patch \string\end{titlepage} to not reset the page counter}{}}
\makeatother

See \show\abstract and \show\titlepage.

jakun
  • 5,981