ChengsongTanPhdThesis/main.tex
author Chengsong
Mon, 10 Jul 2023 19:29:22 +0100
changeset 664 ba44144875b1
parent 653 bc5571c38d1f
child 668 3831621d7b14
permissions -rw-r--r--
introduction Contribution section update
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     1
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     2
% Masters/Doctoral Thesis 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     3
% LaTeX Template
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     4
% Version 2.5 (27/8/17)
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     5
%
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     6
% This template was downloaded from:
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     7
% http://www.LaTeXTemplates.com
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     8
%
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
     9
% Version 2.x major modifications by:
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    10
% Vel (vel@latextemplates.com)
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    11
%
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    12
% This template is based on a template by:
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    13
% Steve Gunn (http://users.ecs.soton.ac.uk/srg/softwaretools/document/templates/)
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    14
% Sunil Patel (http://www.sunilpatel.co.uk/thesis-template/)
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    15
%
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    16
% Template license:
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    17
% CC BY-NC-SA 3.0 (http://creativecommons.org/licenses/by-nc-sa/3.0/)
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    18
%
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    19
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    20
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    21
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    22
%	PACKAGES AND OTHER DOCUMENT CONFIGURATIONS
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    23
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    24
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    25
\documentclass[
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    26
11pt, % The default document font size, options: 10pt, 11pt, 12pt
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    27
%oneside, % Two side (alternating margins) for binding by default, uncomment to switch to one side
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    28
english, % ngerman for German
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    29
singlespacing, % Single line spacing, alternatives: onehalfspacing or doublespacing
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    30
%draft, % Uncomment to enable draft mode (no pictures, no links, overfull hboxes indicated)
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    31
%nolistspacing, % If the document is onehalfspacing or doublespacing, uncomment this to set spacing in lists to single
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    32
%liststotoc, % Uncomment to add the list of figures/tables/etc to the table of contents
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    33
%toctotoc, % Uncomment to add the main table of contents to the table of contents
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    34
%parskip, % Uncomment to add space between paragraphs
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    35
%nohyperref, % Uncomment to not load the hyperref package
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    36
headsepline, % Uncomment to get a line under the header
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    37
%chapterinoneline, % Uncomment to place the chapter title next to the number on one line
471
Chengsong
parents: 468
diff changeset
    38
consistentlayout, % Uncomment to change the layout of the declaration, abstract and acknowledgements pages to match the default layout
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    39
]{MastersDoctoralThesis} % The class file specifying the document structure
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    40
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    41
\usepackage[utf8]{inputenc} % Required for inputting international characters
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    42
\usepackage[T1]{fontenc} % Output font encoding for international characters
505
5ce3bd8e5696 thesis chapter2 section 2.4
Chengsong
parents: 503
diff changeset
    43
%\usepackage{fdsymbol} % Loads unicode-math
585
4969ef817d92 chap4 more
Chengsong
parents: 580
diff changeset
    44
\usepackage{cancel}
646
Chengsong
parents: 638
diff changeset
    45
\usepackage{fontawesome5}
Chengsong
parents: 638
diff changeset
    46
\usepackage{bbding,pifont,dingbat}
585
4969ef817d92 chap4 more
Chengsong
parents: 580
diff changeset
    47
590
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
    48
\usepackage{listings}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
    49
\usepackage{xcolor}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
    50
\usepackage{beramono}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
    51
555
Chengsong
parents: 554
diff changeset
    52
\usepackage{verbatim}
580
e0f0a81f907b halfway chap3
Chengsong
parents: 579
diff changeset
    53
\usepackage{float}
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    54
\usepackage{mathpazo} % Use the Palatino font by default
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    55
\usepackage{hyperref}
542
a7344c9afbaf chapter3 finished
Chengsong
parents: 538
diff changeset
    56
\usepackage{lipsum}
564
Chengsong
parents: 555
diff changeset
    57
\usepackage[backend=bibtex]{biblatex} % Use the bibtex backend with the authoryear citation style (which resembles APA)
577
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    58
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    59
\usepackage[usestackEOL]{stackengine}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    60
\usepackage{scalerel}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    61
\usepackage{graphicx}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    62
564
Chengsong
parents: 555
diff changeset
    63
%style=authoryear, natbib=true 
500
Chengsong
parents: 472
diff changeset
    64
\usepackage{stmaryrd}
537
Chengsong
parents: 535
diff changeset
    65
\usepackage{caption}
601
Chengsong
parents: 600
diff changeset
    66
\usepackage{afterpage}
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    67
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    68
\addbibresource{example.bib} % The filename of the bibliography
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    69
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    70
\usepackage[autostyle=true]{csquotes} % Required to generate language-dependent quotes in the bibliography
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    71
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    72
%My Newly added Libraries in addition to template
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    73
\usepackage{graphic}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    74
\usepackage{data}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    75
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    76
%\usepackage{algorithm}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    77
\usepackage{amsmath}
577
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    78
\makeatletter
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    79
\newcommand{\xleftrightarrow}[2][]{\ext@arrow 3359\leftrightarrowfill@{#1}{#2}}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    80
\newcommand{\xdashrightarrow}[2][]{\ext@arrow 0359\rightarrowfill@@{#1}{#2}}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    81
\newcommand{\xdashleftarrow}[2][]{\ext@arrow 3095\leftarrowfill@@{#1}{#2}}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    82
\newcommand{\xdashleftrightarrow}[2][]{\ext@arrow 3359\leftrightarrowfill@@{#1}{#2}}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    83
\def\rightarrowfill@@{\arrowfill@@\relax\relbar\rightarrow}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    84
\def\leftarrowfill@@{\arrowfill@@\leftarrow\relbar\relax}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    85
\def\leftrightarrowfill@@{\arrowfill@@\leftarrow\relbar\rightarrow}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    86
\def\arrowfill@@#1#2#3#4{%
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    87
  $\m@th\thickmuskip0mu\medmuskip\thickmuskip\thinmuskip\thickmuskip
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    88
   \relax#4#1
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    89
   \xleaders\hbox{$#4#2$}\hfill
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    90
   #3$%
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    91
}
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    92
\makeatother
579
35df9cdd36ca more chap3
Chengsong
parents: 577
diff changeset
    93
\def\checkmark{\tikz\fill[scale=0.4](0,.35) -- (.25,0) -- (1,.7) -- (.25,.15) -- cycle;} 
577
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
    94
506
69ad05398894 thesis chapter 2 section 2.4 2.5
Chengsong
parents: 505
diff changeset
    95
\usepackage{amsthm}
69ad05398894 thesis chapter 2 section 2.4 2.5
Chengsong
parents: 505
diff changeset
    96
\usepackage{amssymb}
519
Chengsong
parents: 518
diff changeset
    97
\usepackage{cleveref}
505
5ce3bd8e5696 thesis chapter2 section 2.4
Chengsong
parents: 503
diff changeset
    98
%\usepackage{mathtools}
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
    99
\usepackage[noend]{algpseudocode}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   100
\usepackage{enumitem}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   101
\usepackage{nccmath}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   102
\usepackage{tikz-cd}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   103
\usepackage{tikz}
472
Chengsong
parents: 471
diff changeset
   104
\usetikzlibrary{automata, positioning, calc}
579
35df9cdd36ca more chap3
Chengsong
parents: 577
diff changeset
   105
\usetikzlibrary{arrows}
580
e0f0a81f907b halfway chap3
Chengsong
parents: 579
diff changeset
   106
\usetikzlibrary{shapes.misc}
542
a7344c9afbaf chapter3 finished
Chengsong
parents: 538
diff changeset
   107
\usetikzlibrary{fit,
564
Chengsong
parents: 555
diff changeset
   108
                shapes.geometric,
Chengsong
parents: 555
diff changeset
   109
		patterns,
Chengsong
parents: 555
diff changeset
   110
		backgrounds,
Chengsong
parents: 555
diff changeset
   111
		graphs}
Chengsong
parents: 555
diff changeset
   112
\usetikzlibrary{babel}
538
8016a2480704 intro and chap2
Chengsong
parents: 537
diff changeset
   113
\usepackage{mathpartir}
555
Chengsong
parents: 554
diff changeset
   114
\usepackage{stackrel}
537
Chengsong
parents: 535
diff changeset
   115
Chengsong
parents: 535
diff changeset
   116
\DeclareCaptionType{mytype}[Illustration][]
Chengsong
parents: 535
diff changeset
   117
\newenvironment{envForCaption}{\captionsetup{type=mytype} }{}
577
f47fc4840579 thesis chap2
Chengsong
parents: 568
diff changeset
   118
590
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   119
\pgfplotsset{
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   120
    myplotstyle/.style={
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   121
    legend style={draw=none, font=\small},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   122
    legend cell align=left,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   123
    legend pos=north east,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   124
    ylabel style={align=center, font=\bfseries\boldmath},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   125
    xlabel style={align=center, font=\bfseries\boldmath},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   126
    x tick label style={font=\bfseries\boldmath},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   127
    y tick label style={font=\bfseries\boldmath},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   128
    scaled ticks=true,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   129
    every axis plot/.append style={thick},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   130
    },
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   131
}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   132
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   133
\definecolor{dkgreen}{rgb}{0,0.6,0}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   134
\definecolor{gray}{rgb}{0.5,0.5,0.5}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   135
\definecolor{mauve}{rgb}{0.58,0,0.82}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   136
\lstdefinestyle{myScalastyle}{
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   137
  frame=tb,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   138
  language=scala,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   139
  aboveskip=3mm,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   140
  belowskip=3mm,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   141
  showstringspaces=false,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   142
  columns=flexible,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   143
  basicstyle={\small\ttfamily},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   144
  numbers=none,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   145
  numberstyle=\tiny\color{gray},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   146
  keywordstyle=\color{blue},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   147
  commentstyle=\color{dkgreen},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   148
  stringstyle=\color{mauve},
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   149
  frame=single,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   150
  breaklines=true,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   151
  breakatwhitespace=true,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   152
  tabsize=3,
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   153
}
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   154
988e92a70704 more chap5 and chap6 bsimp_idem
Chengsong
parents: 585
diff changeset
   155
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   156
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   157
%	MARGIN SETTINGS
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   158
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   159
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   160
\geometry{
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   161
	paper=a4paper, % Change to letterpaper for US letter
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   162
	inner=2.5cm, % Inner margin
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   163
	outer=3.8cm, % Outer margin
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   164
	bindingoffset=.5cm, % Binding offset
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   165
	top=1.5cm, % Top margin
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   166
	bottom=1.5cm, % Bottom margin
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   167
	%showframe, % Uncomment to show how the type block is set on the page
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   168
}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   169
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   170
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   171
%	THESIS INFORMATION
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   172
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   173
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   174
\thesistitle{POSIX Regular Expression Matching and Lexing} % Your thesis title, this is used in the title and abstract, print it elsewhere with \ttitle
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   175
\supervisor{Dr. Christian \textsc{Urban}} % Your supervisor's name, this is used in the title page, print it elsewhere with \supname
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   176
\examiner{} % Your examiner's name, this is not currently used anywhere in the template, print it elsewhere with \examname
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   177
\degree{Doctor of Philosophy} % Your degree name, this is used in the title page and abstract, print it elsewhere with \degreename
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   178
\author{Chengsong \textsc{Tan}} % Your name, this is used in the title page and abstract, print it elsewhere with \authorname
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   179
\addresses{} % Your address, this is not currently used anywhere in the template, print it elsewhere with \addressname
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   180
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   181
\subject{Computer Science} % Your subject area, this is not currently used anywhere in the template, print it elsewhere with \subjectname
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   182
\keywords{} % Keywords for your thesis, this is not currently used anywhere in the template, print it elsewhere with \keywordnames
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   183
\university{\href{https://www.kcl.ac.uk}{King's College London}} % Your university's name and URL, this is used in the title page and abstract, print it elsewhere with \univname
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   184
\department{\href{https://www.kcl.ac.uk/informatics}{Department or Informatics}} % Your department's name and URL, this is used in the title page and abstract, print it elsewhere with \deptname
471
Chengsong
parents: 468
diff changeset
   185
\group{\href{https://www.kcl.ac.uk/research/ssy}{Software Systems Group}} % Your research group's name and URL, this is used in the title page, print it elsewhere with \groupname
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   186
\faculty{\href{http://faculty.university.com}{Chengsong Tan}} % Your faculty's name and URL, this is used in the title page and abstract, print it elsewhere with \facname
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   187
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   188
\AtBeginDocument{
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   189
\hypersetup{pdftitle=\ttitle} % Set the PDF's title to your title
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   190
\hypersetup{pdfauthor=\authorname} % Set the PDF's author to your name
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   191
\hypersetup{pdfkeywords=\keywordnames} % Set the PDF's keywords to your keywords
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   192
}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   193
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   194
\begin{document}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   195
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   196
\frontmatter % Use roman page numbering style (i, ii, iii, iv...) for the pre-content pages
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   197
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   198
\pagestyle{plain} % Default to the plain heading style until the thesis style is called for the body content
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   199
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   200
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   201
%	TITLE PAGE
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   202
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   203
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   204
\begin{titlepage}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   205
\begin{center}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   206
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   207
\vspace*{.06\textheight}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   208
{\scshape\LARGE \univname\par}\vspace{1.5cm} % University name
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   209
\textsc{\Large Doctoral Thesis}\\[0.5cm] % Thesis type
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   210
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   211
\HRule \\[0.4cm] % Horizontal line
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   212
{\huge \bfseries \ttitle\par}\vspace{0.4cm} % Thesis title
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   213
\HRule \\[1.5cm] % Horizontal line
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   214
 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   215
\begin{minipage}[t]{0.4\textwidth}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   216
\begin{flushleft} \large
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   217
\emph{Author:}\\
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   218
\href{https://kclpure.kcl.ac.uk/portal/en/persons/chengsong-tan(a63b381b-04bc-4cd7-beea-beb3e96cb153).html}{\authorname} % Author name - remove the \href bracket to remove the link
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   219
\end{flushleft}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   220
\end{minipage}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   221
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   222
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   223
\begin{minipage}[t]{0.4\textwidth}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   224
\begin{flushright} \large
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   225
\emph{Supervisor:} \\
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   226
\href{https://www.kcl.ac.uk/people/christian-urban}{\supname} % Supervisor name - remove the \href bracket to remove the link  
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   227
\end{flushright}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   228
\end{minipage}\\[3cm]
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   229
 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   230
\vfill
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   231
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   232
\large \textit{A thesis submitted in fulfillment of the requirements\\ for the degree of \degreename}\\[0.3cm] % University requirement text
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   233
\textit{in the}\\[0.4cm]
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   234
\groupname\\\deptname\\[2cm] % Research group name and department name
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   235
 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   236
\vfill
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   237
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   238
{\large \today}\\[4cm] % Date
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   239
%\includegraphics{Logo} % University/department logo - uncomment to place it
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   240
 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   241
\vfill
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   242
\end{center}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   243
\end{titlepage}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   244
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   245
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   246
%	DECLARATION PAGE
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   247
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   248
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   249
\begin{declaration}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   250
\addchaptertocentry{\authorshipname} % Add the declaration to the table of contents
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   251
\noindent I, \authorname, declare that this thesis titled, \enquote{\ttitle} and the work presented in it are my own. I confirm that:
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   252
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   253
\begin{itemize} 
629
96e009a446d5 abstract comments incorporated
Chengsong
parents: 628
diff changeset
   254
\item This work was done wholly while in candidature for a research degree at this University.
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   255
\item Where any part of this thesis has previously been submitted for a degree or any other qualification at this University or any other institution, this has been clearly stated.
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   256
\item Where I have consulted the published work of others, this is always clearly attributed.
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   257
\item Where I have quoted from the work of others, the source is always given. With the exception of such quotations, this thesis is entirely my own work.
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   258
\item I have acknowledged all main sources of help.
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   259
\item Where the thesis is based on work done by myself jointly with others, I have made clear exactly what was done by others and what I have contributed myself.\\
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   260
\end{itemize}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   261
 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   262
\noindent Signed:\\
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   263
\rule[0.5em]{25em}{0.5pt} % This prints a line for the signature
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   264
 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   265
\noindent Date:\\
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   266
\rule[0.5em]{25em}{0.5pt} % This prints a line to write the date
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   267
\end{declaration}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   268
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   269
\cleardoublepage
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   270
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   271
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   272
%	QUOTATION PAGE
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   273
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   274
601
Chengsong
parents: 600
diff changeset
   275
%\vspace*{0.2\textheight}
Chengsong
parents: 600
diff changeset
   276
%
Chengsong
parents: 600
diff changeset
   277
%\noindent\enquote{\itshape Thanks to my solid academic training, today I can write hundreds of words on virtually any topic without possessing a shred of information, which is how I got a good job in journalism.}\bigbreak
Chengsong
parents: 600
diff changeset
   278
%
Chengsong
parents: 600
diff changeset
   279
%\hfill Dave Barry
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   280
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   281
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   282
%	ABSTRACT PAGE
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   283
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   284
519
Chengsong
parents: 518
diff changeset
   285
%\begin{abstract}
Chengsong
parents: 518
diff changeset
   286
Chengsong
parents: 518
diff changeset
   287
 
Chengsong
parents: 518
diff changeset
   288
%\end{abstract}
Chengsong
parents: 518
diff changeset
   289
Chengsong
parents: 518
diff changeset
   290
527
2c907b118f78 all chapters put in
Chengsong
parents: 526
diff changeset
   291
\begin{abstract}
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   292
\addchaptertocentry{\abstractname} % Add the abstract to the table of contents
527
2c907b118f78 all chapters put in
Chengsong
parents: 526
diff changeset
   293
%\addchap{Abstract} 
653
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   294
\marginpar{\em Reviewer feedback:  Problem: not like an abstract, more like a summary\\
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   295
New abstract: more high-level and abstract, tell the problem and solution in a concise way.
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   296
}
646
Chengsong
parents: 638
diff changeset
   297
%Modern computer systems rely on lexing for essential applications such as
Chengsong
parents: 638
diff changeset
   298
%compilers, IDEs, file systems, and network intrusion detection systems.
Chengsong
parents: 638
diff changeset
   299
%These applications require correctness with respect to
Chengsong
parents: 638
diff changeset
   300
%the POSIX standard and high performance.
Chengsong
parents: 638
diff changeset
   301
%%While existing implementations of lexers often achieve high performance,
Chengsong
parents: 638
diff changeset
   302
%Existing implementations had drawbacks such as bugs and catastrophic backtracking,
Chengsong
parents: 638
diff changeset
   303
%preventing them from solving the problem once
Chengsong
parents: 638
diff changeset
   304
%and for all.
Chengsong
parents: 638
diff changeset
   305
%To address these drawbacks,
Chengsong
parents: 638
diff changeset
   306
%this thesis offers an algorithm with formally proven correctness and internal data structures' size bound. 
Chengsong
parents: 638
diff changeset
   307
%These mechanised proofs ensure that our algorithm is fast and correct in \textbf{all} cases.
Chengsong
parents: 638
diff changeset
   308
%Our proofs use term-rewriting relations to establish invariants during derivatives and simplifications,
Chengsong
parents: 638
diff changeset
   309
%which is extensible and friendly to theorem provers.
Chengsong
parents: 638
diff changeset
   310
Chengsong
parents: 638
diff changeset
   311
POSIX is the most widely used disambiguation strategy for regular expression matching.  There are some difficulties associated with the POSIX strategy and according to tests conducted by Kulkewitz, many regular expression matchers implementing this strategy produce incorrect results. This thesis is concerned with an POSIX regular expression matching algorithm introduced by Sulzmann and Lu. This algorithm uses bitcoded regular expressions and is based on the idea of Brzozowski derivatives. The algorithm generates POSIX values which encode the information of how a regular expression matches a string - that is, which part of the string is matched by which part of the regular expression. This information is needed in the context of lexing in order to extract and to classify tokens.
Chengsong
parents: 638
diff changeset
   312
Chengsong
parents: 638
diff changeset
   313
While a formalised correctness proof for Sulzmann and Lu's algorithm already exists, this proof does not include any of the crucial simplification rules. These simplification rules are however necessary in order to have an acceptable runtime for this algorithm. Our version of the simplification rules includes a number of fixes and improvements: one problem we fix has to do with their use of the nub function that does not remove non-trivial duplicates. We improve the simplification rules by formulating them as simple recursive function and also by simplifying more instances of regular expressions.  As a result we can establish a bound on the size of derivatives. Our proofs are formalised in Isabelle/HOL.
Chengsong
parents: 638
diff changeset
   314
Chengsong
parents: 638
diff changeset
   315
Chengsong
parents: 638
diff changeset
   316
664
ba44144875b1 introduction Contribution section update
Chengsong
parents: 653
diff changeset
   317
%Old abstract:
653
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   318
%This thesis is about regular expressions and derivatives. It combines functional algorithms and their formal verification in the Isabelle/HOL theorem prover. 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   319
%Classic results say that regular expression matching should be 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   320
%linear with respect to the input. The size of the regular expressions
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   321
%are often treated as a constant factor.
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   322
%However with some regular expressions and inputs, existing implementations 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   323
%often suffer from non-linear or even exponential running time, 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   324
%giving rise to ReDoS (regular expression denial-of-service ) attacks. 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   325
%To avoid these attacks, regular expression matchers and lexers with 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   326
%formalised correctness and running time related
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   327
%properties are of interest because the guarantees apply to all inputs, not just a finite
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   328
%number of empirical test cases.
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   329
%
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   330
%Sulzmann and Lu describe a lexing algorithm that calculates Brzozowski derivatives using bitcodes annotated to regular expressions. Their algorithm generates POSIX values which encode the information of how a regular expression matches a string—that is, which part of the string is matched by which part of the regular expression. This information is needed in the context of lexing in order to extract and to classify tokens. The purpose of the bitcodes is to generate POSIX values incrementally while derivatives are calculated. They also help with designing an “aggressive” simplification function that keeps the size of derivatives finitely bounded. 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   331
%Our simplification function is more aggressive than the one by Sulzmann and Lu.
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   332
%We also fix a problem in Sulzmann and Lu's simplification to do with their use of
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   333
%the $\textit{nub}$ function which does not remove non-trivial duplicates.
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   334
%Without simplification the size of some derivatives can grow arbitrarily big resulting in an extremely slow lexing algorithm.
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   335
%In this thesis we describe a variant of Sulzmann and Lu’s algorithm: Our variant is a recursive functional program, whereas Sulzmann and Lu’s version involves a fixpoint construction. We (i) prove in Isabelle/HOL that our algorithm is correct and generates unique POSIX values; we also (ii) establish a finite bound for the size of the derivatives for every input string; we also
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   336
%(iii) give a program and a conjecture that the finite 
bc5571c38d1f more updates in section 4.2 and incorporating Christian comments
Chengsong
parents: 646
diff changeset
   337
%bound can be improved to be cubic if stronger simplification rules are applied. 
568
7a579f5533f8 more chapter2 modifications
Chengsong
parents: 564
diff changeset
   338
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   339
568
7a579f5533f8 more chapter2 modifications
Chengsong
parents: 564
diff changeset
   340
7a579f5533f8 more chapter2 modifications
Chengsong
parents: 564
diff changeset
   341
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   342
527
2c907b118f78 all chapters put in
Chengsong
parents: 526
diff changeset
   343
\end{abstract}
519
Chengsong
parents: 518
diff changeset
   344
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   345
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   346
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   347
%	ACKNOWLEDGEMENTS
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   348
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   349
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   350
\begin{acknowledgements}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   351
\addchaptertocentry{\acknowledgementname} % Add the acknowledgements to the table of contents
628
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   352
I would like to express my deepest thanks to my supervisor Doctor Christian Urban, 
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   353
who have been always extremely supportive thoughout my PhD, in all sorts of ways.
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   354
Supervisionwise, Christian always 
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   355
thinks in terms of the best interests for the student, to which I am eternally grateful for. 
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   356
I would also like to thank Doctor Ning Zhang, who have always been very gentle and caring to me,
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   357
quick to lend a
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   358
helping hand at difficult times. 
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   359
I want to thank Doctor Kathrin Stark, my SIGPLAN mentor, for offering brilliant advice
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   360
at the late stage of my PhD. My transition from a PhD student to a postdoc researcher
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   361
could not have been so smooth without Kathrin's mentoring.
638
dd9dde2d902b comments till chap4
Chengsong
parents: 629
diff changeset
   362
%I want to thank Jeanna Wheeler, my UMO mentor, for helping me regulate my mental health
dd9dde2d902b comments till chap4
Chengsong
parents: 629
diff changeset
   363
%and productivity, by being always encouraging
dd9dde2d902b comments till chap4
Chengsong
parents: 629
diff changeset
   364
%and compassionate in her sessions.
dd9dde2d902b comments till chap4
Chengsong
parents: 629
diff changeset
   365
I want to thank Jeanna Wheeler for helping me with keeping sane during my time during the PhD and COVID times when an encouraging and compassionate person was very appreciated.
628
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   366
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   367
I want to thank my father Haiyan Tan and my mother Yunan Cheng,
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   368
for their unconditional love, and who I have not seen
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   369
face to face for three years. 
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   370
I really miss you.
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   371
I want to thank my friends Yuying Chen, Kai Zeng, Rui Luo, Jingyi Liu, Qingtian Ye, and many others,
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   372
who have always been very patient and compassionate, giving clever advice when I turned to 
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   373
them for help.
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   374
\end{acknowledgements}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   375
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   376
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   377
%	LIST OF CONTENTS/FIGURES/TABLES PAGES
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   378
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   379
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   380
\tableofcontents % Prints the main table of contents
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   381
518
ff7945a988a3 more to thesis
Chengsong
parents: 506
diff changeset
   382
%\listoffigures % Prints the list of figures
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   383
518
ff7945a988a3 more to thesis
Chengsong
parents: 506
diff changeset
   384
%\listoftables % Prints the list of tables
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   385
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   386
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   387
%	ABBREVIATIONS
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   388
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   389
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   390
500
Chengsong
parents: 472
diff changeset
   391
Chengsong
parents: 472
diff changeset
   392
\newtheorem{theorem}{Theorem}
Chengsong
parents: 472
diff changeset
   393
\newtheorem{lemma}{Lemma}
528
28751de4b4ba revised according to comments
Chengsong
parents: 527
diff changeset
   394
\newtheorem{definition}{Definition}
542
a7344c9afbaf chapter3 finished
Chengsong
parents: 538
diff changeset
   395
\newtheorem{conjecture}{Conjecture}
554
Chengsong
parents: 542
diff changeset
   396
\newtheorem{corollary}{Corollary}
Chengsong
parents: 542
diff changeset
   397
\newtheorem{property}{Property}
Chengsong
parents: 542
diff changeset
   398
\newtheorem{proposition}{Proposition}
505
5ce3bd8e5696 thesis chapter2 section 2.4
Chengsong
parents: 503
diff changeset
   399
%proof
5ce3bd8e5696 thesis chapter2 section 2.4
Chengsong
parents: 503
diff changeset
   400
500
Chengsong
parents: 472
diff changeset
   401
601
Chengsong
parents: 600
diff changeset
   402
%\newcommand\sflat[1][]{\textit{sflat} \, #1}
Chengsong
parents: 600
diff changeset
   403
%\newcommand{\ASEQ}[3]{\textit{ASEQ}_{#1} \, #2 \, #3}
Chengsong
parents: 600
diff changeset
   404
%\newcommand{\bderssimp}[2]{#1 \backslash_{bsimp} #2}
Chengsong
parents: 600
diff changeset
   405
%\newcommand{\rderssimp}[2]{#1 \backslash_{rsimp} #2}
Chengsong
parents: 600
diff changeset
   406
%\newcommand{\sflataux}[1]{\lbracket #1 \rbracket}
Chengsong
parents: 600
diff changeset
   407
%\newcommand{\dn}{\stackrel{\mbox{\scriptsize def}}{=}}%
Chengsong
parents: 600
diff changeset
   408
%\newcommand{\ZERO}{\mbox{\bf 0}}
Chengsong
parents: 600
diff changeset
   409
%\newcommand{\ONE}{\mbox{\bf 1}}
Chengsong
parents: 600
diff changeset
   410
%\newcommand{\AALTS}[2]{\XOR {\scriptstyle #1}\, #2}
Chengsong
parents: 600
diff changeset
   411
%
Chengsong
parents: 600
diff changeset
   412
%\def\lexer{\mathit{lexer}}
Chengsong
parents: 600
diff changeset
   413
%\def\mkeps{\mathit{mkeps}}
Chengsong
parents: 600
diff changeset
   414
%
Chengsong
parents: 600
diff changeset
   415
%\def\AZERO{\textit{AZERO}}
Chengsong
parents: 600
diff changeset
   416
%\def\AONE{\textit{AONE}}
Chengsong
parents: 600
diff changeset
   417
%\def\ACHAR{\textit{ACHAR}}
Chengsong
parents: 600
diff changeset
   418
%
Chengsong
parents: 600
diff changeset
   419
%
Chengsong
parents: 600
diff changeset
   420
%\def\ALTS{\textit{ALTS}}
Chengsong
parents: 600
diff changeset
   421
%\def\ASTAR{\textit{ASTAR}}
Chengsong
parents: 600
diff changeset
   422
%\def\DFA{\textit{DFA}}
Chengsong
parents: 600
diff changeset
   423
%\def\bmkeps{\textit{bmkeps}}
Chengsong
parents: 600
diff changeset
   424
%\def\retrieve{\textit{retrieve}}
Chengsong
parents: 600
diff changeset
   425
%\def\blexer{\textit{blexer}}
Chengsong
parents: 600
diff changeset
   426
%\def\flex{\textit{flex}}
Chengsong
parents: 600
diff changeset
   427
%\def\inj{\mathit{inj}}
Chengsong
parents: 600
diff changeset
   428
%\def\Empty{\mathit{Empty}}
Chengsong
parents: 600
diff changeset
   429
%\def\Left{\mathit{Left}}
Chengsong
parents: 600
diff changeset
   430
%\def\Right{\mathit{Right}}
Chengsong
parents: 600
diff changeset
   431
%\def\Stars{\mathit{Stars}}
Chengsong
parents: 600
diff changeset
   432
%\def\Char{\mathit{Char}}
Chengsong
parents: 600
diff changeset
   433
%\def\Seq{\mathit{Seq}}
Chengsong
parents: 600
diff changeset
   434
%\def\Der{\mathit{Der}}
Chengsong
parents: 600
diff changeset
   435
%\def\nullable{\mathit{nullable}}
Chengsong
parents: 600
diff changeset
   436
%\def\Z{\mathit{Z}}
Chengsong
parents: 600
diff changeset
   437
%\def\S{\mathit{S}}
Chengsong
parents: 600
diff changeset
   438
%\def\rup{r^\uparrow}
Chengsong
parents: 600
diff changeset
   439
%%\def\bderssimp{\mathit{bders}\_\mathit{simp}}
Chengsong
parents: 600
diff changeset
   440
%\def\distinctWith{\textit{distinctWith}}
Chengsong
parents: 600
diff changeset
   441
%
Chengsong
parents: 600
diff changeset
   442
%\def\rexp{\mathbf{rexp}}
Chengsong
parents: 600
diff changeset
   443
%\def\simp{\mathit{simp}}
Chengsong
parents: 600
diff changeset
   444
%\def\simpALTs{\mathit{simp}\_\mathit{ALTs}}
Chengsong
parents: 600
diff changeset
   445
%\def\map{\mathit{map}}
Chengsong
parents: 600
diff changeset
   446
%\def\distinct{\mathit{distinct}}
Chengsong
parents: 600
diff changeset
   447
%\def\blexersimp{\mathit{blexer}\_\mathit{simp}}
Chengsong
parents: 600
diff changeset
   448
%\def\map{\textit{map}}
Chengsong
parents: 600
diff changeset
   449
%\def\vsuf{\textit{vsuf}}
Chengsong
parents: 600
diff changeset
   450
%\def\sflataux{\textit{sflat}\_\textit{aux}}
Chengsong
parents: 600
diff changeset
   451
%\def\rrexp{\textit{rrexp}}
Chengsong
parents: 600
diff changeset
   452
%\def\rsize{\textit{rsize}}
Chengsong
parents: 600
diff changeset
   453
%\def\asize{\textit{asize}}
Chengsong
parents: 600
diff changeset
   454
%\def\rerase{\textit{rerase}}
Chengsong
parents: 600
diff changeset
   455
%\def\erase{\textit{erase}}
Chengsong
parents: 600
diff changeset
   456
%\def\STAR{\textit{STAR}}
Chengsong
parents: 600
diff changeset
   457
%\def\flts{\textit{flts}}
Chengsong
parents: 600
diff changeset
   458
%
503
35b80e37dfe7 new writing
Chengsong
parents: 500
diff changeset
   459
35b80e37dfe7 new writing
Chengsong
parents: 500
diff changeset
   460
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   461
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   462
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   463
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   464
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   465
%	SYMBOLS
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   466
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   467
528
28751de4b4ba revised according to comments
Chengsong
parents: 527
diff changeset
   468
%\begin{symbols}{lll} % Include a list of Symbols (a three column table)
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   469
528
28751de4b4ba revised according to comments
Chengsong
parents: 527
diff changeset
   470
%$a$ & distance & \si{\meter} \\
28751de4b4ba revised according to comments
Chengsong
parents: 527
diff changeset
   471
%$P$ & power & \si{\watt} (\si{\joule\per\second}) \\
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   472
%Symbol & Name & Unit \\
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   473
528
28751de4b4ba revised according to comments
Chengsong
parents: 527
diff changeset
   474
%\addlinespace % Gap to separate the Roman symbols from the Greek
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   475
528
28751de4b4ba revised according to comments
Chengsong
parents: 527
diff changeset
   476
%$\omega$ & angular frequency & \si{\radian} \\
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   477
528
28751de4b4ba revised according to comments
Chengsong
parents: 527
diff changeset
   478
%\end{symbols}
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   479
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   480
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   481
%	DEDICATION
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   482
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   483
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   484
\dedicatory{For/Dedicated to/To my\ldots} 
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   485
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   486
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   487
%	THESIS CONTENT - CHAPTERS
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   488
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   489
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   490
\mainmatter % Begin numeric (1,2,3...) page numbering
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   491
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   492
\pagestyle{thesis} % Return the page headers back to the "thesis" style
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   493
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   494
% Include the chapters of the thesis as separate files from the Chapters folder
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   495
% Uncomment the lines as you write the chapters
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   496
532
cc54ce075db5 restructured
Chengsong
parents: 528
diff changeset
   497
\include{Chapters/Introduction}
cc54ce075db5 restructured
Chengsong
parents: 528
diff changeset
   498
\include{Chapters/Inj} 
cc54ce075db5 restructured
Chengsong
parents: 528
diff changeset
   499
\include{Chapters/Bitcoded1}
cc54ce075db5 restructured
Chengsong
parents: 528
diff changeset
   500
\include{Chapters/Bitcoded2}
cc54ce075db5 restructured
Chengsong
parents: 528
diff changeset
   501
\include{Chapters/Finite} 
cc54ce075db5 restructured
Chengsong
parents: 528
diff changeset
   502
\include{Chapters/Cubic}
608
37b6fd310a16 added related work chap
Chengsong
parents: 601
diff changeset
   503
\include{Chapters/RelatedWork}
626
1c8525061545 finished!
Chengsong
parents: 612
diff changeset
   504
\include{Chapters/Future}
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   505
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   506
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   507
%	THESIS CONTENT - APPENDICES
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   508
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   509
628
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   510
%\appendix % Cue to tell LaTeX that the following "chapters" are Appendices
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   511
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   512
% Include the appendices of the thesis as separate files from the Appendices folder
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   513
% Uncomment the lines as you write the Appendices
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   514
628
7af4e2420a8c ready to submit~~
Chengsong
parents: 626
diff changeset
   515
%\include{Appendices/AppendixA}
468
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   516
%\include{Appendices/AppendixB}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   517
%\include{Appendices/AppendixC}
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   518
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   519
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   520
%	BIBLIOGRAPHY
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   521
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   522
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   523
\printbibliography[heading=bibintoc]
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   524
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   525
%----------------------------------------------------------------------------------------
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   526
a0f27e21b42c all texrelated
Chengsong
parents:
diff changeset
   527
\end{document}