summaryrefslogtreecommitdiff
path: root/macros/latex/contrib
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2020-02-19 03:02:04 +0000
committerNorbert Preining <norbert@preining.info>2020-02-19 03:02:04 +0000
commitc36a274c633c08115b6006622112f5609031001e (patch)
treee0935730aa90d6cd1427245dbb6e996fc331de94 /macros/latex/contrib
parentbb5325dae4202b519b7210a338651301e048998d (diff)
CTAN sync 202002190302
Diffstat (limited to 'macros/latex/contrib')
-rw-r--r--macros/latex/contrib/breqn/CHANGES.md5
-rw-r--r--macros/latex/contrib/breqn/breqn.dtx69
-rw-r--r--macros/latex/contrib/breqn/breqn.pdfbin661796 -> 661613 bytes
-rw-r--r--macros/latex/contrib/breqn/breqnbundle.ins3
-rw-r--r--macros/latex/contrib/breqn/flexisym.dtx6
-rw-r--r--macros/latex/contrib/breqn/flexisym.pdfbin286251 -> 286070 bytes
-rw-r--r--macros/latex/contrib/breqn/mathstyle.dtx6
-rw-r--r--macros/latex/contrib/breqn/mathstyle.pdfbin185385 -> 185205 bytes
-rw-r--r--macros/latex/contrib/hitszthesis/Makefile83
-rw-r--r--macros/latex/contrib/hitszthesis/README.md55
-rw-r--r--macros/latex/contrib/hitszthesis/hitszthesis.cls822
-rw-r--r--macros/latex/contrib/hitszthesis/hitszthesis.dtx2401
-rw-r--r--macros/latex/contrib/hitszthesis/hitszthesis.ins66
-rw-r--r--macros/latex/contrib/hitszthesis/hitszthesis.pdfbin894116 -> 572821 bytes
-rw-r--r--macros/latex/contrib/hitszthesis/hitszthesis.sty32
-rw-r--r--macros/latex/contrib/hitszthesis/latexmkrc23
-rw-r--r--macros/latex/contrib/hitszthesis/main.pdfbin0 -> 908166 bytes
-rw-r--r--macros/latex/contrib/hitszthesis/main.tex (renamed from macros/latex/contrib/hitszthesis/hitszthesis.tex)139
-rw-r--r--macros/latex/contrib/hitszthesis/spine.pdfbin0 -> 7132 bytes
-rw-r--r--macros/latex/contrib/hitszthesis/spine.tex14
20 files changed, 2798 insertions, 926 deletions
diff --git a/macros/latex/contrib/breqn/CHANGES.md b/macros/latex/contrib/breqn/CHANGES.md
index 7d823015d6..bad962a4b7 100644
--- a/macros/latex/contrib/breqn/CHANGES.md
+++ b/macros/latex/contrib/breqn/CHANGES.md
@@ -1,5 +1,10 @@
# Release notes for the `breqn` packages
+## v0.98i (2020/02/18)
+
+ * Fix clash with new version of `babel` around use of the generic `\\@elt` command.
+
+
## v0.98h (2020/02/16)
* No longer redefine LaTeX2e's `\\@ifstar` command, use a custom prefix instead.
diff --git a/macros/latex/contrib/breqn/breqn.dtx b/macros/latex/contrib/breqn/breqn.dtx
index 3222bb8945..9f344f3d1e 100644
--- a/macros/latex/contrib/breqn/breqn.dtx
+++ b/macros/latex/contrib/breqn/breqn.dtx
@@ -150,8 +150,8 @@
%
%
% \title{The \pkg{breqn} package}
-% \def\fileversion{0.98h}
-% \def\filedate{2020/02/16}
+% \def\fileversion{0.98i}
+% \def\filedate{2020/02/18}
% \date{\pkg{breqn} bundle: \filedate\space\fileversion}
% \author{Authors: Michael J. Downes, Morten H\o gholm\\ Maintained by Morten H\o gholm, Will Robertson\\ Feedback: \texttt{https://github.com/wspr/breqn/issues}}
%
@@ -1381,7 +1381,7 @@
% Declare package name and date.
% \begin{macrocode}
\RequirePackage{expl3}
-\ProvidesExplPackage{breqn}{2020/02/16}{0.98h}{Breaking equations}
+\ProvidesExplPackage{breqn}{2020/02/18}{0.98i}{Breaking equations}
% \end{macrocode}
% Regrettably, \pkg{breqn} is internally a mess, so we have to take
% some odd steps.
@@ -1786,17 +1786,6 @@
% \end{macro}
%
%
-% \begin{macro}{\eq@cons}
-%
-% \latex 's \cs{@cons} appends to the end of a list, but we need
-% a function that adds material at the beginning.
-% \begin{macrocode}
-\def\eq@cons#1#2{%
- \begingroup \let\@elt\relax \xdef#1{\@elt{#2}#1}\endgroup
-}
-% \end{macrocode}
-% \end{macro}
-%
% \begin{macro}{\@saveprimitive}
% If some preceding package redefined one of the
% primitives that we must change, we had better do some checking to make
@@ -4238,17 +4227,17 @@
\def\debug@showmeasurements{%
\breqn@debugmsg{=> \number\eq@lines\space lines}%
\begingroup
- \def\@elt##1X##2{\MessageBreak==== \space\space##1/##2}%
- \let\@endelt\@empty
+ \def\breqn@elt##1X##2{\MessageBreak==== \space\space##1/##2}%
+ \let\breqn@endelt\@empty
\breqn@debugmsg{=> trial info:\eq@measurements}%
\breqn@debugmsg{=> bounding box: \the\eq@wdT x\the\eq@vspan, badness=\the\eq@badness}%
- \let\@elt\relax \let\@endelt\relax
+ \let\breqn@elt\relax \let\breqn@endelt\relax
\endgroup
}
\def\debug@showmeasurements{%
\begingroup
- \def\@elt##1X##2{\MessageBreak==== ##1/##2}%
- \let\@endelt\@empty
+ \def\breqn@elt##1X##2{\MessageBreak==== ##1/##2}%
+ \let\breqn@endelt\@empty
\breqn@debugmsg{===> Measurements: \number\eq@lines\space lines
\eq@measurements
\MessageBreak
@@ -4417,9 +4406,9 @@
% \begin{macrocode}
\def\eq@trial@save#1{%
%<*trace>
-% \begingroup \def\@elt##1X##2{\MessageBreak==== \space\space##1/##2}\let\@endelt\@empty\breqn@debugmsg{=> trial info:\eq@measurements}%
+% \begingroup \def\breqn@elt##1X##2{\MessageBreak==== \space\space##1/##2}\let\breqn@endelt\@empty\breqn@debugmsg{=> trial info:\eq@measurements}%
% \breqn@debugmsg{=> bounding box: \the\eq@wdT x\the\eq@vspan, badness=\the\eq@badness\MessageBreak}%
-% \let\@elt\relax \let\@endelt\relax
+% \let\breqn@elt\relax \let\breqn@endelt\relax
% \endgroup
%</trace>
\xdef#1{%
@@ -4571,7 +4560,7 @@
% \begin{macrocode}
\def\eq@recalc{%
\eq@wdT\z@ \eq@wdMin\maxdimen \eq@vspan\z@skip \eq@badness\z@
- \let\@elt\eq@recalc@a \eq@measurements \let\@elt\relax
+ \let\breqn@elt\eq@recalc@a \eq@measurements \let\breqn@elt\relax
}
% \end{macrocode}
% \end{macro}
@@ -4579,10 +4568,10 @@
%
% \begin{macro}{\eq@recalc@a}
% \begin{macrocode}
-\def\eq@recalc@a#1x#2+#3\@endelt{%
+\def\eq@recalc@a#1x#2+#3\breqn@endelt{%
\eq@firstht#2\relax
- \let\@elt\eq@recalc@b
- \@elt#1x#2+#3\@endelt
+ \let\breqn@elt\eq@recalc@b
+ \breqn@elt#1x#2+#3\breqn@endelt
}
% \end{macrocode}
% \end{macro}
@@ -4590,7 +4579,7 @@
%
% \begin{macro}{\eq@recalc@b}
% \begin{macrocode}
-\def\eq@recalc@b#1X#2,#3x#4+#5@#6\@endelt{%
+\def\eq@recalc@b#1X#2,#3x#4+#5@#6\breqn@endelt{%
\setlength\dim@a{#2+#3}%
\ifdim\dim@a>\eq@wdT \eq@wdT\dim@a \fi
\ifdim\dim@a<\eq@wdMin \eq@wdMin\dim@a \fi
@@ -5001,12 +4990,12 @@
% \end{macrocode}
% \end{macro}
%
-% \begin{macro}{\@endelt}
+% \begin{macro}{\breqn@endelt}
% This is a scan marker.
% It should get a non-expandable definition.
% It could be \cs{relax}, but let's try a chardef instead.
% \begin{macrocode}
-\chardef\@endelt=`\?
+\chardef\breqn@endelt=`\?
% \end{macrocode}
% \end{macro}
%
@@ -5015,8 +5004,10 @@
% This is similar to a parshape spec but for each line we record more
% info: space above, indent, width x height + dp, and badness.
% \begin{macrocode}
+\let\breqn@elt\relax
+\let\breqn@endelt\relax
\def\eq@measurements{%
- \@elt 4.5pt/5.0pt,66.0ptx6.8pt+2.4pt@27\@endelt
+ \breqn@elt 4.5pt/5.0pt,66.0ptx6.8pt+2.4pt@27\breqn@endelt
...
}
% \end{macrocode}
@@ -5074,14 +5065,14 @@
\fi
}%
\fi
- \edef\eq@measurements{\@elt
+ \edef\eq@measurements{\breqn@elt
\the\skip@a\space X% extra space to facilitate extracting only the
% dimen part later
\csname eq@i%
\ifnum\eq@curline<\parshape \number\eq@curline
\else\number\parshape
\fi
- \endcsname,\the\dim@a x\the\ht\tw@+\the\dp\tw@ @\the\eq@badness\@endelt
+ \endcsname,\the\dim@a x\the\ht\tw@+\the\dp\tw@ @\the\eq@badness\breqn@endelt
\eq@measurements
}%
\advance\eq@curline\m@ne
@@ -5170,7 +5161,7 @@
\ifnum\eq@lines>\sixt@@n
\eq@dense@enough@b
\else
- \dim@b\z@ \let\@elt\eq@delt \eq@measurements
+ \dim@b\z@ \let\breqn@elt\eq@delt \eq@measurements
\dim@c\eq@density@factor\eq@wdT \multiply\dim@c\eq@lines
%<trace> \breqn@debugmsg{Density check: black \the\dim@b/\eq@density@factor total \the\dim@c}%
\ifdim\dim@b>\dim@c \true@false@true \else \false@false@false \fi
@@ -5183,7 +5174,7 @@
% \begin{macro}{\eq@delt}
% Args are space-above, indent, width, height, depth, badness.
% \begin{macrocode}
-\def\eq@delt#1X#2,#3x#4+#5@#6\@endelt{\addtolength\dim@b{#3}}%
+\def\eq@delt#1X#2,#3x#4+#5@#6\breqn@endelt{\addtolength\dim@b{#3}}%
% \end{macrocode}
% \end{macro}
%
@@ -6526,7 +6517,7 @@
% \begin{macrocode}
\def\grp@push{%
\global\GRP@queue\@xp\@xp\@xp{\@xp\the\@xp\GRP@queue
- \@xp\@elt\@xp{\EQ@trial}%
+ \@xp\breqn@elt\@xp{\EQ@trial}%
}%
\global\setbox\GRP@box\vbox{%
\hbox{\box\EQ@box\box\EQ@copy\penalty\@ne\copy\EQ@numbox}%
@@ -6606,7 +6597,7 @@
% in a \cs{vbox}
% \begin{macrocode}
\setbox\GRP@wholebox\vbox{%
- \let\@elt\eqgrp@elt
+ \let\breqn@elt\eqgrp@elt
\the\GRP@queue
}%
% \end{macrocode}
@@ -6647,7 +6638,7 @@
%\debug@box\GRP@wholebox
%</trace>
\unvbox\GRP@wholebox
- \let\@elt\relax
+ \let\breqn@elt\relax
% \end{macrocode}
% We'd need to handle shifted, right number here, too!!!
% \begin{macrocode}
@@ -6925,7 +6916,7 @@
% Need to add a dummy element to \cs{GRP@queue}.
% \begin{macrocode}
\global\GRP@queue\@xp{\the\GRP@queue
- \@elt{\gdef\EQ@trial{}}%
+ \breqn@elt{\gdef\EQ@trial{}}%
}%
}
% \end{macrocode}
@@ -6942,8 +6933,8 @@
\unvbox\GRP@box
}%
\global\GRP@queue\@xp{\the\GRP@queue
-% \@elt{\gdef\EQ@trial{\let\eq@isIntertext\@True}}%
- \@elt{\let\eq@isIntertext\@True}%
+% \breqn@elt{\gdef\EQ@trial{\let\eq@isIntertext\@True}}%
+ \breqn@elt{\let\eq@isIntertext\@True}%
}%
}
% \end{macrocode}
diff --git a/macros/latex/contrib/breqn/breqn.pdf b/macros/latex/contrib/breqn/breqn.pdf
index 6491bca5f8..900eee8636 100644
--- a/macros/latex/contrib/breqn/breqn.pdf
+++ b/macros/latex/contrib/breqn/breqn.pdf
Binary files differ
diff --git a/macros/latex/contrib/breqn/breqnbundle.ins b/macros/latex/contrib/breqn/breqnbundle.ins
index e48619eeb2..69b303c5e5 100644
--- a/macros/latex/contrib/breqn/breqnbundle.ins
+++ b/macros/latex/contrib/breqn/breqnbundle.ins
@@ -34,13 +34,11 @@ flexisym.dtx, and mathstyle.dtx.
\endpreamble
\generate{%
- \file{breqn.ins}{\from{breqn.dtx}{install}}%
\usedir{tex/latex/breqn}%
\file{breqn.sty}{\from{breqn.dtx}{package}}%
}
\generate{%
- \file{flexisym.ins}{\from{flexisym.dtx}{install}}%
\usedir{tex/latex/breqn}%
\file{flexisym.sty}{\from{flexisym.dtx}{package}}%
\file{cmbase.sym}{\from{flexisym.dtx}{cmbase}}%
@@ -50,7 +48,6 @@ flexisym.dtx, and mathstyle.dtx.
}
\generate{%
- \file{mathstyle.ins}{\from{mathstyle.dtx}{install}}%
\usedir{tex/latex/breqn}%
\file{mathstyle.sty}{\from{mathstyle.dtx}{package}}%
}
diff --git a/macros/latex/contrib/breqn/flexisym.dtx b/macros/latex/contrib/breqn/flexisym.dtx
index caf76eea74..cb9206c14e 100644
--- a/macros/latex/contrib/breqn/flexisym.dtx
+++ b/macros/latex/contrib/breqn/flexisym.dtx
@@ -78,8 +78,8 @@
% \fi
%
% \title{The \textsf{flexisym} package}
-% \def\fileversion{0.98h}
-% \def\filedate{2020/02/16}
+% \def\fileversion{0.98i}
+% \def\filedate{2020/02/18}
% \date{\filedate\space\fileversion}
% \author{Authors: Michael J. Downes, Morten H\o gholm\\ Maintained by Morten H\o gholm, Will Robertson\\ Feedback: \texttt{https://github.com/wspr/breqn/issues}}
%
@@ -97,7 +97,7 @@
% \begin{macrocode}
%<*package>
\RequirePackage{expl3}[2009/08/05]
-\ProvidesExplPackage{flexisym}{2020/02/16}{0.98h}{Make math characters macros}
+\ProvidesExplPackage{flexisym}{2020/02/18}{0.98i}{Make math characters macros}
\edef\do{%
\noexpand\AtEndOfPackage{%
diff --git a/macros/latex/contrib/breqn/flexisym.pdf b/macros/latex/contrib/breqn/flexisym.pdf
index 54f47e4ab4..0fddf92710 100644
--- a/macros/latex/contrib/breqn/flexisym.pdf
+++ b/macros/latex/contrib/breqn/flexisym.pdf
Binary files differ
diff --git a/macros/latex/contrib/breqn/mathstyle.dtx b/macros/latex/contrib/breqn/mathstyle.dtx
index 6a3e99e001..6df4e9426a 100644
--- a/macros/latex/contrib/breqn/mathstyle.dtx
+++ b/macros/latex/contrib/breqn/mathstyle.dtx
@@ -57,8 +57,8 @@
% \fi
%
% \title{The \textsf{mathstyle} package}
-% \def\fileversion{0.98h}
-% \def\filedate{2020/02/16}
+% \def\fileversion{0.98i}
+% \def\filedate{2020/02/18}
% \date{\filedate\quad\fileversion}
% \author{Authors: Michael J. Downes, Morten H\o gholm\\ Maintained by Morten H\o gholm, Will Robertson\\ Feedback: \texttt{https://github.com/wspr/breqn/issues}}
%
@@ -151,7 +151,7 @@
%<*package>
\NeedsTeXFormat{LaTeX2e}
\RequirePackage{expl3}
-\ProvidesExplPackage{mathstyle}{2020/02/16}{0.98h}{Tracking mathstyle implicitly}
+\ProvidesExplPackage{mathstyle}{2020/02/18}{0.98i}{Tracking mathstyle implicitly}
\ExplSyntaxOff
% \end{macrocode}
%
diff --git a/macros/latex/contrib/breqn/mathstyle.pdf b/macros/latex/contrib/breqn/mathstyle.pdf
index 39e9fe3456..c9d84aee9a 100644
--- a/macros/latex/contrib/breqn/mathstyle.pdf
+++ b/macros/latex/contrib/breqn/mathstyle.pdf
Binary files differ
diff --git a/macros/latex/contrib/hitszthesis/Makefile b/macros/latex/contrib/hitszthesis/Makefile
new file mode 100644
index 0000000000..ce3df42ab9
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/Makefile
@@ -0,0 +1,83 @@
+# Makefile for HITSZThesis
+
+PACKAGE = hitszthesis
+THESIS = main
+SPINE = spine
+
+SOURCES = $(PACKAGE).ins $(PACKAGE).dtx
+CLSFILE = dtx-style.sty $(PACKAGE).cls
+
+LATEXMK = latexmk
+
+# make deletion work on Windows
+ifdef SystemRoot
+ RM = del /Q
+else
+ RM = rm -f
+endif
+
+.PHONY: all all-dev clean distclean dist thesis viewthesis spine viewspine doc viewdoc cls check save savepdf test FORCE_MAKE
+
+thesis: $(THESIS).pdf
+
+all: thesis spine
+
+all-dev: doc all
+
+cls: $(CLSFILE)
+
+$(CLSFILE): $(SOURCES)
+ xetex $(PACKAGE).ins
+
+doc: $(PACKAGE).pdf
+
+spine: $(SPINE).pdf
+
+$(PACKAGE).pdf: cls FORCE_MAKE
+ $(LATEXMK) $(PACKAGE).dtx
+
+$(THESIS).pdf: cls FORCE_MAKE
+ $(LATEXMK) $(THESIS)
+
+$(SPINE).pdf: cls FORCE_MAKE
+ $(LATEXMK) $(SPINE)
+
+viewdoc: doc
+ $(LATEXMK) -pv $(PACKAGE).dtx
+
+viewthesis: thesis
+ $(LATEXMK) -pv $(THESIS)
+
+viewspine: spine
+ $(LATEXMK) -pv $(SPINE)
+
+save:
+ bash testfiles/save.sh
+
+savepdf:
+ bash testfiles/save-pdf.sh
+
+test:
+ l3build check
+
+clean:
+ $(LATEXMK) -c $(PACKAGE).dtx $(THESIS) $(SPINE)
+ -@$(RM) *~ main-survey.*
+
+cleanall: clean
+ -@$(RM) $(PACKAGE).pdf $(THESIS).pdf $(SPINE).pdf
+
+distclean: cleanall
+ -@$(RM) $(CLSFILE)
+ -@$(RM) -r dist
+
+check: FORCE_MAKE
+ifeq ($(version),)
+ @echo "Error: version missing: \"make [check|dist] version=X.Y\""; exit 1
+else
+ @[[ $(shell grep -E -c '$(version) A Bachelor Thesis Template for Harbin Institute of Technology, ShenZhen|\\def\\version\{$(version)\}' hitszthesis.dtx) -eq 3 ]] || (echo "update version in hitszthesis.dtx before release"; exit 1)
+ @[[ $(shell grep -E -c '"version": "$(version)"' package.json) -eq 1 ]] || (echo "update version in package.json before release"; exit 1)
+endif
+
+dist: check all-dev
+ npm run build -- --version=$(version) \ No newline at end of file
diff --git a/macros/latex/contrib/hitszthesis/README.md b/macros/latex/contrib/hitszthesis/README.md
index 838f63a599..c915afa624 100644
--- a/macros/latex/contrib/hitszthesis/README.md
+++ b/macros/latex/contrib/hitszthesis/README.md
@@ -1,27 +1,54 @@
<!-- Author : Jingxuan Yang-->
<!-- Program Email: yanglatex2e@gmail.com -->
-[Github](https://github.com/YangLaTeX/YangThesis) | [Download](https://github.com/YangLaTeX/YangThesis/releases) | [Wiki](https://github.com/YangLaTeX/YangThesis/wiki)
+[Github](https://github.com/YangLaTeX/YangThesis) | [Download](https://github.com/YangLaTeX/YangThesis/releases) | [Wiki](https://github.com/YangLaTeX/YangThesis/wiki) | [CTAN](https://www.ctan.org/pkg/hitszthesis)
-# HITSZThesis
+# Introduction to hitszthesis
-## Introduction
+HITSZThesis is a **bachelor dissertation** LaTeX template for **Harbin Institute of Technology, ShenZhen** (HITSZ). Current version is 2.0, updated on 2020/2/18.
-HITSZThesis is a **bachelor dissertation** LaTeX template for **Harbin Institute of Technology, ShenZhen** (HITSZ).
+# Documentation
+Download and unzip the template. Specific usage documentation and examples can be found in the files below. At present, these documents are <b>only available in Chinese</b>:
+* Template usage (hitszthesis.pdf)
+* Template example (main.pdf)
-## Requirements
+# Downloads
+* Published version: [CTAN](https://www.ctan.org/pkg/hitszthesis)
+* Developer version: [GitHub](https://github.com/YangLaTeX/hitszthesis)
-This package uses `mtpro2` as math font, you can install this font from [here](https://www.latexstudio.net/archives/51742.html).
+# Updates
+## Automatic
+Get the most up-to-date published version with your TeX distribution from [CTAN](https://www.ctan.org/pkg/hitszthesis).
-## Version
+## Manual
+Download the package from [GitHub](https://github.com/YangLaTeX/hitszthesis) to the root directory of your thesis, then execute the command (Windows users `Shift + right click` white area in the file window and click "Open command line window here" from the popup menu):
-This is version 1.2, updated on 2/15/2020.
+```shell
+xetex hitszthesis.ins
+```
-## Issues
-If you have any questions or advice, you can create an issue at [https://github.com/YangLaTeX/YangThesis/issues](https://github.com/YangLaTeX/YangThesis/issues)
+You'll get `hitszthesis.cls` along with other template files.
-## Contact
-Email: [yanglatex2e@gmail.com](mailto:yanglatex2e@gmail.com)
+# Reporting Issues
+Please follow the procedure below:
-## License
-This material is subject to the [LATEX Project Public License 1.3c](https://ctan.org/license/lppl1.3) or any later version. \ No newline at end of file
+* Check the [FAQ](https://github.com/YangLaTeX/hitszthesis/wiki/FAQ)
+* [GitHub Issues](https://github.com/YangLaTeX/hitszthesis/issues)
+
+# Makefile Usage
+
+```shell
+make [{all|thesis|spine|doc|clean|cleanall|distclean}]
+```
+
+## Targets
+* `make thesis` generate thesis main.pdf;
+* `make spine` generate book spine for printing spine.pdf;
+* `make doc` generate template documentation hitszthesis.pdf;
+* `make all` generate thesis and spine, same as `make thesis && make spine`;
+* `make clean` delete all examples' files (excluding main.pdf);
+* `make cleanall` delete all examples' files and main.pdf;
+* `make distclean` delete all examples' and templates' files and PDFs.
+
+# License
+This material is subject to the [LATEX Project Public License 1.3c](https://ctan.org/license/lppl1.3) or any later version.
diff --git a/macros/latex/contrib/hitszthesis/hitszthesis.cls b/macros/latex/contrib/hitszthesis/hitszthesis.cls
deleted file mode 100644
index d6d1815d32..0000000000
--- a/macros/latex/contrib/hitszthesis/hitszthesis.cls
+++ /dev/null
@@ -1,822 +0,0 @@
-%%==============================================
-%% start of file `HITSZThesis.cls'.
-%% Copyright 2019-2020 YangLaTeX (yanglatex2e@gmail.com)
-%%
-%% This work is available at GitHub:
-%% https://github.com/YangLaTeX/YangThesis
-%%
-%% This material is subject to the LATEX Project Public License 1.3c
-%% (https://ctan.org/license/lppl1.3) or any later version
-%%==============================================
-
-% 开始写类文件
-% 设置需要的LaTeX版本
-\NeedsTeXFormat{LaTeX2e}
-
-% 定义提供的类文件名称以及说明文字
-\ProvidesClass{hitszthesis}[2020/02/15 v1.2 HITSZThesis document class]
-
-% 键值对设置
-\RequirePackage{kvoptions}
-
-% 对宏包、环境、命令进行操作
-\RequirePackage{etoolbox}
-
-% 设置关键词
-\SetupKeyvalOptions{family=Yang, prefix=Yang@, setkeys=\kvsetkeys}
-
-% 定义设置关键词命令
-\newcommand{\ykv}[1]{\kvsetkeys{Yang}{#1}}
-
-% 表格信息对齐
-\DeclareStringOption[infocenter]{infoalign}
-\DeclareVoidOption{infocenter}{\ykv{infoalign = infocenter}}
-\DeclareVoidOption{infoleft}{\ykv{infoalign = infoleft}}
-
-% 封面标题行数
-\DeclareStringOption[onerow]{covertitle}
-\DeclareVoidOption{onerow}{\ykv{covertitle = onerow}}
-\DeclareVoidOption{tworow}{\ykv{covertitle = tworow}}
-
-% 默认选项
-\DeclareDefaultOption{\PassOptionsToClass{\CurrentOption}{book}}
-
-% 禁用键值对操作
-\ProcessKeyvalOptions*\relax
-
-% 加载book类,A4大小,正文12磅,单面打印
-\LoadClass[12pt,a4paper,openany,oneside]{book}
-
-% 使用xelatex编译mtpro2宏包必须加载此宏包
-\RequirePackage{etex}
-
-% 加载支持中文的ctex宏包
-\RequirePackage[UTF8,space=auto,scheme=plain]{ctex}
-
-% 正文和数学字体设置
-\RequirePackage{amsmath}
-\RequirePackage[T1]{fontenc}
-\RequirePackage{newtxtext}
-\RequirePackage[mtphrb,mtpcal,zswash,subscriptcorrection,uprightGreek,nofontinfo]{mtpro2}
-\renewcommand{\rmdefault}{ptm}
-\RequirePackage[scaled=0.92]{helvet}
-\RequirePackage{type1cm}
-\RequirePackage{lipsum}
-
-% 使字体设置生效,排除其他干扰
-\RequirePackage{mathdesign}
-
-% 设置中文加粗字体
-\setCJKfamilyfont{kai}[AutoFakeBold]{simkai.ttf}
-\newcommand*{\kai}{\CJKfamily{kai}}
-\setCJKfamilyfont{song}[AutoFakeBold]{SimSun}
-\newcommand*{\song}{\CJKfamily{song}}
-
-% 行间距,设为1.3,due to 12pt与小四号字的大小微差
-\linespread{1.3}
-
-%%===============常用宏包=========================
-% 在一页上可以使用单栏和多栏样式
-\RequirePackage{multicol}
-% 自定义颜色
-\RequirePackage{xcolor}
-% 排版代码
-\RequirePackage{fancyvrb}
-% 自定义目录格式
-\RequirePackage{titletoc}
-% 设置颜色
-\RequirePackage{xcolor}
-% 插入图片
-\RequirePackage{graphicx}
-% 表格
-\RequirePackage{array}
-% 长表格
-\RequirePackage{longtable}
-% booktabs 提供了\toprule 等命令.
-\RequirePackage{booktabs}
-% multirow 支持在表格中跨行
-\RequirePackage{multirow}
-% 调整间隔, 让表格更好看些
-\RequirePackage{bigstrut}
-% 在跨行表格中输入定界符
-\RequirePackage{bigdelim}
-% 保护脆落命令
-\RequirePackage{cprotect}
-% 定制列表环境
-\RequirePackage{enumitem}
-% 设置代码环境
-\RequirePackage{listings}
-% 超链接格式设置
-\RequirePackage{hyperref}
-% 首行缩进
-\RequirePackage{indentfirst}
-\setlength\parindent{2em}
-% 设置浮动体的标题
-\RequirePackage{caption}
-% 浮动环境
-\RequirePackage{float}
-% 下划线
-\RequirePackage{ulem}
-% 尺寸计算
-\RequirePackage{calc}
-% tikz绘图
-\RequirePackage{tikz}
-% 公式字母加粗
-\RequirePackage{bm}
-% 子公式编号
-\RequirePackage{cases}
-% 单位
-\RequirePackage{siunitx}
-% 排版代码
-\RequirePackage{listings}
-\renewcommand{\ttdefault}{cmtt}
-% 定义<ystyle>样式
-\lstdefinestyle{ystyle}{
- basicstyle=%
- \ttfamily
- \lst@ifdisplaystyle\small\fi
-}
-% 使用<ystyle>样式
-\lstset{basicstyle = \ttfamily, style = ystyle, breaklines = true}
-% 定义代码颜色
-\definecolor{lightgrey}{rgb}{0.9,0.9,0.9}
-\definecolor{frenchplum}{RGB}{190,20,83}
-\definecolor{winered}{rgb}{0.5,0,0}
-% 设置LaTeX代码排版样式
-\lstset{language = [LaTeX]TeX,
- texcsstyle = *\color{winered},
- numbers = none,
- mathescape,
- breaklines = true,
- keywordstyle = \color{winered},
- commentstyle = \color{gray},
- emph = {Yangpaper,fontenc,fontspec,xeCJK,FiraMono,xunicode,newtxmath, figure,fig,image,img,table,itemize,enumerate,newtxtext,newtxtt,ctex, microtype,description,times,newtx,booktabs,tabular,PDFLaTeX, XeLaTeX,type1cm,BibTeX,device,color,mode,lang,amsthm,tcolorbox, titlestyle,cite,marginnote,ctex,listings,base,subnumcases},
- emphstyle = {\color{frenchplum}},
- morekeywords = {DeclareSymbolFont,SetSymbolFont,toprule,midrule,bottomrule, institute,version,includegraphics,setmainfont,setsansfont,setmonofont, setCJKmainfont,setCJKsansfont,setCJKmonofont,RequirePackage,figref, tabref,email,maketitle,keywords,definecolor,extrainfo,logo,cover,subtitle, appendix,chapter,hypersetup,mainmatter,frontmatter,tableofcontents, Yangpar,heiti,kaishu,lstset,pagecolor,zhnumber,marginpar,part, equote,marginnote},
- frame = single,
- tabsize = 2,
- rulecolor = \color{black},
- framerule = 0.2pt,
- columns = flexible,
- % backgroundcolor = \color{lightgrey}
-}
-%%==============================================
-
-% 定义输入常量<tokens>
-% 论文标题
-\newcommand\Yang@tokens@thesistitle{}
-% 关键词,中文
-\newcommand\Yang@tokens@keywords{}
-% 关键词,英文
-\newcommand\Yang@tokens@keywordsen{}
-% 论文类别
-\newcommand*\Yang@tokens@papercategory{}
-% 学校名称
-\newcommand*\Yang@tokens@schoolname{}
-% 院系
-\newcommand*\Yang@tokens@departname{}
-% 班级
-\newcommand*\Yang@tokens@classnumber{}
-% 日期
-\newcommand*\Yang@tokens@dateinput{}
-% 姓名
-\newcommand*\Yang@tokens@authorname{}
-% 学号
-\newcommand*\Yang@tokens@studentID{}
-% 专业
-\newcommand*\Yang@tokens@majorin{}
-% 指导教师
-\newcommand*\Yang@tokens@instructor{}
-% 第一行标题
-\newcommand*\Yang@tokens@titleone{}
-% 第二行标题
-\newcommand*\Yang@tokens@titletwo{}
-
-% 定义与常量有关的新命令
-% 输入论文标题
-\newcommand*\thesistitle[1]{%
- \renewcommand{\Yang@tokens@thesistitle}{#1}}
-% 输入论文类别
-\newcommand*\papercategory[1]{%
- \renewcommand{\Yang@tokens@papercategory}{#1}}
-% 输入校名
-\newcommand*\schoolname[1]{%
- \renewcommand{\Yang@tokens@schoolname}{#1}}
-% 输入院系名称
-\newcommand*\departname[1]{%
- \renewcommand{\Yang@tokens@departname}{#1}}
-% 输入班级
-\newcommand*\classnumber[1]{%
- \renewcommand{\Yang@tokens@classnumber}{#1}}
-% 输入日期
-\newcommand*\dateinput[1]{%
- \renewcommand{\Yang@tokens@dateinput}{#1}}
-% 输入姓名
-\newcommand*\authorname[1]{%
- \renewcommand{\Yang@tokens@authorname}{#1}}
-% 输入学号
-\newcommand*\studentID[1]{%
- \renewcommand{\Yang@tokens@studentID}{#1}}
-% 输入专业
-\newcommand*\majorin[1]{%
- \renewcommand{\Yang@tokens@majorin}{#1}}
-% 输入指导教师
-\newcommand*\instructor[1]{%
- \renewcommand{\Yang@tokens@instructor}{#1}}
-% 输入第一行标题
-\newcommand*\titleone[1]{%
- \renewcommand{\Yang@tokens@titleone}{#1}}
-% 输入第二行标题
-\newcommand*\titletwo[1]{%
- \renewcommand{\Yang@tokens@titletwo}{#1}}
-
-% 定义常量的值
-% 中文标题名称设置
-
-\renewcommand\listfigurename{插图目录}
-\renewcommand\listtablename{附表目录}
-\renewcommand\abstractname{摘\quad 要}
-\newcommand{\keywordsname}{关键词}
-\newcommand{\keywordsenname}{Keywords}
-%%中文结构名字
-\renewcommand{\contentsname}{目\quad 录}
-\renewcommand{\figurename}{图}
-\renewcommand{\tablename}{表}
-\renewcommand{\partname}{部分}
-\renewcommand{\listfigurename}{插图目录}
-\renewcommand{\listtablename}{表格目录}
-\renewcommand{\bibname}{参考文献}
-\renewcommand{\appendixname}{附录}
-\renewcommand{\indexname}{索\quad 引}
-
-\newcommand{\notename}{笔记}
-\renewcommand*{\proofname}{证明}
-\newcommand{\problemname}{例题}
-\newcommand{\definitionname}{定义}
-\newcommand{\theoremname}{定理}
-\newcommand{\axiomname}{公理}
-\newcommand{\postulatename}{公设}
-\newcommand{\lemmaname}{引理}
-\newcommand{\propositionname}{命题}
-\newcommand{\corollaryname}{推论}
-\newcommand{\examplename}{例}
-\newcommand{\exercisename}{练习}
-\newcommand{\remarkname}{注}
-\newcommand{\assumptionname}{假设}
-\newcommand{\conclusionname}{结论}
-\newcommand{\solutionname}{解}
-\newcommand{\propertyname}{性质}
-
-% 中英字号转换
-\def\Yang@def@fontsize#1#2{%
- \expandafter\newcommand\csname #1\endcsname[1][1.3]{%
- \fontsize{#2}{##1\dimexpr #2}\selectfont}}
-
-% 定义字号
-\Yang@def@fontsize{chuhao}{42bp}
-\Yang@def@fontsize{xiaochu}{36bp}
-\Yang@def@fontsize{yihao}{26bp}
-\Yang@def@fontsize{xiaoyi}{24bp}
-\Yang@def@fontsize{erhao}{22bp}
-\Yang@def@fontsize{xiaoer}{18bp}
-\Yang@def@fontsize{sanhao}{16bp}
-\Yang@def@fontsize{xiaosan}{15bp}
-\Yang@def@fontsize{sihao}{14bp}
-\Yang@def@fontsize{banxiaosi}{13bp}
-\Yang@def@fontsize{xiaosi}{12bp}
-\Yang@def@fontsize{dawu}{11bp}
-\Yang@def@fontsize{wuhao}{10.5bp}
-\Yang@def@fontsize{xiaowu}{9bp}
-\Yang@def@fontsize{liuhao}{7.5bp}
-\Yang@def@fontsize{xiaoliu}{6.5bp}
-\Yang@def@fontsize{qihao}{5.5bp}
-\Yang@def@fontsize{bahao}{5bp}
-
-% 图片搜索目录
-\graphicspath{{./figure/}{./figures/}{./image/}{./images/}{./graphics/}{./graphic/}{./pictures/}{./picture/}{./front/}}
-
-% 页面设置
-\RequirePackage{geometry}
-\geometry{
- a4paper,
- left=30mm,
- right=30mm,
- top=41mm,
- bottom=30mm,
- headheight = 2.17cm,
- headsep = 1mm,
- footskip = 0cm,
-}
-
-% 超链接设置
-\RequirePackage{hyperref}
-\hypersetup{
- breaklinks,
- unicode,
- linktoc=all,
- bookmarksnumbered=true,
- bookmarksopen=true,
- pdfsubject=\@author \@title Book,
- pdftitle = {哈尔滨工业大学(深圳)本科毕业设计(论文)},
- pdfauthor = {\@author},
- pdfkeywords={YangBook},
- pdfcreator={XeLaTeX with YangThesis class},
- colorlinks,
- linkcolor=black,
- citecolor=black,
- plainpages=false,
- pdfstartview=FitH,
- pdfborder={0 0 0},
-}
-
-% 章节设置
-\RequirePackage[pagestyles]{titlesec}
-\RequirePackage{apptools}
-\RequirePackage[toc,page]{appendix}
-
-% 更改章节编号样式
-\setcounter{secnumdepth}{3}
-\renewcommand{\chaptername}{第 \thechapter\;章}
-
-% 设置章节标题样式
-\titleformat{\chapter}[hang]{\centering\heiti}
-{\filcenter\xiaoer\enspace\heiti{\IfAppendix{\appendixname}{\chaptername}\enspace}}{1pt}{\xiaoer}
-
-% 设置节标题样式
-\titleformat{\section}[hang]{\heiti}
-{\xiaosan\heiti{\thesection}\enspace}{1pt}{\xiaosan\heiti\filright}
-
-% 设置条标题样式
-\titleformat{\subsection}[hang]{\heiti}
-{\sihao\heiti\thesubsection\enspace}{1pt}{\sihao\heiti\filright}
-
-% 设置四级标题样式
-\titleformat{\subsubsection}[hang]{\heiti}
-{\xiaosi\heiti\thesubsubsection\enspace}{1pt}{\xiaosi\heiti\filright}
-
-% 设置标题与上下文间距
-% \titlespacing*{<command>}{<left>}{<before-sep>}{<after-sep>}[<right-sep>]
-\titlespacing{\chapter}{0pt}{0bp}{14.4bp}
-\titlespacing{\section}{0pt}{7.5bp}{7.5bp}
-\titlespacing{\subsection}{0pt}{7bp}{7bp}
-\titlespacing{\subsubsection}{0pt}{6bp}{6bp}
-
-% 图表标题设置,字号为small,分割符为空格
-\RequirePackage[font=small,labelsep=quad]{caption}
-
-% 标题与图表的间距为3pt
-\captionsetup[table]{skip=3pt}
-\captionsetup[figure]{skip=10pt}
-
-% 图表的引用格式
-\newcommand\figref[1]{图\ref{#1}}
-\newcommand\tabref[1]{表\ref{#1}}
-\newcommand\equref[1]{式(\ref{#1})}
-
-% 设置列表环境各项间无自动间距
-\setlist{nolistsep}
-
-% 定义各类定理样式
-\RequirePackage{amsthm}
-\let\proof\relax
-\let\endproof\relax
-
-% 定义新定义样式
-\newtheoremstyle{ydefstyle}{3pt}{3pt}{\itshape}{}{\bfseries}{}{0.5em}{\thmname{#1} \thmnumber{#2} \thmnote{(#3)}}
-
-% 定义新定理样式
-\newtheoremstyle{ythmstyle}{3pt}{3pt}{\itshape}{}{\bfseries}{}{0.5em}{\thmname{#1} \thmnumber{#2} \thmnote{(#3)}}
-
-% 定义新命题样式
-\newtheoremstyle{yprostyle}{3pt}{3pt}{\itshape}{}{\bfseries}{}{0.5em}{\thmname{#1} \thmnumber{#2} \thmnote{(#3)}}
-
-% 应用定义样式
-\theoremstyle{ydefstyle}
-\newtheorem{ydefinition}{\definitionname }[chapter]
-
-% 应用定理样式
-\theoremstyle{ythmstyle}
-\newtheorem{ytheorem}{\theoremname }[chapter]
-\newtheorem{ylemma}{\lemmaname }[chapter]
-\newtheorem{ycorollary}{\corollaryname }[chapter]
-\newtheorem{ypostulate}{\postulatename }[chapter]
-\newtheorem{yaxiom}{\axiomname }[chapter]
-
-% 应用命题样式
-\theoremstyle{yprostyle}
-\newtheorem{yproposition}{\propositionname }[chapter]
-
-% 定义新定理环境
-\newenvironment{theorem}[2]
- {\ifstrempty{#1}{\ytheorem}{\ytheorem[#1]}\ifstrempty{#2}{}{\label{#2}}}
- {\endytheorem}
-
-% 定义新定义环境
-\newenvironment{definition}[2]
- {\ifstrempty{#1}{\ydefinition}{\ydefinition[#1]}\ifstrempty{#2}{}{\label{#2}}}
- {\endydefinition}
-
-% 定义新引理环境
-\newenvironment{lemma}[2]
- {\ifstrempty{#1}{\ylemma}{\ylemma[#1]}\ifstrempty{#2}{}{\label{#2}}}
- {\endylemma}
-
-% 定义新推论环境
-\newenvironment{corollary}[2]
- {\ifstrempty{#1}{\ycorollary}{\ycorollary[#1]}\ifstrempty{#2}{}{\label{#2}}}
- {\endycorollary}
-
-% 定义新公设环境
-\newenvironment{postulate}[2]
- {\ifstrempty{#1}{\ypostulate}{\ypostulate[#1]}\ifstrempty{#2}{}{\label{#2}}}
- {\endypostulate}
-
-% 定义新公理环境
-\newenvironment{axiom}[2]
- {\ifstrempty{#1}{\yaxiom}{\yaxiom[#1]}\ifstrempty{#2}{}{\label{#2}}}
- {\endyaxiom}
-
-% 定义新命题环境
-\newenvironment{proposition}[2]
- {\ifstrempty{#1}{\yproposition}{\yproposition[#1]}\ifstrempty{#2}{}{\label{#2}}}
- {\endyproposition}
-
-% 定义新注解环境
-\newenvironment{note}{
- \par\noindent\textbf{\notename\,}
- \itshape}{\par}
-
-% 定义新证明环境
-\newenvironment{proof}{
- \par\noindent\textbf{\proofname\;}
-}{\hfill$\Box$\quad\par}
-
-% 定义新解答环境
-\newenvironment{solution}{\medskip\par\noindent\textbf{\solutionname} \itshape}{\par}
-
-% 定义新注释环境
-\newenvironment{remark}{\noindent\textbf{\remarkname}}{\par}
-
-% 定义新假设环境
-\newenvironment{assumption}{\par\noindent\textbf{\assumptionname}}{\par}
-
-% 定义新结论环境
-\newenvironment{conclusion}{\par\noindent\textbf{\conclusionname}}{\par}
-
-% 定义新性质环境
-\newenvironment{property}{\par\noindent\textbf{\propertyname}}{\par}
-
-
-% 重定义<\maketitle>命令
-\renewcommand{\maketitle}{\par
- \begingroup
- \newgeometry{left=20mm,right=20mm,top=30mm,bottom=35mm}
- \newpage
- % 禁止图片位于页面最上方
- \global\@topnum\z@
- \@maketitle % 下面再设置封面具体内容
- \endgroup
- % 先取消原来封面样式的所有设置,以便后面重写此命令
- \global\let\thanks\relax
- \global\let\maketitle\relax
- \global\let\@maketitle\relax
- \global\let\@thanks\@empty
- \global\let\@author\@empty
- \global\let\@date\@empty
- \global\let\@title\@empty
- \global\let\title\relax
- \global\let\author\relax
- \global\let\date\relax
- \global\let\and\relax
-}
-
-% 定义封面具体内容
-\newdimen\infowidth
-\infowidth = 6.5cm
-\def\@maketitle{%
- \newpage
- % 开始写封面
- \thispagestyle{empty}
- \vspace*{2cm}
- %%------------------------
- \begin{center}
- \ifdefstring{\Yang@covertitle}{tworow}{
- \parbox[t][1.4cm][t]{\textwidth}{
- \begin{center}\erhao[0]\bfseries\Yang@tokens@titleone\end{center}
- }\par
- \parbox[t][2.5cm][t]{\textwidth}{
- \begin{center}\erhao[0]\bfseries\Yang@tokens@titletwo\end{center}
- }\par
- }{\relax}
- \ifdefstring{\Yang@covertitle}{onerow}{
- \parbox[t][3.4cm][t]{\textwidth}{
- \begin{center}\erhao[0]\bfseries\Yang@tokens@thesistitle\end{center}
- }
- }{\relax}
- \parbox[t][8.7cm][t]{\textwidth}{
- \begin{center}\xiaoer[0]\song\textbf{\ziju{0.2}\Yang@tokens@authorname}\end{center}
- }
- \begin{center}
- \bfseries
- \begin{tabular}{rl}
-{\xiaosi 学\hphantom{教师}院:} & \xiaosi\Yang@tokens@departname\\[14pt]
-{\xiaosi 学\hphantom{教师}号:} & \xiaosi\Yang@tokens@studentID
- \end{tabular}
- \hspace{0.5cm}
- \begin{tabular}{rl}
-{\xiaosi 专\hphantom{教师}业:} & \xiaosi\Yang@tokens@majorin\\[14pt]
-{\xiaosi 指导教师:} & \xiaosi\Yang@tokens@instructor
- \end{tabular}
- \end{center}
- % 日期
- \vspace{2.6cm}
- {\xiaosi[0]\song\textbf{2020年7月}}
- \end{center}
- %%----------------------------
-%% 第二页
-\clearpage
-\thispagestyle{empty}
- \vspace*{0.8cm}
- \centering\includegraphics[width=8cm]{HITSZname}
- \vspace{1.3cm}
- \begin{center}
- \centering\includegraphics[width=10.5cm]{thesistitle}
- \vfill
- \parbox[t][14.2cm][b]{\textwidth}
- {\heiti\xiaosan
- \begin{center} \renewcommand{\arraystretch}{2.6} \bfseries
- % 居中对齐
- \ifdefstring{\Yang@infoalign}{infocenter}{
- \begin{tabular}{l@{\ \ }c}
-
- {\xiaoer 题\hphantom{\ 导\ \ \ }目} & \underline{\makebox[\infowidth]{\xiaoer \Yang@tokens@titleone}}\\
- & \underline{\makebox[\infowidth]{\xiaoer \Yang@tokens@titletwo}}\\
- & \\
- {\xiaosan 专\hphantom{\ 导\ 教\ }业} & \underline{\makebox[\infowidth]{\xiaosan\Yang@tokens@majorin}}\\
- {\xiaosan 学\hphantom{\ 导\ 教\ }号} & \underline{\makebox[\infowidth]{\xiaosan\Yang@tokens@studentID}}\\
- {\xiaosan 学\hphantom{\ 导\ 教\ }生} & \underline{\makebox[\infowidth]{\xiaosan\Yang@tokens@authorname}}\\
- {\xiaosan 指\ 导\ 教\ 师} & \underline{\makebox[\infowidth]{\xiaosan\Yang@tokens@instructor}}\\
- {\xiaosan 答\ 辩\ 日\ 期} & \underline{\makebox[\infowidth]{\xiaosan\Yang@tokens@dateinput}}
- \end{tabular} \renewcommand{\arraystretch}{1}
- }{\relax}
- % 左对齐
- \ifdefstring{\Yang@infoalign}{infoleft}{
- \begin{tabular}{l@{\ \ }c}
-
- {\xiaoer 题\hphantom{\ 导\ \ \ }目} & \underline{\makebox[\infowidth][l]{\hspace*{1em}\xiaoer \Yang@tokens@titleone}}\\
- & \underline{\makebox[\infowidth][l]{\hspace*{1em}\xiaoer \Yang@tokens@titletwo}}\\
- & \\
- {\xiaosan 专\hphantom{\ 导\ 教\ }业} & \underline{\makebox[\infowidth][l]{\hspace*{1em}\xiaosan\Yang@tokens@majorin}}\\
- {\xiaosan 学\hphantom{\ 导\ 教\ }号} & \underline{\makebox[\infowidth][l]{\hspace*{1em}\xiaosan\Yang@tokens@studentID}}\\
- {\xiaosan 学\hphantom{\ 导\ 教\ }生} & \underline{\makebox[\infowidth][l]{\hspace*{1em}\xiaosan\Yang@tokens@authorname}}\\
- {\xiaosan 指\ 导\ 教\ 师} & \underline{\makebox[\infowidth][l]{\hspace*{1em}\xiaosan\Yang@tokens@instructor}}\\
- {\xiaosan 答\ 辩\ 日\ 期} & \underline{\makebox[\infowidth][l]{\hspace*{1em}\xiaosan\Yang@tokens@dateinput}}
- \end{tabular} \renewcommand{\arraystretch}{1}
- }{\relax}
- \end{center}
- }
- \end{center}
- \restoregeometry
- \clearpage
-}
-
-%% 中文摘要环境
-\newenvironment{abstract}{\chapter*{\abstractname}
-\addcontentsline{toc}{chapter}{\abstractname}
-}{\if@twocolumn\else\null\fi}
-
-% 中文关键词环境
-\newcommand\keywords[1]{%
- \renewcommand{\Yang@tokens@keywords}{#1}
- {\vskip18pt
- \hspace{-30bp}\begin{tabular}{lp{132mm}}
- {\zihao{-4}\heiti\keywordsname:}&
- {\xiaosi\Yang@tokens@keywords}
- \end{tabular}}
- }
-
-% 英文摘要环境
-\newenvironment{abstracten}{\chapter*{\bfseries Abstract}
-\addcontentsline{toc}{chapter}{ABSTRACT}
-}{\if@twocolumn\else\null\fi}
-
-% 英文关键词环境
-\newcommand\keywordsen[1]{%
- \renewcommand{\Yang@tokens@keywordsen}{#1}
- {\vskip 18pt
- \hspace{-30bp}\begin{tabular}{lp{127mm}}
- {\zihao{-4}\bf\keywordsenname:}&
- {\xiaosi\Yang@tokens@keywordsen}
- \end{tabular}}
- }
-
-% 定义原创性声明命令
-\newcommand{\declaration}{\par
- \begingroup
- \@declaration
- \endgroup
-}
-
-% 定义原创性声明具体内容
-\def\@declaration{
-\chapter*{\sanhao 哈尔滨工业大学(深圳)本科毕业设计(论文)原创性声明}
-\addcontentsline{toc}{chapter}{原创性声明}\par
-本人郑重声明:在哈尔滨工业大学(深圳)攻读学士学位期间,所提交的毕业设计(论文)《\Yang@tokens@thesistitle》,是本人在导师指导下独立进行研究工作所取得的成果。对本文的研究工作做出重要贡献的个人和集体,均已在文中以明确方式注明,其它未注明部分不包含他人已发表或撰写过的研究成果,不存在购买、由他人代写、剽窃和伪造数据等作假行为。
-\par
-本人愿为此声明承担法律责任。\par
-\vspace{30pt}
-\hspace{6em}作者签名:\hspace{8em}日期:\hspace{3em}年\hspace{1.5em}月\hspace{1.5em}日
-}
-
-% 定义附录,编号格式为大写字母
-\renewcommand\appendix{\par
- \setcounter{section}{0}%
- \setcounter{subsection}{0}%
- \gdef\thesection{\appendixname\@Alph\c@section}}
-
-% 重定义参考文献环境
-\renewenvironment{thebibliography}[1]
- {\chapter*{\bibname}%
- \@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}%
- \list{\@biblabel{\@arabic\c@enumiv}}%
- {\settowidth\labelwidth{\@biblabel{#1}}%
- \leftmargin\labelwidth
- \advance\leftmargin\labelsep
- \@openbib@code
- \usecounter{enumiv}%
- \let\p@enumiv\@empty
- \renewcommand\theenumiv{\@arabic\c@enumiv}}%
- \sloppy
- \clubpenalty4000
- \@clubpenalty \clubpenalty
- \widowpenalty4000%
- \sfcode`\.\@m}
- {\def\@noitemerr
- {\@latex@warning{Empty `thebibliography' environment}}%
- \endlist}
-
-% 定义页眉页脚
-\RequirePackage{fancyhdr}
-\RequirePackage{lastpage}
-\pagestyle{fancy}
-% 页眉
-\lhead{}
-\chead{\wuhao 哈尔滨工业大学(深圳)本科毕业设计(论文)}
-\rhead{}
-% 页脚
-\lfoot{}
-\cfoot{\wuhao -\thepage-}
-\rfoot{}
-
-% 定义页眉双横线样式
-% 注意下面代码中的<%>不能删
-\newcommand{\makeheadrule}{%
-\makebox[0pt][l]{\rule[1mm]{\headwidth}{0.4mm}}%
-\rule[0.35\baselineskip]{\headwidth}{0.8mm}}
-
-% 定义页眉横线为双横线
-\renewcommand{\headrule}{%
-{\if@fancyplain\let\headrulewidth\plainheadrulewidth\fi%
-\makeheadrule}}
-
-% 设置目录格式,目录只有三级
-% 1级目录格式
-\titlecontents{chapter}[0pt]{\vspace{1mm}\heiti}
-{第\thecontentslabel 章\hskip.5em}{}{\titlerule*[0.5pc]{.}\contentspage}
-% 2级目录格式
-\titlecontents{section}[25pt]{\songti}
-{\thecontentslabel\hskip.5em}{}{\titlerule*[0.5pc]{.}\contentspage}
-% 3级目录格式
-\titlecontents{subsection}[47pt]{\songti}
-{\thecontentslabel\hskip.5em}{}{\titlerule*[0.5pc]{.}\contentspage}
-
-% 修改表格字号,注意tabular要放在table环境里
-\BeforeBeginEnvironment{tabular}{\wuhao}
-% 修改表格与后文间距,缩短1cm
-\AfterEndEnvironment{table}{\vspace{-1cm}}
-
-% 新计数器,编排表格编号用
-\newcounter{rowno}
-
-% 使公式图表的编号随章节编号更新
-%\numberwithin{equation}{chapter}
-%\numberwithin{figure}{chapter}
-%\numberwithin{table}{chapter}
-
-% 设置图表公式编号格式为1-1
-\renewcommand{\thefigure}{\arabic{chapter}-\arabic{figure}}
-\renewcommand{\thetable}{\arabic{chapter}-\arabic{table}}
-\renewcommand{\theequation}{\arabic{chapter}-\arabic{equation}}
-
-% 使用tikz配置流程图基本图形
-\usetikzlibrary{shapes.geometric, arrows}
-% 开始
-\tikzstyle{startstop} = [rectangle, rounded corners, minimum width = 2cm, minimum height=1cm,text centered, draw = black]
-% 输入输出
-\tikzstyle{io} = [trapezium, trapezium left angle=70, trapezium right angle=110, minimum width=2cm, minimum height=1cm, text centered, draw=black]
-% 过程
-\tikzstyle{process} = [rectangle, minimum width=3cm, minimum height=1cm, text centered, draw=black]
-% 判断
-\tikzstyle{decision} = [diamond, aspect = 3, text centered, draw=black]
-% 箭头形式
-\tikzstyle{arrow} = [->,>=stealth]
-
-% 参考文献标号为上标
-\newcommand{\upcite}[1]{\textsuperscript{\textsuperscript{\cite{#1}}}}
-
-% 设置脚注编号格式
-\renewcommand{\thefootnote}{\fnsymbol{footnote}}
-
-% 解决book类文档章首页和目录页没有页眉页脚的问题
-\makeatletter
-\renewcommand\chapter{\if@openright\cleardoublepage\else\clearpage\fi
- \thispagestyle{fancy} % original style: plain
- \global\@topnum\z@
- \@afterindentfalse
- \secdef\@chapter\@schapter}
-\makeatother
-
-%%=====新数学命令================================
-\newcommand\dif{\text{d}}
-\newcommand\no{\noindent}
-\newcommand\dis{\displaystyle}
-\newcommand\ls{\leqslant}
-\newcommand\gs{\geqslant}
-
-\newcommand\limit{\dis\lim\limits}
-\newcommand\limn{\dis\lim\limits_{n\to\infty}}
-\newcommand\limxz{\dis\lim\limits_{x\to0}}
-\newcommand\limxi{\dis\lim\limits_{x\to\infty}}
-\newcommand\limxpi{\dis\lim\limits_{x\to+\infty}}
-\newcommand\limxni{\dis\lim\limits_{x\to-\infty}}
-\newcommand\limtpi{\dis\lim\limits_{t\to+\infty}}
-\newcommand\limtni{\dis\lim\limits_{t\to-\infty}}
-
-\newcommand\sumn{\dis\sum\limits_{n=1}^{\infty}}
-\newcommand\sumnz{\dis\sum\limits_{n=0}^{\infty}}
-
-\newcommand\sumi{\dis\sum\limits_{i=1}^{\infty}}
-\newcommand\sumiz{\dis\sum\limits_{i=0}^{\infty}}
-\newcommand\sumin{\dis\sum\limits_{i=1}^{n}}
-\newcommand\sumizn{\dis\sum\limits_{i=0}^{n}}
-
-\newcommand\sumk{\dis\sum\limits_{k=1}^{\infty}}
-\newcommand\sumkz{\dis\sum\limits_{k=0}^{\infty}}
-\newcommand\sumkn{\dis\sum\limits_{k=0}^n}
-\newcommand\sumkfn{\dis\sum\limits_{k=1}^n}
-
-\newcommand\pzx{\dis\frac{\partial z}{\partial x}}
-\newcommand\pzy{\dis\frac{\partial z}{\partial y}}
-
-\newcommand\pfx{\dis\frac{\partial f}{\partial x}}
-\newcommand\pfy{\dis\frac{\partial f}{\partial y}}
-
-\newcommand\pzxx{\dis\frac{\partial^2 z}{\partial x^2}}
-\newcommand\pzxy{\dis\frac{\partial^2 z}{\partial x\partial y}}
-\newcommand\pzyx{\dis\frac{\partial^2 z}{\partial y\partial x}}
-\newcommand\pzyy{\dis\frac{\partial^2 z}{\partial y^2}}
-
-\newcommand\pfxx{\dis\frac{\partial^2 f}{\partial x^2}}
-\newcommand\pfxy{\dis\frac{\partial^2 f}{\partial x\partial y}}
-\newcommand\pfyx{\dis\frac{\partial^2 f}{\partial y\partial x}}
-\newcommand\pfyy{\dis\frac{\partial^2 f}{\partial y^2}}
-
-\newcommand\intzi{\dis\int_{0}^{+\infty}}
-\newcommand\intd{\dis\int}
-\newcommand\intab{\dis\int_a^b}
-
-\newcommand{\degree}{^\circ}
-
-\newcommand\ma{\mathcal{A}}
-\newcommand\mb{\mathcal{B}}
-\newcommand\mc{\mathcal{C}}
-\newcommand\me{\mathcal{E}}
-\newcommand\mg{\mathcal{g}}
-
-\newcommand\mcc{\mathbb{C}}
-\newcommand\mrr{\mathbb{R}}
-\newcommand\mzz{\mathbb{Z}}
-
-\newcommand\mx{\bf{x}}
-\newcommand\mX{\bf{X}}
-\newcommand\my{\bf{y}}
-\newcommand\mY{\bf{Y}}
-%%=============================================
-
-%%=====定义新数学符号===============================
-\DeclareMathOperator{\sgn}{sgn}
-\DeclareMathOperator{\arccot}{arccot}
-\DeclareMathOperator{\arccosh}{arccosh}
-\DeclareMathOperator{\arcsinh}{arcsinh}
-\DeclareMathOperator{\arctanh}{arctanh}
-\DeclareMathOperator{\arccoth}{arccoth}
-\DeclareMathOperator{\grad}{\bf{grad}}
-\DeclareMathOperator{\argmax}{argmax}
-\DeclareMathOperator{\argmin}{argmin}
-\DeclareMathOperator{\diag}{diag}
-\DeclareMathOperator{\csign}{csign}
-%===============================================
-
-%%===============================================
-%% End of file `HITSZThesis.cls'
-%%=============================================== \ No newline at end of file
diff --git a/macros/latex/contrib/hitszthesis/hitszthesis.dtx b/macros/latex/contrib/hitszthesis/hitszthesis.dtx
new file mode 100644
index 0000000000..ffb6069343
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/hitszthesis.dtx
@@ -0,0 +1,2401 @@
+% \iffalse meta-comment
+%
+% Copyright (C) 2019-2020 by Jingxuan Yang <yanglatex2e@gmail.com>
+%
+% This work may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+% http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2005/12/01 or later.
+%
+% This work has the LPPL maintenance status `maintained'.
+%
+% \fi
+%
+% \iffalse
+%<*driver>
+\ProvidesFile{hitszthesis.dtx}[2020/02/18 v2.0 A Bachelor Thesis Template for Harbin Institute of Technology, ShenZhen (HITSZ) ]
+\documentclass{ltxdoc}
+\usepackage{dtx-style}
+
+\EnableCrossrefs
+\CodelineIndex
+\RecordChanges
+
+\begin{document}
+ \DocInput{\jobname.dtx}
+\end{document}
+%</driver>
+% \fi
+%
+% \GetFileInfo{\jobname.dtx}
+%
+% \DoNotIndex{\newenvironment,\@bsphack,\@empty,\@esphack,\sfcode}
+% \DoNotIndex{\addtocounter,\label,\let,\linewidth,\newcounter}
+% \DoNotIndex{\noindent,\normalfont,\par,\parskip,\phantomsection}
+% \DoNotIndex{\providecommand,\ProvidesPackage,\refstepcounter}
+% \DoNotIndex{\RequirePackage,\setcounter,\setlength,\string,\strut}
+% \DoNotIndex{\textbackslash,\texttt,\ttfamily,\usepackage}
+% \DoNotIndex{\begin,\end,\begingroup,\endgroup,\par,\\}
+% \DoNotIndex{\if,\ifx,\ifdim,\ifnum,\ifcase,\else,\or,\fi}
+% \DoNotIndex{\let,\def,\xdef,\edef,\newcommand,\renewcommand}
+% \DoNotIndex{\expandafter,\csname,\endcsname,\relax,\protect}
+% \DoNotIndex{\Huge,\huge,\LARGE,\Large,\large,\normalsize}
+% \DoNotIndex{\small,\footnotesize,\scriptsize,\tiny}
+% \DoNotIndex{\normalfont,\bfseries,\slshape,\sffamily,\interlinepenalty}
+% \DoNotIndex{\textbf,\textit,\textsf,\textsc}
+% \DoNotIndex{\hfil,\par,\hskip,\vskip,\vspace,\quad}
+% \DoNotIndex{\centering,\raggedright,\ref}
+% \DoNotIndex{\c@secnumdepth,\@startsection,\@setfontsize}
+% \DoNotIndex{\ ,\@plus,\@minus,\p@,\z@,\@m,\@M,\@ne,\m@ne}
+% \DoNotIndex{\@@par,\DeclareOperation,\RequirePackage,\LoadClass}
+% \DoNotIndex{\AtBeginDocument,\AtEndDocument}
+% \DoNotIndex{\widowpenalty,\vfill,\usetikzlibrary,\usecounter}
+% \DoNotIndex{\underline,\to,\text,\textsuperscript,\textwidth}
+% \DoNotIndex{\thanks,\subsubsection,\subsection,\sloppy,\rule}
+% \DoNotIndex{\ProvidesClass,\makebox,\makeatletter,\makeatother}
+% \DoNotIndex{\,,\.,\;}
+%
+% \changes{v1.0}{2019/9/26}{Initial creation}
+% \changes{v1.1}{2019/10/30}{Fix loading \pkg{mtpro2} bug, add \pkg{etex} package}
+% \changes{v1.2}{2020/02/15}{Add two options: onerow or tworow, infoleft or infocenter, migrate settings file into cls file, initial commit on ctan}
+% \changes{v2.0}{2020/02/18}{Format cls file to dtx file, regulate thesis template for HITSZ}
+%
+% \def\indexname{索引}
+% \def\glossaryname{修改记录}
+% \IndexPrologue{\section{\indexname}}
+% \GlossaryPrologue{\section{\glossaryname}}
+%
+% \definecolor{hitcolor}{RGB}{21,95,130}
+% \title{\bfseries\color{hitcolor}\hitszthesis:哈尔滨工业大学(深圳)\\ 本科毕业设计(论文)模板}
+% \author{{\Large\fangsong 杨敬轩}\\[5pt]\texttt{yanglatex2e@gmail.com}\\[5pt]\texttt{yangjingxuan@stu.hit.edu.cn}}
+% \date{\fileversion\ (\filedate)}
+% \maketitle\thispagestyle{empty}
+%
+% \vskip0.5cm
+%
+% \def\abstractname{\Large 摘要}
+% \begin{abstract}\normalsize\vskip0.5cm
+% \hitszthesis 宏包旨在建立一个规格严格、功夫到家的哈尔滨工业大学(深圳)学位论文模板,目前只包含本科毕业设计(论文)模板。模板的构建基于 \pkg{hitszthesis.dtx} 与 \pkg{hitszthesis.ins},在使用本模板之前,请仔细阅读\file{hitszthesis.pdf}(本文件)、\file{main.tex}(撰写示例)及\file{main.pdf}(撰写效果)。
+% \end{abstract}
+%
+% \vskip1.5cm
+% \def\abstractname{\Large 免责声明}
+% \begin{abstract}
+% \normalsize\noindent
+% \begin{enumerate}
+% \item 本模板的发布遵守 \href{http://www.latex-project.org/lppl.txt}{\LaTeX\ Project Public License},使用前请认真阅读协议内
+% 容。
+% \item 本模板为作者根据哈尔滨工业大学(深圳)教务处颁发的《本科毕业设计(论文)撰写规范》、《书写范例》
+% 编写而成,旨在供哈尔滨工业大学(深圳)本科毕业生撰写学位论文使用。
+% \item 哈尔滨工业大学(深圳)教务处只提供毕业论文写作指南,不提供官方模板,也不会授
+% 权第三方模板为官方模板,所以此模板仅为写作指南的参考实现,不保证格式审查老师
+% 不提意见。任何由于使用本模板而引起的论文格式审查问题均与本模板作者无关。
+% \item 任何个人或组织以本模板为基础进行修改、扩展而生成的新的专用模板,请严格遵
+% 守 \href{http://www.latex-project.org/lppl.txt}{\LaTeX\ Project Public License} 协议。由于违犯协议而引起的任何纠纷争端均与
+% 本模板作者无关。
+% \end{enumerate}
+% \end{abstract}
+%
+%
+% \clearpage
+% \pagestyle{fancy}
+% \begin{multicols}{2}[
+% \setlength{\columnseprule}{.4pt}
+% \setlength{\columnsep}{18pt}]
+% \large
+% \tableofcontents
+% \end{multicols}
+% \clearpage
+%
+% \section{模板介绍}
+% \hitszthesis\ (\textbf{H}arbin \textbf{I}nstitute of \textbf{T}echnology,
+% \textbf{S}hen\textbf{Z}hen \LaTeX\
+% \textbf{Thesis} Template) 是为了帮助哈尔滨工业大学(深圳)本科毕业生撰写毕业论文而编写
+% 的 \LaTeX\ 论文模板。
+%
+% 本文档将尽量完整的介绍模板的使用方法,如有不清楚之处可以参考示例文档或者根据
+% 第~\ref{sec:howtoask} 节说明提问,有兴趣者可以联系作者参与完善此手册,非常欢迎窝工学子对本代码作出贡献。
+%
+% \note[注意:]{模板的作用在于减少论文写作过程中格式调整的时间。前提是遵守模板的
+% 用法,否则即便用了 \textup{\hitszthesis}\ 也难以保证输出的论文符合学校规范。}
+%
+%
+% \section{安装}
+% \label{sec:installation}
+%
+% \hitszthesis\ 已经上传CTAN,将包含在2020年主要的 \TeX\ 发行版中。% 安装方法:打开命令行,输入以下命令即可
+% \begin{shell}
+% $ tlmgr install hitszthesis
+% \end{shell}
+% 阅读本说明文档可以使用以下命令:
+% \begin{shell}
+% $ texdoc hitszthesis
+% \end{shell}
+%
+% 如果要使用开发版,需自己下载,\hitszthesis\ 相关链接:
+% \begin{itemize}
+% \item 主页:\href{https://github.com/YangLaTeX/hitszthesis}{GitHub}
+% \item 下载:\href{http://www.ctan.org/pkg/hitszthesis}{CTAN}
+% \end{itemize}
+%
+% \subsection{模板的组成}
+% 下表列出了 \hitszthesis\ 的主要文件及其功能介绍:
+%
+% \begin{longtable}{l|p{8cm}}
+% \toprule
+% {\heiti 文件(夹)} & {\heiti 功能描述}\\\midrule
+% \endfirsthead
+% \midrule
+% {\heiti 文件(夹)} & {\heiti 功能描述}\\\midrule
+% \endhead
+% \endfoot
+% \endlastfoot
+% hitszthesis.ins & \textsc{DocStrip} 驱动文件(开发用) \\
+% hitszthesis.dtx & \textsc{DocStrip} 源文件(开发用)\\\midrule
+% hitszthesis.cls & 模板类文件(由上述两个文件生成)\\\midrule
+% main.tex & 示例文档主文件\\
+% spine.tex & 书脊示例文档\\
+% figure/ & 示例文档插图路径\\
+% front/ & 示例文档封面插图路径\\
+% hitszthesis.sty & 为示例文档加载其它宏包\\\midrule
+% Makefile & Makefile\\
+% latexmkrc & latexmk 配置文件 \\
+% README.md & Readme\\
+% \textbf{hitszthesis.pdf} & 用户手册(本文档)\\\bottomrule
+% \end{longtable}
+%
+% 几点说明:
+% \begin{itemize}
+% \item \file{hitszthesis.cls} 可由 \file{hitszthesis.ins}
+% 和 \file{hitszthesis.dtx} 生成,但为了降低同学们的使用难度,故
+% 将 \file{hitszthesis.cls} 文件一起发布。
+% \item 使用前请一定阅读文档:\file{hitszthesis.pdf}。
+% \end{itemize}
+%
+% \subsection{生成模板}
+% \label{sec:generate-cls}
+% \note[提示:]{若使用 \TeX 发行版自带的 \textup{\hitszthesis}\ 或 Github 上发布的版本,可忽
+% 略此节,直接阅读第~\ref{sec:generate-thesis} 节。若下载 CTAN 包或者 Github 开发
+% 代码,请阅读本节了解生成模板文件的步骤。}
+%
+% 模板解压缩后生成文件夹 \file{hitszthesis-vX.Y}\footnote{\texttt{vX.Y} 为版本
+% 号。},其中包括:模板源文件(\file{hitszthesis.ins} 和 \file{hitszthesis.dtx}),示例文档
+% (\file{main.tex},\file{spine.tex},\file{hitszthesis.sty}\footnote{可能用到的包
+% 以及一些命令定义都放在这里,以免 \file{hitszthesis.cls} 过分臃
+% 肿。},文件夹\file{figure/} 和 \file{front/} 。在使用之前需要先生成模
+% 板文件和配置文件(具体命令细节请参考 \file{README.md} 和 \file{Makefile}):
+%
+% \begin{shell}
+% $ cd hitszthesis-vX.Y
+% # 生成 hitszthesis.cls 与 dtx-style.sty
+% $ xetex hitszthesis.ins
+%
+% # 下面的命令用来生成用户手册,首先生成索引
+% $ xelatex hitszthesis.dtx
+% $ makeindex -s gind.ist -o hitszthesis.ind hitszthesis.idx
+% $ makeindex -s gglo.ist -o hitszthesis.gls hitszthesis.glo
+%
+% # 最后两次编译生成说明文档 hitszthesis.pdf
+% $ xelatex hitszthesis.dtx
+% $ xelatex hitszthesis.dtx
+% \end{shell}
+%
+% \subsection{生成论文}
+% \label{sec:generate-thesis}
+% 本节介绍几种常见的生成论文的方法。用户可根据自己的情况选择。
+%
+% \subsubsection{\XeLaTeX}
+% \label{sec:xelatex}
+% 很多用户对 \LaTeX\ 命令执行的次数不太清楚。一个基本的原则是多次运行 \LaTeX\ 命
+% 令直至不再出现警告。下面给出生成示例文档的详细过程(\texttt{\#} 开头的行为注
+% 释),首先来看推荐的 \texttt{xelatex} 方式:
+% \begin{shell}
+% # 1. 发现里面的引用关系,文件后缀 .tex 可以省略
+% $ xelatex main
+%
+% # 2. 编译参考文件源文件,生成 bbl 文件
+% $ bibtex main
+%
+% # 3. 下面解决引用
+% $ xelatex main
+% $ xelatex main # 此时生成完整的 pdf 文件
+% \end{shell}
+%
+% \subsubsection{latexmk}
+% \label{sec:latexmk}
+% \texttt{latexmk} 命令支持全自动生成 \LaTeX\ 编写的文档,并且支持使用不同的工具
+% 链来进行生成,它会自动运行多次工具直到交叉引用都被解决。下面给出了一个用
+% \texttt{latexmk} 调用 \texttt{xelatex} 生成最终文档的示例:
+% \begin{shell}
+% $ latexmk main.tex # 生成论文 main.pdf
+% $ latexmk spine.tex # 生成书脊 spine.pdf
+% $ latexmk hitszthesis.dtx # 生成说明文档 hitszthesis.pdf
+% $ latexmk -c # 清理编译生成的辅助文件
+% \end{shell}
+%
+% \subsubsection{GNU make}
+% \label{sec:make}
+% \note[提示:]{若要使用 \texttt{make} 编译,需自行下载模板。因为 \TeX\ 发行版中
+% 的 \file{Makefile} 不在当前目录。}
+%
+% 上面的方法虽然不困难,但是每次都输入还是非常麻烦,所以 \hitszthesis\ 提供了一
+% 个 \file{Makefile}。如果可以使用 GNU make 工具,
+% 则使用 \texttt{make} 生成文件是最方便的办法。
+%
+% \begin{shell}
+% $ make clean # 清理辅助文件
+% $ make cls # 生成 hitszthesis.cls
+% $ make doc # 生成说明文档 hitszthesis.pdf
+% $ make thesis # 生成示例文档 main.pdf
+% $ make spine # 生成书脊 spine.pdf
+% \end{shell}
+%
+% \hitszthesis\ 的 \file{Makefile} 默认用 \texttt{latexmk} 调用\texttt{xelatex} 编
+% 译。如有需要可修
+% 改 \file{Makefile} 开头的参数或通过命令行传递参数(请参看 \file{README.md}),
+% 进一步还可以修改 \file{latexmkrc} 进行定制。
+%
+% \subsection{升级}
+% \label{sec:updgrade}
+% \hitszthesis\ 升级非常简单,可以通过 \TeX\ 发行版的包管理工具自动更新发行版,
+% \begin{shell}
+% # 更新 hitszthesis 宏包
+% $ tlmgr update hitszthesis
+% # 或者直接更新全部宏包至最新版
+% $ tlmgr update --all
+% \end{shell}
+%
+% 也可以下载最新的开发版,将 \file{hitszthesis.ins},\file{hitszthesis.dtx},拷贝至工作目录覆盖相应的文件,然后运行:
+% \begin{shell}
+% $ xetex hitszthesis.ins
+% \end{shell}
+% 生成新的类文件和配置文件即可。
+%
+% 还可以直接拷贝 \file{hitszthesis.cls}替换原有文件,避免执行上面的命令行。
+%
+% \section{使用说明}
+% \label{sec:usage}
+% 本手册假定用户已经能处理一般的 \LaTeX\ 文档,并对 \BibTeX\ 有一定了解。如果
+% 从来没有接触过 \TeX\ 和 \LaTeX,建议先学习相关的基础知识。
+%
+% \subsection{关于提问}
+% \label{sec:howtoask}
+% 按照优先级推荐提问的位置如下:
+%
+% \begin{itemize}
+% \item Github Issues: \href{http://github.com/YangLaTeX/hitszthesis/issues}{http://github.com/YangLaTeX/hitszthesis/issues}
+% \item QQ group: 1039392552
+% \item Email: \href{mailto:yanglatex2e@gmail.com}{yanglatex2e@gmail.com}, \href{mailto:yangjingxuan@stu.hit.edu.cn}{yangjingxuan@stu.hit.edu.cn}
+% \end{itemize}
+%
+% \subsection{示例文件}
+% \label{sec:userguide}
+%
+% 模板核心文件为:\file{hitszthesis.cls},
+% 但如果没有示例文档会很难下手,所以推荐从模板自带的示例文档入手,其中包括了论文
+% 写作用到的所有命令及其使用方法,只需要用自己的内容进行相应替换就可以。对于不清
+% 楚的命令可以查阅本手册。下面的例子描述了模板中章节的组织形式,来自于示例文档,
+% 具体内容可以参考模板附带的 \file{main.tex}。
+%
+% \lstinputlisting[style=lstStyleLaTeX]{main.tex}
+%
+% \subsection{论文选项}
+% \label{sec:option}
+%
+% \DescribeOption{covertitle}
+% 选择论文类型,当前支持:\option{onerow},\option{tworow},其中
+% \option{onerow}为默认选项。
+% \begin{latex}
+% % 封面标题两行
+% \documentclass[covertitle=tworow]{hitszthesis}
+% \end{latex}
+%
+% \DescribeOption{infoalign}
+% 论文封面第二页下划线部分内容对齐方式。可选:\option{infoleft},\option{infocenter},其中\option{infocenter}为默认选项。
+% \begin{latex}
+% % 封面第二页信息居左对齐
+% \documentclass[infoalign=infoleft]{hitszthesis}
+% \end{latex}
+%
+% \subsection{引用方式}
+% \label{sec:citestyle}
+%
+% \myentry{引用}
+% \DescribeMacro{\upcite}
+% 学校要求的参考文献引用有两种模式:(1)上标模式。比如“同样的工作有很
+% 多$^{[1,2]}$\ldots”。(2)正文模式。比如“文[3] 中详细说明了\ldots”。其中上标
+% 模式采用 \cs{upcite}\marg{key},而 \cs{cite}\marg{key} 则用来生成正文模式。
+%
+% 关于参考文献表推荐使用 \cs{thebibliography} 环境,虽然有些麻烦,
+% 但是避免了使用 \BibTeX 带来的很多格式设置问题。
+% 有余力者可以尝试使用 \BibTeX,
+% \BibTeX 默认情况下可以自动识别文献语言,
+% 并自动处理文献类型和载体类型标识,也可以手动指定,如:
+% \begin{latex}
+% @misc{citekey,
+% language = {japanese},
+% mark = {Z},
+% medium = {DK},
+% ...
+% \end{latex}
+% 可选的语言有 english, chinese, japanese, russian。
+%
+% \subsection{中文字体}
+% \label{sec:chinese-fonts}
+%
+% \subsubsection{字体配置}
+% \label{sec:font-config}
+% 模板默认使用 \CTeX\ 的字体配置。关于中文字体安装、配置的所有问题不在本模板讨论
+% 范围。
+%
+% \subsubsection{字体命令}
+% \label{sec:fontcmds}
+% \myentry{字体}
+% \DescribeMacro{\songti}
+% \DescribeMacro{\fangsong}
+% \DescribeMacro{\heiti}
+% \DescribeMacro{\kaishu}
+% 用来切换宋体、仿宋、黑体、楷体四种基本字体。
+%
+% \begin{latex}
+% {\songti 乾:元,亨,利贞}
+% {\fangsong 初九,潜龙勿用}
+% {\heiti 九二,见龙在田,利见大人}
+% {\kaishu 九三,君子终日乾乾,夕惕若,厉,无咎}
+% \end{latex}
+%
+% \myentry{字号}
+% \DescribeMacro{\chuhao}
+% \DescribeMacro{\xiaochu}
+% \DescribeMacro{\yihao}
+% \DescribeMacro{\xiaoyi}
+% \DescribeMacro{\bahao}
+% 定义字体大小,分别为:
+%
+% \begin{center}
+% \begin{tabular}{llllll}
+% \toprule
+% \cs{chuhao} & \cs{xiaochu} & \cs{yihao} & \cs{xiaoyi} & \cs{erhao} & \cs{xiaoer}\\
+% \cs{sanhao} & \cs{xiaosan} & \cs{sihao} & \cs{xiaosi} & \cs{wuhao} & \cs{xiaowu}\\
+% \cs{liuhao} & \cs{xiaoliu} & \cs{qihao} & \cs{bahao}\\\bottomrule
+% \end{tabular}
+% \end{center}
+%
+% 使用方法为:\cs{command}\oarg{num},其中 \cs{command} 为字号命令,\meta{num} 为行距。比
+% 如 \cs{xiaosi}[1.5] 表示选择小四字体,行距 1.5 倍。
+%
+% \begin{latex}
+% {\erhao 二号}
+% {\sanhao[1.5] 三号,一点五倍行距}
+% {\sihao 四号}
+% {\qihao[2] 七号,两倍行距}
+% \end{latex}
+%
+% 也可以使用 \CTeX\ 定义的 \cs{zihao}\marg{num} 来切换字号,具体用法参看其文
+% 档。
+%
+% \subsection{封面信息}
+% \label{sec:titlepage}
+% 封面信息配置方法:每个信息利用命令独立设置,大多数命令的使用方法都是 \cs{command}\marg{arg},例外者将具体指出。
+%
+% \myentry{封面信息}
+% \DescribeMacro{\thesistitle}
+% \cs{thesistitle}\marg{arg},输入论文标题
+%
+% \DescribeMacro{\titleone}
+% \cs{titleone}\marg{arg},输入论文标题第一行
+%
+% \DescribeMacro{\titletwo}
+% \cs{titletwo}\marg{arg},输入论文标题第二行
+%
+% \DescribeMacro{\schoolname}
+% \cs{schoolname}\marg{arg},输入学校名称
+%
+% \DescribeMacro{\departname}
+% \cs{departname}\marg{arg},输入学院名称
+%
+% \DescribeMacro{\majorin}
+% \cs{majorin}\marg{arg},输入专业
+%
+% \DescribeMacro{\authorname}
+% \cs{authorname}\marg{arg},输入姓名
+%
+% \DescribeMacro{\studentID}
+% \cs{studentID}\marg{arg},输入学号
+%
+% \DescribeMacro{\dateinput}
+% \cs{dateinput}\marg{arg},输入答辩日期
+%
+% \DescribeMacro{\instructor}
+% \cs{instructor}\marg{arg},输入指导教师
+%
+% \subsubsection{摘要}
+% \myentry{摘要关键词}
+% \DescribeEnv{abstract}
+% \DescribeEnv{abstracten}
+% \DescribeMacro{\keywords}
+% \DescribeMacro{\keywordsen}
+% \begin{latex}
+% \begin{abstract}
+% 摘要请写在这里...
+% \keywords{xxx}
+% \end{abstract}
+%
+% \begin{abstracten}
+% Here comes the abstract in English...
+% \keywordsen{xxx}
+% \end{abstracten}
+% \end{latex}
+%
+% \subsection{目录和索引表}
+% 目录、插图和表格等索引命令分别如下,
+% 将其插入到期望的位置即可
+% (带星号的命令表示对应的索引表不会出现在目录中):
+%
+% \myentry{目录索引}
+% \DescribeMacro{\tableofcontents}
+% \DescribeMacro{\listoffigures}
+% \DescribeMacro{\listoffigures*}
+% \DescribeMacro{\listoftables}
+% \DescribeMacro{\listoftables*}
+% \begin{longtable}{ll}
+% \toprule
+% {\heiti 用途} & {\heiti 命令} \\\midrule
+% 目录 & \cs{tableofcontents} \\\midrule
+% 插图索引 & \cs{listoffigures} \\
+% & \cs{listoffigures*} \\\midrule
+% 表格索引 & \cs{listoftables} \\
+% & \cs{listoftables*} \\\bottomrule
+% \end{longtable}
+%
+% \LaTeX\ 默认支持插图和表格索引,是通过 \cs{caption} 命令完成的,因此它们必须出
+% 现在浮动环境中,否则不被计数。
+%
+% 如果不想让某个表格或者图片出现在索引里面,那么请使用命令 \cs{caption*},这
+% 个命令不会给表格编号,也就是出来的只有标题文字而没有“表~xx”,“图~xx”,
+%
+% \subsection{封底部分}
+%
+% \subsubsection{原创性声明}
+% \myentry{声明}
+% \DescribeMacro{\declaration}
+% \cs{declaration}会自动生成原创性声明的全部内容,其中签字部分需要打印后手签。
+%
+% \subsubsection{附录}
+% \myentry{附录}
+% \DescribeMacro{\appendix}
+% 附录里主要是外文资料以及翻译,放置在 |\appendix| 后面即可。
+%
+% \subsection{自定义}
+% \label{sec:othercmd}
+%
+% \subsubsection{数学环境}
+% \label{sec:math}
+% \hitszthesis\ 定义了常用的数学环境:
+%
+% \begin{center}
+% \begin{tabular}{*{8}{l}}\toprule
+% axiom & theorem & definition & proposition & lemma & postulate &note& conclusion\\
+% 公理 & 定理 & 定义 & 命题 & 引理 & 公设 &笔记& 结论\\\midrule
+% proof & corollary & example & exercise & assumption & remark & problem & property\\
+% 证明 & 推论 & 例& 练习 & 假设 & 注 & 问题 & 性质\\\bottomrule
+% \end{tabular}
+% \end{center}
+%
+% 比如:
+% \begin{latex}
+% \begin{definition}
+% 道千乘之国,敬事而信,节用而爱人,使民以时。
+% \end{definition}
+% \end{latex}
+% 产生(自动编号):
+% \medskip
+%
+% \noindent\framebox[\linewidth][l]{{\heiti 定义~1.1~~~} % {道千乘之国,敬事而信,节用而爱人,使民以时。}}
+%
+% \smallskip
+% 列举出来的数学环境毕竟是有限的,如果想用\emph{胡说}这样的数学环境,那么可以定义:
+% \begin{latex}
+% \theoremstyle{ydefstyle}
+% \newtheorem{ydefinition}{nonsense}[chapter]
+% \end{latex}
+%
+% 然后这样使用:
+% \begin{latex}
+% \begin{nonsense}
+% 契丹武士要来中原夺武林秘笈。—— 慕容博
+% \end{nonsense}
+% \end{latex}
+% 产生(自动编号):
+%
+% \medskip
+% \noindent\framebox[\linewidth][l]{{\heiti 胡说~1.1~~~} % {契丹武士要来中原夺武林秘笈。—— 慕容博}}
+%
+% \subsubsection{列表环境}
+% \myentry{列表}
+% \DescribeEnv{itemize}
+% \DescribeEnv{enumerate}
+% \DescribeEnv{description}
+% 为了适合中文习惯,模板将这三个常用的列表环境用 \pkg{enumitem} 进行了纵向间距压
+% 缩。一方面清除了多余空间,另一方面用户可以自己指定列表环境的样式(如标签符号,
+% 缩进等)。细节请参看 \pkg{enumitem} 文档,此处不再赘述。
+%
+% \subsection{书脊}
+% \myentry{书脊}
+% \DescribeMacro{\spine}
+% 生成装订的书脊,为竖排格式,命令格式:\cs{spine}\oarg{标题}\oarg{作者}。默认参
+% 数为论文中文题目和中文作者。如果中文题目中没有英文字母,那么直接调用此命令即可。
+% 否则,可参考参看模板示例文件 \file{spine.tex} 进行微调:
+%
+% \lstinputlisting[style=lstStyleLaTeX]{spine.tex}
+%
+% \section{致谢}
+% \label{sec:thanks}
+% 感谢|thuthesis|、|hithesis|、|elegantbook|模板的作者,本模板基于他们改编而来!
+%
+% 欢迎各位到 \href{http://github.com/YangLaTeX/hitszthesis/}{\hitszthesis\ Github 主页}贡献!
+%
+% \StopEventually{\PrintChanges\PrintIndex}
+% \clearpage
+%
+% \section{实现细节}
+%
+% \subsection{基本信息}
+% 设置需要的 \LaTeX 版本,定义提供的类文件名称以及说明文字
+% \begin{macrocode}
+%<cls>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
+%<cls>\ProvidesClass{hitszthesis}
+%<cls>[2020/02/18 v2.0 A Bachelor Thesis Template for Harbin Institute of Technology, ShenZhen
+%<cls> (HITSZ)]
+% \end{macrocode}
+%
+% 检查编译引擎,要求使用 \XeLaTeX,否则提示错误
+% \begin{macrocode}
+\RequirePackage{ifxetex}
+\ifxetex\else
+ \ClassError{hitszthesis}{Please use XeLaTeX to compile the file}{}
+ \end{document}
+\fi
+% \end{macrocode}
+%
+% \subsection{定义选项}
+% 加载键值对设置宏包
+% \begin{macrocode}
+%<*cls>
+\RequirePackage{kvoptions}
+% \end{macrocode}
+%
+% 加载对宏包、环境、命令进行操作的强大宏包
+% \begin{macrocode}
+\RequirePackage{etoolbox}
+% \end{macrocode}
+%
+% 设置关键词:|hitsz|
+% \begin{macrocode}
+\SetupKeyvalOptions{family=hitsz, prefix=hitsz@, setkeys=\kvsetkeys}
+% \end{macrocode}
+%
+% \begin{macro}{\ykv}
+% 定义设置关键词命令 \cs{ykv}
+% \begin{macrocode}
+\newcommand{\ykv}[1]{\kvsetkeys{hitsz}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% 表格信息对齐
+% \begin{macrocode}
+\DeclareStringOption[infocenter]{infoalign}
+\DeclareVoidOption{infocenter}{\ykv{infoalign = infocenter}}
+\DeclareVoidOption{infoleft}{\ykv{infoalign = infoleft}}
+% \end{macrocode}
+%
+% 封面标题行数
+% \begin{macrocode}
+\DeclareStringOption[onerow]{covertitle}
+\DeclareVoidOption{onerow}{\ykv{covertitle = onerow}}
+\DeclareVoidOption{tworow}{\ykv{covertitle = tworow}}
+% \end{macrocode}
+%
+% 数学字体选择
+% \begin{macrocode}
+\DeclareStringOption[newtxmath]{mathfont}
+\DeclareVoidOption{newtxmath}{\ykv{mathfont = newtxmath}}
+\DeclareVoidOption{mtpro2}{\ykv{mathfont = mtpro2}}
+% \end{macrocode}
+%
+% 默认选项
+% \begin{macrocode}
+\DeclareDefaultOption{\PassOptionsToClass{\CurrentOption}{book}}
+% \end{macrocode}
+%
+% 禁用键值对操作
+% \begin{macrocode}
+\ProcessKeyvalOptions*\relax
+% \end{macrocode}
+%
+% 加载 |book| 类,A4大小,正文12磅,单面打印
+% \begin{macrocode}
+\LoadClass[12pt,a4paper,openany,oneside]{book}
+% \end{macrocode}
+%
+% \subsection{加载宏包}
+% 使用 \XeLaTeX 编译 \pkg{mtpro2} 宏包必须加载此宏包
+% \begin{macrocode}
+\RequirePackage{etex}
+% \end{macrocode}
+%
+% 加载支持中文的 \pkg{ctex} 宏包
+% \begin{macrocode}
+\RequirePackage[UTF8,space=auto,scheme=plain]{ctex}
+% \end{macrocode}
+%
+% 正文和数学字体设置
+% \begin{macrocode}
+\RequirePackage{amsmath}
+\RequirePackage[T1]{fontenc}
+\RequirePackage{newtxtext}
+\ifdefstring{\hitsz@mathfont}{mtpro2}{
+\RequirePackage[mtphrb,mtpcal,zswash,uprightGreek]{mtpro2}
+}{\relax}
+\ifdefstring{\hitsz@mathfont}{newtxmath}{
+\RequirePackage{newtxmath}
+\let\openbox\relax
+}{\relax}
+\renewcommand{\rmdefault}{ptm}
+\RequirePackage[scaled=0.92]{helvet}
+\RequirePackage{type1cm}
+\RequirePackage{lipsum}
+% \end{macrocode}
+%
+% 使字体设置生效,排除其他干扰,不一定起作用,但为防万一需要保留
+% \begin{macrocode}
+\RequirePackage{mathdesign}
+% \end{macrocode}
+%
+% \begin{macro}{\kai}
+% \begin{macro}{\song}
+% 设置中文加粗字体
+% \begin{macrocode}
+\setCJKfamilyfont{kai}[AutoFakeBold]{simkai.ttf}
+\newcommand*{\kai}{\CJKfamily{kai}}
+\setCJKfamilyfont{song}[AutoFakeBold]{SimSun}
+\newcommand*{\song}{\CJKfamily{song}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\linespread}
+% 行间距,设为1.3,due to 12pt与小四号字的大小微差
+% \begin{macrocode}
+\linespread{1.3}
+% \end{macrocode}
+% \end{macro}
+%
+% 加载常用宏包
+% 在一页上可以使用单栏和多栏样式
+% \begin{macrocode}
+\RequirePackage{multicol}
+% \end{macrocode}
+%
+% 排版代码
+% \begin{macrocode}
+\RequirePackage{fancyvrb}
+% \end{macrocode}
+%
+% 自定义目录格式
+% \begin{macrocode}
+\RequirePackage{titletoc}
+% \end{macrocode}
+%
+% 设置颜色
+% \begin{macrocode}
+\RequirePackage{xcolor}
+% \end{macrocode}
+%
+% 插入图片
+% \begin{macrocode}
+\RequirePackage{graphicx}
+% \end{macrocode}
+%
+% 表格
+% \begin{macrocode}
+\RequirePackage{array}
+% \end{macrocode}
+%
+% 长表格
+% \begin{macrocode}
+\RequirePackage{longtable}
+% \end{macrocode}
+%
+% \pkg{booktabs} 提供了\cs{toprule} 等命令
+% \begin{macrocode}
+\RequirePackage{booktabs}
+% \end{macrocode}
+%
+% \pkg{multirow} 支持在表格中跨行
+% \begin{macrocode}
+\RequirePackage{multirow}
+% \end{macrocode}
+%
+% 调整间隔, 让表格更好看些
+% \begin{macrocode}
+\RequirePackage{bigstrut}
+% \end{macrocode}
+%
+% 在跨行表格中输入定界符
+% \begin{macrocode}
+\RequirePackage{bigdelim}
+% \end{macrocode}
+%
+% 保护脆落命令
+% \begin{macrocode}
+\RequirePackage{cprotect}
+% \end{macrocode}
+%
+% 定制列表环境
+% \begin{macrocode}
+\RequirePackage{enumitem}
+% \end{macrocode}
+%
+% 设置代码环境
+% \begin{macrocode}
+\RequirePackage{listings}
+% \end{macrocode}
+%
+% 超链接格式设置
+% \begin{macrocode}
+\RequirePackage{hyperref}
+% \end{macrocode}
+%
+% \begin{macro}{\parindent}
+% 首行缩进
+% \begin{macrocode}
+\RequirePackage{indentfirst}
+\setlength\parindent{2em}
+% \end{macrocode}
+% \end{macro}
+%
+% 设置浮动体的标题
+% \begin{macrocode}
+\RequirePackage{caption}
+% \end{macrocode}
+%
+% 浮动环境
+% \begin{macrocode}
+\RequirePackage{float}
+% \end{macrocode}
+%
+% 下划线
+% \begin{macrocode}
+\RequirePackage{ulem}
+% \end{macrocode}
+%
+% 尺寸计算
+% \begin{macrocode}
+\RequirePackage{calc}
+% \end{macrocode}
+%
+% \pkg{tikz} 绘图
+% \begin{macrocode}
+\RequirePackage{tikz}
+% \end{macrocode}
+%
+% 公式字母加粗
+% \begin{macrocode}
+\RequirePackage{bm}
+% \end{macrocode}
+%
+% 子公式编号
+% \begin{macrocode}
+\RequirePackage{cases}
+% \end{macrocode}
+%
+% 书写单位
+% \begin{macrocode}
+\RequirePackage{siunitx}
+% \end{macrocode}
+%
+% \pkg{pdfpages} 宏包便于我们插入扫描后的授权页和声明页 PDF 文档。
+% \begin{macrocode}
+\RequirePackage{pdfpages}
+\includepdfset{fitpaper=true}
+% \end{macrocode}
+%
+% \begin{macro}{\ttdefault}
+% 排版代码
+% \begin{macrocode}
+\RequirePackage{listings}
+\renewcommand{\ttdefault}{cmtt}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\lstdefinestyle}
+% 定义 |ystyle| 样式
+% \begin{macrocode}
+\lstdefinestyle{ystyle}{
+ basicstyle=%
+ \ttfamily
+ \lst@ifdisplaystyle\small\fi
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\lstset}
+% 使用 |ystyle| 样式
+% \begin{macrocode}
+\lstset{basicstyle = \ttfamily, style = ystyle, breaklines = true}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\definecolor}
+% 定义代码颜色
+% \begin{macrocode}
+\definecolor{lightgrey}{rgb}{0.9,0.9,0.9}
+\definecolor{frenchplum}{RGB}{190,20,83}
+\definecolor{winered}{rgb}{0.5,0,0}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\lstset}
+% 设置 \LaTeX 代码排版样式
+% \begin{macrocode}
+\lstset{language = [LaTeX]TeX,
+ texcsstyle = *\color{winered},
+ numbers = none,
+ mathescape,
+ breaklines = true,
+ keywordstyle = \color{winered},
+ commentstyle = \color{gray},
+ emph = {hitszpaper,fontenc,fontspec,xeCJK,FiraMono,xunicode,newtxmath,
+ figure,fig,image,img,table,itemize,enumerate,newtxtext,newtxtt,
+ ctex, microtype,description,times,newtx,booktabs,tabular,
+ PDFLaTeX,XeLaTeX,type1cm,BibTeX,device,color,mode,lang,
+ amsthm,tcolorbox,titlestyle,cite,marginnote,ctex,listings,base,
+ subnumcases},
+ emphstyle = {\color{frenchplum}},
+ morekeywords = {DeclareSymbolFont,SetSymbolFont,toprule,midrule,bottomrule,
+ institute,version,includegraphics,setmainfont,setsansfont,
+ setmonofont,setCJKmainfont,setCJKsansfont,setCJKmonofont,
+ RequirePackage,figref, tabref,email,maketitle,keywords,definecolor,
+ extrainfo,logo,cover,subtitle,appendix,chapter,hypersetup,
+ mainmatter,frontmatter,tableofcontents, hitszpar,heiti,kaishu,lstset,
+ pagecolor,zhnumber,marginpar,part, equote,marginnote},
+ frame = single,
+ tabsize = 2,
+ rulecolor = \color{black},
+ framerule = 0.2pt,
+ columns = flexible,
+ % backgroundcolor = \color{lightgrey}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{输入信息}
+% \subsubsection{定义输入常量}
+% \begin{macro}{\hitsz@tokens@thesistitle}
+% 论文标题
+% \begin{macrocode}
+\newcommand\hitsz@tokens@thesistitle{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@keywords}
+% 关键词,中文
+% \begin{macrocode}
+\newcommand\hitsz@tokens@keywords{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@keywordsen}
+% 关键词,英文
+% \begin{macrocode}
+\newcommand\hitsz@tokens@keywordsen{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@papercategory}
+% 论文类别
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@papercategory{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@schoolname}
+% 学校名称
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@schoolname{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@departname}
+% 院系
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@departname{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@dateinput}
+% 日期
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@dateinput{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@authorname}
+% 姓名
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@authorname{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@studentID}
+% 学号
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@studentID{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@majorin}
+% 专业
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@majorin{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@instructor}
+% 指导教师
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@instructor{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@titleone}
+% 第一行标题
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@titleone{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\hitsz@tokens@titletwo}
+% 第二行标题
+% \begin{macrocode}
+\newcommand*\hitsz@tokens@titletwo{}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsubsection{定义与常量有关的新命令}
+%
+% \begin{macro}{\thesistitle}
+% 输入论文标题
+% \begin{macrocode}
+\newcommand*\thesistitle[1]{%
+ \renewcommand{\hitsz@tokens@thesistitle}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\papercategory}
+% 输入论文类别
+% \begin{macrocode}
+\newcommand*\papercategory[1]{%
+ \renewcommand{\hitsz@tokens@papercategory}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\schoolname}
+% 输入校名
+% \begin{macrocode}
+\newcommand*\schoolname[1]{%
+ \renewcommand{\hitsz@tokens@schoolname}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\departname}
+% 输入院系名称
+% \begin{macrocode}
+\newcommand*\departname[1]{%
+ \renewcommand{\hitsz@tokens@departname}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\dateinput}
+% 输入日期
+% \begin{macrocode}
+\newcommand*\dateinput[1]{%
+ \renewcommand{\hitsz@tokens@dateinput}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\authorname}
+% 输入姓名
+% \begin{macrocode}
+\newcommand*\authorname[1]{%
+ \renewcommand{\hitsz@tokens@authorname}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\studentID}
+% 输入学号
+% \begin{macrocode}
+\newcommand*\studentID[1]{%
+ \renewcommand{\hitsz@tokens@studentID}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\majorin}
+% 输入专业
+% \begin{macrocode}
+\newcommand*\majorin[1]{%
+ \renewcommand{\hitsz@tokens@majorin}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\instructor}
+% 输入指导教师
+% \begin{macrocode}
+\newcommand*\instructor[1]{%
+ \renewcommand{\hitsz@tokens@instructor}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\titleone}
+% 输入第一行标题
+% \begin{macrocode}
+\newcommand*\titleone[1]{%
+ \renewcommand{\hitsz@tokens@titleone}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\titletwo}
+% 输入第二行标题
+% \begin{macrocode}
+\newcommand*\titletwo[1]{%
+ \renewcommand{\hitsz@tokens@titletwo}{#1}}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{定义常量的值}
+% \begin{macro}{\listfigurename}
+% \begin{macro}{\listtablename}
+% \begin{macro}{\abstractname}
+% \begin{macro}{\keywordsname}
+% \begin{macro}{\keywordsenname}
+% \begin{macro}{\contentsname}
+% \begin{macro}{\figurename}
+% \begin{macro}{\tablename}
+% \begin{macro}{\partname}
+% \begin{macro}{\bibname}
+% \begin{macro}{\appendixname}
+% \begin{macro}{\indexname}
+% \begin{macro}{\notename}
+% \begin{macro}{\proofname}
+% \begin{macro}{\problemname}
+% \begin{macro}{\definitionname}
+% \begin{macro}{\theoremname}
+% \begin{macro}{\axiomname}
+% \begin{macro}{\postulatename}
+% \begin{macro}{\lemmaname}
+% \begin{macro}{\propositionname}
+% \begin{macro}{\corollaryname}
+% \begin{macro}{\examplename}
+% \begin{macro}{\exercisename}
+% \begin{macro}{\remarkname}
+% \begin{macro}{\assumptionname}
+% \begin{macro}{\conclusionname}
+% 中文标题名称设置
+% \begin{macrocode}
+\renewcommand\listfigurename{插图目录}
+\renewcommand\listtablename{附表目录}
+\renewcommand\abstractname{摘\quad 要}
+\newcommand{\keywordsname}{关键词}
+\newcommand{\keywordsenname}{Keywords}
+\renewcommand{\contentsname}{目\quad 录}
+\renewcommand{\figurename}{图}
+\renewcommand{\tablename}{表}
+\renewcommand{\partname}{部分}
+\renewcommand{\bibname}{参考文献}
+\renewcommand{\appendixname}{附录~\thechapter}
+\renewcommand{\indexname}{索\quad 引}
+\newcommand{\notename}{笔记}
+\renewcommand*{\proofname}{证明}
+\newcommand{\problemname}{问题}
+\newcommand{\definitionname}{定义}
+\newcommand{\theoremname}{定理}
+\newcommand{\axiomname}{公理}
+\newcommand{\postulatename}{公设}
+\newcommand{\lemmaname}{引理}
+\newcommand{\propositionname}{命题}
+\newcommand{\corollaryname}{推论}
+\newcommand{\examplename}{例}
+\newcommand{\exercisename}{练习}
+\newcommand{\remarkname}{注}
+\newcommand{\assumptionname}{假设}
+\newcommand{\conclusionname}{结论}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\solutionname}
+% \begin{macro}{\propertyname}
+% 继续定义
+% \begin{macrocode}
+\newcommand{\solutionname}{解}
+\newcommand{\propertyname}{性质}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \vskip0.3cm
+% \subsection{字号设置}
+% \begin{macro}{\hitsz@def@fontsize}
+% 中英字号转换
+% \begin{macrocode}
+\def\hitsz@def@fontsize#1#2{%
+ \expandafter\newcommand\csname #1\endcsname[1][1.3]{%
+ \fontsize{#2}{##1\dimexpr #2}\selectfont}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\chuhao}
+% \begin{macro}{\xiaochu}
+% \begin{macro}{\yihao}
+% \begin{macro}{\xiaoyi}
+% \begin{macro}{\erhao}
+% 定义一组字号
+% \begin{macrocode}
+\hitsz@def@fontsize{chuhao}{42bp}
+\hitsz@def@fontsize{xiaochu}{36bp}
+\hitsz@def@fontsize{yihao}{26bp}
+\hitsz@def@fontsize{xiaoyi}{24bp}
+\hitsz@def@fontsize{erhao}{22bp}
+% \end{macrocode}
+% \begin{macro}{\xiaoer}
+% \begin{macro}{\sanhao}
+% \begin{macro}{\xiaosan}
+% \begin{macro}{\sihao}
+% \begin{macro}{\banxiaosi}
+% \begin{macro}{\xiaosi}
+% \begin{macro}{\dawu}
+% \begin{macro}{\wuhao}
+% \begin{macro}{\xiaowu}
+% \begin{macro}{\liuhao}
+% \begin{macro}{\xiaoliu}
+% \begin{macro}{\qihao}
+% \begin{macro}{\bahao}
+% 继续定义字号
+% \begin{macrocode}
+\hitsz@def@fontsize{xiaoer}{18bp}
+\hitsz@def@fontsize{sanhao}{16bp}
+\hitsz@def@fontsize{xiaosan}{15bp}
+\hitsz@def@fontsize{sihao}{14bp}
+\hitsz@def@fontsize{banxiaosi}{13bp}
+\hitsz@def@fontsize{xiaosi}{12bp}
+\hitsz@def@fontsize{dawu}{11bp}
+\hitsz@def@fontsize{wuhao}{10.5bp}
+\hitsz@def@fontsize{xiaowu}{9bp}
+\hitsz@def@fontsize{liuhao}{7.5bp}
+\hitsz@def@fontsize{xiaoliu}{6.5bp}
+\hitsz@def@fontsize{qihao}{5.5bp}
+\hitsz@def@fontsize{bahao}{5bp}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \subsection{图片搜索目录设置}
+% \begin{macro}{\graphicspath}
+% 图片搜索目录
+% \begin{macrocode}
+\graphicspath{{./figure/}{./figures/}{./image/}{./images/}
+{./graphics/}{./graphic/}{./pictures/}{./picture/}{./front/}}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{页面设置}
+% \begin{macro}{\geometry}
+% 页面设置,按照撰写示例word模板设置页边距
+% \begin{macrocode}
+\RequirePackage{geometry}
+\geometry{
+ a4paper,
+ left=30mm,
+ right=30mm,
+ top=41mm,
+ bottom=30mm,
+ headheight = 2.17cm,
+ headsep = 1mm,
+ footskip = 0cm,
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{超链接设置}
+% \begin{macro}{\hypersetup}
+% 超链接设置,设置目录、图表公式引用的跳转
+% \begin{macrocode}
+\RequirePackage{hyperref}
+\hypersetup{
+ breaklinks,
+ unicode,
+ linktoc=all,
+ bookmarksnumbered=true,
+ bookmarksopen=true,
+ pdfsubject={哈尔滨工业大学(深圳)本科毕业设计(论文)},
+ pdftitle = {哈尔滨工业大学(深圳)本科毕业设计(论文)},
+ pdfauthor = {杨敬轩},
+ pdfkeywords={HITSZThesis, Dissertation},
+ pdfcreator={XeLaTeX with hitszthesis class},
+ colorlinks,
+ linkcolor=black,
+ citecolor=black,
+ plainpages=false,
+ pdfstartview=FitH,
+ pdfborder={0 0 0},
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{正文内容设置}
+% 章节设置
+% \begin{macrocode}
+\RequirePackage[pagestyles]{titlesec}
+\RequirePackage{apptools}
+% \end{macrocode}
+%
+% \begin{macro}{\setcounter}
+% \begin{macro}{\chaptername}
+% 更改章节编号样式
+% \begin{macrocode}
+\setcounter{secnumdepth}{3}
+\renewcommand{\chaptername}{第 \thechapter\;章}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\titleformat}
+% 设置章节标题样式
+% \begin{macrocode}
+\titleformat{\chapter}[hang]{\centering\heiti}
+{\filcenter\xiaoer\enspace\heiti{%
+\IfAppendix{\appendixname}{\chaptername}\enspace}}{1pt}{\xiaoer}
+% \end{macrocode}
+%
+% 设置节标题样式
+% \begin{macrocode}
+\titleformat{\section}[hang]{\heiti}
+{\xiaosan\heiti{\thesection}\enspace}{1pt}{\xiaosan\heiti\filright}
+% \end{macrocode}
+%
+% 设置条标题样式
+% \begin{macrocode}
+\titleformat{\subsection}[hang]{\heiti}
+{\sihao\heiti\thesubsection\enspace}{1pt}{\sihao\heiti\filright}
+% \end{macrocode}
+%
+% 设置四级标题样式
+% \begin{macrocode}
+\titleformat{\subsubsection}[hang]{\heiti}
+{\xiaosi\heiti\thesubsubsection\enspace}{1pt}{\xiaosi\heiti\filright}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\titlespacing}
+% 设置标题与上下文间距
+% \begin{macrocode}
+\titlespacing{\chapter}{0pt}{0bp}{14.4bp}
+\titlespacing{\section}{0pt}{7.5bp}{7.5bp}
+\titlespacing{\subsection}{0pt}{7bp}{7bp}
+\titlespacing{\subsubsection}{0pt}{6bp}{6bp}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\captionsetup}
+% 图表标题设置,字号为small,分割符为空格
+% \begin{macrocode}
+\RequirePackage[font=small,labelsep=quad]{caption}
+% \end{macrocode}
+%
+% 标题与图表的间距为3pt
+% \begin{macrocode}
+\captionsetup[table]{skip=3pt}
+\captionsetup[figure]{skip=10pt}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\figref}
+% \begin{macro}{\tabref}
+% \begin{macro}{\equref}
+% 图表的引用格式
+% \begin{macrocode}
+\newcommand\figref[1]{图\ref{#1}}
+\newcommand\tabref[1]{表\ref{#1}}
+\newcommand\equref[1]{式(\ref{#1})}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\setlist}
+% 设置列表环境各项间无自动间距
+% \begin{macrocode}
+\setlist{nolistsep}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{定理样式设置}
+% 定义各类定理样式
+% \begin{macrocode}
+\RequirePackage{amsthm}
+\let\proof\relax
+\let\endproof\relax
+% \end{macrocode}
+%
+% \begin{macro}{\newtheoremstyle}
+% 定义新定义样式
+% \begin{macrocode}
+\newtheoremstyle{ydefstyle}{3pt}{3pt}{\itshape}{}{\bfseries}{}{%
+ 0.5em}{\thmname{#1} \thmnumber{#2} \thmnote{(#3)}}
+% \end{macrocode}
+%
+% 定义新定理样式
+% \begin{macrocode}
+\newtheoremstyle{ythmstyle}{3pt}{3pt}{\itshape}{}{\bfseries}{}{%
+ 0.5em}{\thmname{#1} \thmnumber{#2} \thmnote{(#3)}}
+% \end{macrocode}
+%
+% 定义新命题样式
+% \begin{macrocode}
+\newtheoremstyle{yprostyle}{3pt}{3pt}{\itshape}{}{\bfseries}{}{%
+ 0.5em}{\thmname{#1} \thmnumber{#2} \thmnote{(#3)}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\theoremstyle}
+% \begin{macro}{\newtheorem}
+% 应用定义样式
+% \begin{macrocode}
+\theoremstyle{ydefstyle}
+\newtheorem{ydefinition}{\definitionname }[chapter]
+% \end{macrocode}
+%
+% 应用定理样式
+% \begin{macrocode}
+\theoremstyle{ythmstyle}
+\newtheorem{ytheorem}{\theoremname }[chapter]
+\newtheorem{ylemma}{\lemmaname }[chapter]
+\newtheorem{ycorollary}{\corollaryname }[chapter]
+\newtheorem{ypostulate}{\postulatename }[chapter]
+\newtheorem{yaxiom}{\axiomname }[chapter]
+% \end{macrocode}
+%
+% 应用命题样式
+% \begin{macrocode}
+\theoremstyle{yprostyle}
+\newtheorem{yproposition}{\propositionname }[chapter]
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{environment}{theorem}
+% 定义新定理环境
+% \begin{macrocode}
+\newenvironment{theorem}[2]
+ {\ifstrempty{#1}{\ytheorem}{\ytheorem[#1]}\ifstrempty{#2}{}{\label{#2}}}
+ {\endytheorem}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{definition}
+% 定义新定义环境
+% \begin{macrocode}
+\newenvironment{definition}[2]
+ {\ifstrempty{#1}{\ydefinition}{\ydefinition[#1]}\ifstrempty{#2}{}{\label{#2}}}
+ {\endydefinition}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{lemma}
+% 定义新引理环境
+% \begin{macrocode}
+\newenvironment{lemma}[2]
+ {\ifstrempty{#1}{\ylemma}{\ylemma[#1]}\ifstrempty{#2}{}{\label{#2}}}
+ {\endylemma}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{corollary}
+% 定义新推论环境
+% \begin{macrocode}
+\newenvironment{corollary}[2]
+ {\ifstrempty{#1}{\ycorollary}{\ycorollary[#1]}\ifstrempty{#2}{}{\label{#2}}}
+ {\endycorollary}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{postulate}
+% 定义新公设环境
+% \begin{macrocode}
+\newenvironment{postulate}[2]
+ {\ifstrempty{#1}{\ypostulate}{\ypostulate[#1]}\ifstrempty{#2}{}{\label{#2}}}
+ {\endypostulate}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{axiom}
+% 定义新公理环境
+% \begin{macrocode}
+\newenvironment{axiom}[2]
+ {\ifstrempty{#1}{\yaxiom}{\yaxiom[#1]}\ifstrempty{#2}{}{\label{#2}}}
+ {\endyaxiom}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{proposition}
+% 定义新命题环境
+% \begin{macrocode}
+\newenvironment{proposition}[2]
+ {\ifstrempty{#1}{\yproposition}{\yproposition[#1]}\ifstrempty{#2}{}{\label{#2}}}
+ {\endyproposition}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{note}
+% 定义新注解环境
+% \begin{macrocode}
+\newenvironment{note}{
+ \par\noindent\textbf{\notename\,}
+ \itshape}{\par}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{proof}
+% 定义新证明环境
+% \begin{macrocode}
+\newenvironment{proof}{
+ \par\noindent\textbf{\proofname\;}
+}{\hfill$\Box$\quad\par}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{solution}
+% 定义新解答环境
+% \begin{macrocode}
+\newenvironment{solution}{\medskip\par\noindent\textbf{\solutionname} \itshape}{\par}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{remark}
+% 定义新注释环境
+% \begin{macrocode}
+\newenvironment{remark}{\noindent\textbf{\remarkname}}{\par}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{assumption}
+% 定义新假设环境
+% \begin{macrocode}
+\newenvironment{assumption}{\par\noindent\textbf{\assumptionname}}{\par}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{conclusion}
+% 定义新结论环境
+% \begin{macrocode}
+\newenvironment{conclusion}{\par\noindent\textbf{\conclusionname}}{\par}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{property}
+% 定义新性质环境
+% \begin{macrocode}
+\newenvironment{property}{\par\noindent\textbf{\propertyname}}{\par}
+% \end{macrocode}
+% \end{environment}
+%
+% \subsection{封面设置}
+% \begin{macro}{\maketitle}
+% 重定义\cs{maketitle}命令
+% \begin{macrocode}
+\renewcommand{\maketitle}{\par
+ \begingroup
+ \newgeometry{left=20mm,right=20mm,top=30mm,bottom=35mm}
+ \newpage
+ % 禁止图片位于页面最上方
+ \global\@topnum\z@
+ \@maketitle % 下面再设置封面具体内容
+ \endgroup
+ % 先取消原来封面样式的所有设置,以便后面重写此命令
+ \global\let\thanks\relax
+ \global\let\maketitle\relax
+ \global\let\@maketitle\relax
+ \global\let\@thanks\@empty
+ \global\let\@author\@empty
+ \global\let\@date\@empty
+ \global\let\@title\@empty
+ \global\let\title\relax
+ \global\let\author\relax
+ \global\let\date\relax
+ \global\let\and\relax
+}
+% 定义封面具体内容
+\newdimen\infowidth
+\infowidth = 6.5cm
+\def\@maketitle{%
+ \newpage
+ % 开始写封面
+ \thispagestyle{empty}
+ \vspace*{2cm}
+ %%------------------------
+ \begin{center}
+ \ifdefstring{\hitsz@covertitle}{tworow}{
+ \parbox[t][1.4cm][t]{\textwidth}{
+ \begin{center}\erhao[0]\bfseries\hitsz@tokens@titleone\end{center}
+ }\par
+ \parbox[t][2.5cm][t]{\textwidth}{
+ \begin{center}\erhao[0]\bfseries\hitsz@tokens@titletwo\end{center}
+ }\par
+ }{\relax}
+ \ifdefstring{\hitsz@covertitle}{onerow}{
+ \parbox[t][3.4cm][t]{\textwidth}{
+ \begin{center}\erhao[0]\bfseries\hitsz@tokens@thesistitle\end{center}
+ }
+ }{\relax}
+ \parbox[t][8.7cm][t]{\textwidth}{
+ \begin{center}\xiaoer[0]\song\textbf{\ziju{0.2}\hitsz@tokens@authorname}\end{center}
+ }
+ \begin{center}
+ \bfseries
+ \begin{tabular}{rl}
+{\xiaosi 学\hphantom{教师}院:} & \xiaosi\hitsz@tokens@departname\\[14pt]
+{\xiaosi 学\hphantom{教师}号:} & \xiaosi\hitsz@tokens@studentID
+ \end{tabular}
+ \hspace{0.5cm}
+ \begin{tabular}{rl}
+{\xiaosi 专\hphantom{教师}业:} & \xiaosi\hitsz@tokens@majorin\\[14pt]
+{\xiaosi 指导教师:} & \xiaosi\hitsz@tokens@instructor
+ \end{tabular}
+ \end{center}
+ % 日期
+ \vspace{2.6cm}
+ {\xiaosi[0]\song\textbf{2020年7月}}
+ \end{center}
+ %%----------------------------
+%% 第二页
+\clearpage
+\thispagestyle{empty}
+ \vspace*{0.8cm}
+ \centering\includegraphics[width=8cm]{HITSZname}
+ \vspace{1.3cm}
+ \begin{center}
+ \centering\includegraphics[width=10.5cm]{thesistitle}
+ \vfill
+ \parbox[t][14.2cm][b]{\textwidth}
+ {\heiti\xiaosan
+ \begin{center} \renewcommand{\arraystretch}{2.6} \bfseries
+ % 居中对齐
+ \ifdefstring{\hitsz@infoalign}{infocenter}{
+ \begin{tabular}{l@{\ \ }c}
+ {\xiaoer 题\hphantom{\ 导\ \ \ }目} &
+ \underline{\makebox[\infowidth]{%
+ \xiaoer \hitsz@tokens@titleone}}\\
+ & \underline{\makebox[\infowidth]{%
+ \xiaoer \hitsz@tokens@titletwo}}\\
+ & \\
+ {\xiaosan 专\hphantom{\ 导\ 教\ }业} &
+ \underline{\makebox[\infowidth]{%
+ \xiaosan\hitsz@tokens@majorin}}\\
+ {\xiaosan 学\hphantom{\ 导\ 教\ }号} &
+ \underline{\makebox[\infowidth]{%
+ \xiaosan\hitsz@tokens@studentID}}\\
+ {\xiaosan 学\hphantom{\ 导\ 教\ }生} &
+ \underline{\makebox[\infowidth]{%
+ \xiaosan\hitsz@tokens@authorname}}\\
+ {\xiaosan 指\ 导\ 教\ 师} & \underline{\makebox[\infowidth]{%
+ \xiaosan\hitsz@tokens@instructor}}\\
+ {\xiaosan 答\ 辩\ 日\ 期} & \underline{\makebox[\infowidth]{%
+ \xiaosan\hitsz@tokens@dateinput}}
+ \end{tabular} \renewcommand{\arraystretch}{1}
+ }{\relax}
+ % 左对齐
+ \ifdefstring{\hitsz@infoalign}{infoleft}{
+ \begin{tabular}{l@{\ \ }c}
+ {\xiaoer 题\hphantom{\ 导\ \ \ }目} &
+ \underline{\makebox[\infowidth][l]{%
+ \hspace*{1em}\xiaoer \hitsz@tokens@titleone}}\\
+ & \underline{\makebox[\infowidth][l]{%
+ \hspace*{1em}\xiaoer \hitsz@tokens@titletwo}}\\
+ & \\
+ {\xiaosan 专\hphantom{\ 导\ 教\ }业} &
+ \underline{\makebox[\infowidth][l]{%
+ \hspace*{1em}\xiaosan\hitsz@tokens@majorin}}\\
+ {\xiaosan 学\hphantom{\ 导\ 教\ }号} &
+ \underline{\makebox[\infowidth][l]{%
+ \hspace*{1em}\xiaosan\hitsz@tokens@studentID}}\\
+ {\xiaosan 学\hphantom{\ 导\ 教\ }生} &
+ \underline{\makebox[\infowidth][l]{%
+ \hspace*{1em}\xiaosan\hitsz@tokens@authorname}}\\
+ {\xiaosan 指\ 导\ 教\ 师} & \underline{\makebox[\infowidth][l]{%
+ \hspace*{1em}\xiaosan\hitsz@tokens@instructor}}\\
+ {\xiaosan 答\ 辩\ 日\ 期} & \underline{\makebox[\infowidth][l]{%
+ \hspace*{1em}\xiaosan\hitsz@tokens@dateinput}}
+ \end{tabular} \renewcommand{\arraystretch}{1}
+ }{\relax}
+ \end{center}
+ }
+ \end{center}
+ \restoregeometry
+ \clearpage
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\frontmatter}
+% 设置前言页码编号为大写罗马数字
+% \begin{macrocode}
+\renewcommand{\frontmatter}{%
+\cleardoublepage
+\@mainmatterfalse
+\pagenumbering{Roman}
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{中英文摘要环境与关键词命令设置}
+% \begin{environment}{abstract}
+%% 中文摘要环境
+% \begin{macrocode}
+\newenvironment{abstract}{\chapter*{\abstractname}
+\addcontentsline{toc}{chapter}{\abstractname}
+}{\if@twocolumn\else\null\fi}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{keywords}
+% 中文关键词环境
+% \begin{macrocode}
+\newcommand\keywords[1]{%
+ \renewcommand{\hitsz@tokens@keywords}{#1}
+ {\vskip18pt
+ \hspace{-30bp}\begin{tabular}{lp{132mm}}
+ {\zihao{-4}\heiti\keywordsname:}&
+ {\xiaosi\hitsz@tokens@keywords}
+ \end{tabular}}
+}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{abstracten}
+% 英文摘要环境
+% \begin{macrocode}
+\newenvironment{abstracten}{\chapter*{\bfseries Abstract}
+\addcontentsline{toc}{chapter}{ABSTRACT}
+}{\if@twocolumn\else\null\fi}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{keywordsen}
+% 英文关键词环境
+% \begin{macrocode}
+\newcommand\keywordsen[1]{%
+ \renewcommand{\hitsz@tokens@keywordsen}{#1}
+ {\vskip 18pt
+ \hspace{-30bp}\begin{tabular}{lp{127mm}}
+ {\zihao{-4}\bf\keywordsenname:}&
+ {\xiaosi\hitsz@tokens@keywordsen}
+ \end{tabular}}
+}
+% \end{macrocode}
+% \end{environment}
+%
+% \subsection{原创性声明设置}
+% \begin{macro}{\declaration}
+% 定义原创性声明命令
+% \begin{macrocode}
+\newcommand{\declaration}{\par
+ \begingroup
+ \hitsz@declaration
+ \endgroup
+}
+% \end{macrocode}
+%
+% 定义原创性声明具体内容
+% \begin{macrocode}
+\def\hitsztitle{\hitsz@tokens@thesistitle}
+\def\hitszauthor{\hitsz@tokens@authorname}
+\def\hitsz@declaration{
+\chapter*{\sanhao 哈尔滨工业大学(深圳)本科毕业设计(论文)原创性声明}
+\addcontentsline{toc}{chapter}{原创性声明}\par
+本人郑重声明:在哈尔滨工业大学(深圳)攻读学士学位期间,所提交的毕业设计(论文)《\hitsztitle》,是本人在导师指导下独立进行研究工作所取得的成果。对本文的研究工作做出重要贡献的个人和集体,均已在文中以明确方式注明,其它未注明部分不包含他人已发表或撰写过的研究成果,不存在购买、由他人代写、剽窃和伪造数据等作假行为。
+\par
+本人愿为此声明承担法律责任。\par
+\vspace{30pt}
+\hspace{6em}作者签名:\hspace{8em}日期:\hspace{3em}年\hspace{1.5em}月\hspace{1.5em}日
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{参考文献设置}
+% \begin{environment}{thebibliography}
+% 重定义参考文献环境
+% \begin{macrocode}
+\renewenvironment{thebibliography}[1]
+ {\chapter*{\bibname}%
+ \@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}%
+ \list{\@biblabel{\@arabic\c@enumiv}}%
+ {\settowidth\labelwidth{\@biblabel{#1}}%
+ \leftmargin\labelwidth
+ \advance\leftmargin\labelsep
+ \@openbib@code
+ \usecounter{enumiv}%
+ \let\p@enumiv\@empty
+ \renewcommand\theenumiv{\@arabic\c@enumiv}}%
+ \sloppy
+ \clubpenalty4000
+ \@clubpenalty \clubpenalty
+ \widowpenalty4000%
+ \sfcode`\.\@m}
+ {\def\@noitemerr
+ {\@latex@warning{Empty `thebibliography' environment}}%
+ \endlist}
+% \end{macrocode}
+% \end{environment}
+%
+% \subsection{页眉页脚设置}
+% \begin{macro}{\pagestyle}
+% 定义页眉页脚
+% \begin{macrocode}
+\RequirePackage{fancyhdr}
+\RequirePackage{lastpage}
+\pagestyle{fancy}
+% \end{macrocode}
+%
+% 页眉
+% \begin{macrocode}
+\lhead{}
+\chead{\wuhao 哈尔滨工业大学(深圳)本科毕业设计(论文)}
+\rhead{}
+% \end{macrocode}
+%
+% 页脚
+% \begin{macrocode}
+\lfoot{}
+\cfoot{\wuhao -\thepage-}
+\rfoot{}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\makeheadrule}
+% 定义页眉双横线样式,注意下面代码中的\pkg{\%}不能删
+% \begin{macrocode}
+\newcommand{\makeheadrule}{%
+\makebox[0pt][l]{\rule[1mm]{\headwidth}{0.4mm}}%
+\rule[0.35\baselineskip]{\headwidth}{0.8mm}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\headrule}
+% 定义页眉横线为双横线
+% \begin{macrocode}
+\renewcommand{\headrule}{%
+{\if@fancyplain\let\headrulewidth\plainheadrulewidth\fi%
+\makeheadrule}}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{目录格式设置}
+%
+% \begin{macro}{\titlecontents}
+% 设置目录格式,目录只有三级
+%
+% 1级目录格式
+% \begin{macrocode}
+\titlecontents{chapter}[0pt]{\vspace{1mm}\heiti}
+{第\thecontentslabel\,\,章\hskip.5em}{}{\titlerule*[0.5pc]{.}\contentspage}
+% \end{macrocode}
+%
+% 2级目录格式
+% \begin{macrocode}
+\titlecontents{section}[25pt]{\songti}
+{\thecontentslabel\hskip.5em}{}{\titlerule*[0.5pc]{.}\contentspage}
+% \end{macrocode}
+%
+% 3级目录格式
+% \begin{macrocode}
+\titlecontents{subsection}[47pt]{\songti}
+{\thecontentslabel\hskip.5em}{}{\titlerule*[0.5pc]{.}\contentspage}
+% \end{macrocode}
+% \end{macro}
+%
+% 附录环境设置,暂时无用
+% \begin{macrocode}
+\RequirePackage[title,titletoc]{appendix}
+% \end{macrocode}
+%
+% \begin{environment}{tabular}
+% 修改表格字号,注意 |tabular| 要放在 |table| 环境里
+% \begin{macrocode}
+\BeforeBeginEnvironment{tabular}{\wuhao}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{table}
+% 修改表格与后文间距,缩短1cm
+% \begin{macrocode}
+\AfterEndEnvironment{table}{\vspace{-1cm}}
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{macro}{\newcounter}
+% 新计数器,编排表格编号用
+% \begin{macrocode}
+\newcounter{rowno}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\thefigure}
+% \begin{macro}{\thetable}
+% \begin{macro}{\theequation}
+% 设置图表公式编号格式为1-1
+% \begin{macrocode}
+\renewcommand{\thefigure}{\thechapter-\arabic{figure}}
+\renewcommand{\thetable}{\thechapter-\arabic{table}}
+\renewcommand{\theequation}{\thechapter-\arabic{equation}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \subsection{其他杂项设置}
+% \begin{macro}{\usetikzlibrary}
+% 使用\pkg{tikz}配置流程图基本图形
+% \begin{macrocode}
+\usetikzlibrary{shapes.geometric, arrows}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{environment}{startstop}
+% 开始
+% \begin{macrocode}
+\tikzstyle{startstop} = [rectangle, rounded corners, minimum width = 2cm,
+minimum height=1cm,text centered, draw = black]
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{io}
+% 输入输出
+% \begin{macrocode}
+\tikzstyle{io} = [trapezium, trapezium left angle=70, trapezium right angle=110,
+minimum width=2cm, minimum height=1cm, text centered, draw=black]
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{process}
+% 过程
+% \begin{macrocode}
+\tikzstyle{process} = [rectangle, minimum width=3cm, minimum height=1cm,
+text centered, draw=black]
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{decision}
+% 判断
+% \begin{macrocode}
+\tikzstyle{decision} = [diamond, aspect = 3, text centered, draw=black]
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{environment}{arrow}
+% 箭头形式
+% \begin{macrocode}
+\tikzstyle{arrow} = [->,>=stealth]
+% \end{macrocode}
+% \end{environment}
+%
+% \begin{macro}{\upcite}
+% 参考文献标号为上标
+% \begin{macrocode}
+\newcommand{\upcite}[1]{\textsuperscript{\textsuperscript{\cite{#1}}}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\thefootnote}
+% 设置脚注编号格式
+% \begin{macrocode}
+\renewcommand{\thefootnote}{\fnsymbol{footnote}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\chapter}
+% 解决book类文档章首页和目录页没有页眉页脚的问题
+% \begin{macrocode}
+\makeatletter
+\renewcommand\chapter{
+ \if@openright\cleardoublepage
+ \else\clearpage
+ \fi
+ \thispagestyle{fancy}
+ \global\@topnum\z@
+ \@afterindentfalse
+ \secdef\@chapter\@schapter
+}
+\makeatother
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{新数学命令设置}
+% \begin{macro}{\dif}
+% \begin{macro}{\no}
+% \begin{macro}{\dis}
+% \begin{macro}{\ls}
+% \begin{macro}{\gs}
+% 新简记数学命令
+% \begin{macrocode}
+\newcommand\dif{\text{d}}
+\newcommand\no{\noindent}
+\newcommand\dis{\displaystyle}
+\newcommand\ls{\leqslant}
+\newcommand\gs{\geqslant}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\limit}
+% \begin{macro}{\limn}
+% \begin{macro}{\limxz}
+% \begin{macro}{\limxi}
+% \begin{macro}{\limxpi}
+% \begin{macro}{\limxni}
+% \begin{macro}{\limtpi}
+% \begin{macro}{\limtni}
+% 极限
+% \begin{macrocode}
+\newcommand\limit{\dis\lim\limits}
+\newcommand\limn{\dis\lim\limits_{n\to\infty}}
+\newcommand\limxz{\dis\lim\limits_{x\to0}}
+\newcommand\limxi{\dis\lim\limits_{x\to\infty}}
+\newcommand\limxpi{\dis\lim\limits_{x\to+\infty}}
+\newcommand\limxni{\dis\lim\limits_{x\to-\infty}}
+\newcommand\limtpi{\dis\lim\limits_{t\to+\infty}}
+\newcommand\limtni{\dis\lim\limits_{t\to-\infty}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\sumn}
+% \begin{macro}{\sumnz}
+% $n$求和
+% \begin{macrocode}
+\newcommand\sumn{\dis\sum\limits_{n=1}^{\infty}}
+\newcommand\sumnz{\dis\sum\limits_{n=0}^{\infty}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\sumi}
+% \begin{macro}{\sumiz}
+% \begin{macro}{\sumin}
+% \begin{macro}{\sumizn}
+% $i$求和
+% \begin{macrocode}
+\newcommand\sumi{\dis\sum\limits_{i=1}^{\infty}}
+\newcommand\sumiz{\dis\sum\limits_{i=0}^{\infty}}
+\newcommand\sumin{\dis\sum\limits_{i=1}^{n}}
+\newcommand\sumizn{\dis\sum\limits_{i=0}^{n}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\sumk}
+% \begin{macro}{\sumkz}
+% \begin{macro}{\sumkn}
+% \begin{macro}{\sumkfn}
+% $k$求和
+% \begin{macrocode}
+\newcommand\sumk{\dis\sum\limits_{k=1}^{\infty}}
+\newcommand\sumkz{\dis\sum\limits_{k=0}^{\infty}}
+\newcommand\sumkn{\dis\sum\limits_{k=0}^n}
+\newcommand\sumkfn{\dis\sum\limits_{k=1}^n}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\pzx}
+% \begin{macro}{\pzy}
+% $z$偏微分
+% \begin{macrocode}
+\newcommand\pzx{\dis\frac{\partial z}{\partial x}}
+\newcommand\pzy{\dis\frac{\partial z}{\partial y}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\pfx}
+% \begin{macro}{\pfy}
+% $f$偏微分
+% \begin{macrocode}
+\newcommand\pfx{\dis\frac{\partial f}{\partial x}}
+\newcommand\pfy{\dis\frac{\partial f}{\partial y}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\pzxx}
+% \begin{macro}{\pzxy}
+% \begin{macro}{\pzyx}
+% \begin{macro}{\pzyy}
+% $z$二重偏微分
+% \begin{macrocode}
+\newcommand\pzxx{\dis\frac{\partial^2 z}{\partial x^2}}
+\newcommand\pzxy{\dis\frac{\partial^2 z}{\partial x\partial y}}
+\newcommand\pzyx{\dis\frac{\partial^2 z}{\partial y\partial x}}
+\newcommand\pzyy{\dis\frac{\partial^2 z}{\partial y^2}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\pfxx}
+% \begin{macro}{\pfxy}
+% \begin{macro}{\pfyx}
+% \begin{macro}{\pfyy}
+% $f$二重偏微分
+% \begin{macrocode}
+\newcommand\pfxx{\dis\frac{\partial^2 f}{\partial x^2}}
+\newcommand\pfxy{\dis\frac{\partial^2 f}{\partial x\partial y}}
+\newcommand\pfyx{\dis\frac{\partial^2 f}{\partial y\partial x}}
+\newcommand\pfyy{\dis\frac{\partial^2 f}{\partial y^2}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\intzi}
+% \begin{macro}{\intd}
+% \begin{macro}{\intab}
+% 积分
+% \begin{macrocode}
+\newcommand\intzi{\dis\int_{0}^{+\infty}}
+\newcommand\intd{\dis\int}
+\newcommand\intab{\dis\int_a^b}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\degree}
+% 角度符号
+% \begin{macrocode}
+\newcommand{\degree}{^\circ}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\ma}
+% 花体
+% \begin{macrocode}
+\newcommand\ma{\mathcal{A}}
+% \end{macrocode}
+% \end{macro}
+%
+% \begin{macro}{\mb}
+% \begin{macro}{\mc}
+% \begin{macro}{\me}
+% \begin{macro}{\mg}
+% 继续定义
+% \begin{macrocode}
+\newcommand\mb{\mathcal{B}}
+\newcommand\mc{\mathcal{C}}
+\newcommand\me{\mathcal{E}}
+\newcommand\mg{\mathcal{g}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\mcc}
+% \begin{macro}{\mrr}
+% \begin{macro}{\mzz}
+% 重体
+% \begin{macrocode}
+\newcommand\mcc{\mathbb{C}}
+\newcommand\mrr{\mathbb{R}}
+\newcommand\mzz{\mathbb{Z}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\vx}
+% \begin{macro}{\vX}
+% \begin{macro}{\vy}
+% \begin{macro}{\vY}
+% 向量
+% \begin{macrocode}
+\newcommand\vx{\bf{x}}
+\newcommand\vX{\bf{X}}
+\newcommand\vy{\bf{y}}
+\newcommand\vY{\bf{Y}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\sgn}
+% \begin{macro}{\arccot}
+% \begin{macro}{\arccosh}
+% 定义新数学符号
+% \begin{macrocode}
+\DeclareMathOperator{\sgn}{sgn}
+\DeclareMathOperator{\arccot}{arccot}
+\DeclareMathOperator{\arccosh}{arccosh}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \begin{macro}{\arcsinh}
+% \begin{macro}{\arctanh}
+% \begin{macro}{\arccoth}
+% \begin{macro}{\grad}
+% \begin{macro}{\argmax}
+% \begin{macro}{\argmin}
+% \begin{macro}{\diag}
+% \begin{macro}{\csign}
+% 继续定义数学符号
+% \begin{macrocode}
+\DeclareMathOperator{\arcsinh}{arcsinh}
+\DeclareMathOperator{\arctanh}{arctanh}
+\DeclareMathOperator{\arccoth}{arccoth}
+\DeclareMathOperator{\grad}{\bf{grad}}
+\DeclareMathOperator{\argmax}{argmax}
+\DeclareMathOperator{\argmin}{argmin}
+\DeclareMathOperator{\diag}{diag}
+\DeclareMathOperator{\csign}{csign}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
+% \subsection{书脊}
+% \label{sec:spine}
+% \begin{macro}{\spine}
+% 单独使用书脊命令会在新的一页产生竖排书脊。
+% \begin{macrocode}
+\newcommand{\spine}{%
+ \begingroup
+ \hitsz@spine
+ \endgroup
+}
+\def\hitsz@spine{%
+ \newpage\thispagestyle{empty}%
+ \fangsong\addCJKfontfeatures*{RawFeature={vertical:}}
+ \xiaosan\ziju{0.4}%
+ \noindent\hfill\rotatebox[origin=lt]{-90}{%
+ \makebox[\textheight]{\hitsztitle \hfill \hitszauthor}
+ }
+}
+% \end{macrocode}
+% \end{macro}
+%
+% \subsection{其它}
+% \label{sec:other}
+%
+% 在模板文档结束时即装入配置文件,这样用户就能在导言区进行相应的修改。
+% \begin{macrocode}
+\AtEndOfClass{\sloppy}
+%</cls>
+% \end{macrocode}
+%
+% \iffalse
+% \begin{macrocode}
+%<*dtx-style>
+\ProvidesPackage{dtx-style}
+\RequirePackage{hypdoc}
+\RequirePackage{ifthen}
+\RequirePackage[UTF8,scheme=chinese]{ctex}
+\RequirePackage{newtxtext}
+\RequirePackage{newtxmath}
+\RequirePackage[
+ top=2.5cm, bottom=2.5cm,
+ left=5cm, right=1.5cm,
+ headsep=8mm]{geometry}
+\RequirePackage{array,longtable,booktabs}
+\RequirePackage{listings}
+\RequirePackage{fancyhdr}
+\RequirePackage{xcolor}
+\RequirePackage{enumitem}
+\RequirePackage{etoolbox}
+\RequirePackage{metalogo}
+
+\ifthenelse{\equal{\@nameuse{g__ctex_fontset_tl}}{mac}}{%
+ \xeCJKsetwidth{‘’“”}{1em}
+}{}
+
+\colorlet{hitsz@macro}{blue!60!black}
+\colorlet{hitsz@env}{blue!70!black}
+\colorlet{hitsz@option}{purple}
+\patchcmd{\PrintMacroName}{\MacroFont}{\MacroFont\bfseries\color{hitsz@macro}}{}{}
+\patchcmd{\PrintDescribeMacro}{\MacroFont}{\MacroFont\bfseries\color{hitsz@macro}}{}{}
+\patchcmd{\PrintDescribeEnv}{\MacroFont}{\MacroFont\bfseries\color{hitsz@env}}{}{}
+\patchcmd{\PrintEnvName}{\MacroFont}{\MacroFont\bfseries\color{hitsz@env}}{}{}
+
+\def\DescribeOption{%
+ \leavevmode\@bsphack\begingroup\MakePrivateLetters%
+ \Describe@Option}
+\def\Describe@Option#1{\endgroup
+ \marginpar{\raggedleft\PrintDescribeOption{#1}}%
+ \hitsz@special@index{option}{#1}\@esphack\ignorespaces}
+\def\PrintDescribeOption#1{\strut \MacroFont\bfseries\sffamily\color{hitsz@option} #1\ }
+\def\hitsz@special@index#1#2{\@bsphack
+ \begingroup
+ \HD@target
+ \let\HDorg@encapchar\encapchar
+ \edef\encapchar usage{%
+ \HDorg@encapchar hdclindex{\the\c@HD@hypercount}{usage}%
+ }%
+ \index{#2\actualchar{\string\ttfamily\space#2}
+ (#1)\encapchar usage}%
+ \index{#1:\levelchar#2\actualchar
+ {\string\ttfamily\space#2}\encapchar usage}%
+ \endgroup
+ \@esphack}
+
+\lstdefinestyle{lstStyleBase}{%
+ basicstyle=\small\ttfamily,
+ aboveskip=\medskipamount,
+ belowskip=\medskipamount,
+ lineskip=0pt,
+ boxpos=c,
+ showlines=false,
+ extendedchars=true,
+ upquote=true,
+ tabsize=2,
+ showtabs=false,
+ showspaces=false,
+ showstringspaces=false,
+ numbers=none,
+ linewidth=\linewidth,
+ xleftmargin=4pt,
+ xrightmargin=0pt,
+ resetmargins=false,
+ breaklines=true,
+ breakatwhitespace=false,
+ breakindent=0pt,
+ breakautoindent=true,
+ columns=flexible,
+ keepspaces=true,
+ gobble=2,
+ framesep=3pt,
+ rulesep=1pt,
+ framerule=1pt,
+ backgroundcolor=\color{gray!5},
+ stringstyle=\color{green!40!black!100},
+ keywordstyle=\bfseries\color{blue!50!black},
+ commentstyle=\slshape\color{black!60}}
+
+\lstdefinestyle{lstStyleShell}{%
+ style=lstStyleBase,
+ frame=l,
+ rulecolor=\color{purple},
+ language=bash}
+
+\definecolor{hitcolor}{RGB}{21,95,130}
+\lstdefinestyle{lstStyleLaTeX}{%
+ style=lstStyleBase,
+ frame=l,
+ rulecolor=\color{hitcolor},
+ language=[LaTeX]TeX}
+
+\lstnewenvironment{latex}{\lstset{style=lstStyleLaTeX}}{}
+\lstnewenvironment{shell}{\lstset{style=lstStyleShell}}{}
+
+\setlist{nosep}
+
+\DeclareDocumentCommand{\option}{m}{\textsf{#1}}
+\DeclareDocumentCommand{\env}{m}{\texttt{#1}}
+\DeclareDocumentCommand{\pkg}{s m}{%
+ \texttt{#2}\IfBooleanF#1{\hitsz@special@index{package}{#2}}}
+\DeclareDocumentCommand{\file}{s m}{%
+ \texttt{#2}\IfBooleanF#1{\hitsz@special@index{file}{#2}}}
+\newcommand{\myentry}[1]{%
+ \marginpar{\raggedleft\color{purple}\bfseries\strut #1}}
+\newcommand{\note}[2][Note]{{%
+ \color{magenta}{\bfseries #1}\emph{#2}}}
+
+\def\hitszthesis{\textsc{Hitsz}\-\textsc{Thesis}}
+%</dtx-style>
+% \end{macrocode}
+% \fi
+%
+% \Finale
+%
+\endinput
+% \iffalse
+% Local Variables:
+% mode: doctex
+% TeX-master: t
+% End:
+% \fi
diff --git a/macros/latex/contrib/hitszthesis/hitszthesis.ins b/macros/latex/contrib/hitszthesis/hitszthesis.ins
new file mode 100644
index 0000000000..bdcb66f961
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/hitszthesis.ins
@@ -0,0 +1,66 @@
+%%
+%% Copyright (C) 2019-2020 by Jingxuan Yang <yanglatex2e@gmail.com>
+%%
+%% This file is part of the HITSZThesis package project.
+%% ------------------------------------------------------------------------------
+%%
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
+%%
+%% This work has the LPPL maintenance status `maintained'.
+
+\input docstrip
+
+\askforoverwritefalse
+\showprogress
+\keepsilent
+
+\usedir{tex/latex/hitszthesis}
+
+\preamble
+
+This is a generated file.
+
+Copyright (C) 2019-\the\year by Jingxuan Yang <yanglatex2e@gmail.com>
+
+This work may be distributed and/or modified under the
+conditions of the LaTeX Project Public License, either version 1.3
+of this license or (at your option) any later version.
+The latest version of this license is in
+ http://www.latex-project.org/lppl.txt
+and version 1.3 or later is part of all distributions of LaTeX
+version 2005/12/01 or later.
+
+To produce the documentation run the original source files ending with `.dtx'
+through LaTeX.
+
+\endpreamble
+
+\generate{\file{\jobname.cls}{\from{\jobname.dtx}{cls}}
+ \usepreamble\defaultpreamble\usepostamble\defaultpostamble
+ \file{dtx-style.sty}{\from{\jobname.dtx}{dtx-style}}}
+
+\ifToplevel{%
+ \Msg{***********************************************************}
+ \Msg{*}
+ \Msg{* To finish the installation you have to move the following}
+ \Msg{* files into a directory searched by TeX:}
+ \Msg{*}
+ \Msg{* The recommended directory is TEXMF/tex/latex/hitszthesis}
+ \Msg{*}
+ \Msg{* \space\space hitszthesis.cls}
+ \Msg{* \space\space hitszthesis-author-year.bst}
+ \Msg{* \space\space hitszthesis-numeric.bst}
+ \Msg{*}
+ \Msg{* To produce the documentation run the file hitszthesis.dtx}
+ \Msg{* through LaTeX.}
+ \Msg{*}
+ \Msg{* Happy TeXing!}
+ \Msg{***********************************************************}}
+
+\endbatchfile
diff --git a/macros/latex/contrib/hitszthesis/hitszthesis.pdf b/macros/latex/contrib/hitszthesis/hitszthesis.pdf
index d5deb617d1..01ea746ab8 100644
--- a/macros/latex/contrib/hitszthesis/hitszthesis.pdf
+++ b/macros/latex/contrib/hitszthesis/hitszthesis.pdf
Binary files differ
diff --git a/macros/latex/contrib/hitszthesis/hitszthesis.sty b/macros/latex/contrib/hitszthesis/hitszthesis.sty
new file mode 100644
index 0000000000..e27d8309cf
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/hitszthesis.sty
@@ -0,0 +1,32 @@
+%
+% Copyright (C) 2019-2020 by Jingxuan Yang <yanglatex2e@gmail.com>
+%
+% This work may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+% http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2005/12/01 or later.
+%
+% This work has the LPPL maintenance status `maintained'.
+%
+\ProvidesPackage{hitszthesis}[2020/02/18 v2.0 A Collection of Styles for Bachelor Thesis of Harbin Institute of Technology, ShenZhen]
+
+% 将引入的宏包以及各种自定义命令都放在这里
+% 在 \file{main.tex} 中使用 |\usepackage{hitszthesis}| 引入本文件
+
+% 加载宏包
+% \RequirePackage{package}
+
+% 自定义命令
+% \newcommand\totallynewcommand{command details}
+% \renewcommand\existedcommand{command details}
+
+% etc
+
+
+
+
+% 结束输入
+\endinput
diff --git a/macros/latex/contrib/hitszthesis/latexmkrc b/macros/latex/contrib/hitszthesis/latexmkrc
new file mode 100644
index 0000000000..3ba7612943
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/latexmkrc
@@ -0,0 +1,23 @@
+# vim: set ft=perl:
+
+$pdf_mode = 5;
+
+$xelatex = "xelatex -file-line-error -halt-on-error -interaction=nonstopmode -no-pdf -synctex=1 %O %S";
+$xdvipdfmx = "xdvipdfmx -q -E -o %D %O %S";
+
+$bibtex_use = 1.5;
+
+$clean_ext = "hd loe synctex.gz thm xdv";
+
+$makeindex = "makeindex -s gind.ist %O -o %D %S";
+add_cus_dep('glo', 'gls', 0, 'glo2gls');
+sub glo2gls {
+ system("makeindex -s gglo.ist -o \"$_[0].gls\" \"$_[0].glo\"");
+}
+push @generated_exts, 'glo', 'gls';
+
+add_cus_dep('nlo', 'nls', 0, 'nlo2nls');
+sub nlo2nls {
+ system("makeindex -s nomencl.ist -o \"$_[0].nls\" \"$_[0].nlo\"");
+}
+push @generated_exts, 'nlo', 'nls';
diff --git a/macros/latex/contrib/hitszthesis/main.pdf b/macros/latex/contrib/hitszthesis/main.pdf
new file mode 100644
index 0000000000..96295c1920
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/main.pdf
Binary files differ
diff --git a/macros/latex/contrib/hitszthesis/hitszthesis.tex b/macros/latex/contrib/hitszthesis/main.tex
index 1cf3905598..466bc54b8c 100644
--- a/macros/latex/contrib/hitszthesis/hitszthesis.tex
+++ b/macros/latex/contrib/hitszthesis/main.tex
@@ -3,39 +3,42 @@
% !TEX program = XeLaTeX
%%=============================================
% 模板名称:HITSZThesis
-% 模板版本:V1.2
-% 模板作者:JingXuan Yang
+% 模板版本:V2.0
+% 模板作者:杨敬轩(Jingxuan Yang)
% 联系作者:yangjingxuan@stu.hit.edu.cn & yanglatex2e@gmail.com
-% 模板来源:yangtemplate、hithesis与elegantbook综合
+% 模板交流:QQ群:1039392552,加群请备注LaTeX、HITSZThesis相关说明
% 模板适用:哈尔滨工业大学(深圳)本科毕业设计(论文)
% 模板编译:XeLaTeX,编译两次,两次,两次!!!
-% 更新时间:02/15/2020
-% 模板依赖:mtpro2公式字体,安装方法参见:
-% https://www.latexstudio.net/archives/51742.html
-% 模板说明:本模板尽量把接口留在了类文件外面,但是顾名思义,模板即为
-% 部分样式的集合,有些样式是定义在类文件里面的,在外面无法
-% 修改。类文件中注释齐全,很多样式可以个性化定义,建议拥有
-% 一定LaTeX基础以后再尝试修改类文件(YangThesis.cls),请
-% 善用命令行<texdoc xxx>查询帮助文档
-% 模板命令:设置字号可以直接用<\yihao,...,\xiaosi>等命令;
-% 文献引用两种方式:右上角<\upcite{}>,正文<\cite{}>;
-% 图表及公式引用:<\figref{}>,<\tabref{}>,<\equref{}>;
-% 模板使用<siunitx>宏包书写单位
-% 模板交流:QQ群:1039392552,加群请备注LaTeX、HITSZThesis相关说明
+% GNU make 工具:make thesis
+% 更多编译细节详见说明文档:hitszthesis.pdf
+% 更新时间:02/18/2020
+% 模板帮助:请**务必务必务必**阅读 hitszthesis.pdf 说明文档,文档查看方法:
+% cmd 命令行:texdoc hitszthesis
+% 推荐前往模板的GitHub仓库获取最新文件,地址:
+% https://github.com/YangLaTeX/hitszthesis
%%=============================================
% 设置文档类别为<hitszthesis>
\documentclass{hitszthesis}
-% 模板提供两个选项
+% 模板提供以下选项
% 1. 封面标题单行或多行显示:
%% onerow(默认,单行),tworow(两行)
% 2. 封面第二页下划线内容居中或居左显示:
%% infocenter(默认,居中),infoleft(居左)
+% 3. 正文数学字体选项:
+%% newtxmath(默认,凑合),mtpro2(非常推荐)
+%% 将 newtxmath 设置为默认数学字体仅为了避免同学未安装mtpro2字体
+%% 会产生的编译错误
+%% !mtpro2为非免费字体,CTAN禁止提供下载链接,需自行下载该字体
-% 示例:两行,居左,将<\documentclass{hitszthesis}>注释,
+% 示例:两行,居左,mtpro2字体,将<\documentclass{hitszthesis}>注释,
% 且将下面语句取消注释
-%\documentclass[tworow, infoleft]{hitszthesis}
+%\documentclass[tworow, infoleft, mtpro2]{hitszthesis}
+
+% 自定义设置与额外加载的宏包请写在 \file{hitszthesis.sty} 里
+% 预设该文件为空
+\usepackage{hitszthesis}
% 填写封面信息
% 论文标题
@@ -65,19 +68,14 @@
% !!注意本文仅作为排版格式示例,并不作为毕业论文规范
\begin{document}
-% 若题目过长,则需使用一下命令调整封面第二页下划线宽度
+% 若题目过长,则需使用以下命令调整封面第二页下划线长度
%\infowidth = 8cm
% 生成封面两页
\maketitle
-% 封面页与正文布局不同,此处恢复正文的布局设置
-\restoregeometry
-
-% 页码从1开始计数
-\setcounter{page}{1}
-% 页码采用罗马数字格式
-\pagenumbering{Roman}
+% 开始写前言部分
+\frontmatter
% 开始写摘要
\begin{abstract}
@@ -116,17 +114,12 @@ Finally, based on the method of cascade convolution neural network, a convolutio
% 生成目录
\tableofcontents
-% 分页,撰写正文
-\clearpage
+% 开始写正文
+\mainmatter
% 第1章的标题
\chapter{绪论}
-% 页码从1开始计数
-\setcounter{page}{1}
-% 页码格式采用阿拉伯数字
-\pagenumbering{arabic}
-
% 正文内容,注意LaTeX分段有两种方法,直接空一行或者使用<\par>
% 默认首行缩进,不需要在代码编辑区手动敲空格
随着社会发展,人口老龄化,劳动力短缺等问题逐渐凸显,对服务机器人的需求也越来越大,但是服务机器人所工作的非结构化环境也带来了许多技术难题,其中十分主要的一个问题就是非结构环境中机器人的自动抓取,因为抓取是机器人与现实世界交互的主要方式之一。不同于工业机器人在结构化环境中对工件的抓取,服务机器人在非结构化环境下的自动抓取面临着诸多挑战,例如动态化环境、光照变化、物体间存在相互遮挡,以及最主要的,非结构化环境中除了已知的物体,还有大量未知物体。对于非结构化环境中工作的服务机器人,预先获取所有需要进行抓取的物体的模型是不现实的,因此机器人必须能够对未知的物体在线进行快速稳定可靠的抓取规划。
@@ -404,6 +397,7 @@ SqueezeNet 通过 f\/ire 模块和自身优化结构,采用了以下几种常
\begin{equation}
G(u(t), v(t), \theta(t), l(t)) = F(X (t))
\end{equation}
+
其中,$F$为级联机器人平面抓取位姿检测模型,$G$为“点线法”表示的抓取检测结果。
% 条标题
@@ -440,7 +434,6 @@ r_c(i,j\mid\theta)=\sum_{(x,y)\in(i,j)}\frac{z_{i,j,c}(x+x_0,\ y+y_0|\Theta)}{n}
其中,$r_c(i,j\mid\theta)$表示$ (i, j) $块对第$ C $类的池化响应;$z_{i,j,c}$是 $k^2(4 + 1)$分数图中的一个,$(x_0, y_0)$ 表示 RoI 的左上角;$n$表示的是每一块当中的像素值,$\Theta$为待学习参数。
池化操作后输出$k^2$个位置敏感的分数图,利用\equref{eqrc}和\equref{eqsc}得到每一类最终的分数,用于计算损失。
-
\begin{equation}
r_c(\Theta)=\sum_{i,j}r_c(i,j\mid\theta)
\label{eqrc}
@@ -496,11 +489,8 @@ L=\frac{1}{N}\left(\Big|\theta'-\theta_0\Big|+\sum\limits_i^n\lambda\omega_i^2\r
\end{table}
\end{center}
-定义定理等环境示例:
-% 模板支持以下环境:definition、theorem、proposition、corollary、lemma
-% remark、exam、exer、note、proof、assumption、conclusion、solution
-% 第二对{}内的内容为此定理的label,可以用此label引用
-\begin{theorem}{正弦定理}{theoremsin}
+定义定理等环境示例:模板支持以下环境:definition、theorem、proposition、corollary、lemma、remark、exam、exer、note、proof、assumption、conclusion、solution,第二对\{\}内的内容为此定理的label,可以用此label引用,定理\ref{thm:sin}如下。
+\begin{theorem}{正弦定理}{thm:sin}
\begin{equation}
\frac{a}{\sin A}=\frac{b}{\sin B}=\frac{c}{\sin C}
\end{equation}
@@ -508,7 +498,7 @@ L=\frac{1}{N}\left(\Big|\theta'-\theta_0\Big|+\sum\limits_i^n\lambda\omega_i^2\r
\end{theorem}
% 证明环境
\begin{proof}
-\lipsum[5]
+以下是一段无意义文字:\lipsum[5]
\end{proof}
% 结论
@@ -611,5 +601,70 @@ Multiple-Layer Feature Representations of lightweight convolutional neural netwo
$\cdots$
+% 开始写附录
+\appendix
+
+% 注意:由于模板的一些限制,附录部分章节需要手动编号
+% 附录的章节均需要使用带星号的版本
+\chapter*{附录A\hskip.5em 外文资料翻译}
+\addcontentsline{toc}{chapter}{附录A\hskip.5em 外文资料翻译}
+% 设置章节编号为1,即A
+\setcounter{chapter}{1}
+% 重置所有计数器
+\setcounter{equation}{0}
+\setcounter{figure}{0}
+\setcounter{table}{0}
+
+题目:基于驾驶员—车辆—道路交互的驾驶安全场
+
+期刊:IEEE Transactions on Intelligent Transportation Systems, 2015, 16: 2203-2214.
+
+摘要:车辆驾驶安全受许多因素的影响,包括驾驶员、车辆和道路环境,它们之间的相互作用非常复杂。现有的评估驾驶安全性的方法仅考虑有限的因素及其相互作用,基于运动学和动力学的车辆驾驶安全辅助系统难以适应日益复杂的交通环境。在本文中,我们提出了一个新的概念——驾驶安全场。驾驶安全场利用场论来表示由驾驶员、车辆、道路状况和其他交通因素引起的风险因素。本文构建了一个统一的驾驶安全场模型,包括以下三个部分:(1)势能场,由道路上的静止物体构成,例如停止的车辆;(2)动能场,由道路上的移动物体构成,例如车辆和行人;(3)行为场,由驾驶员的个人特征构成。
+
+\section*{A.1\hskip.5em 求和算子}
+
+\textbf{求和算子} 是用以表达多个数求和运算的一个缩略符号,它在统计学和计量经济学分析中扮演着重要作用。如果 $\{x_i: i=1, 2, \cdots, n\}$ 表示 $n$ 个数的一个序列,那么我们就把这 $n$ 个数的和写为\equref{eq:1}:
+\begin{equation}
+\label{eq:1}
+\sum_{i=1}^n x_i \equiv x_1 + x_2 +\cdots + x_n
+\end{equation}
+
+引用图片示例:\figref{appen:angle}
+
+\begin{figure}[!htbp]
+ \centering
+ \includegraphics[width=0.6\textwidth]{3angle}
+ \caption{附录插图示例:Angle-Net 结构}
+ \label{appen:angle}
+\end{figure}
+
+\chapter*{附录B\hskip.5em 其他附录文本}
+\addcontentsline{toc}{chapter}{附录B\hskip.5em 其他附录文本}
+% 设置章节编号为1,即A
+\setcounter{chapter}{2}
+% 重置所有计数器
+\setcounter{equation}{0}
+\setcounter{figure}{0}
+\setcounter{table}{0}
+
+\lipsum[2]
+
+\section*{B.1\hskip.5em 求和算子}
+
+\textbf{求和算子} 是用以表达多个数求和运算的一个缩略符号,它在统计学和计量经济学分析中扮演着重要作用。如果 $\{x_i: i=1, 2, \cdots, n\}$ 表示 $n$ 个数的一个序列,那么我们就把这 $n$ 个数的和写为\equref{eq:2}:
+\begin{equation}
+\label{eq:2}
+a^2+b^2=c^2
+\end{equation}
+
+引用图片示例:\figref{appen:fire}
+
+\begin{figure}[!htbp]
+ \centering
+ \includegraphics[width=0.6\textwidth]{less3}
+ \caption{附录插图示例:f\/ire模块}
+ \label{appen:fire}
+\end{figure}
+
% 结束文档撰写
-\end{document} \ No newline at end of file
+\end{document}
diff --git a/macros/latex/contrib/hitszthesis/spine.pdf b/macros/latex/contrib/hitszthesis/spine.pdf
new file mode 100644
index 0000000000..68581cc563
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/spine.pdf
Binary files differ
diff --git a/macros/latex/contrib/hitszthesis/spine.tex b/macros/latex/contrib/hitszthesis/spine.tex
new file mode 100644
index 0000000000..b4144230d8
--- /dev/null
+++ b/macros/latex/contrib/hitszthesis/spine.tex
@@ -0,0 +1,14 @@
+\documentclass{hitszthesis}
+
+% 论文标题
+\thesistitle{基于神经网络的机器人智能抓取研究}
+
+% 姓名
+\authorname{杨敬轩}
+
+\begin{document}
+
+% 使用默认标题和默认作者
+\spine
+
+\end{document}