页面顶部有“目录”

页面顶部有“目录”

我不知道它从何而来,但有些页面的左上角显示“目录”。我想让问题更具体一些,但我不知道它从何而来。有些页面(如第 4、6 和 10 页)左上角有“目录”,但那里没有意义!

如果我删除该命令\tableofcontents它就会消失。

您知道这取决于什么吗?

第一页:

\documentclass[oneside,a4paper,12pt]{book}
%\usepackage{titling}

\usepackage{amssymb}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\usepackage{geometry}
\usepackage[parfill]{parskip}
\usepackage{amsfonts}
\usepackage{graphicx}
\usepackage{array}
\usepackage[section]{placeins}


\usepackage{amsmath}
%\usepackage{fontspec}
\usepackage{listings}
%\newfontfamily\listingsfont[Scale=.7]{Arial}
\usepackage{color} %red, green, blue, yellow, cyan, magenta, black, white
\definecolor{mygreen}{RGB}{28,172,0} % color values Red, Green, Blue
\definecolor{mylilas}{RGB}{170,55,241}
\definecolor{mygray}{RGB}{150,17,176}
\usepackage{setspace}
%\usepackage[]{mcode}

\bibliographystyle{agsm} 
\geometry{
    a4paper,
    total={170mm,257mm},
    left=30mm,
    right=30mm,
    top=15mm,
}
\makeatletter
\renewcommand\@biblabel[1]{}
\makeatother
\newcommand{\expe}{\mathbb{E}}
\newcommand{\alphat}{\bm{\alpha}_t}
\newcommand{\alphahatt}{\hat{\bm{\alpha}}_{t|t-1}}
\newcommand{\esset}{\vec{s}_t}
\newcommand{\essehatt}{\hat{\vec{s}}_{t|t-1}}
\usepackage{amsthm}
\usepackage{bm}
\renewcommand{\baselinestretch}{1.5} 
\theoremstyle{plain}
\newtheorem{thm}{Theorem}[chapter] % reset theorem numbering for each chapter
\newcommand{\vect}[1]{\boldsymbol{#1}}
\theoremstyle{definition}
\newtheorem{defn}[thm]{Definition} % definition numbers are dependent on theorem numbers
\newtheorem{exmp}[thm]{Example} % same for example numbers
\let\vec\mathbf
\DeclareMathSizes{12}{13}{10}{10}

\renewcommand{\contentsname}{Table of Contents}
\begin{document}

\lstset{language=Matlab,%
    omissis}

\author{Omissis}
\title{Omissis}

\thispagestyle{empty}
\date{Omissis}
\frontmatter
\maketitle
\tableofcontents
\vspace*{\fill}
 Powered with \LaTeX
\mainmatter
\include{./TeX_files/chapter01}
\include{./TeX_files/chapter02}
\include{./TeX_files/chapter2b}
\include{./TeX_files/chapter03}
\backmatter
\include{./TeX_files/appendix}


% bibliography, glossary and index would go here.

\begin{thebibliography}{9}

    omissis
\end{thebibliography}


\end{document}

它回忆起这些:

\newcommand{\mychapter}[2]{
    \setcounter{chapter}{#1}
    \setcounter{section}{0}
    \chapter*{#2}
    \addcontentsline{toc}{chapter}{#2}
}


    \mychapter{0}{Acknowledgments}
    \mychapter{2}{test}
\section{test}
test test test
\section{test}
\mychapter{3}{test}

我尝试尽可能简化

相关内容