├── .gitignore
├── Abstract.tex
├── Acknowledgement.tex
├── Appendix_A.tex
├── Appendix_B.tex
├── Appendix_Settings.tex
├── Chapter1_Introduction.tex
├── Chapter2_Simple_Examples.tex
├── Chapter3_Headers.tex
├── Chapter4_Research_Methods.tex
├── Chapter5_Experiments_and_Results.tex
├── Chapter6_Conclusions_and_Expectations.tex
├── Cover.tex
├── README.md
├── codes
├── for.py
└── re.py
├── gbt7714-numerical.bst
├── gbt7714.sty
├── images
└── Chap2
│ ├── B-C_ratio.pdf
│ ├── B-C_ratio.png
│ ├── Flowchart.pdf
│ ├── Flowchart.tex
│ ├── cascade.pdf
│ ├── cascade.tex
│ ├── confusion.pdf
│ ├── gamma_MCMCanalysis.pdf
│ ├── gamma_MCMCanalysis.png
│ └── hole.pdf
├── main.pdf
├── main.tex
├── template.bib
├── template.sty
└── title.png
/.gitignore:
--------------------------------------------------------------------------------
1 | ## Core latex/pdflatex auxiliary files:
2 | *.aux
3 | *.lof
4 | *.log
5 | *.lot
6 | *.fls
7 | *.out
8 | *.toc
9 | *.fmt
10 | *.fot
11 | *.cb
12 | *.cb2
13 | .*.lb
14 |
15 | ## Intermediate documents:
16 | *.dvi
17 | *.xdv
18 | *-converted-to.*
19 | # these rules might exclude image files for figures etc.
20 | # *.ps
21 | # *.eps
22 | # *.pdf
23 |
24 | ## Generated if empty string is given at "Please type another file name for output:"
25 | .pdf
26 |
27 | ## Bibliography auxiliary files (bibtex/biblatex/biber):
28 | *.bbl
29 | *.bcf
30 | *.blg
31 | *-blx.aux
32 | *-blx.bib
33 | *.run.xml
34 |
35 | ## Build tool auxiliary files:
36 | *.fdb_latexmk
37 | *.synctex
38 | *.synctex(busy)
39 | *.synctex.gz
40 | *.synctex.gz(busy)
41 | *.pdfsync
42 |
43 | ## Build tool directories for auxiliary files
44 | # latexrun
45 | latex.out/
46 |
47 | ## Auxiliary and intermediate files from other packages:
48 | # algorithms
49 | *.alg
50 | *.loa
51 |
52 | # achemso
53 | acs-*.bib
54 |
55 | # amsthm
56 | *.thm
57 |
58 | # beamer
59 | *.nav
60 | *.pre
61 | *.snm
62 | *.vrb
63 |
64 | # changes
65 | *.soc
66 |
67 | # comment
68 | *.cut
69 |
70 | # cprotect
71 | *.cpt
72 |
73 | # elsarticle (documentclass of Elsevier journals)
74 | *.spl
75 |
76 | # endnotes
77 | *.ent
78 |
79 | # fixme
80 | *.lox
81 |
82 | # feynmf/feynmp
83 | *.mf
84 | *.mp
85 | *.t[1-9]
86 | *.t[1-9][0-9]
87 | *.tfm
88 |
89 | #(r)(e)ledmac/(r)(e)ledpar
90 | *.end
91 | *.?end
92 | *.[1-9]
93 | *.[1-9][0-9]
94 | *.[1-9][0-9][0-9]
95 | *.[1-9]R
96 | *.[1-9][0-9]R
97 | *.[1-9][0-9][0-9]R
98 | *.eledsec[1-9]
99 | *.eledsec[1-9]R
100 | *.eledsec[1-9][0-9]
101 | *.eledsec[1-9][0-9]R
102 | *.eledsec[1-9][0-9][0-9]
103 | *.eledsec[1-9][0-9][0-9]R
104 |
105 | # glossaries
106 | *.acn
107 | *.acr
108 | *.glg
109 | *.glo
110 | *.gls
111 | *.glsdefs
112 | *.lzo
113 | *.lzs
114 |
115 | # uncomment this for glossaries-extra (will ignore makeindex's style files!)
116 | # *.ist
117 |
118 | # gnuplottex
119 | *-gnuplottex-*
120 |
121 | # gregoriotex
122 | *.gaux
123 | *.glog
124 | *.gtex
125 |
126 | # htlatex
127 | *.4ct
128 | *.4tc
129 | *.idv
130 | *.lg
131 | *.trc
132 | *.xref
133 |
134 | # hyperref
135 | *.brf
136 |
137 | # knitr
138 | *-concordance.tex
139 | # TODO Uncomment the next line if you use knitr and want to ignore its generated tikz files
140 | # *.tikz
141 | *-tikzDictionary
142 |
143 | # listings
144 | *.lol
145 |
146 | # luatexja-ruby
147 | *.ltjruby
148 |
149 | # makeidx
150 | *.idx
151 | *.ilg
152 | *.ind
153 |
154 | # minitoc
155 | *.maf
156 | *.mlf
157 | *.mlt
158 | *.mtc[0-9]*
159 | *.slf[0-9]*
160 | *.slt[0-9]*
161 | *.stc[0-9]*
162 |
163 | # minted
164 | _minted*
165 | *.pyg
166 |
167 | # morewrites
168 | *.mw
169 |
170 | # newpax
171 | *.newpax
172 |
173 | # nomencl
174 | *.nlg
175 | *.nlo
176 | *.nls
177 |
178 | # pax
179 | *.pax
180 |
181 | # pdfpcnotes
182 | *.pdfpc
183 |
184 | # sagetex
185 | *.sagetex.sage
186 | *.sagetex.py
187 | *.sagetex.scmd
188 |
189 | # scrwfile
190 | *.wrt
191 |
192 | # sympy
193 | *.sout
194 | *.sympy
195 | sympy-plots-for-*.tex/
196 |
197 | # pdfcomment
198 | *.upa
199 | *.upb
200 |
201 | # pythontex
202 | *.pytxcode
203 | pythontex-files-*/
204 |
205 | # tcolorbox
206 | *.listing
207 |
208 | # thmtools
209 | *.loe
210 |
211 | # TikZ & PGF
212 | *.dpth
213 | *.md5
214 | *.auxlock
215 |
216 | # todonotes
217 | *.tdo
218 |
219 | # vhistory
220 | *.hst
221 | *.ver
222 |
223 | # easy-todo
224 | *.lod
225 |
226 | # xcolor
227 | *.xcp
228 |
229 | # xmpincl
230 | *.xmpi
231 |
232 | # xindy
233 | *.xdy
234 |
235 | # xypic precompiled matrices and outlines
236 | *.xyc
237 | *.xyd
238 |
239 | # endfloat
240 | *.ttt
241 | *.fff
242 |
243 | # Latexian
244 | TSWLatexianTemp*
245 |
246 | ## Editors:
247 | # WinEdt
248 | *.bak
249 | *.sav
250 |
251 | # Texpad
252 | .texpadtmp
253 |
254 | # LyX
255 | *.lyx~
256 |
257 | # Kile
258 | *.backup
259 |
260 | # gummi
261 | .*.swp
262 |
263 | # KBibTeX
264 | *~[0-9]*
265 |
266 | # TeXnicCenter
267 | *.tps
268 |
269 | # auto folder when using emacs and auctex
270 | ./auto/*
271 | *.el
272 |
273 | # expex forward references with \gathertags
274 | *-tags.tex
275 |
276 | # standalone packages
277 | *.sta
278 |
279 | # Makeindex log files
280 | *.lpz
281 |
282 | # xwatermark package
283 | *.xwm
284 |
285 | # REVTeX puts footnotes in the bibliography by default, unless the nofootinbib
286 | # option is specified. Footnotes are the stored in a file with suffix Notes.bib.
287 | # Uncomment the next line to have this generated file ignored.
288 | #*Notes.bib
289 |
--------------------------------------------------------------------------------
/Abstract.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % Chinese Abstract
3 | %----------------------------------------------------------------------------------------
4 | \setcounter{page}{1}
5 | \pagenumbering{Roman}
6 | \begin{center}
7 | \addcontentsline{toc}{section}{摘要} % Add to content
8 | \zihao{-2}
9 | \bfseries
10 | 摘\quad 要
11 | \end{center}
12 | \thispagestyle{plain}
13 | \begin{spacing}{1.5}
14 | \zihao{-4}
15 | 摘要内容应概括地反映出本论文的主要内容, 主要说明本论文的研究目的、内容、方法、成果和结论. 要突出本论文的创造性成果或新见解, 不要与引言相混淆. 语言力求精练、准确,以300-500字为宜. 在摘要的下方另起一行, 注明本文的关键词 (3-5个). 关键词是供检索用的主题词条, 应采用能覆盖论文主要内容的通用技术词条 (参照相应的技术术语标准). 按词条的外延层次排列 (外延大的排在前面). 摘要与关键词应在同一页.
16 | \ \\
17 | \textbf{关键词: }多变量系统; 预测控制; 环境试验设备
18 | \end{spacing}
19 | \pagebreak[4]
20 | \thispagestyle{plain}
21 |
22 | %----------------------------------------------------------------------------------------
23 | % English Abstract
24 | %----------------------------------------------------------------------------------------
25 | \begin{center}
26 | \addcontentsline{toc}{section}{Abstract} % Add to content
27 | \zihao{-2}
28 | Abstract
29 | \end{center}
30 | \begin{spacing}{1.5}
31 | \zihao{-4}
32 | 英文摘要内容与中文摘要相同, 以 250-400个实词为宜. 摘要下方另起一行注明英文关键词 (Keywords3-5个).
33 | \ \\
34 | \textbf{Keywords: }Writer recognition; Convolutional Neural Network; Handwritten character recognition
35 | \end{spacing}
36 | \pagebreak[4]
37 |
--------------------------------------------------------------------------------
/Acknowledgement.tex:
--------------------------------------------------------------------------------
1 | \section*{致谢}
2 | \addcontentsline{toc}{section}{致谢}
3 | \zihao{-4}
4 | 很惭愧, 我只做了一点微小的工作, 谢谢大家.
5 |
6 | 为了展示奇偶页眉的效果, 将上面那句话复制若干次, 直到致谢写到第二页位置, 读者可以看看页眉的变化.
7 |
8 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
9 |
10 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
11 |
12 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
13 |
14 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
15 |
16 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
17 |
18 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
19 |
20 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
21 |
22 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
23 |
24 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
25 |
26 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
27 |
28 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
29 |
30 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
31 |
32 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
33 |
34 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
35 |
36 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
37 |
38 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
39 |
40 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
41 |
42 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
43 |
44 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
45 |
46 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
47 |
48 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
49 |
50 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
51 |
52 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
53 |
54 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
55 |
56 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
57 |
58 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
59 |
60 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
61 |
62 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
63 |
64 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
65 |
66 | 很惭愧, 就做了一点微小的工作, 谢谢大家.
67 |
--------------------------------------------------------------------------------
/Appendix_A.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 我是附录
3 | %----------------------------------------------------------------------------------------
4 | \section{我是附录}
5 | \label{sec:A}
6 | 像``附录A''及其页眉也是可以设置的.
7 |
8 | 为了展示奇偶页眉的效果, 将上面那句话复制若干次, 直到附录\ref{sec:A}写到第二页位置, 读者可以看看页眉的变化.
9 |
10 | 像``附录A''及其页眉也是可以设置的.
11 |
12 | 像``附录A''及其页眉也是可以设置的.
13 |
14 | 像``附录A''及其页眉也是可以设置的.
15 |
16 | 像``附录A''及其页眉也是可以设置的.
17 |
18 | 像``附录A''及其页眉也是可以设置的.
19 |
20 | 像``附录A''及其页眉也是可以设置的.
21 |
22 | 像``附录A''及其页眉也是可以设置的.
23 |
24 | 像``附录A''及其页眉也是可以设置的.
25 |
26 | 像``附录A''及其页眉也是可以设置的.
27 |
28 | 像``附录A''及其页眉也是可以设置的.
29 |
30 | 像``附录A''及其页眉也是可以设置的.
31 |
32 | 像``附录A''及其页眉也是可以设置的.
33 |
34 | 像``附录A''及其页眉也是可以设置的.
35 |
36 | 像``附录A''及其页眉也是可以设置的.
37 |
38 | 像``附录A''及其页眉也是可以设置的.
39 |
40 | 像``附录A''及其页眉也是可以设置的.
41 |
42 | 像``附录A''及其页眉也是可以设置的.
43 |
44 | 像``附录A''及其页眉也是可以设置的.
45 |
46 | 像``附录A''及其页眉也是可以设置的.
47 |
48 | 像``附录A''及其页眉也是可以设置的.
49 |
50 | 像``附录A''及其页眉也是可以设置的.
51 |
52 | 像``附录A''及其页眉也是可以设置的.
53 |
54 | 像``附录A''及其页眉也是可以设置的.
55 |
56 | 像``附录A''及其页眉也是可以设置的.
57 |
58 | 像``附录A''及其页眉也是可以设置的.
59 |
60 | 像``附录A''及其页眉也是可以设置的.
61 |
62 | 像``附录A''及其页眉也是可以设置的.
63 |
64 | 像``附录A''及其页眉也是可以设置的.
65 |
66 | 像``附录A''及其页眉也是可以设置的.
67 |
68 | 可以试试写个公式. 公式的编号自动为A.1
69 | \begin{equation}\label{equ:A:1}
70 | a^2+b^2=c^2
71 | \end{equation}
72 | 并且
73 | \begin{equation}\label{equ:A:2}
74 | c^2=a^2+b^2
75 | \end{equation}
76 |
77 | \pagebreak[4]
78 |
--------------------------------------------------------------------------------
/Appendix_B.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 我也是附录
3 | %----------------------------------------------------------------------------------------
4 | \section{我也是附录}
5 | \label{sec:B}
6 | 到了附录\ref{sec:B}则自动编号为B. 可以试试再写个公式
7 | \begin{equation}
8 | a+b=c
9 | \end{equation}
10 | 甚至还能引用A的公式E \ref{equ:A:2}
11 |
12 | \pagebreak[4]
13 |
--------------------------------------------------------------------------------
/Appendix_Settings.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % APPENDIX
3 | %----------------------------------------------------------------------------------------
4 | \appendix
5 |
6 | % 附录标题样式调整
7 | \titleformat{\section}{\centering\zihao{-2}\bfseries}{附录\Alph{section}}{1em}{}
8 | \titleformat{\subsection}{\zihao{-3}\bfseries}{\thesubsection}{1em}{}
9 | \titleformat{\subsubsection}{\zihao{4}\bfseries}{\thesubsubsection}{1em}{}
10 |
11 | \titlecontents{section}[0em]{\zihao{4}\bfseries}
12 | {\contentspush{{附录 \thecontentslabel}\hspace{1em}}}
13 | {}{\titlerule*[5pt]{.}\contentspage}
14 |
15 | \titlecontents{subsection}[2.2em]{\zihao{-4}\songti}{\contentspush{\thecontentslabel\hspace{0.7em}}}
16 | {}{\titlerule*[5pt]{.}\contentspage}
17 | \titlecontents{subsubsection}[3.9em]{\zihao{-4}\songti}{\contentspush{\thecontentslabel\hspace{0.7em}}}
18 | {}{\titlerule*[5pt]{.}\contentspage}
19 | \titlespacing*{\subsection} {0pt}{1ex}{1ex} % Adjust the space between title and context
20 | \titlespacing*{\subsubsection} {0pt}{1ex}{1ex}
21 |
22 | % 保留原有页眉页脚设置,与正文保持一致
23 | \pagestyle{fancy}
24 | \fancyhf{}
25 | \renewcommand{\sectionmark}[1]{\markboth{附录\Alph{section}\ \ #1}{}}
26 | \fancyhead[C]{\songti{华南理工大学学士学位论文}}
27 | \fancyhead[CO]{\songti\leftmark}
28 | \fancyfoot[C]{\thepage}
29 |
30 | % 保留原有公式编号设置,与正文保持一致
31 | \makeatletter
32 | \@addtoreset{equation}{section}
33 | \makeatother
34 | \renewcommand{\theequation}{\Alph{section}.\arabic{equation}}
--------------------------------------------------------------------------------
/Chapter1_Introduction.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 绪论
3 | %----------------------------------------------------------------------------------------
4 | \section{绪论}
5 | %----------------------------------------------------------------------------------------
6 | % 选题背景与意义
7 | %----------------------------------------------------------------------------------------
8 | \subsection{选题背景与意义}
9 | \label{sec:background}
10 | 引言是论文正文的开端, 应包括毕业论文选题的背景、目的和意义; 对国内外研究现状和相关领域中已有的研究成果的简要评述; 介绍本项研究工作研究设想、研究方法或实验设计、理论依据或实验基础; 涉及范围和预期结果等. 要求言简意赅,注意不要与摘要雷同或成为摘要的注解.\cite{liu2011sift}
11 |
12 | %----------------------------------------------------------------------------------------
13 | % 国内外研究现状和相关工作
14 | %----------------------------------------------------------------------------------------
15 | \subsection{国内外研究现状和相关工作}
16 | \label{sec:related_work}
17 | 对国内外研究现状和相关领域中已有的研究成果的简要评述
18 |
19 | %----------------------------------------------------------------------------------------
20 | % 本文的论文结构与章节安排
21 | %----------------------------------------------------------------------------------------
22 | \subsection{本文的论文结构与章节安排}
23 | \label{sec:arrangement}
24 | 本文共分为五章, 各章节内容安排如下:
25 |
26 | 第一章引言.
27 |
28 | 第二章知识点.
29 |
30 | 第三章方法介绍.
31 |
32 | 第四章实验和结果.
33 |
34 | 第五章是本文的最后一章, 总结与展望. 是对本文内容的整体性总结以及对未来工作的展望.
35 |
36 | \pagebreak[4]
37 |
--------------------------------------------------------------------------------
/Chapter2_Simple_Examples.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 简单的使用例子
3 | %----------------------------------------------------------------------------------------
4 | \section{简单的使用例子}
5 | \label{cha:example}
6 | %----------------------------------------------------------------------------------------
7 | % 图片的插入
8 | %----------------------------------------------------------------------------------------
9 | \subsection{图片的插入}
10 | \label{sec:Images}
11 | \begin{wrapfigure}{r}{0.5\linewidth}
12 | \centering
13 | \includegraphics[width=0.5\textwidth]{images/Chap2/confusion.pdf} % width=0.5\textwidth也可以换成width=5cm, height=5cm等关键字参数. width=0.5\textwidth 比较常用: 图片宽度等于你的text宽度的1/2
14 | \caption{镶嵌在文中的图像}
15 | \label{fig:confusion}
16 | \end{wrapfigure}
17 | 论文主体是毕业论文的主要部分, 必须言之成理, 论据可靠, 严格遵循本学科国际通行的学术规范. 在写作上要注意结构合理、层次分明、重点突出, 章节标题、公式图表符号必须规范统一. 论文主体的内容根据不同学科有不同的特点, 一般应包括以下几个方面: (1)毕业论文 (设计) 总体方案或选题的论证; (2)毕业论文 (设计) 各部分的设计实现, 包括实验数据的获取、数据可行性及有效性的处理与分析、各部分的设计计算等; (3)对研究内容及成果的客观阐述, 包括理论依据、创新见解、创造性成果及其改进与实际应用价值等; (4)论文主体的所有数据必须真实可靠, 凡引用他人观点、方案、资料、数据等, 无论曾否发表, 无论是纸质或电子版, 均应详加注释. 自然科学论文应推理正确、结论清晰; 人文和社会学科的论文应把握论点正确、论证充分、论据可靠, 恰当运用系统分析和比较研究的方法进行模型或方案设计, 注重实证研究和案例分析, 根据分析结果提出建议和改进措施等.
18 |
19 | 可以插入单张图像:
20 | \begin{figure}[h]
21 | \centering
22 | \includegraphics[width=0.5\textwidth]{images/Chap2/hole.pdf}
23 | \caption{单张图像}
24 | \label{fig:hole}
25 | \end{figure}
26 |
27 | 甚至可以两张并排, 如图\ref{B-C_ratio}和图\ref{fig:gamma_MCMCanalysis}所示, 并且这句话已经实现了用$\backslash$ref\{key\}来引用内容. 引用的内容包括公式、表格、图片、代码段等等. 对于参考文献的引用并非用ref, 之后会提及.
28 |
29 | 对于多张图片的并排并统一标注caption可使用subfigure和makebox; 因为这个功能用得较少, 用户可自行Google.
30 |
31 | \begin{figure}[th]
32 | \parbox[t]{0.5\textwidth}{
33 | \includegraphics[width=0.5\textwidth]{images/Chap2/B-C_ratio.pdf}
34 | \caption{B/C ratio}
35 | \label{B-C_ratio}
36 | }
37 | \parbox[t]{0.5\textwidth}{
38 | \includegraphics[width=0.5\textwidth]{images/Chap2/gamma_MCMCanalysis.pdf}
39 | \caption{gamma MCMC analysis}
40 | \label{fig:gamma_MCMCanalysis}
41 | }
42 | \end{figure}
43 |
44 | %----------------------------------------------------------------------------------------
45 | % 复杂图表的输入
46 | %----------------------------------------------------------------------------------------
47 | \subsection{复杂图表的输入---tikz}
48 | \label{sec:tikz}
49 | 复杂图表最常见的可以算是算法流程图, 可以用standalone独立出一个文档用tikz来画, 生成PDF后作为图片插入
50 | \begin{figure}[ht]
51 | \centering
52 | \includegraphics[width=0.6\textwidth]{images/Chap2/Flowchart.pdf}
53 | \caption{Flowchart}
54 | \label{Flowchart}
55 | \end{figure}
56 |
57 | \noindent 此外还有如图\ref{cascade}的类似费曼图那样的示意图, 表示电磁级联的$\gamma-B$过程. 用\LaTeX 的tikz画相对有点复杂但并非不可实现; 有专门的包去画类似这样的费曼图, 但做毕设时我还没学会.
58 | \begin{figure}[ht]
59 | \centering
60 | \includegraphics[width=0.5\textwidth]{images/Chap2/cascade.pdf}
61 | \caption{cascade}
62 | \label{cascade}
63 | \end{figure}
64 |
65 | %----------------------------------------------------------------------------------------
66 | % 公式的输入
67 | %----------------------------------------------------------------------------------------
68 | \subsection{公式的输入}
69 | \label{sec:Equations}
70 | 一般的公式如下. 如果用户不想要编号 (目的可能是仅仅想摆个不重要的公式, 或者说是推导的中间过程), 可以在equation后面加个*, 即$\backslash$begin\{equation*\}.
71 | \begin{equation}
72 | x=\frac{-b\pm\sqrt{b^2-4ac}}{2a}
73 | \end{equation}
74 | 推导的中间过程, 往往需要等号对齐. 可用aligned环境加\&实现 (aligned环境切记每行后面要有换行符$\backslash\backslash$):
75 | \begin{equation}
76 | \begin{aligned}
77 | f(E,\bm{r},t)&=\int\ud^3\bm{r'}\ud t'\ud E'G(\bm{r}, t, E; \bm{r'}, t', E')Q(\bm{r'}, t', E')\\
78 | &=\int\ud^3\bm{r'}\ud t'\ud E'\frac{\delta[t-\tau(E,E')-t']}{b(E)[4\pi\lambda(E, E_0)]^{3/2}}\exp\left[-\frac{(\bm{r}-\bm{r'})^2}{4\lambda(E, E_0)}\right]Q(E')\delta^3(\bm{r'}-\bm{r_0})\delta(t'-t_0)\\
79 | &=\int\ud E'\frac{\delta[t-\tau(E,E')-t_0]}{b(E)[4\pi\lambda(E, E_0)]^{3/2}}\exp\left[-\frac{(\bm{r}-\bm{r_0})^2}{4\lambda(E, E_0)}\right]Q(E')\\
80 | &=\int\ud E'\frac{b(E_0)\delta(E'-E_0)}{b(E)[4\pi\lambda(E, E_0)]^{3/2}}\exp\left[-\frac{(\bm{r}-\bm{r_0})^2}{4\lambda(E, E_0)}\right]Q(E')\\
81 | &=\frac{b(E_0)}{b(E)}\frac{Q(E_0)}{[4\pi\lambda(E, E_0)]^{3/2}}\exp\left[-\frac{(\bm{r}-\bm{r_0})^2}{4\lambda(E, E_0)}\right]\\
82 | &=\frac{E_0^2}{E^2}\frac{Q(E_0)}{[4\pi\lambda(E, E_0)]^{3/2}}\exp\left[-\frac{(\bm{r}-\bm{r_0})^2}{4\lambda(E, E_0)}\right]\\
83 | \end{aligned}
84 | \end{equation}
85 |
86 | 如果要加个单边大括号, 并实现对齐, 可以适当使用\&, 一个不够就两个, 如Eq \ref{L_MDM}
87 | \begin{equation}\label{L_MDM}
88 | \mathcal{L}=\mathcal{L}_{SM}+\frac{1}{2}\left\{
89 | \begin{aligned}
90 | &\bar{\mathcal{\chi}}({\rm i}\cancel{D}-M)\mathcal{\chi}&&\quad, {\rm for\ fermionic (\mbox{费米子}) }\ \mathcal{\chi}\\
91 | &|D_\mu\mathcal{\chi}|^2-M^2|\mathcal{\chi}|^2&&\quad, {\rm for\ scalar (\mbox{标量}) }\ \mathcal{\chi}\\
92 | \end{aligned}
93 | \right.
94 | \end{equation}
95 | 这里, 正体的fermionic和scalar是用了\{$\backslash$rm text\}, ``费米子''和``标量''用了$\backslash$mbox\{中文\}.
96 |
97 | 关于矩阵, 可以用pmatrix或者bmatrix或者matrix环境. pmatrix自带弯的大括号, bmatrix自带大的中括号[\ \ ], matrix不带括号 (当然你也可以配合$\backslash$left($\backslash$right)加上括号). 一个宏伟的MCMC矩阵方程可以表达为
98 | \begin{small}
99 | \begin{equation}\label{MCMC_equation}
100 | \begin{pmatrix}
101 | p(\theta_{m,t+1,1})\\
102 | \vdots\\
103 | p(\theta_{m,t+1,i})\\
104 | p(\theta_{m,t+1,j})\\
105 | \vdots\\
106 | p(\theta_{m,t+1,S})\\
107 | \end{pmatrix}
108 | =
109 | \begin{pmatrix}
110 | p(\theta_{m,t+1,1}|\theta_{m,t,1})&\cdots&p(\theta_{m,t+1,1}|\theta_{m,t,i})&p(\theta_{m,t+1,1}|\theta_{m,t,j})&\cdots&p(\theta_{m,t+1,1}|\theta_{m,t,S})\\
111 | \vdots&\ddots&\cdots&\cdots&{\mathinner{\mkern2mu\raise1pt\hbox{.}\mkern2mu \raise4pt\hbox{.}\mkern2mu\raise7pt\hbox{.}\mkern1mu}}&\vdots\\
112 | p(\theta_{m,t+1,i}|\theta_{m,t,1})&\cdots&p(\theta_{m,t+1,i}|\theta_{m,t,i})&p(\theta_{m,t+1,i}|\theta_{m,t,j})&\cdots&p(\theta_{m,t+1,i}|\theta_{m,t,S})\\
113 | p(\theta_{m,t+1,j}|\theta_{m,t,1})&\cdots&p(\theta_{m,t+1,j}|\theta_{m,t,i})&p(\theta_{m,t+1,j}|\theta_{m,t,j})&\cdots&p(\theta_{m,t+1,j}|\theta_{m,t,S})\\
114 | \vdots&{\mathinner{\mkern2mu\raise1pt\hbox{.}\mkern2mu \raise4pt\hbox{.}\mkern2mu\raise7pt\hbox{.}\mkern1mu}}&\cdots&\cdots&\ddots&\vdots\\
115 | p(\theta_{m,t+1,S}|\theta_{m,t,1})&\cdots&p(\theta_{m,t+1,S}|\theta_{m,t,i})&p(\theta_{m,t+1,S}|\theta_{m,t,j})&\cdots&p(\theta_{m,t+1,S}|\theta_{m,t,S})\\
116 | \end{pmatrix}
117 | \begin{pmatrix}
118 | p(\theta_{m,t,1})\\
119 | \vdots\\
120 | p(\theta_{m,t,i})\\
121 | p(\theta_{m,t,j})\\
122 | \vdots\\
123 | p(\theta_{m,t,S})\\
124 | \end{pmatrix}
125 | \end{equation}
126 | \end{small}
127 |
128 | %----------------------------------------------------------------------------------------
129 | % 表格的插入
130 | %----------------------------------------------------------------------------------------
131 | \subsection{表格的插入}
132 | \label{sec:Tables}
133 | 表格通常绘成三线表比较好看. 表格里也可以通过\$a\^2\_1+b\^2\_1=c\^2\_1\$这种语法来插入数学表达式的上下标, 如
134 | \begin{table}[ht]
135 | \centering
136 | \caption{16个脉冲星发射正负电子对的$\eta$}
137 | \begin{tabular}{llllll}
138 | \toprule
139 | Pulsar name&$\tau_c$($\times10^5$ yr)&$|\dot{E}|$($\times10^{33}$ erg/s)&$E_{\rm tot}$($\times10^{47}$ erg)&$E_{\rm out}$($\times10^{47}$ erg)&$\eta$/\%\\
140 | \midrule
141 | J0357+3205&5.40&5.9&54.25&$34^{+186}_{-29}$&$63.62^{+344}_{-53.58}$\\ % Checked
142 | Geminga &3.42&32&118.03&$13.45^{+0.15}_{-0.15}$&$11.39^{+0.13}_{-0.12}$\\ % Checked
143 | Monogem &1.11&38&14.76&$3.58^{+0.23}_{-0.21}$&$24.28^{+1.56}_{-1.42}$\\ % Checked
144 | J0736-6304&5.07&0.052&0.42&$21^{+9.6\times10^4}_{-21}$&$5078^{+2.3\times10^7}_{-5077}$\\ % Checked
145 | B0922-52 &3.33&3.4&11.89&$16.1^{+1.0}_{-0.9}$&$135^{+9}_{-8}$\\ % Checked
146 | B0940-55 &4.61&3.1&20.78&$20.53^{+0.89}_{-0.84}$&$98.84^{+4.29}_{-4.03}$\\ % Checked
147 | B0941-56 &3.23&3.0&9.87&$14.82^{+0.72}_{-0.66}$&$150^{+7}_{-7}$\\ % Checked
148 | J0954-5430&1.71&16&14.75&$7.07^{+0.15}_{-0.15}$&$47.93^{+1.03}_{-1.00}$\\ % Checked
149 | B0959-54 &4.43&0.68&4.21&$19.62^{+0.46}_{-0.44}$&$466^{+11}_{-10}$\\ % Checked
150 | B1001-47 &2.20&30&45.79&$9.12^{+0.58}_{-0.54}$&$19.91^{+1.27}_{-1.19}$\\ % Checked
151 | J1020-5921&4.85&0.84&6.23&$36^{+2.6\times10^4}_{-36}$&$584^{+4.2\times10^5}_{-584}$\\ % Checked
152 | B1055-52 &5.35&30&270.79&$22.73^{+0.33}_{-0.32}$&$8.39^{+0.12}_{-0.12}$\\ % Checked
153 | J1732-3131&1.11&150&58.28&$11^{+1.3\times10^4}_{-11}$&$18^{+2.2\times10^3}_{-18}$\\ % Checked
154 | J1741-2054&3.86&9.5&44.64&$16.65^{+0.90}_{-0.85}$&$37.29^{+2.02}_{-1.91}$\\ % Checked
155 | B1742-30 &5.46&8.5&79.91&$24.07^{+0.86}_{-0.83}$&$30.13^{+1.08}_{-1.04}$\\ % Checked
156 | B1822-09 &2.32&4.6&7.80&$8.99^{+0.21}_{-0.19}$&$115.19^{+2.68}_{-2.43}$\\ % Checked
157 | \bottomrule
158 | \end{tabular}
159 | \label{tab:pulsar_eta}
160 | \end{table}
161 |
162 | 表格当然也可以有行合并和列合并. 列合并的表格如表\ref{tab:Multiple_Pulsar_Complete}.
163 | \begin{table}[t]
164 | \centering
165 | \caption{抛弃简化假设得到的7颗脉冲星的15个关键参数的拟合结果 (含$\chi^2$和置信度)}
166 | \begin{tabular}{lccccc}
167 | \toprule
168 | Pulsar name&$\gamma_s$&$\eta$&$A_{{\rm prim},e^-}$&$\chi^2$&C.I.\\
169 | \midrule
170 | Geminga &$2.24^{\pm0.19}$&$0.40^{\pm2.6}\%$&\multirow{7}*{$0.69^{\pm0.02}$}&\multirow{7}*{27.24/28}&\multirow{7}*{50.50\%}\\
171 | Monogem &$1.81^{\pm0.2}$&$8.52^{\pm7.9}\%$&\\
172 | J0954-5430&$2.25^{\pm0.3}$&$1.26^{\pm18}\%$&\\
173 | B1001-47 &$2.41^{\pm0.3}$&$6.37^{\pm6}\%$&\\
174 | B1055-52 &$1.83^{\pm0.4}$&$0.70^{\pm1.3}\%$&\\
175 | J1741-2054&$1.90^{\pm0.36}$&$8.59^{\pm3.2}\%$&\\
176 | B1742-30 &$2.02^{\pm0.13}$&$7.87^{\pm2.3}\%$&\\
177 | \bottomrule
178 | \end{tabular}
179 | \label{tab:Multiple_Pulsar_Complete}
180 | \end{table}
181 |
182 | %----------------------------------------------------------------------------------------
183 | % 插入代码块
184 | %----------------------------------------------------------------------------------------
185 | \subsection{插入代码块}
186 | \label{sec:code}
187 | 代码块需要用户写好了保存为py文件再插入. \LaTeX 支持大多数主流的编程语言, 若要个性化插入的代码, 需要在本模板的第51-88行自行修改. 代码块的两个例子如Listing 1和2所示
188 | \ \\\ \\
189 | \pythonscript{codes/for}{for循环}\label{for}
190 | \pythonscript{codes/re}{用正则表达式修改文件的特定语句}\label{re}
191 |
192 | %----------------------------------------------------------------------------------------
193 | % 字体、列表及脚注
194 | %----------------------------------------------------------------------------------------
195 | \subsection{字体、列表及脚注}
196 | \label{sec:font_list_etc}
197 | \subsubsection{字体}
198 | \label{sec:font_list_etc:font}
199 | 中文论文排版中除了宋体, 最常见的用于强调的字体是\textbf{黑体}和\textit{楷体}.
200 | \subsubsection{列表}
201 | \label{sec:font_list_etc:list}
202 | 这是一个无序列表
203 | \begin{itemize}
204 | \item 引用文献\cite{long2015fully}, 甚至可以上标引用\upcite{tighe2013finding}. 每引用一篇\LaTeX 就会在末尾自动加多一篇\upcite{hariharan2014simultaneous}.
205 | \item 字体{\color{red}{变红}},\textbf{粗体}
206 | \end{itemize}
207 |
208 | 这是一个有序列表
209 | \begin{enumerate}
210 | \item 索引前面的章节\ref{sec:Equations}、图\ref{fig:gamma_MCMCanalysis}、表\ref{tab:Multiple_Pulsar_Complete}
211 | \item 加脚注\footnote{https://github.com/OChicken/SCUT-Bachelor-Thesis-Template}
212 | \end{enumerate}
213 |
214 | \pagebreak[4]
215 |
--------------------------------------------------------------------------------
/Chapter3_Headers.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 页眉
3 | %----------------------------------------------------------------------------------------
4 | \section{页眉}
5 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
6 |
7 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
8 |
9 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
10 |
11 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
12 |
13 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
14 |
15 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
16 |
17 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
18 |
19 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
20 |
21 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
22 |
23 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
24 |
25 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
26 |
27 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
28 |
29 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
30 |
31 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
32 |
33 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
34 |
35 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
36 |
37 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
38 |
39 | 华工本科毕业论文的一个特色是其页眉也页脚分了奇偶页面来排版. 我将将这句话复制若干次直到下一页, 读者可以看看页眉的变化.
40 |
41 | 在接下来的空白章节读者也可以感受一下页眉变化.
42 |
43 | \pagebreak[4]
44 |
--------------------------------------------------------------------------------
/Chapter4_Research_Methods.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 研究方法
3 | %----------------------------------------------------------------------------------------
4 | \section{研究方法}
5 |
6 | \pagebreak[4]
7 |
--------------------------------------------------------------------------------
/Chapter5_Experiments_and_Results.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 实验与结果
3 | %----------------------------------------------------------------------------------------
4 | \section{实验与结果}
5 |
6 | \pagebreak[4]
7 |
--------------------------------------------------------------------------------
/Chapter6_Conclusions_and_Expectations.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % 总结与展望
3 | %----------------------------------------------------------------------------------------
4 | \section{总结与展望}
5 |
6 | \pagebreak[4]
7 |
--------------------------------------------------------------------------------
/Cover.tex:
--------------------------------------------------------------------------------
1 | %----------------------------------------------------------------------------------------
2 | % Cover
3 | %----------------------------------------------------------------------------------------
4 | \thispagestyle{empty}
5 | \begin{figure}[ht]
6 | \centering
7 | \includegraphics[height=2.75cm]{title.png}
8 | \end{figure}
9 | \begin{center}
10 | \zihao{0}
11 | \textbf{本科毕业论文}
12 | \end{center}
13 | \nopagebreak[4]
14 | \begin{center}
15 | \zihao{1}
16 | \ \\
17 | \end{center}
18 | \nopagebreak[4]
19 | \begin{center}
20 | \zihao{2}
21 | \textbf{你的本科毕业论文题目}
22 | \end{center}
23 | % Via \quad, \qquad or '\ ' (backslash and space) you can adjust any space
24 |
25 | \begin{center}
26 | \zihao{1}
27 | \ \\\ \\\ \\
28 | \end{center}
29 | \nopagebreak[4]
30 | \begin{spacing}{1.8}
31 | \begin{center}
32 | %\zihao{-3}
33 | \begin{table}[ht]
34 | \centering
35 | \setlength{\tabcolsep}{7mm}{
36 | \renewcommand\arraystretch{2.5}
37 | \begin{tabular}{cc}
38 | \zihao{-3}学\quad \quad 院 & \zihao{-3}你的学院 \\ \cline{2-2}
39 | \zihao{-3}专\quad \quad 业 & \zihao{-3}你的专业 \\ \cline{2-2}
40 | \zihao{-3}学生姓名 & \zihao{-3} 你的名字 \\ \cline{2-2}
41 | \zihao{-3}学生学号 & \zihao{-3}201400000000 \\ \cline{2-2}
42 | \zihao{-3}指导老师 & \zihao{-3}xxxx\quad 教授 \\ \cline{2-2}
43 | \zihao{-3}提交日期 & \zihao{-3}2xxx年xx月xx日 \\ \cline{2-2}
44 | \end{tabular}
45 | }
46 | \end{table}
47 | \end{center}
48 | \end{spacing}
49 | \pagebreak[4]
50 | \thispagestyle{empty}
51 | \mbox{}
52 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # SCUT-Bachelor-Thesis-Template
2 | Latex template for the bachelor graduation thesis of South China University of Technology (SCUT) 华南理工大学 本科毕业论文LaTeX模板
3 |
4 | 请务必使用XeLaTeX引擎编译!!!
5 |
6 | 至于LaTeX的发行版, 请使用跨平台的**TeX Live**, 支持Windows, Linux, MacOS等操作系统. 至于CTeX套装, 由于只支持Windows系统, 出现了不兼容的问题, 目前博主正在调试.
7 |
8 | 这一版本也能凑合着用 (本人毕设就是拿这个作为模板的), 拿来入门也是OK的, 至于格式上小小的不同以及平台兼容性还需进一步调试. 因此本模板会不定期更新.
9 |
10 | 学弟学妹们可关注这个项目[SCUT-Bachelor-Thesis-Template](https://github.com/OChicken/SCUT-Bachelor-Thesis-Template), 下载最新版本的模板.
11 |
12 | 参考文献格式参考了开源项目[gbt7714-bibtex-style](https://github.com/zepinglee/gbt7714-bibtex-style)。
--------------------------------------------------------------------------------
/codes/for.py:
--------------------------------------------------------------------------------
1 | Sign = ['+', '-']
2 | # Para_uplims_lolims is a (2^ParaLen) x ParaLen matrix
3 | i = 0
4 | for Iter in product(range(2), repeat=ParaLen):
5 | for j in range(ParaLen):
6 | Para_uplims_lolims[i, j] = eval('{}{}{}'.format(
7 | Para_uplims_lolims[i,j],Sign[Iter[j]],Uncertainty[j]))
8 | i += 1
--------------------------------------------------------------------------------
/codes/re.py:
--------------------------------------------------------------------------------
1 | string = re.sub('',
2 | '', string)
3 | string = re.sub('',
4 | '', string)
--------------------------------------------------------------------------------
/gbt7714-numerical.bst:
--------------------------------------------------------------------------------
1 | %%
2 | %% This is file `gbt7714-numerical.bst',
3 | %% generated with the docstrip utility.
4 | %%
5 | %% The original source files were:
6 | %%
7 | %% gbt7714.dtx (with options: `2015,numerical')
8 | %% -------------------------------------------------------------------
9 | %% GB/T 7714 BibTeX Style
10 | %% https://github.com/zepinglee/gbt7714-bibtex-style
11 | %% Version: 2024/03/08 v2.1.6
12 | %% -------------------------------------------------------------------
13 | %% Copyright (C) 2016--2024 by Zeping Lee
14 | %% -------------------------------------------------------------------
15 | %% This file may be distributed and/or modified under the
16 | %% conditions of the LaTeX Project Public License, either version 1.3c
17 | %% of this license or (at your option) any later version.
18 | %% The latest version of this license is in
19 | %% https://www.latex-project.org/lppl.txt
20 | %% and version 1.3c or later is part of all distributions of LaTeX
21 | %% version 2008 or later.
22 | %% -------------------------------------------------------------------
23 | INTEGERS {
24 | citation.et.al.min
25 | citation.et.al.use.first
26 | bibliography.et.al.min
27 | bibliography.et.al.use.first
28 | uppercase.name
29 | terms.in.macro
30 | year.after.author
31 | period.after.author
32 | italic.book.title
33 | sentence.case.title
34 | link.title
35 | title.in.journal
36 | show.patent.country
37 | show.mark
38 | space.before.mark
39 | show.medium.type
40 | short.journal
41 | italic.journal
42 | link.journal
43 | bold.journal.volume
44 | show.missing.address.publisher
45 | space.before.pages
46 | only.start.page
47 | wave.dash.in.pages
48 | show.urldate
49 | show.url
50 | show.doi
51 | show.preprint
52 | show.note
53 | show.english.translation
54 | end.with.period
55 | }
56 |
57 | STRINGS {
58 | component.part.label
59 | }
60 |
61 | FUNCTION {load.config}
62 | {
63 | #2 'citation.et.al.min :=
64 | #1 'citation.et.al.use.first :=
65 | #4 'bibliography.et.al.min :=
66 | #3 'bibliography.et.al.use.first :=
67 | #0 'uppercase.name :=
68 | #0 'terms.in.macro :=
69 | #0 'year.after.author :=
70 | #1 'period.after.author :=
71 | #0 'italic.book.title :=
72 | #1 'sentence.case.title :=
73 | #0 'link.title :=
74 | #1 'title.in.journal :=
75 | #0 'show.patent.country :=
76 | #1 'show.mark :=
77 | #0 'space.before.mark :=
78 | #1 'show.medium.type :=
79 | "slash" 'component.part.label :=
80 | #0 'short.journal :=
81 | #1 'italic.journal :=
82 | #0 'link.journal :=
83 | #0 'bold.journal.volume :=
84 | #0 'show.missing.address.publisher :=
85 | #1 'space.before.pages :=
86 | #0 'only.start.page :=
87 | #0 'wave.dash.in.pages :=
88 | #0 'show.urldate :=
89 | #0 'show.url :=
90 | #0 'show.doi :=
91 | #0 'show.preprint :=
92 | #0 'show.note :=
93 | #0 'show.english.translation :=
94 | #1 'end.with.period :=
95 | }
96 |
97 | ENTRY
98 | { address
99 | archivePrefix
100 | author
101 | booktitle
102 | date
103 | doi
104 | edition
105 | editor
106 | eprint
107 | eprinttype
108 | entrysubtype
109 | howpublished
110 | institution
111 | journal
112 | journaltitle
113 | key
114 | langid
115 | language
116 | location
117 | mark
118 | medium
119 | note
120 | number
121 | organization
122 | pages
123 | publisher
124 | school
125 | series
126 | shortjournal
127 | title
128 | translation
129 | translator
130 | url
131 | urldate
132 | volume
133 | year
134 | }
135 | { entry.lang entry.is.electronic is.pure.electronic entry.numbered }
136 | { label extra.label sort.label short.label short.list entry.mark entry.url }
137 |
138 | INTEGERS { output.state before.all mid.sentence after.sentence after.block after.slash }
139 |
140 | INTEGERS { lang.zh lang.ja lang.en lang.ru lang.other }
141 |
142 | INTEGERS { charptr len }
143 |
144 | FUNCTION {init.state.consts}
145 | { #0 'before.all :=
146 | #1 'mid.sentence :=
147 | #2 'after.sentence :=
148 | #3 'after.block :=
149 | #4 'after.slash :=
150 | #3 'lang.zh :=
151 | #4 'lang.ja :=
152 | #1 'lang.en :=
153 | #2 'lang.ru :=
154 | #0 'lang.other :=
155 | }
156 |
157 | FUNCTION {bbl.anonymous}
158 | { entry.lang lang.zh =
159 | { "佚名" }
160 | { "Anon" }
161 | if$
162 | }
163 |
164 | FUNCTION {bbl.space}
165 | { entry.lang lang.zh =
166 | { "\ " }
167 | { " " }
168 | if$
169 | }
170 |
171 | FUNCTION {bbl.and}
172 | { "" }
173 |
174 | FUNCTION {bbl.et.al}
175 | { entry.lang lang.zh =
176 | { "等" }
177 | { entry.lang lang.ja =
178 | { "他" }
179 | { entry.lang lang.ru =
180 | { "идр" }
181 | { "et~al." }
182 | if$
183 | }
184 | if$
185 | }
186 | if$
187 | }
188 |
189 | FUNCTION {citation.and}
190 | { terms.in.macro
191 | { "{\biband}" }
192 | 'bbl.and
193 | if$
194 | }
195 |
196 | FUNCTION {citation.et.al}
197 | { terms.in.macro
198 | { "{\bibetal}" }
199 | 'bbl.et.al
200 | if$
201 | }
202 |
203 | FUNCTION {bbl.colon} { ": " }
204 |
205 | FUNCTION {bbl.pages.colon}
206 | { space.before.pages
207 | { ": " }
208 | { ":\allowbreak " }
209 | if$
210 | }
211 |
212 | FUNCTION {bbl.wide.space} { "\quad " }
213 |
214 | FUNCTION {bbl.slash} { "//\allowbreak " }
215 |
216 | FUNCTION {bbl.sine.loco}
217 | { entry.lang lang.zh =
218 | { "[出版地不详]" }
219 | { "[S.l.]" }
220 | if$
221 | }
222 |
223 | FUNCTION {bbl.sine.nomine}
224 | { entry.lang lang.zh =
225 | { "[出版者不详]" }
226 | { "[s.n.]" }
227 | if$
228 | }
229 |
230 | FUNCTION {bbl.sine.loco.sine.nomine}
231 | { entry.lang lang.zh =
232 | { "[出版地不详: 出版者不详]" }
233 | { "[S.l.: s.n.]" }
234 | if$
235 | }
236 |
237 | FUNCTION {not}
238 | { { #0 }
239 | { #1 }
240 | if$
241 | }
242 |
243 | FUNCTION {and}
244 | { 'skip$
245 | { pop$ #0 }
246 | if$
247 | }
248 |
249 | FUNCTION {or}
250 | { { pop$ #1 }
251 | 'skip$
252 | if$
253 | }
254 |
255 | STRINGS { x y }
256 |
257 | FUNCTION {contains}
258 | { 'y :=
259 | 'x :=
260 | y text.length$ 'len :=
261 | x text.length$ len - #1 + 'charptr :=
262 | { charptr #0 >
263 | x charptr len substring$ y = not
264 | and
265 | }
266 | { charptr #1 - 'charptr := }
267 | while$
268 | charptr #0 >
269 | }
270 |
271 | STRINGS { s t }
272 |
273 | FUNCTION {output.nonnull}
274 | { 's :=
275 | output.state mid.sentence =
276 | { ", " * write$ }
277 | { output.state after.block =
278 | { add.period$ write$
279 | newline$
280 | "\newblock " write$
281 | }
282 | { output.state before.all =
283 | 'write$
284 | { output.state after.slash =
285 | { bbl.slash * write$
286 | newline$
287 | }
288 | { add.period$ " " * write$ }
289 | if$
290 | }
291 | if$
292 | }
293 | if$
294 | mid.sentence 'output.state :=
295 | }
296 | if$
297 | s
298 | }
299 |
300 | FUNCTION {output}
301 | { duplicate$ empty$
302 | 'pop$
303 | 'output.nonnull
304 | if$
305 | }
306 |
307 | FUNCTION {output.after}
308 | { 't :=
309 | duplicate$ empty$
310 | 'pop$
311 | { 's :=
312 | output.state mid.sentence =
313 | { t * write$ }
314 | { output.state after.block =
315 | { add.period$ write$
316 | newline$
317 | "\newblock " write$
318 | }
319 | { output.state before.all =
320 | 'write$
321 | { output.state after.slash =
322 | { bbl.slash * write$ }
323 | { add.period$ " " * write$ }
324 | if$
325 | }
326 | if$
327 | }
328 | if$
329 | mid.sentence 'output.state :=
330 | }
331 | if$
332 | s
333 | }
334 | if$
335 | }
336 |
337 | FUNCTION {output.check}
338 | { 't :=
339 | duplicate$ empty$
340 | { pop$ "empty " t * " in " * cite$ * warning$ }
341 | 'output.nonnull
342 | if$
343 | }
344 |
345 | FUNCTION {fin.entry}
346 | { end.with.period
347 | 'add.period$
348 | 'skip$
349 | if$
350 | write$
351 | show.english.translation entry.lang lang.zh = and
352 | { ")"
353 | write$
354 | }
355 | 'skip$
356 | if$
357 | newline$
358 | }
359 |
360 | FUNCTION {new.block}
361 | { output.state before.all =
362 | 'skip$
363 | { output.state after.slash =
364 | 'skip$
365 | { after.block 'output.state := }
366 | if$
367 | }
368 | if$
369 | }
370 |
371 | FUNCTION {new.sentence}
372 | { output.state after.block =
373 | 'skip$
374 | { output.state before.all =
375 | 'skip$
376 | { output.state after.slash =
377 | 'skip$
378 | { after.sentence 'output.state := }
379 | if$
380 | }
381 | if$
382 | }
383 | if$
384 | }
385 |
386 | FUNCTION {new.slash}
387 | { output.state before.all =
388 | 'skip$
389 | { component.part.label "slash" =
390 | { after.slash 'output.state := }
391 | { new.block
392 | component.part.label "in" =
393 | { entry.lang lang.en =
394 | { "In: " output
395 | write$
396 | ""
397 | before.all 'output.state :=
398 | }
399 | 'skip$
400 | if$
401 | }
402 | 'skip$
403 | if$
404 | }
405 | if$
406 | }
407 | if$
408 | }
409 |
410 | FUNCTION {new.block.checka}
411 | { empty$
412 | 'skip$
413 | 'new.block
414 | if$
415 | }
416 |
417 | FUNCTION {new.block.checkb}
418 | { empty$
419 | swap$ empty$
420 | and
421 | 'skip$
422 | 'new.block
423 | if$
424 | }
425 |
426 | FUNCTION {new.sentence.checka}
427 | { empty$
428 | 'skip$
429 | 'new.sentence
430 | if$
431 | }
432 |
433 | FUNCTION {new.sentence.checkb}
434 | { empty$
435 | swap$ empty$
436 | and
437 | 'skip$
438 | 'new.sentence
439 | if$
440 | }
441 |
442 | FUNCTION {field.or.null}
443 | { duplicate$ empty$
444 | { pop$ "" }
445 | 'skip$
446 | if$
447 | }
448 |
449 | FUNCTION {emphasize}
450 | { duplicate$ empty$
451 | { pop$ "" }
452 | { "\emph{" swap$ * "}" * }
453 | if$
454 | }
455 |
456 | FUNCTION {format.btitle}
457 | { italic.book.title
458 | entry.lang lang.en = and
459 | 'emphasize
460 | 'skip$
461 | if$
462 | }
463 |
464 | INTEGERS { byte second.byte }
465 |
466 | INTEGERS { char.lang tmp.lang }
467 |
468 | STRINGS { tmp.str }
469 |
470 | FUNCTION {get.str.lang}
471 | { 'tmp.str :=
472 | lang.other 'tmp.lang :=
473 | #1 'charptr :=
474 | tmp.str text.length$ #1 + 'len :=
475 | { charptr len < }
476 | { tmp.str charptr #1 substring$ chr.to.int$ 'byte :=
477 | byte #128 <
478 | { charptr #1 + 'charptr :=
479 | byte #64 > byte #91 < and byte #96 > byte #123 < and or
480 | { lang.en 'char.lang := }
481 | { lang.other 'char.lang := }
482 | if$
483 | }
484 | { tmp.str charptr #1 + #1 substring$ chr.to.int$ 'second.byte :=
485 | byte #224 <
486 | { charptr #2 + 'charptr :=
487 | byte #207 > byte #212 < and
488 | byte #212 = second.byte #176 < and or
489 | { lang.ru 'char.lang := }
490 | { lang.other 'char.lang := }
491 | if$
492 | }
493 | { byte #240 <
494 | { charptr #3 + 'charptr :=
495 | byte #227 > byte #234 < and
496 | { lang.zh 'char.lang := }
497 | { byte #227 =
498 | { second.byte #143 >
499 | { lang.zh 'char.lang := }
500 | { second.byte #128 > second.byte #132 < and
501 | { lang.ja 'char.lang := }
502 | { lang.other 'char.lang := }
503 | if$
504 | }
505 | if$
506 | }
507 | { byte #239 =
508 | second.byte #163 > second.byte #172 < and and
509 | { lang.zh 'char.lang := }
510 | { lang.other 'char.lang := }
511 | if$
512 | }
513 | if$
514 | }
515 | if$
516 | }
517 | { charptr #4 + 'charptr :=
518 | byte #240 = second.byte #159 > and
519 | { lang.zh 'char.lang := }
520 | { lang.other 'char.lang := }
521 | if$
522 | }
523 | if$
524 | }
525 | if$
526 | }
527 | if$
528 | char.lang tmp.lang >
529 | { char.lang 'tmp.lang := }
530 | 'skip$
531 | if$
532 | }
533 | while$
534 | tmp.lang
535 | }
536 |
537 | FUNCTION {check.entry.lang}
538 | { author field.or.null
539 | title field.or.null *
540 | get.str.lang
541 | }
542 |
543 | STRINGS { entry.langid }
544 |
545 | FUNCTION {set.entry.lang}
546 | { "" 'entry.langid :=
547 | language empty$ not
548 | { language 'entry.langid := }
549 | 'skip$
550 | if$
551 | langid empty$ not
552 | { langid 'entry.langid := }
553 | 'skip$
554 | if$
555 | entry.langid empty$
556 | { check.entry.lang }
557 | { entry.langid "english" = entry.langid "american" = or entry.langid "british" = or
558 | { lang.en }
559 | { entry.langid "chinese" =
560 | { lang.zh }
561 | { entry.langid "japanese" =
562 | { lang.ja }
563 | { entry.langid "russian" =
564 | { lang.ru }
565 | { check.entry.lang }
566 | if$
567 | }
568 | if$
569 | }
570 | if$
571 | }
572 | if$
573 | }
574 | if$
575 | 'entry.lang :=
576 | }
577 |
578 | FUNCTION {set.entry.numbered}
579 | { type$ "patent" =
580 | type$ "standard" = or
581 | type$ "techreport" = or
582 | { #1 'entry.numbered := }
583 | { #0 'entry.numbered := }
584 | if$
585 | }
586 |
587 | INTEGERS { nameptr namesleft numnames name.lang }
588 |
589 | FUNCTION {format.name}
590 | { "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
591 | t "others" =
592 | { bbl.et.al }
593 | { t get.str.lang 'name.lang :=
594 | name.lang lang.en =
595 | { t #1 "{vv~}{ll}{ f{~}}" format.name$
596 | uppercase.name
597 | { "u" change.case$ }
598 | 'skip$
599 | if$
600 | t #1 "{, jj}" format.name$ *
601 | }
602 | { t #1 "{ll}{ff}" format.name$ }
603 | if$
604 | }
605 | if$
606 | }
607 |
608 | FUNCTION {format.names}
609 | { 's :=
610 | #1 'nameptr :=
611 | s num.names$ 'numnames :=
612 | ""
613 | numnames 'namesleft :=
614 | { namesleft #0 > }
615 | { s nameptr format.name bbl.et.al =
616 | numnames bibliography.et.al.min #1 - > nameptr bibliography.et.al.use.first > and or
617 | { ", " *
618 | bbl.et.al *
619 | #1 'namesleft :=
620 | }
621 | { nameptr #1 >
622 | { namesleft #1 = bbl.and "" = not and
623 | { bbl.and * }
624 | { ", " * }
625 | if$
626 | }
627 | 'skip$
628 | if$
629 | s nameptr format.name *
630 | }
631 | if$
632 | nameptr #1 + 'nameptr :=
633 | namesleft #1 - 'namesleft :=
634 | }
635 | while$
636 | }
637 |
638 | FUNCTION {format.key}
639 | { empty$
640 | { key field.or.null }
641 | { "" }
642 | if$
643 | }
644 |
645 | FUNCTION {format.authors}
646 | { author empty$ not
647 | { author format.names }
648 | { "empty author in " cite$ * warning$
649 | ""
650 | }
651 | if$
652 | }
653 |
654 | FUNCTION {format.editors}
655 | { editor empty$
656 | { "" }
657 | { editor format.names }
658 | if$
659 | }
660 |
661 | FUNCTION {format.translators}
662 | { translator empty$
663 | { "" }
664 | { translator format.names
665 | entry.lang lang.zh =
666 | { translator num.names$ #3 >
667 | { "译" * }
668 | { ", 译" * }
669 | if$
670 | }
671 | 'skip$
672 | if$
673 | }
674 | if$
675 | }
676 |
677 | FUNCTION {format.full.names}
678 | {'s :=
679 | #1 'nameptr :=
680 | s num.names$ 'numnames :=
681 | numnames 'namesleft :=
682 | { namesleft #0 > }
683 | { s nameptr "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
684 | t get.str.lang 'name.lang :=
685 | name.lang lang.en =
686 | { t #1 "{vv~}{ll}" format.name$ 't := }
687 | { t #1 "{ll}{ff}" format.name$ 't := }
688 | if$
689 | nameptr #1 >
690 | {
691 | namesleft #1 >
692 | { ", " * t * }
693 | {
694 | numnames #2 >
695 | { "," * }
696 | 'skip$
697 | if$
698 | t "others" =
699 | { " et~al." * }
700 | { " and " * t * }
701 | if$
702 | }
703 | if$
704 | }
705 | 't
706 | if$
707 | nameptr #1 + 'nameptr :=
708 | namesleft #1 - 'namesleft :=
709 | }
710 | while$
711 | }
712 |
713 | FUNCTION {author.editor.full}
714 | { author empty$
715 | { editor empty$
716 | { "" }
717 | { editor format.full.names }
718 | if$
719 | }
720 | { author format.full.names }
721 | if$
722 | }
723 |
724 | FUNCTION {author.full}
725 | { author empty$
726 | { "" }
727 | { author format.full.names }
728 | if$
729 | }
730 |
731 | FUNCTION {editor.full}
732 | { editor empty$
733 | { "" }
734 | { editor format.full.names }
735 | if$
736 | }
737 |
738 | FUNCTION {make.full.names}
739 | { type$ "book" =
740 | type$ "inbook" = booktitle empty$ not and
741 | or
742 | 'author.editor.full
743 | { type$ "collection" =
744 | type$ "proceedings" =
745 | or
746 | 'editor.full
747 | 'author.full
748 | if$
749 | }
750 | if$
751 | }
752 |
753 | FUNCTION {output.bibitem}
754 | { newline$
755 | "\bibitem[" write$
756 | label ")" *
757 | make.full.names duplicate$ short.list =
758 | { pop$ }
759 | { duplicate$ "]" contains
760 | { "{" swap$ * "}" * }
761 | 'skip$
762 | if$
763 | *
764 | }
765 | if$
766 | "]{" * write$
767 | cite$ write$
768 | "}" write$
769 | newline$
770 | ""
771 | before.all 'output.state :=
772 | }
773 |
774 | FUNCTION {change.sentence.case}
775 | { entry.lang lang.en =
776 | { "t" change.case$ }
777 | 'skip$
778 | if$
779 | }
780 |
781 | FUNCTION {add.link}
782 | { url empty$ not
783 | { "\href{" url * "}{" * swap$ * "}" * }
784 | { doi empty$ not
785 | { "\href{https://doi.org/" doi * "}{" * swap$ * "}" * }
786 | 'skip$
787 | if$
788 | }
789 | if$
790 | }
791 |
792 | FUNCTION {format.title}
793 | { title empty$
794 | { "" }
795 | { title
796 | sentence.case.title
797 | 'change.sentence.case
798 | 'skip$
799 | if$
800 | entry.numbered number empty$ not and
801 | { bbl.colon *
802 | type$ "patent" = show.patent.country and
803 | { address empty$ not
804 | { address * ", " * }
805 | { location empty$ not
806 | { location * ", " * }
807 | { entry.lang lang.zh =
808 | { "中国" * ", " * }
809 | 'skip$
810 | if$
811 | }
812 | if$
813 | }
814 | if$
815 | }
816 | 'skip$
817 | if$
818 | number *
819 | }
820 | 'skip$
821 | if$
822 | link.title
823 | 'add.link
824 | 'skip$
825 | if$
826 | }
827 | if$
828 | }
829 |
830 | FUNCTION {tie.or.space.connect}
831 | { duplicate$ text.length$ #3 <
832 | { "~" }
833 | { " " }
834 | if$
835 | swap$ * *
836 | }
837 |
838 | FUNCTION {either.or.check}
839 | { empty$
840 | 'pop$
841 | { "can't use both " swap$ * " fields in " * cite$ * warning$ }
842 | if$
843 | }
844 |
845 | FUNCTION {is.digit}
846 | { duplicate$ empty$
847 | { pop$ #0 }
848 | { chr.to.int$
849 | duplicate$ "0" chr.to.int$ <
850 | { pop$ #0 }
851 | { "9" chr.to.int$ >
852 | { #0 }
853 | { #1 }
854 | if$
855 | }
856 | if$
857 | }
858 | if$
859 | }
860 |
861 | FUNCTION {is.number}
862 | { 's :=
863 | s empty$
864 | { #0 }
865 | { s text.length$ 'charptr :=
866 | { charptr #0 >
867 | s charptr #1 substring$ is.digit
868 | and
869 | }
870 | { charptr #1 - 'charptr := }
871 | while$
872 | charptr not
873 | }
874 | if$
875 | }
876 |
877 | FUNCTION {format.volume}
878 | { volume empty$ not
879 | { volume is.number
880 | { entry.lang lang.zh =
881 | { "第 " volume * " 卷" * }
882 | { "Vol." volume tie.or.space.connect }
883 | if$
884 | }
885 | { volume }
886 | if$
887 | }
888 | { "" }
889 | if$
890 | }
891 |
892 | FUNCTION {format.number}
893 | { number empty$ not
894 | { number is.number
895 | { entry.lang lang.zh =
896 | { "第 " number * " 册" * }
897 | { "No." number tie.or.space.connect }
898 | if$
899 | }
900 | { number }
901 | if$
902 | }
903 | { "" }
904 | if$
905 | }
906 |
907 | FUNCTION {format.volume.number}
908 | { volume empty$ not
909 | { format.volume }
910 | { format.number }
911 | if$
912 | }
913 |
914 | FUNCTION {format.title.vol.num}
915 | { title
916 | sentence.case.title
917 | 'change.sentence.case
918 | 'skip$
919 | if$
920 | entry.numbered
921 | { number empty$ not
922 | { bbl.colon * number * }
923 | 'skip$
924 | if$
925 | }
926 | { format.volume.number 's :=
927 | s empty$ not
928 | { bbl.colon * s * }
929 | 'skip$
930 | if$
931 | }
932 | if$
933 | }
934 |
935 | FUNCTION {format.series.vol.num.title}
936 | { format.volume.number 's :=
937 | series empty$ not
938 | { series
939 | sentence.case.title
940 | 'change.sentence.case
941 | 'skip$
942 | if$
943 | entry.numbered
944 | { bbl.wide.space * }
945 | { bbl.colon *
946 | s empty$ not
947 | { s * bbl.wide.space * }
948 | 'skip$
949 | if$
950 | }
951 | if$
952 | title *
953 | sentence.case.title
954 | 'change.sentence.case
955 | 'skip$
956 | if$
957 | entry.numbered number empty$ not and
958 | { bbl.colon * number * }
959 | 'skip$
960 | if$
961 | }
962 | { format.title.vol.num }
963 | if$
964 | format.btitle
965 | link.title
966 | 'add.link
967 | 'skip$
968 | if$
969 | }
970 |
971 | FUNCTION {format.booktitle.vol.num}
972 | { booktitle
973 | entry.numbered
974 | 'skip$
975 | { format.volume.number 's :=
976 | s empty$ not
977 | { bbl.colon * s * }
978 | 'skip$
979 | if$
980 | }
981 | if$
982 | }
983 |
984 | FUNCTION {format.series.vol.num.booktitle}
985 | { format.volume.number 's :=
986 | series empty$ not
987 | { series bbl.colon *
988 | entry.numbered not s empty$ not and
989 | { s * bbl.wide.space * }
990 | 'skip$
991 | if$
992 | booktitle *
993 | }
994 | { format.booktitle.vol.num }
995 | if$
996 | format.btitle
997 | }
998 |
999 | FUNCTION {remove.period}
1000 | { 't :=
1001 | "" 's :=
1002 | { t empty$ not }
1003 | { t #1 #1 substring$ 'tmp.str :=
1004 | tmp.str "." = not
1005 | { s tmp.str * 's := }
1006 | 'skip$
1007 | if$
1008 | t #2 global.max$ substring$ 't :=
1009 | }
1010 | while$
1011 | s
1012 | }
1013 |
1014 | FUNCTION {abbreviate}
1015 | { remove.period
1016 | 't :=
1017 | t "l" change.case$ 's :=
1018 | ""
1019 | s "physical review letters" =
1020 | { "Phys Rev Lett" }
1021 | 'skip$
1022 | if$
1023 | 's :=
1024 | s empty$
1025 | { t }
1026 | { pop$ s }
1027 | if$
1028 | }
1029 |
1030 | FUNCTION {get.journal.title}
1031 | { short.journal
1032 | { shortjournal empty$ not
1033 | { shortjournal }
1034 | { journal empty$ not
1035 | { journal abbreviate }
1036 | { journaltitle empty$ not
1037 | { journaltitle abbreviate }
1038 | { "" }
1039 | if$
1040 | }
1041 | if$
1042 | }
1043 | if$
1044 | }
1045 | { journal empty$ not
1046 | { journal }
1047 | { journaltitle empty$ not
1048 | { journaltitle }
1049 | { shortjournal empty$ not
1050 | { shortjournal }
1051 | { "" }
1052 | if$
1053 | }
1054 | if$
1055 | }
1056 | if$
1057 | }
1058 | if$
1059 | }
1060 |
1061 | FUNCTION {check.arxiv.preprint}
1062 | { #1 #5 substring$ purify$ "l" change.case$ "arxiv" =
1063 | { #1 }
1064 | { #0 }
1065 | if$
1066 | }
1067 |
1068 | FUNCTION {format.journal}
1069 | { get.journal.title
1070 | duplicate$ empty$ not
1071 | { italic.journal entry.lang lang.en = and
1072 | 'emphasize
1073 | 'skip$
1074 | if$
1075 | link.journal
1076 | 'add.link
1077 | 'skip$
1078 | if$
1079 | }
1080 | 'skip$
1081 | if$
1082 | }
1083 |
1084 | FUNCTION {set.entry.mark}
1085 | { entry.mark empty$ not
1086 | 'pop$
1087 | { mark empty$ not
1088 | { pop$ mark 'entry.mark := }
1089 | { 'entry.mark := }
1090 | if$
1091 | }
1092 | if$
1093 | }
1094 |
1095 | FUNCTION {format.mark}
1096 | { show.mark
1097 | { entry.mark
1098 | show.medium.type
1099 | { medium empty$ not
1100 | { "/" * medium * }
1101 | { entry.is.electronic
1102 | { "/OL" * }
1103 | 'skip$
1104 | if$
1105 | }
1106 | if$
1107 | }
1108 | 'skip$
1109 | if$
1110 | 'entry.mark :=
1111 | space.before.mark
1112 | { " " }
1113 | { "\allowbreak" }
1114 | if$
1115 | "[" * entry.mark * "]" *
1116 | }
1117 | { "" }
1118 | if$
1119 | }
1120 |
1121 | FUNCTION {num.to.ordinal}
1122 | { duplicate$ text.length$ 'charptr :=
1123 | duplicate$ charptr #1 substring$ 's :=
1124 | s "1" =
1125 | { "st" * }
1126 | { s "2" =
1127 | { "nd" * }
1128 | { s "3" =
1129 | { "rd" * }
1130 | { "th" * }
1131 | if$
1132 | }
1133 | if$
1134 | }
1135 | if$
1136 | }
1137 |
1138 | FUNCTION {format.edition}
1139 | { edition empty$
1140 | { "" }
1141 | { edition is.number
1142 | { edition "1" = not
1143 | { entry.lang lang.zh =
1144 | { edition " 版" * }
1145 | { edition num.to.ordinal " ed." * }
1146 | if$
1147 | }
1148 | 'skip$
1149 | if$
1150 | }
1151 | { entry.lang lang.en =
1152 | { edition change.sentence.case 's :=
1153 | s "Revised" = s "Revised edition" = or
1154 | { "Rev. ed." }
1155 | { s " ed." * }
1156 | if$
1157 | }
1158 | { edition }
1159 | if$
1160 | }
1161 | if$
1162 | }
1163 | if$
1164 | }
1165 |
1166 | FUNCTION {format.publisher}
1167 | { publisher empty$ not
1168 | { publisher }
1169 | { school empty$ not
1170 | { school }
1171 | { organization empty$ not
1172 | { organization }
1173 | { institution empty$ not
1174 | { institution }
1175 | { "" }
1176 | if$
1177 | }
1178 | if$
1179 | }
1180 | if$
1181 | }
1182 | if$
1183 | }
1184 |
1185 | FUNCTION {format.address.publisher}
1186 | { address empty$ not
1187 | { address }
1188 | { location empty$ not
1189 | { location }
1190 | { "" }
1191 | if$
1192 | }
1193 | if$
1194 | duplicate$ empty$ not
1195 | { format.publisher empty$ not
1196 | { bbl.colon * format.publisher * }
1197 | { entry.is.electronic not show.missing.address.publisher and
1198 | { bbl.colon * bbl.sine.nomine * }
1199 | 'skip$
1200 | if$
1201 | }
1202 | if$
1203 | }
1204 | { pop$
1205 | entry.is.electronic not show.missing.address.publisher and
1206 | { format.publisher empty$ not
1207 | { bbl.sine.loco bbl.colon * format.publisher * }
1208 | { bbl.sine.loco.sine.nomine }
1209 | if$
1210 | }
1211 | { format.publisher empty$ not
1212 | { format.publisher }
1213 | { "" }
1214 | if$
1215 | }
1216 | if$
1217 | }
1218 | if$
1219 | }
1220 |
1221 | FUNCTION {extract.before.dash}
1222 | { duplicate$ empty$
1223 | { pop$ "" }
1224 | { 's :=
1225 | #1 'charptr :=
1226 | s text.length$ #1 + 'len :=
1227 | { charptr len <
1228 | s charptr #1 substring$ "-" = not
1229 | and
1230 | }
1231 | { charptr #1 + 'charptr := }
1232 | while$
1233 | s #1 charptr #1 - substring$
1234 | }
1235 | if$
1236 | }
1237 |
1238 | FUNCTION {extract.after.dash}
1239 | { duplicate$ empty$
1240 | { pop$ "" }
1241 | { 's :=
1242 | #1 'charptr :=
1243 | s text.length$ #1 + 'len :=
1244 | { charptr len <
1245 | s charptr #1 substring$ "-" = not
1246 | and
1247 | }
1248 | { charptr #1 + 'charptr := }
1249 | while$
1250 | { charptr len <
1251 | s charptr #1 substring$ "-" =
1252 | and
1253 | }
1254 | { charptr #1 + 'charptr := }
1255 | while$
1256 | s charptr global.max$ substring$
1257 | }
1258 | if$
1259 | }
1260 |
1261 | FUNCTION {extract.before.slash}
1262 | { duplicate$ empty$
1263 | { pop$ "" }
1264 | { 's :=
1265 | #1 'charptr :=
1266 | s text.length$ #1 + 'len :=
1267 | { charptr len <
1268 | s charptr #1 substring$ "/" = not
1269 | and
1270 | }
1271 | { charptr #1 + 'charptr := }
1272 | while$
1273 | s #1 charptr #1 - substring$
1274 | }
1275 | if$
1276 | }
1277 |
1278 | FUNCTION {extract.after.slash}
1279 | { duplicate$ empty$
1280 | { pop$ "" }
1281 | { 's :=
1282 | #1 'charptr :=
1283 | s text.length$ #1 + 'len :=
1284 | { charptr len <
1285 | s charptr #1 substring$ "-" = not
1286 | and
1287 | s charptr #1 substring$ "/" = not
1288 | and
1289 | }
1290 | { charptr #1 + 'charptr := }
1291 | while$
1292 | { charptr len <
1293 | s charptr #1 substring$ "-" =
1294 | s charptr #1 substring$ "/" =
1295 | or
1296 | and
1297 | }
1298 | { charptr #1 + 'charptr := }
1299 | while$
1300 | s charptr global.max$ substring$
1301 | }
1302 | if$
1303 | }
1304 |
1305 | FUNCTION {format.year}
1306 | { year empty$ not
1307 | { year extract.before.slash extra.label * }
1308 | { date empty$ not
1309 | { date extract.before.dash extra.label * }
1310 | { entry.is.electronic not
1311 | { "empty year in " cite$ * warning$ }
1312 | 'skip$
1313 | if$
1314 | urldate empty$ not
1315 | { "[" urldate extract.before.dash * extra.label * "]" * }
1316 | { "" }
1317 | if$
1318 | }
1319 | if$
1320 | }
1321 | if$
1322 | }
1323 |
1324 | FUNCTION {format.periodical.year}
1325 | { year empty$ not
1326 | { year extract.before.slash
1327 | "--" *
1328 | year extract.after.slash
1329 | duplicate$ empty$
1330 | 'pop$
1331 | { * }
1332 | if$
1333 | }
1334 | { date empty$ not
1335 | { date extract.before.dash }
1336 | { "empty year in " cite$ * warning$
1337 | urldate empty$ not
1338 | { "[" urldate extract.before.dash * "]" * }
1339 | { "" }
1340 | if$
1341 | }
1342 | if$
1343 | }
1344 | if$
1345 | }
1346 |
1347 | FUNCTION {format.date}
1348 | { date empty$ not
1349 | { type$ "patent" = type$ "newspaper" = or
1350 | { date }
1351 | { entrysubtype empty$ not
1352 | { type$ "article" = entrysubtype "newspaper" = and
1353 | { date }
1354 | { format.year }
1355 | if$
1356 | }
1357 | { format.year }
1358 | if$
1359 | }
1360 | if$
1361 | }
1362 | { year empty$ not
1363 | { format.year }
1364 | { "" }
1365 | if$
1366 | }
1367 | if$
1368 | }
1369 |
1370 | FUNCTION {format.editdate}
1371 | { date empty$ not
1372 | { "\allowbreak(" date * ")" * }
1373 | { "" }
1374 | if$
1375 | }
1376 |
1377 | FUNCTION {format.urldate}
1378 | { show.urldate show.url and entry.url empty$ not and
1379 | is.pure.electronic or
1380 | urldate empty$ not and
1381 | { "\allowbreak[" urldate * "]" * }
1382 | { "" }
1383 | if$
1384 | }
1385 |
1386 | FUNCTION {hyphenate}
1387 | { 't :=
1388 | ""
1389 | { t empty$ not }
1390 | { t #1 #1 substring$ "-" =
1391 | { wave.dash.in.pages
1392 | { "~" * }
1393 | { "-" * }
1394 | if$
1395 | { t #1 #1 substring$ "-" = }
1396 | { t #2 global.max$ substring$ 't := }
1397 | while$
1398 | }
1399 | { t #1 #1 substring$ *
1400 | t #2 global.max$ substring$ 't :=
1401 | }
1402 | if$
1403 | }
1404 | while$
1405 | }
1406 |
1407 | FUNCTION {format.pages}
1408 | { pages empty$
1409 | { "" }
1410 | { pages hyphenate }
1411 | if$
1412 | }
1413 |
1414 | FUNCTION {format.extracted.pages}
1415 | { pages empty$
1416 | { "" }
1417 | { pages
1418 | only.start.page
1419 | 'extract.before.dash
1420 | 'hyphenate
1421 | if$
1422 | }
1423 | if$
1424 | }
1425 |
1426 | FUNCTION {format.journal.volume}
1427 | { volume empty$ not
1428 | { bold.journal.volume
1429 | { "\textbf{" volume * "}" * }
1430 | { volume }
1431 | if$
1432 | }
1433 | { "" }
1434 | if$
1435 | }
1436 |
1437 | FUNCTION {format.journal.number}
1438 | { number empty$ not
1439 | { "\allowbreak (" number * ")" * }
1440 | { "" }
1441 | if$
1442 | }
1443 |
1444 | FUNCTION {format.journal.pages}
1445 | { pages empty$
1446 | { "" }
1447 | { format.extracted.pages }
1448 | if$
1449 | }
1450 |
1451 | FUNCTION {format.periodical.year.volume.number}
1452 | { year empty$ not
1453 | { year extract.before.slash }
1454 | { "empty year in periodical " cite$ * warning$ }
1455 | if$
1456 | volume empty$ not
1457 | { ", " * volume extract.before.dash * }
1458 | 'skip$
1459 | if$
1460 | number empty$ not
1461 | { "\allowbreak (" * number extract.before.dash * ")" * }
1462 | 'skip$
1463 | if$
1464 | "--" *
1465 | year extract.after.slash empty$
1466 | volume extract.after.dash empty$ and
1467 | number extract.after.dash empty$ and not
1468 | { year extract.after.slash empty$ not
1469 | { year extract.after.slash * }
1470 | { year extract.before.slash * }
1471 | if$
1472 | volume empty$ not
1473 | { ", " * volume extract.after.dash * }
1474 | 'skip$
1475 | if$
1476 | number empty$ not
1477 | { "\allowbreak (" * number extract.after.dash * ")" * }
1478 | 'skip$
1479 | if$
1480 | }
1481 | 'skip$
1482 | if$
1483 | }
1484 |
1485 | FUNCTION {check.url}
1486 | { url empty$ not
1487 | { "\url{" url * "}" * 'entry.url :=
1488 | #1 'entry.is.electronic :=
1489 | }
1490 | { howpublished empty$ not
1491 | { howpublished #1 #5 substring$ "\url{" =
1492 | { howpublished 'entry.url :=
1493 | #1 'entry.is.electronic :=
1494 | }
1495 | 'skip$
1496 | if$
1497 | }
1498 | { note empty$ not
1499 | { note #1 #5 substring$ "\url{" =
1500 | { note 'entry.url :=
1501 | #1 'entry.is.electronic :=
1502 | }
1503 | 'skip$
1504 | if$
1505 | }
1506 | 'skip$
1507 | if$
1508 | }
1509 | if$
1510 | }
1511 | if$
1512 | }
1513 |
1514 | FUNCTION {output.url}
1515 | { show.url is.pure.electronic or
1516 | entry.url empty$ not and
1517 | { new.block
1518 | entry.url output
1519 | }
1520 | 'skip$
1521 | if$
1522 | }
1523 |
1524 | FUNCTION {check.doi}
1525 | { doi empty$ not
1526 | { #1 'entry.is.electronic := }
1527 | 'skip$
1528 | if$
1529 | }
1530 |
1531 | FUNCTION {is.in.url}
1532 | { 's :=
1533 | s empty$
1534 | { #1 }
1535 | { entry.url empty$
1536 | { #0 }
1537 | { s text.length$ 'len :=
1538 | entry.url text.length$ 'charptr :=
1539 | { entry.url charptr len substring$ s = not
1540 | charptr #0 >
1541 | and
1542 | }
1543 | { charptr #1 - 'charptr := }
1544 | while$
1545 | charptr
1546 | }
1547 | if$
1548 | }
1549 | if$
1550 | }
1551 |
1552 | FUNCTION {format.doi}
1553 | { ""
1554 | doi empty$ not
1555 | { "" 's :=
1556 | doi 't :=
1557 | #0 'numnames :=
1558 | { t empty$ not}
1559 | { t #1 #1 substring$ 'tmp.str :=
1560 | tmp.str "," = tmp.str " " = or t #2 #1 substring$ empty$ or
1561 | { t #2 #1 substring$ empty$
1562 | { s tmp.str * 's := }
1563 | 'skip$
1564 | if$
1565 | s empty$ s is.in.url or
1566 | 'skip$
1567 | { numnames #1 + 'numnames :=
1568 | numnames #1 >
1569 | { ", " * }
1570 | { "DOI: " * }
1571 | if$
1572 | "\doi{" s * "}" * *
1573 | }
1574 | if$
1575 | "" 's :=
1576 | }
1577 | { s tmp.str * 's := }
1578 | if$
1579 | t #2 global.max$ substring$ 't :=
1580 | }
1581 | while$
1582 | }
1583 | 'skip$
1584 | if$
1585 | }
1586 |
1587 | FUNCTION {output.doi}
1588 | { doi empty$ not show.doi and
1589 | show.english.translation entry.lang lang.zh = and not and
1590 | { new.block
1591 | format.doi output
1592 | }
1593 | 'skip$
1594 | if$
1595 | }
1596 |
1597 | FUNCTION {check.electronic}
1598 | { "" 'entry.url :=
1599 | #0 'entry.is.electronic :=
1600 | 'check.doi
1601 | 'skip$
1602 | if$
1603 | 'check.url
1604 | 'skip$
1605 | if$
1606 | medium empty$ not
1607 | { medium "MT" = medium "DK" = or medium "CD" = or medium "OL" = or
1608 | { #1 'entry.is.electronic := }
1609 | 'skip$
1610 | if$
1611 | }
1612 | 'skip$
1613 | if$
1614 | }
1615 |
1616 | FUNCTION {format.eprint}
1617 | { archivePrefix empty$ not
1618 | { archivePrefix }
1619 | { eprinttype empty$ not
1620 | { archivePrefix }
1621 | { "" }
1622 | if$
1623 | }
1624 | if$
1625 | 's :=
1626 | s empty$ not
1627 | { s ": \eprint{" *
1628 | url empty$ not
1629 | { url }
1630 | { "https://" s "l" change.case$ * ".org/abs/" * eprint * }
1631 | if$
1632 | * "}{" *
1633 | eprint * "}" *
1634 | }
1635 | { eprint }
1636 | if$
1637 | }
1638 |
1639 | FUNCTION {output.eprint}
1640 | { show.preprint eprint empty$ not and
1641 | { new.block
1642 | format.eprint output
1643 | }
1644 | 'skip$
1645 | if$
1646 | }
1647 |
1648 | FUNCTION {format.note}
1649 | { note empty$ not show.note and
1650 | { note }
1651 | { "" }
1652 | if$
1653 | }
1654 |
1655 | FUNCTION {output.translation}
1656 | { show.english.translation entry.lang lang.zh = and
1657 | { translation empty$ not
1658 | { translation }
1659 | { "[English translation missing!]" }
1660 | if$
1661 | " (in Chinese)" * output
1662 | write$
1663 | format.doi duplicate$ empty$ not
1664 | { newline$
1665 | write$
1666 | }
1667 | 'pop$
1668 | if$
1669 | " \\" write$
1670 | newline$
1671 | "(" write$
1672 | ""
1673 | before.all 'output.state :=
1674 | }
1675 | 'skip$
1676 | if$
1677 | }
1678 |
1679 | FUNCTION {empty.misc.check}
1680 | { author empty$ title empty$
1681 | year empty$
1682 | and and
1683 | key empty$ not and
1684 | { "all relevant fields are empty in " cite$ * warning$ }
1685 | 'skip$
1686 | if$
1687 | }
1688 |
1689 | FUNCTION {monograph}
1690 | { output.bibitem
1691 | output.translation
1692 | author empty$ not
1693 | { format.authors }
1694 | { editor empty$ not
1695 | { format.editors }
1696 | { "empty author and editor in " cite$ * warning$
1697 | ""
1698 | }
1699 | if$
1700 | }
1701 | if$
1702 | output
1703 | year.after.author
1704 | { period.after.author
1705 | 'new.sentence
1706 | 'skip$
1707 | if$
1708 | format.year "year" output.check
1709 | }
1710 | 'skip$
1711 | if$
1712 | new.block
1713 | format.series.vol.num.title "title" output.check
1714 | "M" set.entry.mark
1715 | format.mark "" output.after
1716 | new.block
1717 | format.translators output
1718 | new.sentence
1719 | format.edition output
1720 | new.block
1721 | format.address.publisher output
1722 | year.after.author not
1723 | { format.year "year" output.check }
1724 | 'skip$
1725 | if$
1726 | format.pages bbl.pages.colon output.after
1727 | format.urldate "" output.after
1728 | output.url
1729 | output.doi
1730 | new.block
1731 | format.note output
1732 | fin.entry
1733 | }
1734 |
1735 | FUNCTION {incollection}
1736 | { output.bibitem
1737 | output.translation
1738 | format.authors output
1739 | author format.key output
1740 | year.after.author
1741 | { period.after.author
1742 | 'new.sentence
1743 | 'skip$
1744 | if$
1745 | format.year "year" output.check
1746 | }
1747 | 'skip$
1748 | if$
1749 | new.block
1750 | format.title "title" output.check
1751 | "M" set.entry.mark
1752 | format.mark "" output.after
1753 | new.block
1754 | format.translators output
1755 | new.slash
1756 | format.editors output
1757 | new.block
1758 | format.series.vol.num.booktitle "booktitle" output.check
1759 | new.block
1760 | format.edition output
1761 | new.block
1762 | format.address.publisher output
1763 | year.after.author not
1764 | { format.year "year" output.check }
1765 | 'skip$
1766 | if$
1767 | format.extracted.pages bbl.pages.colon output.after
1768 | format.urldate "" output.after
1769 | output.url
1770 | output.doi
1771 | new.block
1772 | format.note output
1773 | fin.entry
1774 | }
1775 |
1776 | FUNCTION {periodical}
1777 | { output.bibitem
1778 | output.translation
1779 | format.authors output
1780 | author format.key output
1781 | year.after.author
1782 | { period.after.author
1783 | 'new.sentence
1784 | 'skip$
1785 | if$
1786 | format.year "year" output.check
1787 | }
1788 | 'skip$
1789 | if$
1790 | new.block
1791 | format.title "title" output.check
1792 | "J" set.entry.mark
1793 | format.mark "" output.after
1794 | new.block
1795 | format.periodical.year.volume.number output
1796 | new.block
1797 | format.address.publisher output
1798 | year.after.author not
1799 | { format.periodical.year "year" output.check }
1800 | 'skip$
1801 | if$
1802 | format.urldate "" output.after
1803 | output.url
1804 | output.doi
1805 | new.block
1806 | format.note output
1807 | fin.entry
1808 | }
1809 |
1810 | FUNCTION {journal.article}
1811 | { output.bibitem
1812 | output.translation
1813 | format.authors output
1814 | author format.key output
1815 | year.after.author
1816 | { period.after.author
1817 | 'new.sentence
1818 | 'skip$
1819 | if$
1820 | format.year "year" output.check
1821 | }
1822 | 'skip$
1823 | if$
1824 | new.block
1825 | title.in.journal
1826 | { format.title "title" output.check
1827 | entrysubtype empty$ not
1828 | {
1829 | entrysubtype "newspaper" =
1830 | { "N" set.entry.mark }
1831 | { "J" set.entry.mark }
1832 | if$
1833 | }
1834 | { "J" set.entry.mark }
1835 | if$
1836 | format.mark "" output.after
1837 | new.block
1838 | }
1839 | 'skip$
1840 | if$
1841 | format.journal "journal" output.check
1842 | year.after.author not
1843 | { format.date "year" output.check }
1844 | 'skip$
1845 | if$
1846 | format.journal.volume output
1847 | format.journal.number "" output.after
1848 | format.journal.pages bbl.pages.colon output.after
1849 | format.urldate "" output.after
1850 | output.url
1851 | output.doi
1852 | new.block
1853 | format.note output
1854 | fin.entry
1855 | }
1856 |
1857 | FUNCTION {patent}
1858 | { output.bibitem
1859 | output.translation
1860 | format.authors output
1861 | author format.key output
1862 | year.after.author
1863 | { period.after.author
1864 | 'new.sentence
1865 | 'skip$
1866 | if$
1867 | format.year "year" output.check
1868 | }
1869 | 'skip$
1870 | if$
1871 | new.block
1872 | format.title "title" output.check
1873 | "P" set.entry.mark
1874 | format.mark "" output.after
1875 | new.block
1876 | format.date "year" output.check
1877 | format.urldate "" output.after
1878 | output.url
1879 | output.doi
1880 | new.block
1881 | format.note output
1882 | fin.entry
1883 | }
1884 |
1885 | FUNCTION {electronic}
1886 | { #1 #1 check.electronic
1887 | #1 'entry.is.electronic :=
1888 | #1 'is.pure.electronic :=
1889 | output.bibitem
1890 | output.translation
1891 | format.authors output
1892 | author format.key output
1893 | year.after.author
1894 | { period.after.author
1895 | 'new.sentence
1896 | 'skip$
1897 | if$
1898 | format.year "year" output.check
1899 | }
1900 | 'skip$
1901 | if$
1902 | new.block
1903 | format.series.vol.num.title "title" output.check
1904 | "EB" set.entry.mark
1905 | format.mark "" output.after
1906 | new.block
1907 | format.address.publisher output
1908 | year.after.author not
1909 | { date empty$
1910 | { format.date output }
1911 | 'skip$
1912 | if$
1913 | }
1914 | 'skip$
1915 | if$
1916 | format.pages bbl.pages.colon output.after
1917 | format.editdate "" output.after
1918 | format.urldate "" output.after
1919 | output.url
1920 | output.doi
1921 | new.block
1922 | format.note output
1923 | fin.entry
1924 | }
1925 |
1926 | FUNCTION {preprint}
1927 | { output.bibitem
1928 | output.translation
1929 | author empty$ not
1930 | { format.authors }
1931 | { editor empty$ not
1932 | { format.editors }
1933 | { "empty author and editor in " cite$ * warning$
1934 | ""
1935 | }
1936 | if$
1937 | }
1938 | if$
1939 | output
1940 | year.after.author
1941 | { period.after.author
1942 | 'new.sentence
1943 | 'skip$
1944 | if$
1945 | format.year "year" output.check
1946 | }
1947 | 'skip$
1948 | if$
1949 | new.block
1950 | title.in.journal
1951 | { format.series.vol.num.title "title" output.check
1952 | "A" set.entry.mark
1953 | format.mark "" output.after
1954 | new.block
1955 | }
1956 | 'skip$
1957 | if$
1958 | format.translators output
1959 | new.sentence
1960 | format.edition output
1961 | new.block
1962 | year.after.author not
1963 | { date empty$
1964 | { format.date output }
1965 | 'skip$
1966 | if$
1967 | }
1968 | 'skip$
1969 | if$
1970 | format.pages bbl.pages.colon output.after
1971 | format.editdate "" output.after
1972 | format.urldate "" output.after
1973 | output.eprint
1974 | output.url
1975 | show.preprint not eprint empty$ or
1976 | 'output.doi
1977 | 'skip$
1978 | if$
1979 | new.block
1980 | format.note output
1981 | fin.entry
1982 | }
1983 |
1984 | FUNCTION {misc}
1985 | { get.journal.title
1986 | duplicate$ empty$ not
1987 | { check.arxiv.preprint
1988 | 'preprint
1989 | 'journal.article
1990 | if$
1991 | }
1992 | { pop$
1993 | booktitle empty$ not
1994 | 'incollection
1995 | { publisher empty$ not
1996 | 'monograph
1997 | { eprint empty$ not archivePrefix empty$ not or
1998 | 'preprint
1999 | { entry.is.electronic
2000 | 'electronic
2001 | {
2002 | "Z" set.entry.mark
2003 | monograph
2004 | }
2005 | if$
2006 | }
2007 | if$
2008 | }
2009 | if$
2010 | }
2011 | if$
2012 | }
2013 | if$
2014 | empty.misc.check
2015 | }
2016 |
2017 | FUNCTION {archive}
2018 | { "A" set.entry.mark
2019 | misc
2020 | }
2021 |
2022 | FUNCTION {article} { misc }
2023 |
2024 | FUNCTION {book} { monograph }
2025 |
2026 | FUNCTION {booklet} { book }
2027 |
2028 | FUNCTION {collection}
2029 | { "G" set.entry.mark
2030 | monograph
2031 | }
2032 |
2033 | FUNCTION {database}
2034 | { "DB" set.entry.mark
2035 | electronic
2036 | }
2037 |
2038 | FUNCTION {dataset}
2039 | { "DS" set.entry.mark
2040 | electronic
2041 | }
2042 |
2043 | FUNCTION {inbook} {
2044 | booktitle empty$
2045 | 'book
2046 | 'incollection
2047 | if$
2048 | }
2049 |
2050 | FUNCTION {inproceedings}
2051 | { "C" set.entry.mark
2052 | incollection
2053 | }
2054 |
2055 | FUNCTION {conference} { inproceedings }
2056 |
2057 | FUNCTION {legislation} { archive }
2058 |
2059 | FUNCTION {map}
2060 | { "CM" set.entry.mark
2061 | misc
2062 | }
2063 |
2064 | FUNCTION {manual} { monograph }
2065 |
2066 | FUNCTION {mastersthesis}
2067 | { "D" set.entry.mark
2068 | monograph
2069 | }
2070 |
2071 | FUNCTION {newspaper}
2072 | { "N" set.entry.mark
2073 | article
2074 | }
2075 |
2076 | FUNCTION {online}
2077 | { "EB" set.entry.mark
2078 | electronic
2079 | }
2080 |
2081 | FUNCTION {phdthesis} { mastersthesis }
2082 |
2083 | FUNCTION {proceedings}
2084 | { "C" set.entry.mark
2085 | monograph
2086 | }
2087 |
2088 | FUNCTION {software}
2089 | { "CP" set.entry.mark
2090 | electronic
2091 | }
2092 |
2093 | FUNCTION {standard}
2094 | { "S" set.entry.mark
2095 | misc
2096 | }
2097 |
2098 | FUNCTION {techreport}
2099 | { "R" set.entry.mark
2100 | misc
2101 | }
2102 |
2103 | FUNCTION {unpublished} { misc }
2104 |
2105 | FUNCTION {default.type} { misc }
2106 |
2107 | MACRO {jan} {"January"}
2108 |
2109 | MACRO {feb} {"February"}
2110 |
2111 | MACRO {mar} {"March"}
2112 |
2113 | MACRO {apr} {"April"}
2114 |
2115 | MACRO {may} {"May"}
2116 |
2117 | MACRO {jun} {"June"}
2118 |
2119 | MACRO {jul} {"July"}
2120 |
2121 | MACRO {aug} {"August"}
2122 |
2123 | MACRO {sep} {"September"}
2124 |
2125 | MACRO {oct} {"October"}
2126 |
2127 | MACRO {nov} {"November"}
2128 |
2129 | MACRO {dec} {"December"}
2130 |
2131 | MACRO {acmcs} {"ACM Computing Surveys"}
2132 |
2133 | MACRO {acta} {"Acta Informatica"}
2134 |
2135 | MACRO {cacm} {"Communications of the ACM"}
2136 |
2137 | MACRO {ibmjrd} {"IBM Journal of Research and Development"}
2138 |
2139 | MACRO {ibmsj} {"IBM Systems Journal"}
2140 |
2141 | MACRO {ieeese} {"IEEE Transactions on Software Engineering"}
2142 |
2143 | MACRO {ieeetc} {"IEEE Transactions on Computers"}
2144 |
2145 | MACRO {ieeetcad}
2146 | {"IEEE Transactions on Computer-Aided Design of Integrated Circuits"}
2147 |
2148 | MACRO {ipl} {"Information Processing Letters"}
2149 |
2150 | MACRO {jacm} {"Journal of the ACM"}
2151 |
2152 | MACRO {jcss} {"Journal of Computer and System Sciences"}
2153 |
2154 | MACRO {scp} {"Science of Computer Programming"}
2155 |
2156 | MACRO {sicomp} {"SIAM Journal on Computing"}
2157 |
2158 | MACRO {tocs} {"ACM Transactions on Computer Systems"}
2159 |
2160 | MACRO {tods} {"ACM Transactions on Database Systems"}
2161 |
2162 | MACRO {tog} {"ACM Transactions on Graphics"}
2163 |
2164 | MACRO {toms} {"ACM Transactions on Mathematical Software"}
2165 |
2166 | MACRO {toois} {"ACM Transactions on Office Information Systems"}
2167 |
2168 | MACRO {toplas} {"ACM Transactions on Programming Languages and Systems"}
2169 |
2170 | MACRO {tcs} {"Theoretical Computer Science"}
2171 |
2172 | FUNCTION {sortify}
2173 | { purify$
2174 | "l" change.case$
2175 | }
2176 |
2177 | FUNCTION {chop.word}
2178 | { 's :=
2179 | 'len :=
2180 | s #1 len substring$ =
2181 | { s len #1 + global.max$ substring$ }
2182 | 's
2183 | if$
2184 | }
2185 |
2186 | FUNCTION {format.lab.name}
2187 | { "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
2188 | t "others" =
2189 | { citation.et.al }
2190 | { t get.str.lang 'name.lang :=
2191 | name.lang lang.zh = name.lang lang.ja = or
2192 | { t #1 "{ll}{ff}" format.name$ }
2193 | { t #1 "{vv~}{ll}" format.name$ }
2194 | if$
2195 | }
2196 | if$
2197 | }
2198 |
2199 | FUNCTION {format.lab.names}
2200 | { 's :=
2201 | s #1 format.lab.name 'short.label :=
2202 | #1 'nameptr :=
2203 | s num.names$ 'numnames :=
2204 | ""
2205 | numnames 'namesleft :=
2206 | { namesleft #0 > }
2207 | { s nameptr format.lab.name citation.et.al =
2208 | numnames citation.et.al.min #1 - > nameptr citation.et.al.use.first > and or
2209 | { bbl.space *
2210 | citation.et.al *
2211 | #1 'namesleft :=
2212 | }
2213 | { nameptr #1 >
2214 | { namesleft #1 = citation.and "" = not and
2215 | { citation.and * }
2216 | { ", " * }
2217 | if$
2218 | }
2219 | 'skip$
2220 | if$
2221 | s nameptr format.lab.name *
2222 | }
2223 | if$
2224 | nameptr #1 + 'nameptr :=
2225 | namesleft #1 - 'namesleft :=
2226 | }
2227 | while$
2228 | }
2229 |
2230 | FUNCTION {author.key.label}
2231 | { author empty$
2232 | { key empty$
2233 | { cite$ #1 #3 substring$ }
2234 | 'key
2235 | if$
2236 | }
2237 | { author format.lab.names }
2238 | if$
2239 | }
2240 |
2241 | FUNCTION {author.editor.key.label}
2242 | { author empty$
2243 | { editor empty$
2244 | { key empty$
2245 | { cite$ #1 #3 substring$ }
2246 | 'key
2247 | if$
2248 | }
2249 | { editor format.lab.names }
2250 | if$
2251 | }
2252 | { author format.lab.names }
2253 | if$
2254 | }
2255 |
2256 | FUNCTION {author.key.organization.label}
2257 | { author empty$
2258 | { key empty$
2259 | { organization empty$
2260 | { cite$ #1 #3 substring$ }
2261 | { "The " #4 organization chop.word #3 text.prefix$ }
2262 | if$
2263 | }
2264 | 'key
2265 | if$
2266 | }
2267 | { author format.lab.names }
2268 | if$
2269 | }
2270 |
2271 | FUNCTION {editor.key.organization.label}
2272 | { editor empty$
2273 | { key empty$
2274 | { organization empty$
2275 | { cite$ #1 #3 substring$ }
2276 | { "The " #4 organization chop.word #3 text.prefix$ }
2277 | if$
2278 | }
2279 | 'key
2280 | if$
2281 | }
2282 | { editor format.lab.names }
2283 | if$
2284 | }
2285 |
2286 | FUNCTION {calc.short.authors}
2287 | { "" 'short.label :=
2288 | type$ "book" =
2289 | type$ "inbook" = booktitle empty$ not and
2290 | or
2291 | 'author.editor.key.label
2292 | { type$ "collection" =
2293 | type$ "proceedings" =
2294 | or
2295 | { editor empty$ not
2296 | 'editor.key.organization.label
2297 | 'author.key.organization.label
2298 | if$
2299 | }
2300 | 'author.key.label
2301 | if$
2302 | }
2303 | if$
2304 | 'short.list :=
2305 | short.label empty$
2306 | { short.list 'short.label := }
2307 | 'skip$
2308 | if$
2309 | }
2310 |
2311 | FUNCTION {calc.label}
2312 | { calc.short.authors
2313 | short.list "]" contains
2314 | { "{" short.list * "}" * }
2315 | { short.list }
2316 | if$
2317 | "("
2318 | *
2319 | format.year duplicate$ empty$
2320 | short.list key field.or.null = or
2321 | { pop$ "" }
2322 | 'skip$
2323 | if$
2324 | duplicate$ "]" contains
2325 | { "{" swap$ * "}" * }
2326 | 'skip$
2327 | if$
2328 | *
2329 | 'label :=
2330 | short.label
2331 | "("
2332 | *
2333 | format.year duplicate$ empty$
2334 | short.list key field.or.null = or
2335 | { pop$ "" }
2336 | 'skip$
2337 | if$
2338 | *
2339 | 'short.label :=
2340 | }
2341 |
2342 | INTEGERS { seq.num }
2343 |
2344 | FUNCTION {init.seq}
2345 | { #0 'seq.num :=}
2346 |
2347 | FUNCTION {int.to.fix}
2348 | { "000000000" swap$ int.to.str$ *
2349 | #-1 #10 substring$
2350 | }
2351 |
2352 | FUNCTION {presort}
2353 | { set.entry.lang
2354 | set.entry.numbered
2355 | show.url show.doi check.electronic
2356 | #0 'is.pure.electronic :=
2357 | calc.label
2358 | label sortify
2359 | " "
2360 | *
2361 | seq.num #1 + 'seq.num :=
2362 | seq.num int.to.fix
2363 | 'sort.label :=
2364 | sort.label *
2365 | #1 entry.max$ substring$
2366 | 'sort.key$ :=
2367 | }
2368 |
2369 | STRINGS { longest.label last.label next.extra last.extra.label }
2370 |
2371 | INTEGERS { longest.label.width number.label }
2372 |
2373 | FUNCTION {initialize.longest.label}
2374 | { "" 'longest.label :=
2375 | #0 int.to.chr$ 'last.label :=
2376 | "" 'next.extra :=
2377 | #0 'longest.label.width :=
2378 | #0 'number.label :=
2379 | "" 'last.extra.label :=
2380 | }
2381 |
2382 | FUNCTION {forward.pass}
2383 | {
2384 | number.label #1 + 'number.label :=
2385 | }
2386 |
2387 | FUNCTION {reverse.pass}
2388 | {
2389 | label extra.label * 'label :=
2390 | }
2391 |
2392 | FUNCTION {bib.sort.order}
2393 | { sort.label 'sort.key$ :=
2394 | }
2395 |
2396 | FUNCTION {begin.bib}
2397 | { preamble$ empty$
2398 | 'skip$
2399 | { preamble$ write$ newline$ }
2400 | if$
2401 | "\begin{thebibliography}{" number.label int.to.str$ * "}" *
2402 | write$ newline$
2403 | terms.in.macro
2404 | { "\providecommand{\biband}{和}"
2405 | write$ newline$
2406 | "\providecommand{\bibetal}{等}"
2407 | write$ newline$
2408 | }
2409 | 'skip$
2410 | if$
2411 | "\providecommand{\natexlab}[1]{#1}"
2412 | write$ newline$
2413 | "\providecommand{\url}[1]{#1}"
2414 | write$ newline$
2415 | "\expandafter\ifx\csname urlstyle\endcsname\relax\else"
2416 | write$ newline$
2417 | " \urlstyle{same}\fi"
2418 | write$ newline$
2419 | "\expandafter\ifx\csname href\endcsname\relax"
2420 | write$ newline$
2421 | " \DeclareUrlCommand\doi{\urlstyle{rm}}"
2422 | write$ newline$
2423 | " \def\eprint#1#2{#2}"
2424 | write$ newline$
2425 | "\else"
2426 | write$ newline$
2427 | " \def\doi#1{\href{https://doi.org/#1}{\nolinkurl{#1}}}"
2428 | write$ newline$
2429 | " \let\eprint\href"
2430 | write$ newline$
2431 | "\fi"
2432 | write$ newline$
2433 | }
2434 |
2435 | FUNCTION {end.bib}
2436 | { newline$
2437 | "\end{thebibliography}" write$ newline$
2438 | }
2439 |
2440 | READ
2441 |
2442 | EXECUTE {init.state.consts}
2443 |
2444 | EXECUTE {load.config}
2445 |
2446 | EXECUTE {init.seq}
2447 |
2448 | ITERATE {presort}
2449 |
2450 | SORT
2451 |
2452 | EXECUTE {initialize.longest.label}
2453 |
2454 | ITERATE {forward.pass}
2455 |
2456 | REVERSE {reverse.pass}
2457 |
2458 | ITERATE {bib.sort.order}
2459 |
2460 | SORT
2461 |
2462 | EXECUTE {begin.bib}
2463 |
2464 | ITERATE {call.type$}
2465 |
2466 | EXECUTE {end.bib}
2467 |
--------------------------------------------------------------------------------
/gbt7714.sty:
--------------------------------------------------------------------------------
1 | %%
2 | %% This is file `gbt7714.sty',
3 | %% generated with the docstrip utility.
4 | %%
5 | %% The original source files were:
6 | %%
7 | %% gbt7714.dtx (with options: `package')
8 | %% -------------------------------------------------------------------
9 | %% GB/T 7714 BibTeX Style
10 | %% https://github.com/zepinglee/gbt7714-bibtex-style
11 | %% Version: 2024/03/08 v2.1.6
12 | %% -------------------------------------------------------------------
13 | %% Copyright (C) 2016--2024 by Zeping Lee
14 | %% -------------------------------------------------------------------
15 | %% This file may be distributed and/or modified under the
16 | %% conditions of the LaTeX Project Public License, either version 1.3c
17 | %% of this license or (at your option) any later version.
18 | %% The latest version of this license is in
19 | %% https://www.latex-project.org/lppl.txt
20 | %% and version 1.3c or later is part of all distributions of LaTeX
21 | %% version 2008 or later.
22 | %% -------------------------------------------------------------------
23 | \NeedsTeXFormat{LaTeX2e}[1999/12/01]
24 | \ProvidesPackage{gbt7714}
25 | [2024/03/08 v2.1.6 GB/T 7714 BibTeX Style]
26 | \newif\ifgbt@legacy@interface
27 | \newif\ifgbt@mmxv
28 | \newif\ifgbt@numerical
29 | \newif\ifgbt@super
30 | \newcommand\gbt@obsolete@option[1]{%
31 | \PackageWarning{gbt7714}{The option "#1" is obsolete}%
32 | }
33 | \DeclareOption{2015}{%
34 | \gbt@obsolete@option{2015}%
35 | \gbt@legacy@interfacetrue
36 | \gbt@mmxvtrue
37 | }
38 | \DeclareOption{2005}{%
39 | \gbt@obsolete@option{2005}%
40 | \gbt@legacy@interfacetrue
41 | \gbt@mmxvfalse
42 | }
43 | \DeclareOption{super}{%
44 | \gbt@obsolete@option{super}%
45 | \gbt@legacy@interfacetrue
46 | \gbt@numericaltrue
47 | \gbt@supertrue
48 | }
49 | \DeclareOption{numbers}{%
50 | \gbt@obsolete@option{numbers}%
51 | \gbt@legacy@interfacetrue
52 | \gbt@numericaltrue
53 | \gbt@superfalse
54 | }
55 | \DeclareOption{authoryear}{%
56 | \gbt@obsolete@option{authoryear}%
57 | \gbt@legacy@interfacetrue
58 | \gbt@numericalfalse
59 | }
60 | \DeclareOption*{\PassOptionsToPackage{\CurrentOption}{natbib}}
61 | \ProcessOptions\relax
62 | \RequirePackage{natbib}
63 | \RequirePackage{url}
64 | \def\NAT@cmprs{\@ne}
65 | \renewcommand\newblock{\space}
66 | \newcommand\bibstyle@super{\bibpunct{[}{]}{,}{s}{,}{\textsuperscript{,}}}
67 | \newcommand\bibstyle@numbers{\bibpunct{[}{]}{,}{n}{,}{,}}
68 | \newcommand\bibstyle@authoryear{\bibpunct{(}{)}{;}{a}{,}{,}}
69 | \newcommand\bibstyle@inline{\bibstyle@numbers}
70 | \@namedef{bibstyle@gbt7714-numerical}{\bibstyle@super}
71 | \@namedef{bibstyle@gbt7714-author-year}{\bibstyle@authoryear}
72 | \@namedef{bibstyle@gbt7714-2005-numerical}{\bibstyle@super}
73 | \@namedef{bibstyle@gbt7714-2005-author-year}{\bibstyle@authoryear}
74 | \renewcommand\NAT@citesuper[3]{%
75 | \ifNAT@swa
76 | \if*#2*\else
77 | #2\NAT@spacechar
78 | \fi
79 | % \unskip\kern\p@\textsuperscript{\NAT@@open#1\NAT@@close}%
80 | % \if*#3*\else\NAT@spacechar#3\fi\else #1\fi\endgroup}
81 | \unskip\kern\p@
82 | \textsuperscript{%
83 | \NAT@@open
84 | #1%
85 | \NAT@@close
86 | \if*#3*\else
87 | #3%
88 | \fi
89 | }%
90 | \kern\p@
91 | \else
92 | #1%
93 | \fi
94 | \endgroup
95 | }
96 | \renewcommand\NAT@citenum[3]{%
97 | \ifNAT@swa
98 | \NAT@@open
99 | \if*#2*\else
100 | #2\NAT@spacechar
101 | \fi
102 | % #1\if*#3*\else\NAT@cmt#3\fi\NAT@@close\else#1\fi\endgroup}
103 | #1\NAT@@close
104 | \if*#3*\else
105 | \textsuperscript{#3}%
106 | \fi
107 | \else
108 | #1%
109 | \fi
110 | \endgroup
111 | }
112 | \def\NAT@citexnum[#1][#2]#3{%
113 | \NAT@reset@parser
114 | \NAT@sort@cites{#3}%
115 | \NAT@reset@citea
116 | \@cite{\def\NAT@num{-1}\let\NAT@last@yr\relax\let\NAT@nm\@empty
117 | \@for\@citeb:=\NAT@cite@list\do
118 | {\@safe@activestrue
119 | \edef\@citeb{\expandafter\@firstofone\@citeb\@empty}%
120 | \@safe@activesfalse
121 | \@ifundefined{b@\@citeb\@extra@b@citeb}{%
122 | {\reset@font\bfseries?}
123 | \NAT@citeundefined\PackageWarning{natbib}%
124 | {Citation `\@citeb' on page \thepage \space undefined}}%
125 | {\let\NAT@last@num\NAT@num\let\NAT@last@nm\NAT@nm
126 | \NAT@parse{\@citeb}%
127 | \ifNAT@longnames\@ifundefined{bv@\@citeb\@extra@b@citeb}{%
128 | \let\NAT@name=\NAT@all@names
129 | \global\@namedef{bv@\@citeb\@extra@b@citeb}{}}{}%
130 | \fi
131 | \ifNAT@full\let\NAT@nm\NAT@all@names\else
132 | \let\NAT@nm\NAT@name\fi
133 | \ifNAT@swa
134 | \@ifnum{\NAT@ctype>\@ne}{%
135 | \@citea
136 | \NAT@hyper@{\@ifnum{\NAT@ctype=\tw@}{\NAT@test{\NAT@ctype}}{\NAT@alias}}%
137 | }{%
138 | \@ifnum{\NAT@cmprs>\z@}{%
139 | \NAT@ifcat@num\NAT@num
140 | {\let\NAT@nm=\NAT@num}%
141 | {\def\NAT@nm{-2}}%
142 | \NAT@ifcat@num\NAT@last@num
143 | {\@tempcnta=\NAT@last@num\relax}%
144 | {\@tempcnta\m@ne}%
145 | \@ifnum{\NAT@nm=\@tempcnta}{%
146 | \@ifnum{\NAT@merge>\@ne}{}{\NAT@last@yr@mbox}%
147 | }{%
148 | \advance\@tempcnta by\@ne
149 | \@ifnum{\NAT@nm=\@tempcnta}{%
150 | % \ifx\NAT@last@yr\relax
151 | % \def@NAT@last@yr{\@citea}%
152 | % \else
153 | % \def@NAT@last@yr{--\NAT@penalty}%
154 | % \fi
155 | \def@NAT@last@yr{-\NAT@penalty}%
156 | }{%
157 | \NAT@last@yr@mbox
158 | }%
159 | }%
160 | }{%
161 | \@tempswatrue
162 | \@ifnum{\NAT@merge>\@ne}{\@ifnum{\NAT@last@num=\NAT@num\relax}{\@tempswafalse}{}}{}%
163 | \if@tempswa\NAT@citea@mbox\fi
164 | }%
165 | }%
166 | \NAT@def@citea
167 | \else
168 | \ifcase\NAT@ctype
169 | \ifx\NAT@last@nm\NAT@nm \NAT@yrsep\NAT@penalty\NAT@space\else
170 | \@citea \NAT@test{\@ne}\NAT@spacechar\NAT@mbox{\NAT@super@kern\NAT@@open}%
171 | \fi
172 | \if*#1*\else#1\NAT@spacechar\fi
173 | \NAT@mbox{\NAT@hyper@{{\citenumfont{\NAT@num}}}}%
174 | \NAT@def@citea@box
175 | \or
176 | \NAT@hyper@citea@space{\NAT@test{\NAT@ctype}}%
177 | \or
178 | \NAT@hyper@citea@space{\NAT@test{\NAT@ctype}}%
179 | \or
180 | \NAT@hyper@citea@space\NAT@alias
181 | \fi
182 | \fi
183 | }%
184 | }%
185 | \@ifnum{\NAT@cmprs>\z@}{\NAT@last@yr}{}%
186 | \ifNAT@swa\else
187 | % \@ifnum{\NAT@ctype=\z@}{%
188 | % \if*#2*\else\NAT@cmt#2\fi
189 | % }{}%
190 | \NAT@mbox{\NAT@@close}%
191 | \@ifnum{\NAT@ctype=\z@}{%
192 | \if*#2*\else
193 | \textsuperscript{#2}%
194 | \fi
195 | }{}%
196 | \NAT@super@kern
197 | \fi
198 | }{#1}{#2}%
199 | }%
200 | \renewcommand\NAT@cite%
201 | [3]{\ifNAT@swa\NAT@@open\if*#2*\else#2\NAT@spacechar\fi
202 | #1\NAT@@close\if*#3*\else\textsuperscript{#3}\fi\else#1\fi\endgroup}
203 | \def\NAT@citex%
204 | [#1][#2]#3{%
205 | \NAT@reset@parser
206 | \NAT@sort@cites{#3}%
207 | \NAT@reset@citea
208 | \@cite{\let\NAT@nm\@empty\let\NAT@year\@empty
209 | \@for\@citeb:=\NAT@cite@list\do
210 | {\@safe@activestrue
211 | \edef\@citeb{\expandafter\@firstofone\@citeb\@empty}%
212 | \@safe@activesfalse
213 | \@ifundefined{b@\@citeb\@extra@b@citeb}{\@citea%
214 | {\reset@font\bfseries ?}\NAT@citeundefined
215 | \PackageWarning{natbib}%
216 | {Citation `\@citeb' on page \thepage \space undefined}\def\NAT@date{}}%
217 | {\let\NAT@last@nm=\NAT@nm\let\NAT@last@yr=\NAT@year
218 | \NAT@parse{\@citeb}%
219 | \ifNAT@longnames\@ifundefined{bv@\@citeb\@extra@b@citeb}{%
220 | \let\NAT@name=\NAT@all@names
221 | \global\@namedef{bv@\@citeb\@extra@b@citeb}{}}{}%
222 | \fi
223 | \ifNAT@full\let\NAT@nm\NAT@all@names\else
224 | \let\NAT@nm\NAT@name\fi
225 | \ifNAT@swa\ifcase\NAT@ctype
226 | \if\relax\NAT@date\relax
227 | \@citea\NAT@hyper@{\NAT@nmfmt{\NAT@nm}\NAT@date}%
228 | \else
229 | \ifx\NAT@last@nm\NAT@nm\NAT@yrsep
230 | \ifx\NAT@last@yr\NAT@year
231 | \def\NAT@temp{{?}}%
232 | \ifx\NAT@temp\NAT@exlab\PackageWarningNoLine{natbib}%
233 | {Multiple citation on page \thepage: same authors and
234 | year\MessageBreak without distinguishing extra
235 | letter,\MessageBreak appears as question mark}\fi
236 | \NAT@hyper@{\NAT@exlab}%
237 | \else\unskip\NAT@spacechar
238 | \NAT@hyper@{\NAT@date}%
239 | \fi
240 | \else
241 | \@citea\NAT@hyper@{%
242 | \NAT@nmfmt{\NAT@nm}%
243 | \hyper@natlinkbreak{%
244 | \NAT@aysep\NAT@spacechar}{\@citeb\@extra@b@citeb
245 | }%
246 | \NAT@date
247 | }%
248 | \fi
249 | \fi
250 | \or\@citea\NAT@hyper@{\NAT@nmfmt{\NAT@nm}}%
251 | \or\@citea\NAT@hyper@{\NAT@date}%
252 | \or\@citea\NAT@hyper@{\NAT@alias}%
253 | \fi \NAT@def@citea
254 | \else
255 | \ifcase\NAT@ctype
256 | \if\relax\NAT@date\relax
257 | \@citea\NAT@hyper@{\NAT@nmfmt{\NAT@nm}}%
258 | \else
259 | \ifx\NAT@last@nm\NAT@nm\NAT@yrsep
260 | \ifx\NAT@last@yr\NAT@year
261 | \def\NAT@temp{{?}}%
262 | \ifx\NAT@temp\NAT@exlab\PackageWarningNoLine{natbib}%
263 | {Multiple citation on page \thepage: same authors and
264 | year\MessageBreak without distinguishing extra
265 | letter,\MessageBreak appears as question mark}\fi
266 | \NAT@hyper@{\NAT@exlab}%
267 | \else
268 | \unskip\NAT@spacechar
269 | \NAT@hyper@{\NAT@date}%
270 | \fi
271 | \else
272 | \@citea\NAT@hyper@{%
273 | \NAT@nmfmt{\NAT@nm}%
274 | \hyper@natlinkbreak{\NAT@spacechar\NAT@@open\if*#1*\else#1\NAT@spacechar\fi}%
275 | {\@citeb\@extra@b@citeb}%
276 | \NAT@date
277 | }%
278 | \fi
279 | \fi
280 | \or\@citea\NAT@hyper@{\NAT@nmfmt{\NAT@nm}}%
281 | \or\@citea\NAT@hyper@{\NAT@date}%
282 | \or\@citea\NAT@hyper@{\NAT@alias}%
283 | \fi
284 | \if\relax\NAT@date\relax
285 | \NAT@def@citea
286 | \else
287 | \NAT@def@citea@close
288 | \fi
289 | \fi
290 | }}\ifNAT@swa\else
291 | % \if*#2*\else\NAT@cmt#2\fi
292 | \if\relax\NAT@date\relax\else\NAT@@close\fi
293 | \if*#2*\else\textsuperscript{#2}\fi
294 | \fi}{#1}{#2}}
295 | \renewcommand\@biblabel[1]{[#1]\hfill}
296 | \g@addto@macro\UrlBreaks{%
297 | \do0\do1\do2\do3\do4\do5\do6\do7\do8\do9%
298 | \do\A\do\B\do\C\do\D\do\E\do\F\do\G\do\H\do\I\do\J\do\K\do\L\do\M
299 | \do\N\do\O\do\P\do\Q\do\R\do\S\do\T\do\U\do\V\do\W\do\X\do\Y\do\Z
300 | \do\a\do\b\do\c\do\d\do\e\do\f\do\g\do\h\do\i\do\j\do\k\do\l\do\m
301 | \do\n\do\o\do\p\do\q\do\r\do\s\do\t\do\u\do\v\do\w\do\x\do\y\do\z
302 | }
303 | \Urlmuskip=0mu plus 0.1mu
304 | \newif\ifgbt@bib@style@written
305 | \@ifpackageloaded{chapterbib}{}{%
306 | \def\bibliography#1{%
307 | \ifgbt@bib@style@written\else
308 | \bibliographystyle{gbt7714-numerical}%
309 | \fi
310 | \if@filesw
311 | \immediate\write\@auxout{\string\bibdata{\zap@space#1 \@empty}}%
312 | \fi
313 | \@input@{\jobname.bbl}}
314 | \def\bibliographystyle#1{%
315 | \gbt@bib@style@writtentrue
316 | \ifx\@begindocumenthook\@undefined\else
317 | \expandafter\AtBeginDocument
318 | \fi
319 | {\if@filesw
320 | \immediate\write\@auxout{\string\bibstyle{#1}}%
321 | \fi}%
322 | }%
323 | }
324 | \ifgbt@legacy@interface
325 | \ifgbt@numerical
326 | \ifgbt@super\else
327 | \citestyle{numbers}
328 | \fi
329 | \bibliographystyle{gbt7714-numerical}
330 | \else
331 | \bibliographystyle{gbt7714-author-year}
332 | \fi
333 | \fi
334 |
--------------------------------------------------------------------------------
/images/Chap2/B-C_ratio.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/B-C_ratio.pdf
--------------------------------------------------------------------------------
/images/Chap2/B-C_ratio.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/B-C_ratio.png
--------------------------------------------------------------------------------
/images/Chap2/Flowchart.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/Flowchart.pdf
--------------------------------------------------------------------------------
/images/Chap2/Flowchart.tex:
--------------------------------------------------------------------------------
1 | % texlive2017, xelatex
2 | % author: Ma Seoyin, 2014 Applied Physics, SCUT
3 | \documentclass{standalone}
4 | \usepackage{bm} % Required for the bold in math display
5 | \usepackage{amsmath} % Required for the math display
6 | \usepackage{tikz, tikzscale}
7 | \usetikzlibrary{shapes.geometric, arrows,calc,positioning,decorations.pathreplacing,bending}
8 |
9 | %----------------------------------------------------------------------------------------
10 | % Flow chart setting
11 | %----------------------------------------------------------------------------------------
12 | % Define the fundamental shapes of the flow chart
13 | \tikzstyle{StartEnd} = [rectangle, rounded corners, minimum width = 2cm, minimum height=0.6cm,text centered, draw = black, fill = red!40]
14 | \tikzstyle{ioFunction} = [trapezium, trapezium left angle=70, trapezium right angle=110, minimum width=2cm, minimum height=0.6cm, text centered, draw=black, fill = blue!40]
15 | \tikzstyle{process} = [rectangle, minimum width=2cm, minimum height=0.6cm, text centered, draw=black, fill = yellow!50]
16 | \tikzstyle{decision} = [diamond, minimum height=0.8cm, aspect = 5, text centered, draw=black, fill = green!30]
17 | \tikzstyle{defineRangeSearch} = [rectangle, minimum width=2cm, minimum height=0.6cm, text centered, draw=black, fill = green!30]
18 | % Define the arrows' shape of the flow chart
19 | \tikzstyle{arrow} = [->,>=stealth]
20 |
21 |
22 | \begin{document}
23 | \begin{tikzpicture}[transform shape, node distance=1.0cm]
24 | % Draw shapes
25 | \node (t_1) [StartEnd]
26 | {Start, $t = 1$};
27 | \node (Input) [ioFunction, below of = t_1, node distance=1.2cm]
28 | {\begin{tabular}{l}
29 | Sample $\vec{\theta}_t$ from a distribution\\
30 | Calculate $P(\vec{\theta}_{t}|D)$\\
31 | \end{tabular}};
32 | \node (t_2) [process, below of = Input, node distance=1.2cm]
33 | {$t = t + 1$};
34 | \node (iteration) [decision, below of = t_2]
35 | {$t \leq T$ ?};
36 | \node (trial) [ioFunction, below of = iteration, node distance = 1.25cm]
37 | {\begin{tabular}{l}
38 | Sample $\vec{\theta}_{trial}$ from a distribution\\
39 | Calculate $P(\vec{\theta}_{trial}|D)$\\
40 | \end{tabular}};
41 | \node (alpha_beta) [process, below of = trial, node distance = 1.6cm]
42 | {\begin{tabular}{l}
43 | $\alpha=\min\left[1, e^{-\frac12\left(\chi^2(\vec{\theta}_{trial}) - \chi^2(\vec{\theta}_{t})\right)}\right]$\\
44 | $\beta={\rm random}(0,1)$\\
45 | \end{tabular}};
46 | \node (If_alpha_beta) [decision, below of = alpha_beta, node distance=1.6cm]
47 | {$\alpha > \beta\ ?$};
48 | \node (Accept) [process, below of = If_alpha_beta, xshift=-3.5cm]
49 | {Accept $\vec{\theta}_{trial}$};
50 | \node (AcceptUpdate) [process, below of = Accept, node distance=1.6cm]
51 | {\begin{tabular}{l}
52 | $\vec{\theta}_{t+1}=\vec{\theta}_{\rm trial}$\\
53 | $P(\vec{\theta}_{t+1}|D)=P(\vec{\theta}_{\rm trial}|D)$\\
54 | accept ++\\
55 | \end{tabular}};
56 | \node (Reject) [process, below of = If_alpha_beta, xshift=3.5cm]
57 | {Reject $\vec{\theta}_{trial}$};
58 | \node (RejectUpdate) [process, below of = Reject, node distance=1.6cm]
59 | {\begin{tabular}{l}
60 | $\vec{\theta}_{t+1}=\vec{\theta}_{t}$\\
61 | $P(\vec{\theta}_{t+1}|D)=P(\vec{\theta}_{t}|D)$\\
62 | \end{tabular}};
63 | \node (t_plus_1) [process, below of = If_alpha_beta, node distance = 4.1cm]
64 | {$t = t + 1$};
65 | \node (End) [StartEnd, below of = t_plus_1]
66 | {End, Output $\vec{\theta}$, $\chi^2(\vec{\theta})$, $P(\vec{\theta}|D)$, accept};
67 | % Draw arrows
68 | \draw [arrow] (t_1) -- (Input);
69 | \draw [arrow] (Input) -- (t_2);
70 | \draw [arrow] (t_2) -- (iteration);
71 | \draw [arrow] (iteration) -- node [right] {Y} (trial);
72 | \draw [arrow] (trial) -- (alpha_beta);
73 | \draw [arrow] (alpha_beta) -- (If_alpha_beta);
74 | \draw [arrow] (If_alpha_beta) -| node [above] {Y} (Accept);
75 | \draw [arrow] (If_alpha_beta) -| node [above] {N} (Reject);
76 | \draw [arrow] (Accept) -- (AcceptUpdate);
77 | \draw [arrow] (AcceptUpdate) |- (0,-11.4) -- (t_plus_1);
78 | \draw [arrow] (Reject) -- (RejectUpdate);
79 | \draw [arrow] (RejectUpdate) |- (0,-11.4) -- (t_plus_1);
80 | \draw [arrow] (t_plus_1) -| (-6,-3.4) -- (iteration);
81 | \draw [arrow] (iteration) -- (6,-3.4) node [above, xshift=-2.5cm] {N} |- (0,-12.4) -- (End);
82 | \end{tikzpicture}
83 | \end{document}
--------------------------------------------------------------------------------
/images/Chap2/cascade.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/cascade.pdf
--------------------------------------------------------------------------------
/images/Chap2/cascade.tex:
--------------------------------------------------------------------------------
1 | % texlive2017, xelatex
2 | % author: Ma Seoyin, 2014 Applied Physics, SCUT
3 | \documentclass{standalone}
4 | \usepackage{amsmath}
5 | \usepackage{tikz, tikzscale}
6 | \usetikzlibrary{arrows,shapes,positioning}
7 | \usetikzlibrary{snakes}
8 | \usetikzlibrary{decorations.markings}
9 | \tikzstyle arrowstyle=[scale=1]
10 | \tikzstyle fermion=[postaction={decorate,decoration={markings, mark=at position 0.5 with {\arrow[arrowstyle]{latex}} }}] %or style stealth
11 | \tikzstyle gauge_boson=[postaction={decorate, decoration={snake, segment length=5mm, amplitude=15mm}}]
12 | \begin{document}
13 | \begin{tikzpicture}
14 | \node [] at (1, 0.25) {$\gamma$};
15 | \draw [decorate, decoration={snake, segment length=2.5mm, amplitude=0.5mm}] (0,0) -- (2, 0);
16 | \node [] at (2.965925826289068, 0.5088190451025207) {$e^+$};
17 | \draw [fermion] (2, 0) -- (3.9318516525781366, 0.5176380902050415);
18 | \node [] at (5.431851652578136, 0.7676380902050415) {$e^+$};
19 | \draw [fermion] (3.9318516525781366, 0.5176380902050415) -- (5.9318516525781366, 0.5176380902050415);
20 | \node [] at (4.797877056362575, 1.2676380902050415) {$\gamma$};
21 | \draw [decorate, decoration={snake, segment length=2.5mm, amplitude=0.5mm}] (3.9318516525781366, 0.5176380902050415) -- (5.663902460147014, 1.5176380902050415);
22 | \node [] at (2.965925826289068, -0.5088190451025207) {$e^-$};
23 | \draw [fermion] (2, 0) -- (3.9318516525781366, -0.5176380902050415);
24 | \node [] at (5.431851652578136, -0.7676380902050415) {$e^-$};
25 | \draw [fermion] (3.9318516525781366, -0.5176380902050415) -- (5.9318516525781366, -0.5176380902050415);
26 | \node [] at (4.797877056362575, -1.2676380902050415) {$\gamma$};
27 | \draw [decorate, decoration={snake, segment length=2.5mm, amplitude=0.5mm}] (3.9318516525781366, -0.5176380902050415) -- (5.663902460147014, -1.5176380902050415);
28 | \end{tikzpicture}
29 | \end{document}
--------------------------------------------------------------------------------
/images/Chap2/confusion.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/confusion.pdf
--------------------------------------------------------------------------------
/images/Chap2/gamma_MCMCanalysis.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/gamma_MCMCanalysis.pdf
--------------------------------------------------------------------------------
/images/Chap2/gamma_MCMCanalysis.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/gamma_MCMCanalysis.png
--------------------------------------------------------------------------------
/images/Chap2/hole.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/images/Chap2/hole.pdf
--------------------------------------------------------------------------------
/main.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/main.pdf
--------------------------------------------------------------------------------
/main.tex:
--------------------------------------------------------------------------------
1 | % !TeX encoding = UTF-8
2 | % !TEX program = xelatex
3 |
4 | % texlive2017, xelatex
5 | % author: Ma Seoyin, 2014 Applied Physics, SCUT
6 | \documentclass[a4paper]{article}
7 |
8 | \usepackage{template}
9 | \begin{document}
10 | \input{Cover}
11 | \input{Abstract}
12 | %----------------------------------------------------------------------------------------
13 | % CONTENTS
14 | %----------------------------------------------------------------------------------------
15 | \thispagestyle{plain}
16 | \begin{spacing}{1.5}
17 | \addcontentsline{toc}{section}{目录}
18 | \tableofcontents
19 | \end{spacing}
20 | \thispagestyle{plain}
21 | \pagebreak[4]
22 |
23 | %----------------------------------------------------------------------------------------
24 | % BEGIN TO COUNT THE PAGE NUMBER
25 | %----------------------------------------------------------------------------------------
26 | \setboolean{@twoside}{true}
27 | \begin{spacing}{1.5}
28 | \zihao{-4}
29 | \setcounter{page}{1}
30 | \pagenumbering{arabic}
31 | %----------------------------------------------------------------------------------------
32 | % BELOW IS YOUR MAIN TEXT. BEGIN.
33 | %----------------------------------------------------------------------------------------
34 | \input{Chapter1_Introduction}
35 | \input{Chapter2_Simple_Examples}
36 | \input{Chapter3_Headers}
37 | \input{Chapter4_Research_Methods}
38 | \input{Chapter5_Experiments_and_Results}
39 | \input{Chapter6_Conclusions_and_Expectations}
40 |
41 | \input{Appendix_Settings}
42 | \input{Appendix_A}
43 | \input{Appendix_B}
44 | \end{spacing}
45 | %----------------------------------------------------------------------------------------
46 | % ABOVE IS YOUR MAIN TEXT. FINISHED.
47 | %----------------------------------------------------------------------------------------
48 |
49 | %----------------------------------------------------------------------------------------
50 | % 参考文献
51 | %----------------------------------------------------------------------------------------
52 | % \bibliographystyle{plain}
53 | \addcontentsline{toc}{section}{参考文献}
54 | \zihao{-4}
55 | \bibliography{template}
56 | \pagebreak[4]
57 |
58 | %----------------------------------------------------------------------------------------
59 | % ACKNOWLEDGEMENT
60 | %----------------------------------------------------------------------------------------
61 | \fancyhead[C]{\songti{华南理工大学学士学位论文}}
62 | \fancyhead[CO]{\songti{致谢}}
63 | \begin{spacing}{1.5}
64 | \input{Acknowledgement}
65 | \end{spacing}
66 | \setboolean{@twoside}{false}
67 |
68 | \end{document}
69 |
--------------------------------------------------------------------------------
/template.bib:
--------------------------------------------------------------------------------
1 | %%
2 | % 参考文献
3 | % 参考文献是毕业设计(论文)不可缺少的组成部分,它反映毕业设计(论文)的取材来源、材料的广博程度和材料的可靠程度,也是作者对他人知识成果的承认和尊重。一份完整的参考文献可向读者提供一份有价值的信息资料,列入的文献应在 10 篇以上,其中外文文献在 2 篇以上。
4 | %%
5 |
6 | @article{liu2011sift,
7 | title={Sift flow: Dense correspondence across scenes and its applications},
8 | author={Liu, Ce and Yuen, Jenny and Torralba, Antonio},
9 | journal={Pattern Analysis and Machine Intelligence, IEEE Transactions on},
10 | volume={33},
11 | number={5},
12 | pages={978--994},
13 | year={2011},
14 | publisher={IEEE}
15 | }
16 | @inproceedings{tighe2013finding,
17 | title={Finding things: Image parsing with regions and per-exemplar detectors},
18 | author={Tighe, Joseph and Lazebnik, Svetlana},
19 | booktitle={Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition},
20 | pages={3001--3008},
21 | year={2013}
22 | }
23 | @inproceedings{long2015fully,
24 | title={Fully convolutional networks for semantic segmentation},
25 | author={Long, Jonathan and Shelhamer, Evan and Darrell, Trevor},
26 | booktitle={Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition},
27 | pages={3431--3440},
28 | year={2015}
29 | }
30 | @inproceedings{chen14semantic,
31 | title={Semantic Image Segmentation with Deep Convolutional Nets and Fully Connected CRFs},
32 | author={Liang-Chieh Chen and George Papandreou and Iasonas Kokkinos and Kevin Murphy and Alan L Yuille},
33 | booktitle={ICLR},
34 | url={http://arxiv.org/abs/1412.7062},
35 | year={2015}
36 | }
37 | @incollection{hariharan2014simultaneous,
38 | title={Simultaneous detection and segmentation},
39 | author={Hariharan, Bharath and Arbel{\'a}ez, Pablo and Girshick, Ross and Malik, Jitendra},
40 | booktitle={Computer vision--ECCV 2014},
41 | pages={297--312},
42 | year={2014},
43 | publisher={Springer}
44 | }
45 |
46 |
--------------------------------------------------------------------------------
/template.sty:
--------------------------------------------------------------------------------
1 | \ProvidesPackage{template}
2 |
3 | \usepackage{ctex} % 中文支持
4 |
5 | \usepackage[
6 | top=2.5cm,
7 | bottom=2.5cm,
8 | left=2.5cm,
9 | right=2.5cm
10 | ]{geometry} % 页边距布局
11 |
12 | \usepackage{fancyhdr} % Required for custom headers
13 | \usepackage{setspace} % Required for the space setting
14 | \usepackage{zhnumber}
15 | \usepackage{titlesec} % Required for the Chapter & Section fonts adjustment
16 | \usepackage{titletoc} % Required for the Content fonts adjustment
17 | \usepackage[toc,page]{appendix} % Required for the appendix environment
18 | \usepackage{lastpage} % Required to determine the last page for the footer
19 | \usepackage{extramarks} % Required for headers and footers
20 | \usepackage{courier} % Required for the courier font
21 | \usepackage{float} % Required for the Here float
22 | \usepackage{graphicx} % Required to insert images
23 | \usepackage{wrapfig}
24 | \usepackage{booktabs} % Required for the hline of the three lines table
25 | \usepackage{multirow} % Required for the multirow of table
26 | \usepackage{listings} % Required for insertion of code
27 | \usepackage{indentfirst} % Required for the indent before each paragraph
28 | \usepackage[bookmarks=true,colorlinks=true,linkcolor=black,anchorcolor=blue,citecolor=blue,urlcolor=blue]{hyperref}
29 |
30 | \usepackage[usenames,dvipsnames]{color} % Required for custom colors
31 | \usepackage[font=footnotesize,tableposition=top]{caption} % Required for the footnote size captions of figures and tables
32 | %----------------------------------------------------------------------------------------
33 | % 数学宏包
34 | %----------------------------------------------------------------------------------------
35 | \usepackage{bm} % Required for the bold in math display
36 | \usepackage{amsmath} % Required for the math display
37 | \usepackage{amssymb} % Required for the math display
38 | \usepackage{amsbsy} % Required for the math display
39 | \usepackage{cancel} % Required for the cancel symbol in math display
40 | \usepackage{amsthm} % Required for the theorem edition
41 | \usepackage{array} % Required for the array in math display
42 | \usepackage{ifthen} % Required for the conditional commands
43 |
44 | %----------------------------------------------------------------------------------------
45 | % Superscript citation
46 | %----------------------------------------------------------------------------------------
47 | % 参考文献相关,需要更新
48 | \usepackage{gbt7714}
49 | \bibliographystyle{gbt7714-numerical}
50 |
51 |
52 | \newcommand{\upcite}[1]{\textsuperscript{\textsuperscript{\cite{#1}}}}
53 |
54 | \setmainfont{Times New Roman} % 常规英文字体
55 | \setsansfont{Arial} % 非衬线字体
56 | \setmonofont{Consolas} % 打字机字体,代码字体
57 | \setCJKmainfont[AutoFakeBold=true]{SimSun}%正文字体
58 |
59 | %----------------------------------------------------------------------------------------
60 | % Upright d in integrate
61 | %----------------------------------------------------------------------------------------
62 | \newcommand{\ud}{\mathrm{d}}
63 |
64 | %----------------------------------------------------------------------------------------
65 | % Code Inclusion Configuration
66 | %----------------------------------------------------------------------------------------
67 | \definecolor{MyDarkGreen}{rgb}{0.0,0.4,0.0} % This is the color used for comments
68 | \lstloadlanguages{Python} % Load Python syntax for listings, for a list of other languages supported see: ftp://ftp.tex.ac.uk/tex-archive/macros/latex/contrib/listings/listings.pdf
69 | \lstset{language=Python, % Use Python in this example
70 | frame=single, % Single frame around code
71 | %basicstyle=\ttfamily, % Use small true type font
72 | keywordstyle=[1]\color{Blue}\bf, % Python functions bold and blue
73 | keywordstyle=[2]\color{Purple}\it, % Python function arguments purple
74 | keywordstyle=[3]\color{Blue}\underbar, % Custom functions underlined and blue
75 | identifierstyle=, % Nothing special about identifiers
76 | commentstyle=\color{Gray}, % Comments small dark green courier font
77 | stringstyle=\color{Green}, % Strings are purple
78 | showstringspaces=false, % Don't put marks in string spaces
79 | tabsize=4, % 4 spaces per tab
80 | % Put standard Python functions not included in the default language here
81 | morekeywords={rand},
82 | % Put Python function parameters here
83 | morekeywords=[2]{on, off, interp},
84 | % Put user defined functions here
85 | morekeywords=[3]{test},
86 | %
87 | morecomment=[l][\color{Blue}]{...}, % Line continuation (...) like blue comment
88 | numbers=left, % Line numbers on left
89 | firstnumber=1, % Line numbers start with line 1
90 | numberstyle=\tiny\color{Blue}, % Line numbers are blue and small
91 | stepnumber=1 % Line numbers go in steps of 1
92 | }
93 | % Creates a new command to include a Python script, the first parameter is the filename of the script (without .py), the second parameter is the caption
94 | \newcommand{\pythonscript}[2]{
95 | \begin{itemize}
96 | \begin{spacing}{1.0}
97 | \item[]\lstinputlisting[
98 | caption=#2,
99 | label=#1,
100 | gobble=2,
101 | numbers=left
102 | ]{#1.py}
103 | \end{spacing}
104 | \end{itemize}
105 | }
106 |
107 | %----------------------------------------------------------------------------------------
108 | % Section related equations' number
109 | %----------------------------------------------------------------------------------------
110 | \makeatletter
111 | \@addtoreset{equation}{section}
112 | \makeatother
113 | \renewcommand{\theequation}{\arabic{section}.\arabic{equation}}
114 |
115 | %----------------------------------------------------------------------------------------
116 | % 章节标题格式调整
117 | %----------------------------------------------------------------------------------------
118 | % section
119 | \titleformat{\section}{\centering\zihao{-2}\bfseries}{第\,\zhnumber{\thesection}\,章}{1em}{}
120 | % subsection
121 | \titleformat{\subsection}{\zihao{-3}\bfseries}{\thesubsection}{1em}{}
122 | % subsubsection
123 | \titleformat{\subsubsection}{\zihao{4}\bfseries}{\thesubsubsection}{1em}{}
124 |
125 |
126 |
127 | % 重新定义paragraph样式
128 | \titlespacing*{\paragraph}{0pt}{3.25ex plus 1ex minus .2ex}{0.75ex plus .2ex}
129 | \titleformat{\paragraph}[hang]{\normalfont\normalsize\bfseries}{\theparagraph}{1em}{\raggedright}
130 |
131 | %----------------------------------------------------------------------------------------
132 | % 目录格式调整
133 | %----------------------------------------------------------------------------------------
134 | \renewcommand\contentsname{目\quad\quad 录} % Setup contents
135 | \titlecontents{section}[0em]{\zihao{4}\bfseries}
136 | {\contentspush{第\,\zhnumber{\thecontentslabel}\,章\hspace{1em}}}
137 | {}{\titlerule*[5pt]{.}\contentspage}
138 |
139 | \titlecontents{subsection}[2.2em]{\zihao{-4}\songti}{\contentspush{\thecontentslabel\hspace{0.7em}}}
140 | {}{\titlerule*[5pt]{.}\contentspage}
141 | \titlecontents{subsubsection}[3.9em]{\zihao{-4}\songti}{\contentspush{\thecontentslabel\hspace{0.7em}}}
142 | {}{\titlerule*[5pt]{.}\contentspage}
143 | \titlespacing*{\subsection} {0pt}{1ex}{1ex} % Adjust the space between title and context
144 | \titlespacing*{\subsubsection} {0pt}{1ex}{1ex}
145 |
146 | %----------------------------------------------------------------------------------------
147 | % Page header & Page footer setting
148 | %----------------------------------------------------------------------------------------
149 | \pagestyle{fancy}
150 | \fancyhf{}
151 | \renewcommand{\sectionmark}[1]{\markboth{第\chinese{section} 章{\color{white}.} #1}{}}
152 | \fancyhead[C]{\songti{华南理工大学学士学位论文}}
153 | \fancyhead[CO]{\songti\leftmark}
154 | \fancyfoot[C]{\thepage}
155 |
--------------------------------------------------------------------------------
/title.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/OChicken/SCUT-Bachelor-Thesis-Template/d2c14bf3856bf0248d80091e3f2b3c93b8ed52a8/title.png
--------------------------------------------------------------------------------