\chapter 文档类报告中未定义控制序列

\chapter 文档类报告中未定义控制序列

我在命令 \chapter{Introduction} 中收到“未定义控制序列”错误,我在 overleaf 上使用以下设置:

\documentclass[12pt]{report}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\graphicspath{ {Figures/} }
\usepackage[english]{babel}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{a4}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{braket}
\usepackage{mathtools}
\usepackage{enumerate}
%\usepackage{mathrsfs,upref}
%\usepackage{mathptmx}  
\usepackage{book tabs}
\usepackage[nottoc,numbib]{tocbibind}





\usepackage[margin=1in]{geometry}% Just for this example
\usepackage{parcolumns,lipsum}


%Declaring packages for figures, TikZ-cd

\usepackage{wrapfig}
\usepackage{pgfplots}
\usepackage{placeins}
\pgfplotsset{compat=1.15}
\usepackage{mathrsfs}
\usetikzlibrary{arrows}
\DeclareMathOperator{\Ima}{Im}
\usepackage{tikz-cd}


\usetikzlibrary{patterns}
\usepackage{amsfonts}
\usetikzlibrary{decorations.markings}
\tikzset{->-/.style={decoration={
  markings,
  mark=at position #1 with {\arrow{>}}},postaction={decorate}}}
\usepackage{capt-of}
\usepackage{asymptote}





\usepackage{lipsum} % for filler text
\makeatletter
\renewcommand{\@makechapterhead}[1]{%
    \vspace*{50\p@}%
    {\parindent \z@ \centering \largefont
    \hrule
    \vspace{12pt}%
    \ifnum \c@secnumdepth >\m@ne
    \Huge\bfseries \@chapapp\space \thechapter
        \par\nobreak
        \vskip 20\p@
    \fi
    \interlinepenalty\@M
    \Huge \bfseries #1\par
    \vspace{10pt}%
    \hrule
    \vskip 40\p@
}}
\renewcommand{\@makeschapterhead}[1]{%
    \vspace*{50\p@}%
    {\parindent \z@ \centering
    \normalfont
    \hrule
    \vspace{12pt}%
    \interlinepenalty\@M
    \Huge \bfseries #1\par
    \vspace{10pt}%
    \hrule
    \vskip 40\p@
}}
\makeatother



\newtheorem{theorem}{Theorem}[section]
\newtheorem{prop}[theorem]{Proposition}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{corol}[theorem]{Corollary}

\theoremstyle{definition}
\newtheorem{definition}{Definition}[section]
\newtheorem{remark}{Remark}
\newtheorem{example}{Example}[section]

\newcommand\restr[2]{\ensuremath{\left.#1\right|_{#2}}}
\newcommand{\norm}[1]{\left\lVert#1\right\rVert}

\makeatletter
\renewenvironment{proof}[1][\proofname]{%
  \par\pushQED{\qed}\normalfont%
  \topsep6\p@\@plus6\p@\relax
  \trivlist\item[\hskip\labelsep\bfseries#1\@addpunct{.}]%
  \ignorespaces
}{%
  \popQED\endtrivlist\@endpefalse
}
\makeatother

 
\usepackage[framemethod=tikz]{mdframed}
\mdfdefinestyle{proofstyle}{%
%linecolor=red,
middlelinewidth=2pt,%
frametitlerule=true,%
apptotikzsetting={\tikzset{mdfframetitlebackground/.append style={%
shade,left color=white, right color=blue!20}}},
frametitlerulecolor=green!60,
frametitlerulewidth=1pt,
innertopmargin=\topskip,
}
\mdtheorem[style=proofstyle]{proof}{Proof}

\newenvironment{boxedd}
    {\begin{center}
    \begin{tabular}{|p{0.9\textwidth}|}
    \hline\\
    }
    { 
    \\\\\hline
    \end{tabular} 
    \end{center}
    }



\begin{document}

\tableofcontents{}
\thispagestyle{empty}

\chapter{Introduction}

\pagenumbering{arabic}
\setcounter{page}{1}

\end{document}

请相应地指导我。谢谢

相关内容