[Tex/LaTex] Roman numerals at the bottom

header-footer

I'm quite struggling with footers. After hours spent trying to customize usepackage{fancyhdr} and pagestyle{fancy}, I decided to create as simple document as possible. Something reminding picture below.

enter image description here

Unfortunately, when I use

\documentclass[a4paper,12pt,titlepage,oneside,final]{book}
\begin{document}

\frontmatter
\begin{titlepage}
{\bf Titlepage}
\end{titlepage}

\newpage
\thispagestyle{empty}
{\bf included pdf}

\newpage
{\bf declaration}

\newpage
{\bf Acknowledgement}

\newpage
\thispagestyle{empty}
{\bf included pdf}

\tableofcontents


\mainmatter
\chapter*{introduction}
\addcontentsline{toc}{chapter}{introduction}

\chapter{1st chapter}

\end{document}

two problems occur:

1) Roman numerals (i – iv) are placed in the header, on the right. Maybe it's more convenient, I'm not sure – I would rather put them at the bottom if possible.

2) Final .pdf file starts with 1 instead of i (or nothing for titlepage). I would expect pages to be denoted by Arabic numerals since Introduction.

Do you have any clue? Thanks for your time!

Best Answer

Does this produce the result you are looking for?

\documentclass[a4paper,12pt,titlepage,oneside,final]{book}
\usepackage{fancyhdr}
  \fancyhf{}
  \renewcommand{\headrulewidth}{0pt}
  \fancyhf[cf]{\thepage}
  \pagestyle{fancy}

\begin{document}

\frontmatter
\begin{titlepage}
{\bf Titlepage}\thispagestyle{empty}
\end{titlepage}
\pagenumbering{roman}
\stepcounter{page}% comment if the titlepage should not be counted

\newpage
\thispagestyle{empty}
{\bf included pdf}

\newpage
{\bf declaration}

\newpage
{\bf Acknowledgement}

\newpage
\thispagestyle{empty}
{\bf included pdf}

\tableofcontents


\mainmatter
\chapter*{introduction}
\pagenumbering{arabic}
\addcontentsline{toc}{chapter}{introduction}

\chapter{1st chapter}

\end{document}

This omits the number on the title page and included pdfs but counts them. (Comment the relevant line if you don't want to count the title page.)

title page, first included pdf, first numbered page shows 'iii' next three pages with included pdfs unnumbered but counted introduction starts arabic page numbering with '1'

EDIT: This does leave one problem which is not to do with the page numbering of the pages as such but, rather, with the way they are designated in a PDF viewer. Although the page shows 'iii', for example, the viewer will call this '3'. And although the introduction is labelled '1', the viewer will refer to it as '7'.

To address this, we need to use a package designed for dealing with electronic versions of documents rather than merely printed ones. hyperref will address this problem and bookmark may optionally be loaded for enhanced, but more experimental, handling of bookmarks.

The following code produces the same visual output on the page but persuades the PDF viewer to label the pages correctly. This version also updates the deprecated commands identified by Harish Kumar in the comments.

\documentclass[a4paper,12pt,titlepage,oneside,final]{book}
\usepackage{hyperref}
%\usepackage{bookmark}%  uncomment for enhanced, but experimental, bookmark handling
\usepackage{fancyhdr}
  \fancyhf{}
  \renewcommand{\headrulewidth}{0pt}
  \fancyhf[cf]{\thepage}
  \pagestyle{fancy}

\begin{document}

\frontmatter
\begin{titlepage}
{\bfseries Titlepage}\thispagestyle{empty}% note use of \bfseries replacing obsolete \bf command
\end{titlepage}
\pagenumbering{roman}
\stepcounter{page}% comment if the titlepage should not be counted

\clearpage% replaces deprecated \newpage
\thispagestyle{empty}
{\bfseries included pdf}

\clearpage
{\bfseries declaration}

\clearpage
{\bfseries Acknowledgement}

\clearpage
\thispagestyle{empty}
{\bfseries included pdf}

\tableofcontents


\mainmatter
\chapter*{introduction}
\pagenumbering{arabic}
\addcontentsline{toc}{chapter}{introduction}

\chapter{1st chapter}

\end{document}