-
Notifications
You must be signed in to change notification settings - Fork 1
/
slides.tex
203 lines (180 loc) · 6.84 KB
/
slides.tex
1
2
3
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
% !TEX program = xelatex
% !TEX options = -synctex=1 -file-line-error -halt-on-error -xelatex -shell-escape "%DOC%"
\input{./preamble.tex}
\title[Sample]{CUHK Beamer Template}
\subtitle{Sample Slides}
\author[Li Zhuohua]{Li Zhuohua}
\institute[CUHK]{The Chinese University of Hong Kong}
\date{\today}
\begin{document}
\frame[plain]{\maketitle}
%\begin{frame}{Outline}
% \tableofcontents{}
%\end{frame}
\begin{frame}{Itemize Tests}
\begin{itemize}
\item One: \textit{Two} \textbf{Three}
\begin{itemize}
\item \so{letterspacing}
\item \ul{underlining}
\item \st{striking out}
\item \hl{highlighting}
\item \caps{CAPITALS, Small Capitals}
\item \boxalert{Box}
\end{itemize}
\item Test Test Test
\end{itemize}
\end{frame}
\begin{frame}{Multi-Columns}
\begin{multicols}{3}
[
All human things are subject to decay. And when fate summons, Monarchs must obey.
]
Hello, here is some text without a meaning. This text should show what
a printed text will look like at this place.
If you read this text, you will get no information. Really? Is there
no information? Is there...
\end{multicols}
\end{frame}
\begin{frame}{Plot Test}
\pgfplotsset{width=5.5cm,compat=1.9}
\begin{figure}
\centering
\begin{tikzpicture}
\begin{axis}
\addplot3[
surf,
]
{exp(-x^2-y^2)*x};
\end{axis}
\end{tikzpicture}
\caption{Plot $z=x(-x^2-y^2)$} \label{fig:plot}
\end{figure}
\end{frame}
\begin{frame}{中文测试}
\begin{itemize}
\item 这是简体中文: \textbf{加粗} + \underline{下划线}
\begin{itemize}
\item 这是第二层
\end{itemize}
\item 大部分中文字体不支持斜体命令\texttt{\textbackslash textit\{\}}
\end{itemize}
\hfill \break
披绣闼,俯雕甍,山原旷其盈视,川泽纡其骇瞩。闾阎扑地,钟鸣鼎食之家;舸舰弥津,青雀黄龙之舳。云销雨霁,彩彻区明。落霞与孤鹜齐飞,秋水共长天一色。渔舟唱晚,响穷彭蠡之滨;雁阵惊寒,声断衡阳之浦。
\end{frame}
\begin{frame}{中文測試}
\begin{itemize}
\item 這是繁體中文: \textbf{加粗} + \underline{下劃線}
\begin{itemize}
\item 這是第二層
\end{itemize}
\item 大部分中文字體不支持斜體命令\texttt{\textbackslash textit\{\}}
\end{itemize}
\hfill \break
披繡闥,俯雕甍。山原曠其盈視,川澤紆其駭矚。閭閻撲地,鐘鳴鼎食之家;舸艦彌津,青雀黃龍之舳。雲銷雨霽,彩徹區明。落霞與孤鶩齊飛,秋水共長天一色。漁舟唱晚,響窮彭蠡之濱;雁陣驚寒,聲斷衡陽之浦。
\end{frame}
\begin{frame}{Citation Tests}
\begin{itemize}
\item Yao's Millionaires' problem~\footcite{10.5555/1382436.1382751}
\end{itemize}
\end{frame}
\begin{frame}{Algorithm Test}
\IncMargin{1em}
\begin{algorithm}[H]
\DontPrintSemicolon
\SetVlineSkip{0pt}
\scriptsize
\SetKwFunction{Successors}{\textsc{Successors}}%
\SetKwFunction{Entry}{\textsc{Entry}}%
\SetKwFunction{Transfer}{\textsc{Transfer}}%
\KwIn{Control Flow Graph: $CFG$}%
\KwOut{Invariant: $State$}%
initialization: \parbox[t]{\linewidth}{
$State[n] \leftarrow \top$ if $n=\Entry{CFG}$\;
$State[n] \leftarrow \bot$ otherwise\;}
$WorkList \leftarrow \Entry{CFG}$\;
\While{$WorkList$ is not empty}{
$WorkList \leftarrow WorkList \backslash \{n\}$\;
$new\_state \leftarrow \Transfer{State[n]}$\;
\ForEach{$succ \in \Successors{CFG, n}$} {
\If{$new\_state \not\sqsubseteq State[succ]$} {
$State[succ] \leftarrow State[succ] \sqcup new\_state$\;
$WorkList \leftarrow WorkList \cup \{succ\}$\;
}
}
}
\SetAlCapHSkip{.5em}
\caption{Basic algorithm for Abstract Interpretation}
\end{algorithm}
\end{frame}
\begin{frame}[fragile]{Code Test}
\begin{minted}{rust}
fn main() {
println!("Hello World!");
}
\end{minted}
\begin{itemize}
\item Inline code is also supported: \mintinline{rust}{fn main() { }}
\end{itemize}
\end{frame}
\begin{frame}{Math Test}
\begin{enumerate}
\item Symbols: $\alpha,\beta,\gamma,\delta,\epsilon,\varepsilon,\zeta,\eta,\theta,\vartheta,\iota,\kappa,\lambda,\nu,\xi,\varpi,\rho,\varrho,\sigma,\varsigma,\tau,\upsilon,\phi,\varphi,\chi,\psi,\omega$;
\item Symbols: $f'',\sqrt{a},\overrightarrow{a},\subseteq,\supseteq$
\[\int,\iint,\iiint,\iiiint,\oint\]
\item Complex equation:
\resizebox{.9\hsize}{!}{%
$
\displaystyle\lim_{x\rightarrow 0^+}\displaystyle\lim_{y\rightarrow +\infty}\frac{\displaystyle\sum_{n=1}^{\infty}{\frac{\left(-1\right)^{n-1}}{n}}\displaystyle\sum_{m=0}^{\infty}{\frac{1}{n2^m+1}}\displaystyle\int_0^{x^2}{\frac{\pi \left(\sqrt[4]{1+t}-1\right)\sin t^4}{\displaystyle\sum_{n=1}^{\infty}{\displaystyle\frac{\left(\left(n-1\right)!\right)^2\left(2t\right)^{2n}}{\left(2n\right)!}}\displaystyle\int_0^1{\displaystyle\frac{\left(1-2x\right)\ln\left(1-x\right)}{x^2-x+1}\textrm{d}x}}\textrm{d}x}}{x^2\left(x-\tan x\right)\ln\left(x^2+1\right)\left[\left(\displaystyle\frac{2\arctan\frac{y}{x}}{\pi}\right)^y-1\right]}=\frac{27}{32}
$
}
\end{enumerate}
\end{frame}
\begin{frame}{Theorem/Lemma/Corollary/Proof}
Fancy style theorem:
\begin{theo}{Pythagorean Theorem}{pythagoras}
For a right triangle with legs $a$ and $b$ and hypotenuse $c$,
\[
a^2 + b^2 = c^2.
\]
\end{theo}
This is a reference to Theorem \ref{th:pythagoras}.
Normal style theorem:
\begin{theorem}[Fixed-point Theorem]
In a lattice $L$ with finite height, every monotone function $f : L \rightarrow L$
has a unique least fixed-point denoted $fix (f)$ defined as:
\[
fix (f) = \bigsqcup_{i \geq 0}f^i(\bot)
\]
\end{theorem}
\end{frame}
\begin{frame}{Theorem/Lemma/Corollary/Proof}
\begin{lemma}[Lemma Name]
$ x + y = y + x $
\end{lemma}
\begin{corollary}[Corollary Name]
There's no right rectangle whose sides measure 3cm, 4cm, and 6cm.
\end{corollary}
\begin{proof}[\proofname\ (Theorem \ref{th:pythagoras})]
$\omega +\phi = \epsilon $
\end{proof}
\end{frame}
% \setbeamertemplate{headline}{}
% \addtobeamertemplate{frametitle}{\vspace*{-0.9\baselineskip}}{}
\begin{frame}[plain]{}
\centering \Huge
\emph{Thank You}
\end{frame}
\begin{frame}[noframenumbering,allowframebreaks]{References}
\setbeamertemplate{bibliography item}{}
% \setbeamertemplate{bibliography item}{\insertbiblabel}
\printbibliography
\end{frame}
\end{document}
%%% Local Variables:
%%% coding: utf-8
%%% mode: latex
%%% TeX-master: t
%%% TeX-command-extra-options: "-shell-escape"
%%% TeX-engine: xetex
%%% End: