I have a problem when I typeset my document. The document class is book
. I added the List of Figures to Table of Contents manually using following command:
\newpage
\phantomsection\label{listoffig}
\addcontentsline{toc}{chapter}{List of Figures}
\listoffigures
The Table of Contents itself contains of 3 pages and started at page xii. The List of Figures appears at page xv. However, the Table of Contents showed that the List of Figures is at page xiii (which is wrong).
I have also tried this command:
\cleardoublepage
\phantomsection
\addcontentsline{toc}{chapter}{List of Figures}
\listoffigures
but the problem still occurs. Every page number within the Table of Contents is correct, except for the List of Figures. Strangely, when I open the .toc files, the page number for the List of Figures is correct (it showed xv).
Update: I still unable to fix the problem, now the Table of Contents page number is incorrect within the Table of Contents itself, here is the example of what I have done so far.
\documentclass[12pt,a4paper,final,titlepage,onecolumn,openright,oneside]{book}
\usepackage{amsfonts}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{amstext}
\usepackage{color}
\usepackage{enumerate}
\usepackage{eurosym}
\usepackage{fancyhdr}
\usepackage{geometry}
\usepackage{graphicx}
\usepackage{indentfirst}
\usepackage{makeidx}
\usepackage{nomencl}
\usepackage[onehalfspacing]{setspace}
\usepackage{theorem}
\usepackage{ulem}
\usepackage[debug]{hyperref}
\setcounter{MaxMatrixCols}{10}
\newtheorem{theorem}{Theorem}[section]
\newtheorem{acknowledgement}[theorem]{Acknowledgement}
\newtheorem{algorithm}[theorem]{Algorithm}
\newtheorem{axiom}[theorem]{Axiom}
\newtheorem{case}[theorem]{Case}
\newtheorem{claim}[theorem]{Claim}
\newtheorem{conclusion}[theorem]{Conclusion}
\newtheorem{condition}[theorem]{Condition}
\newtheorem{conjecture}[theorem]{Conjecture}
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{criterion}[theorem]{Criterion}
\newtheorem{definition}[theorem]{Definition}
\newtheorem{example}[theorem]{Example}
\newtheorem{exercise}[theorem]{Exercise}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{notation}[theorem]{Notation}
\newtheorem{problem}[theorem]{Problem}
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{remark}[theorem]{Remark}
\newtheorem{solution}[theorem]{Solution}
\newtheorem{summary}[theorem]{Summary}
\newenvironment{proof}[1][Proof]{\noindent\textbf{#1.} }{\ \rule{0.5em}{0.5em}}
\topmargin=0.4 cm\headsep=0.5 cm \textwidth=15cm
\textheight=22.5cm\oddsidemargin=1.5cm
\geometry{left=3.5cm,right=2.5cm,top=2.5cm,bottom=2.5cm}
\def\contentsname{Contents}
\renewcommand{\bibname}{Reference}
\pagestyle{fancy}
\lhead{}
\chead{}
\rhead{\\
hepage}
\lfoot{}
\cfoot{}
\rfoot{}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}
\begin{document}
\frontmatter
\thispagestyle{empty}
\begin{center}
\begin{figure}\begin{center}
\end{center}\end{figure}
\renewcommand
{\baselinestretch}{1}
\textsc{\Large{GREAT UNIVERSITY}}\\
\bigskip\bigskip\bigskip\bigskip
\textsc{\large{TRANSLATION OF SEVERAL LOGICS \\
TO ANOTHER LOGICS}}
\bigskip
\vspace{0.7 in}
\textsc{THESES}\\
\bigskip
\normalsize
\textsc{Submitted as A Partial Fulfillment\\
to Obtain Master Degree\\
In Mathematics}
\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip
\textsc{Harry McKenzie}\\
\textrm{99999}\\
\vfill
\vfill
\vfill
\vfill
\textsc{SCHOOL OF MATH AND CS}\\
\textsc{GRADUATE PROGRAM IN MATH} \\
\textsc{ANTARTICA}\\
\textsc{1998}\\
\bigskip
\end{center}
\chapter{Approval Page}
\chapter{Preface}
\chapter{Abstract}
\cleardoublepage
\phantomsection
\tableofcontents
\addcontentsline{toc}{chapter}{Report Contents} \markboth{Report Contents}{\textbf{Reports Contents}}
\cleardoublepage
\phantomsection
\addtocontents{lof}{\protect\addcontentsline{toc}{chapter}{Figures}}
\listoffigures
\mainmatter
\chapter{Introduction}
\section{Background}
\subsection{The Importance of This Topic}
\subsection{An Example in The Real World}
\subsection{Related Work}
\section{Problem Identification}
\section{Goal of This Project}
\section{Outline of This Project}
\section{Some Mathematical Preliminaries}
\subsection{Set Theory}
\subsection{Order Theory}
\chapter{A Variant of The Logic A and B}
\section{Informal Syntax and Semantics}
\section{Formal Syntax of Logic A and B}
\subsection{Formal Syntax of Logic A}
\subsection{Formal Syntax of Logic B}
\section{Formal Semantics of Logic A and B}
\subsection{Formal Semantics of Logic A}
\subsection{Formal Semantics of Logic B}
\section{Two Specific Variants}
\chapter{Logic 1 and Logic 2}
\section{Logic 1}
\subsection{Syntax of Logic 1}
\subsection{Semantics of Logic 1}
\subsection{A Variant of Logic 1}
\subsection{The Satisfiability Problem of Logic 1}
\section{Logic 2}
\subsection{Syntax of Logic 2}
\subsection{Semantics of Logic 2}
\subsection{The Satisfiability Problem of Logic 2}
\chapter{Translations}
\section{The First Translations}
\subsection{First Model Construction}
\subsection{First Translation Construction}
\subsection{The First Algorithm}
\subsection{Size Propagation}
\section{The Second Translations}
\subsection{Second Model Construction}
\subsection{Second Translation Construction}
\subsection{The Second Algorithm}
\subsection{Size Propagation}
\section{Some Concluding Remarks}
\chapter{The Decidability of The Logic}
\section{Computable Mapping and Mapping Reduction}
\section{The Reduction}
\section{Some Concluding Remarks}
\chapter{Conclusions and Future Works}
\section{Conclusion}
\section{Future Works}
\appendix
\chapter{The Appendix}
\backmatter
\cleardoublepage
\phantomsection
\addcontentsline{toc}{chapter}{Reference}
\begin{thebibliography}{Gr\"{a}11}
\bibitem[All83]{All83}
\bibitem[All84]{All84}
\bibitem[BGMS07]{BGMS07}
\bibitem[BGMS09]{BGMS09}
\bibitem[BHH07]{BHH07}
\bibitem[BM05]{BM05}
\bibitem[BMSS08]{BMSS08}
\bibitem[BMSS11]{BMSS11}
\bibitem[Bro97]{Bro97}
\bibitem[CH98]{CH98}
\bibitem[CH04]{CH04}
\bibitem[GMS03]{GMS03}
\bibitem[GMS04]{GMS04}
\bibitem[Gr\"{a}11]{Gra11}
\bibitem[HH07]{HH07}
\bibitem[HR04]{HR04}
\bibitem[KJJ03]{KJJ03}
\bibitem[LPS95]{LPS95}
\bibitem[Mar03]{Mar03}
\bibitem[Mei07]{Mei07}
\bibitem[Nel11]{Nel11}
\bibitem[OD08]{OD08}
\bibitem[Rab00]{Rab00}
\bibitem[RB06]{RB06}
\bibitem[Ros07]{Ros07}
\bibitem[SC85]{SC85}
\bibitem[Sip06]{Sip06}
\bibitem[SS94]{SS94}
\bibitem[Vit05]{Vit05}
\bibitem[VKvB89]{VKvB89}
\end{thebibliography}
\end{document}
\tableofcontents
followed by\addcontentsline{toc}{chapter}{Report Contents} \markboth{Report Contents}{\textbf{Reports Contents}}
. Not the other way around. Then I obtain the correct page numbering in the ToC.