# Interference of Geometry and counter of the page number

I'm having troubles with the geometry package, it seems that every time that I reset the pagenumber to one, the geometry package treats it like it's the first page of the document. Now this is rather inconvenient since I use the geometry package to get a bindingoffset.

So each time I rest my pagenumber to 1, the bindingoffset gets set to the left (even if it isn't the first page, or any uneven page).

I also checked and it's not because of the titlepage-environment that the error occurs (notice that I also reset the page numbering for my bibliography).

Warning, there is a bibliography in there, so be aware of that while compiling (i left it in the document to show that it also does this error at the end).

supplementary (related) question: Is there a way to reset the internal counter of the geometry package ? To force geometry to treat even numbered pages as right handed ones and uneven numbered pages as left handed ones starting from a given point in the tex-file ?

\documentclass[a4paper,11pt]{article}
\author{Some author}
\title{Some title}
\date{Some date}

\usepackage[english]{babel}
\usepackage{lipsum}

\begin{document}
\pagenumbering{Roman}
\begin{titlepage}
\maketitle
\begin{abstract}
\lipsum[1-3]
\end{abstract}
\tableofcontents
\thispagestyle{empty}
\end{titlepage}
\pagenumbering{arabic}
\setcounter{page}{1}

\section{The Section Manace}
\lipsum[5-10]
\section{Attack of the Sections}
\lipsum[11-17]
\section{Revenge of the Section}
\lipsum[18-24]
\section{A New Section}
\lipsum[25-30]
\section{The Section Strikes Back}
\lipsum[31-32]
\section{Return of the Section}
\lipsum[33-36]

\newpage
\setcounter{page}{1}
\pagenumbering{roman}

\bibliographystyle{unsrt}
\bibliography{LGT}

\end{document}

• Isn't this just a default of a twoside document? That odd pages (including the first) get an appropriately-sided bindingoffset? – Werner May 3 '14 at 17:28
• @Werner Yes (otherwise it would be a silly format indeed), but the problem is that whenever I reset my pagenumber to one, the geometry package treats it like it's an odd-numbered page (even if it might be even numbered). – Nick May 3 '14 at 17:35
• Why might an odd-numbered page be even numbered"? Because you should issue a \cleardoublepage so you're always on the right side. Otherwise you'll be flip-flopping between odd/even on left/right, which isn't good. – Werner May 3 '14 at 17:37
• @Werner, What I'm trying to do (in the enlisted document) is to make an article where I have a titlepage (1 page) and then start with the article. Now I have removed the numbering of the titlepage and resetted this to 1 when starting the article. The problem is that it's going to be printed as a double-sided document and the bindingoffset got resetted after the resetting of the page numbering. So now it gives a binding offset in the wrong direction in the article itself. – Nick May 3 '14 at 17:42
• @Nick If it's a double side document, odd numbers should be on right hand pages. Note that geometry has nothing to do with this. Note also that it's normal that the wider margin is the outer one. – egreg May 3 '14 at 17:45

If you really want to ignore time honored conventions, according to which the right hand pages are odd numbered, just do the following:

\pagenumbering{Roman}

\begin{titlepage}
\maketitle
\begin{abstract}
\lipsum[1-3]
\end{abstract}
\tableofcontents
\thispagestyle{empty}
\end{titlepage}

\clearpage % always clear the page before \pagenumbering
\pagenumbering{arabic}

\setcounter{page}{0}
\renewcommand{\thepage}{\the\numexpr\value{page}+1\relax}

\section{The Section Manace}

• thanks a lot for this nice answer. I will certainly use it if I want to ignore the time honored conventions ;). My problem was the fact that I used the titlepage-environment, apperantly geometry doesn't count titlepages which is why my bindingoffset was off with one page. – Nick May 3 '14 at 18:09
• @Nick No, geometry has nothing to do with this. It just sets up the parameters that LaTeX uses for pagination. It's LaTeX that uses \oddsidemargin and \evensidemargin respectively on pages where the page counter has an odd or even value respectively. – egreg May 3 '14 at 18:13
• I indeed noticed when I started compiling, thanks for the answer it's real helpfull and completely solved my problem! – Nick May 3 '14 at 18:14