slides/slides01.tex
author Christian Urban <christian dot urban at kcl dot ac dot uk>
Sun, 21 Sep 2014 23:23:43 +0100
changeset 254 dcd4688690ce
parent 253 75c469893514
child 255 96a99237fa42
permissions -rw-r--r--
updated
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
95
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
     1
\documentclass[dvipsnames,14pt,t,xelatex]{beamer}
252
e8ef8f38ca84 added style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 215
diff changeset
     2
\usepackage{../slides}
e8ef8f38ca84 added style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 215
diff changeset
     3
\usepackage{../graphics}
215
828303e8e4af updated slides
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 98
diff changeset
     4
\usepackage{../langs}
828303e8e4af updated slides
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 98
diff changeset
     5
\usepackage{../data}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     6
252
e8ef8f38ca84 added style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 215
diff changeset
     7
\hfuzz=220pt 
e8ef8f38ca84 added style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 215
diff changeset
     8
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
     9
%\setmonofont[Scale=.88]{Consolas}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    10
%\newfontfamily{\consolas}{Consolas}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    11
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    12
\lstset{language=Scala,
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    13
        style=mystyle,
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    14
        numbersep=0pt,
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    15
        numbers=none,
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    16
        xleftmargin=0mm}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
    17
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
    18
\newcommand{\bl}[1]{\textcolor{blue}{#1}}     
95
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
    19
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    20
% beamer stuff 
252
e8ef8f38ca84 added style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 215
diff changeset
    21
\renewcommand{\slidecaption}{AFL 01, King's College London}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    22
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    23
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    24
\begin{document}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    25
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    26
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
    27
\begin{frame}[t]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    28
\frametitle{%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    29
  \begin{tabular}{@ {}c@ {}}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    30
  \\[-3mm]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    31
  \LARGE Automata and \\[-2mm] 
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    32
  \LARGE Formal Languages (1)\\[-3mm] 
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    33
  \end{tabular}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    34
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    35
  \begin{center}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    36
  \includegraphics[scale=0.3]{pics/ante1.jpg}\hspace{5mm}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    37
  \includegraphics[scale=0.31]{pics/ante2.jpg}\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    38
  \footnotesize\textcolor{gray}{Antikythera automaton, 100 BC (Archimedes?)}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    39
  \end{center}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    40
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    41
\normalsize
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    42
  \begin{center}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    43
  \begin{tabular}{ll}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    44
  Email:  & christian.urban at kcl.ac.uk\\
95
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
    45
  Office: & S1.27 (1st floor Strand Building)\\
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    46
  Slides: & KEATS
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    47
  \end{tabular}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    48
  \end{center}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    49
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    50
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
    51
\end{frame}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    52
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    53
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    54
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    55
\begin{frame}[c]
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    56
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    57
\begin{textblock}{1}(2,5)
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    58
\begin{tabular}{c}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    59
\includegraphics[scale=0.15]{pics/servers.png}\\[-2mm]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    60
\small Server
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    61
\end{tabular}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    62
\end{textblock}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    63
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    64
\begin{textblock}{1}(5.6,4)
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    65
  \begin{tikzpicture}[scale=1.1]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    66
  \draw[white] (0,1) node (X) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    67
  \draw[white] (2,1) node (Y) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    68
   \draw[white] (0,0) node (X1) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    69
  \draw[white] (2,0) node (Y1) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    70
   \draw[white] (0,-1) node (X2) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    71
  \draw[white] (2,-1) node (Y2) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    72
  \draw[red, <-, line width = 2mm] (X) -- (Y);
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    73
  \node [inner sep=5pt,label=above:\textcolor{black}{GET request}] at ($ (X)!.5!(Y) $) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    74
  \draw[red, ->, line width = 2mm] (X1) -- (Y1);
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    75
  \node [inner sep=5pt,label=above:\textcolor{black}{webpage}] at ($ (X1)!.5!(Y1) $) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    76
  \draw[red, <-, line width = 2mm] (X2) -- (Y2);
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    77
  \node [inner sep=7pt,label=above:\textcolor{black}{POST data}] at ($ (X2)!.5!(Y2) $) {};
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    78
  \end{tikzpicture}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    79
\end{textblock}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    80
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    81
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    82
\begin{textblock}{1}(9,5.5)
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    83
\begin{tabular}{c}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    84
\includegraphics[scale=0.15]{pics/laptop.png}\\[-2mm]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    85
\small Browser
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    86
\end{tabular}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    87
\end{textblock}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    88
  
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    89
\only<2>{  
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    90
\begin{textblock}{10}(2,13.5)
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    91
\begin{itemize}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    92
\item programming languages, compilers
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    93
\end{itemize}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    94
\end{textblock}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    95
  
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
    96
\end{frame}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    97
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    98
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    99
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   100
\begin{frame}[c]
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   101
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   102
transforming strings into structured data\\[10mm]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   103
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   104
{\LARGE\bf Lexing}\medskip\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   105
\hspace{5mm}(recognising ``words'')\\[6mm]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   106
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   107
{\LARGE\bf Parsing}\medskip\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   108
\hspace{5mm}(recognising ``sentences'')
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   109
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   110
\end{frame}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   111
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   112
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   113
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   114
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   115
\begin{frame}[c]
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   116
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   117
The subject is quite old:
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   118
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   119
\begin{itemize}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   120
\item Turing Machines, 1936
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   121
\item first compiler for COBOL, 1957 (Grace Hopper)
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   122
\item but surprisingly research papers are still published now
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   123
\end{itemize}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   124
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   125
\begin{flushright}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   126
\includegraphics[scale=0.3]{pics/hopper.jpg}\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   127
\footnotesize\textcolor{gray}{Grace Hopper}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   128
\end{flushright}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   129
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   130
{\footnotesize\textcolor{gray}{(she made it to David Letterman's Tonight Show, \url{http://www.youtube.com/watch?v=aZOxtURhfEU})}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   131
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   132
\end{frame}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   133
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   134
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   135
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   136
\mode<presentation>{
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   137
\begin{frame}[c]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   138
\frametitle{\begin{tabular}{c}This Course\end{tabular}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   139
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   140
\begin{itemize}
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   141
\item the ultimate goal is to implement a small compiler (a really small one for the JVM)\bigskip
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   142
\end{itemize}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   143
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   144
Let's start with:
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   145
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   146
\begin{itemize}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   147
\item a web-crawler
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   148
\item an email harvester
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   149
\item a web-scraper
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   150
\end{itemize}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   151
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   152
\begin{textblock}{6}(10,7)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   153
\begin{tikzpicture}[scale=0.38]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   154
\begin{axis}[axis x line=bottom, axis y line=left, ylabel=secs,
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   155
    xlabel=n,
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   156
    enlargelimits=0.05,
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   157
    ybar interval=0.7, legend style=small]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   158
\addplot file {interpreted2.data};
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   159
\addplot file {compiled2.data};
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   160
%\legend{interpreted, compiled}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   161
\end{axis}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   162
\end{tikzpicture}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   163
\end{textblock}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   164
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   165
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   166
\end{frame}}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   167
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   168
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   169
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   170
\begin{frame}[t]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   171
\frametitle{A Web-Crawler}
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   172
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   173
\mbox{}\\[10mm]
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   174
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   175
\begin{enumerate}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   176
\item given an URL, read the corresponding webpage
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   177
\item extract all links from it
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   178
\item call the web-crawler again for all these links
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   179
\end{enumerate}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   180
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   181
\end{frame}
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   182
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   183
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   184
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   185
\mode<presentation>{
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   186
\begin{frame}[t]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   187
\frametitle{A Web-Crawler}
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   188
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   189
\mbox{}\\[10mm]
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   190
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   191
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   192
\begin{enumerate}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   193
\item given an URL, read the corresponding webpage
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   194
\item if not possible print, out a problem
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   195
\item if possible, extract all links from it
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   196
\item call the web-crawler again for all these links
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   197
\end{enumerate}\bigskip\pause
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   198
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   199
\small (we need a bound for the number of recursive calls)
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   200
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   201
\small (the purpose is to check all links on my own webpage)
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   202
\end{frame}}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   203
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   204
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   205
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   206
\begin{frame}[c]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   207
\frametitle{Scala}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   208
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   209
\small A simple Scala function for reading webpages:
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   210
\smallskip
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   211
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   212
\footnotesize
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   213
\lstinputlisting{../progs/app0.scala}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   214
\medskip\pause
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   215
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   216
\lstinline{get_page("""http://www.inf.kcl.ac.uk/staff/urbanc/""")}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   217
\bigskip\medskip\pause
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   218
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   219
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   220
\small A slightly more complicated version for handling errors properly:
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   221
\smallskip
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   222
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   223
\footnotesize
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   224
\lstinputlisting{../progs/app1.scala}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   225
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   226
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   227
\end{frame}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   228
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   229
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   230
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   231
\begin{frame}[c]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   232
\frametitle{Why Scala?}
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   233
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   234
\begin{textblock}{6}(1,3)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   235
\begin{tabular}{l}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   236
\mbox{}\hspace{-1mm}\includegraphics[scale=0.36]{pics/twitter.png}\\[-1mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   237
\includegraphics[scale=0.30]{pics/linked.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   238
\includegraphics[scale=0.30]{pics/guardian.jpg}\\[-3mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   239
\mbox{}\hspace{-2mm}\includegraphics[scale=0.38]{pics/morgan.png}\\[-3mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   240
\includegraphics[scale=0.30]{pics/suisse.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   241
\includegraphics[scale=0.20]{pics/edf.png}\\[-1mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   242
\includegraphics[scale=0.08]{pics/novell.png}\\[-1mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   243
\includegraphics[scale=0.30]{pics/foursquare.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   244
\includegraphics[scale=0.30]{pics/hsbc.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   245
{\large\bf ...}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   246
\end{tabular}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   247
\end{textblock}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   248
 
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   249
\only<2->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   250
\begin{textblock}{6}(6,3)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   251
\includegraphics[scale=0.35]{pics/jobgraph.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   252
\end{textblock}}  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   253
  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   254
\only<3->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   255
\begin{textblock}{6}(7.3,9.2)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   256
\begin{tabular}{l}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   257
\footnotesize 2013: 1$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   258
\footnotesize 2014: 3$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   259
\footnotesize 2015: 9$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   260
\footnotesize 2016: 27$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   261
\footnotesize 2017: 81$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   262
\footnotesize 2018: 243$\%$ \raisebox{-1mm}{\includegraphics[scale=0.02]{pics/smiley.jpg}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   263
\end{tabular}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   264
\end{textblock}} 
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   265
  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   266
\only<3->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   267
\begin{textblock}{6}(6,9.5)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   268
\footnotesize 5 yrs $\begin{cases}\mbox{}\\[1.4cm]\end{cases}$
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   269
\end{textblock}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   270
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   271
\only<4->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   272
\begin{textblock}{11}(5,14.1)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   273
\textcolor{gray}{
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   274
\footnotesize {\bf in London today:} 1 Scala job for every 30 Java jobs;\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   275
Scala programmers seem to get up to 20\% better salary}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   276
\end{textblock}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   277
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   278
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   279
\only<5->{
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   280
\begin{textblock}{1}(3,6)
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   281
\begin{bubble}[8.5cm]
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   282
\normalsize
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   283
Scala is a functional and object-oriented programming
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   284
language; compiles to the JVM; does not need null-pointer
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   285
exceptions; a course on Coursera\\
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   286
\mbox{}\hfill\url{http://www.scala-lang.org}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   287
\end{bubble}
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   288
\end{textblock}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   289
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   290
\end{frame}
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   291
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   292
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   293
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   294
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   295
\begin{frame}[t]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   296
\frametitle{A Regular Expression}
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   297
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   298
\begin{itemize}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   299
\item \ldots{} is a pattern or template for specifying strings
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   300
\end{itemize}\bigskip
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   301
  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   302
\begin{center}  
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   303
\only<1>{\scode{"https?://[^"]*"}}%
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   304
\only<2>{\scode{""""https?://[^"]*"""".r}}
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   305
\end{center}\bigskip\bigskip
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   306
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   307
matches for example\smallskip\\  
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   308
\hspace{2mm}\code{"http://www.foobar.com"}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   309
\hspace{2mm}\code{"https://www.tls.org"}\\
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   310
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   311
\end{frame}
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   312
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   313
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   314
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   315
\begin{frame}[t]
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   316
\frametitle{Finding Operations}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   317
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   318
{\bf\code{rexp.findAllIn(string)}}\medskip
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   319
  
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   320
returns a list of all (sub)strings that match the 
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   321
regular expression
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   322
\bigskip\bigskip  
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   323
  
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   324
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   325
{\bf\code{rexp.findFirstIn(string)}}\medskip
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   326
 
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   327
returns either 
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   328
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   329
\begin{itemize}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   330
\item \code{None} if no (sub)string matches or 
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   331
\item \code{Some(s)} with the first (sub)string
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   332
\end{itemize}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   333
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   334
\end{frame}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   335
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   336
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   337
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   338
\begin{frame}[c]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   339
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   340
\footnotesize
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   341
\lstinputlisting{../progs/app2.scala}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   342
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   343
\end{frame}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   344
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   345
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   346
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   347
\begin{frame}[c]
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   348
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   349
\small
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   350
A version that only crawls links in ``my'' domain:
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   351
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   352
\footnotesize
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   353
\lstinputlisting{../progs/app3.scala}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   354
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   355
\end{frame}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   356
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   357
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   358
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   359
\begin{frame}[c]
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   360
\lstset{xleftmargin=-4mm}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   361
\small
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   362
A little email harvester:
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   363
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   364
\footnotesize
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   365
\lstinputlisting{../progs/app4.scala}\bigskip
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   366
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   367
\tiny
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   368
\url{http://net.tutsplus.com/tutorials/other/8-regular-expressions-you-should-know/}
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   369
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   370
\end{frame}
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   371
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   372
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   373
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   374
\begin{frame}[t]
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   375
\frametitle{\begin{tabular}{c}Regular Expressions\end{tabular}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   376
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   377
Their inductive definition:\medskip
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   378
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   379
\begin{textblock}{6}(2,5)
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   380
  \begin{tabular}{rrl@ {\hspace{13mm}}l}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   381
  \bl{$r$} & \bl{$::=$}  & \bl{$\varnothing$}   & null\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   382
           & \bl{$\mid$} & \bl{$\epsilon$}      & empty string / \pcode{""} / \pcode{[]}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   383
           & \bl{$\mid$} & \bl{$c$}             & character\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   384
           & \bl{$\mid$} & \bl{$r_1 \cdot r_2$} & sequence\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   385
           & \bl{$\mid$} & \bl{$r_1 + r_2$}     & alternative / choice\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   386
           & \bl{$\mid$} & \bl{$r^*$}           & star (zero or more)\\
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   387
  \end{tabular}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   388
  \end{textblock}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   389
  
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   390
\end{frame}
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   391
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   392
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   393
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   394
\begin{frame}[t]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   395
\frametitle{Regular Expressions}
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   396
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   397
\small
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   398
In Scala:\bigskip
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   399
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   400
\footnotesize
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   401
\lstinputlisting{../progs/app51.scala}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   402
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   403
  
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   404
\end{frame}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   405
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   406
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   407
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   408
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   409
\begin{frame}[c]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   410
\frametitle{\begin{tabular}{c}The Meaning of a\\[-2mm] 
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   411
  Regular Expression\end{tabular}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   412
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   413
\begin{textblock}{15}(1,4)
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   414
 \begin{tabular}{rcl}
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   415
 \bl{$L(\varnothing)$}  & \bl{$\dn$} & \bl{$\varnothing$}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   416
 \bl{$L(\epsilon)$}     & \bl{$\dn$} & \bl{$\{[]\}$}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   417
 \bl{$L(c)$}            & \bl{$\dn$} & \bl{$\{[c]\}$}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   418
 \bl{$L(r_1 + r_2)$}    & \bl{$\dn$} & \bl{$L(r_1) \cup L(r_2)$}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   419
 \bl{$L(r_1 \cdot r_2)$} & \bl{$\dn$} & \bl{$\{ s_1 \,@\, s_2 \;|\; s_1 \in L(r_1) \wedge s_2 \in L(r_2) \}$}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   420
 \bl{$L(r^*)$}           & \bl{$\dn$} & \onslide<4->{\bl{$\bigcup_{n \ge 0} L(r)^n$}}\\
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   421
  \end{tabular}\bigskip
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   422
  
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   423
\onslide<2->{
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   424
\hspace{5mm}\bl{$L(r)^0 \;\dn\; \{[]\}$}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   425
\bl{$L(r)^{n+1} \;\dn\; L(r) \,@\, L(r)^n$}\hspace{9mm}\onslide<3->{\small\textcolor{gray}{(append on sets)}\\
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   426
\small\hspace{5cm}\textcolor{gray}{$\{ s_1 @ s_2 \;|\; s_1\in L(r) \wedge s_2 \in L(r)^n \}$}}
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   427
}  
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   428
    \end{textblock}
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   429
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   430
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   431
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   432
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   433
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   434
\begin{frame}[c]
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   435
\frametitle{The Meaning of Matching}
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   436
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   437
\begin{bubble}[10cm]
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   438
\large
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   439
A regular expression \bl{$r$} matches a string \bl{$s$} 
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   440
provided
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   441
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   442
\begin{center}
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   443
\bl{$s \in L(r)$}\\ 
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   444
\end{center}
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   445
\end{bubble}
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   446
254
dcd4688690ce updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 253
diff changeset
   447
\end{frame}
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   448
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   449
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   450
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   451
\mode<presentation>{
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   452
\begin{frame}[c]
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   453
\frametitle{\begin{tabular}{c}This Course\end{tabular}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   454
7
73cf4406b773 updated
Christian Urban <urbanc@in.tum.de>
parents: 6
diff changeset
   455
We will have a look at:
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   456
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   457
\begin{itemize}
7
73cf4406b773 updated
Christian Urban <urbanc@in.tum.de>
parents: 6
diff changeset
   458
\item regular expressions / regular expression matching
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   459
\item derivatives 
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   460
\item automata
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   461
\item parsing
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   462
\item grammars
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   463
\item a small interpreter / compiler
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   464
\end{itemize}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   465
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   466
\end{frame}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   467
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   468
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   469
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   470
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   471
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   472
\begin{frame}[c]
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   473
\frametitle{Written Exam}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   474
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   475
\begin{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   476
\item Accounts for 75\%.\bigskip
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   477
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   478
\item You will understand the question ``Is this relevant for
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   479
      the exam?'' is very demotivating for the lecturer!\bigskip\\
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   480
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   481
\item Deal: Whatever is in the homework (and is not marked
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   482
      ``optional'') is relevant for the exam.
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   483
\end{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   484
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   485
\end{frame}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   486
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   487
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   488
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   489
\begin{frame}[t]
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   490
\frametitle{Coursework}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   491
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   492
\begin{itemize}
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   493
\item Accounts for 25\%. Two strands. Choose \alert{\bf one}!\bigskip
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   494
\end{itemize}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   495
253
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   496
\begin{columns}[t]
\begin{column}{.5\textwidth}
\underline{\bf Strand 1}\medskip
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   497
\begin{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   498
\item four programming subtasks:
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   499
\begin{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   500
\item matcher (5\%, 13.10.) 
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   501
\item lexer (5\%, 03.11.)
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   502
\item parser (5\%, 27.11.)
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   503
\item compiler (10\%, 12.12.)
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   504
\end{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   505
\end{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   506
\end{column}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   507
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   508
\hspace{-45pt}\vrule{}\hspace{10pt}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   509
\begin{column}{.5\textwidth}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   510
\underline{\bf Strand 2}\smallskip
\begin{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   511
\item one task: prove the correctness of a regular expression matcher in 
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   512
the Isabelle theorem prover
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   513
\item 25\%, submission 12.12.
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   514
\end{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   515
\end{column}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   516
\end{columns}\medskip
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   517
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   518
\small
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   519
\begin{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   520
\item Solving more than one strand will {\bf not} give you more 
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   521
marks.\\[-2mm]
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   522
\item The exam will contain in much, much smaller form 
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   523
elements from both (but will also be in lectures and HW).
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   524
\end{itemize}
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   525
75c469893514 added coursework
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 252
diff changeset
   526
\end{frame}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   527
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   528
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   529
\end{document}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   530
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   531
%%% Local Variables:  
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   532
%%% mode: latex
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   533
%%% TeX-master: t
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   534
%%% End: 
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   535