slides/slides01.tex
author Christian Urban <christian dot urban at kcl dot ac dot uk>
Sun, 01 Dec 2013 09:58:41 +0000
changeset 215 828303e8e4af
parent 98 1f3d89fe9820
child 252 e8ef8f38ca84
permissions -rw-r--r--
updated slides
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}
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
     2
\usepackage{beamerthemeplaincu}
215
828303e8e4af updated slides
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 98
diff changeset
     3
\usepackage{fontenc,xltxtra,xunicode}
95
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
     4
\defaultfontfeatures{Mapping=tex-text}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     5
\usepackage[absolute,overlay]{textpos}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     6
\usepackage{ifthen}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     7
\usepackage{tikz}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     8
\usepackage{pgf}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     9
\usepackage{calc} 
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    10
\usepackage{ulem}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    11
\usepackage{listings}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    12
\renewcommand{\uline}[1]{#1}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    13
\usetikzlibrary{arrows}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    14
\usetikzlibrary{automata}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    15
\usetikzlibrary{shapes}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    16
\usetikzlibrary{shadows}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    17
\usetikzlibrary{positioning}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    18
\usetikzlibrary{calc}
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
    19
\usetikzlibrary{plotmarks}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    20
\usepackage{graphicx} 
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
    21
\usepackage{pgfplots}
215
828303e8e4af updated slides
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 98
diff changeset
    22
\usepackage{../langs}
828303e8e4af updated slides
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 98
diff changeset
    23
\usepackage{../data}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    24
95
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
    25
\makeatletter
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
    26
\lst@CCPutMacro\lst@ProcessOther {"2D}{\lst@ttfamily{-{}}{-{}}}
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
    27
\@empty\z@\@empty
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
    28
\makeatother
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
    29
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    30
% beamer stuff 
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
    31
\renewcommand{\slidecaption}{AFL 01, King's College London, 25.~September 2013}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    32
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    33
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    34
\begin{document}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    35
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    36
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    37
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    38
\begin{frame}<1>[t]
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    39
\frametitle{%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    40
  \begin{tabular}{@ {}c@ {}}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    41
  \\[-3mm]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    42
  \LARGE Automata and \\[-2mm] 
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    43
  \LARGE Formal Languages (1)\\[-3mm] 
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    44
  \end{tabular}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    45
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    46
  \begin{center}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    47
  \includegraphics[scale=0.3]{pics/ante1.jpg}\hspace{5mm}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    48
  \includegraphics[scale=0.31]{pics/ante2.jpg}\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    49
  \footnotesize\textcolor{gray}{Antikythera automaton, 100 BC (Archimedes?)}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    50
  \end{center}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    51
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    52
\normalsize
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    53
  \begin{center}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    54
  \begin{tabular}{ll}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    55
  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
    56
  Office: & S1.27 (1st floor Strand Building)\\
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    57
  Slides: & KEATS
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    58
  \end{tabular}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    59
  \end{center}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    60
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    61
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    62
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    63
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    64
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    65
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    66
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    67
\begin{frame}[c]
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    68
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    69
\begin{textblock}{1}(2,5)
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    70
\begin{tabular}{c}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    71
\includegraphics[scale=0.15]{pics/servers.png}\\[-2mm]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    72
\small Server
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    73
\end{tabular}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    74
\end{textblock}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    75
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    76
\begin{textblock}{1}(5.6,4)
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    77
  \begin{tikzpicture}[scale=1.1]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    78
  \draw[white] (0,1) node (X) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    79
  \draw[white] (2,1) node (Y) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    80
   \draw[white] (0,0) node (X1) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    81
  \draw[white] (2,0) node (Y1) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    82
   \draw[white] (0,-1) node (X2) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    83
  \draw[white] (2,-1) node (Y2) {};
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    84
  \draw[red, <-, line width = 2mm] (X) -- (Y);
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    85
  \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
    86
  \draw[red, ->, line width = 2mm] (X1) -- (Y1);
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    87
  \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
    88
  \draw[red, <-, line width = 2mm] (X2) -- (Y2);
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    89
  \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
    90
  \end{tikzpicture}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    91
\end{textblock}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    92
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    93
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    94
\begin{textblock}{1}(9,5.5)
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    95
\begin{tabular}{c}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    96
\includegraphics[scale=0.15]{pics/laptop.png}\\[-2mm]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
    97
\small Browser
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    98
\end{tabular}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    99
\end{textblock}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   100
  
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   101
\only<2>{  
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   102
\begin{textblock}{10}(2,13.5)
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   103
\begin{itemize}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   104
\item programming languages, compilers
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   105
\end{itemize}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   106
\end{textblock}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   107
  
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   108
  
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   109
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   110
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   111
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   112
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   113
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   114
\begin{frame}[c]
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   115
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   116
transforming strings into structured data\\[10mm]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   117
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   118
{\LARGE\bf Lexing}\medskip\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   119
\hspace{5mm}(recognising ``words'')\\[6mm]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   120
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   121
{\LARGE\bf Parsing}\medskip\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   122
\hspace{5mm}(recognising ``sentences'')
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   123
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   124
\end{frame}}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   125
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   126
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   127
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   128
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   129
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   130
\begin{frame}[c]
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   131
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   132
The subject is quite old:
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   133
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   134
\begin{itemize}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   135
\item Turing Machines, 1936
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   136
\item first compiler for COBOL, 1957 (Grace Hopper)
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   137
\item but surprisingly research papers are still published now
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   138
\end{itemize}
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{flushright}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   141
\includegraphics[scale=0.3]{pics/hopper.jpg}\\
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   142
\footnotesize\textcolor{gray}{Grace Hopper}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   143
\end{flushright}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   144
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   145
{\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
   146
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   147
\end{frame}}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   148
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   149
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   150
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   151
\mode<presentation>{
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   152
\begin{frame}[c]
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   153
\frametitle{\begin{tabular}{c}This Course\end{tabular}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   154
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   155
\begin{itemize}
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   156
\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
   157
\end{itemize}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   158
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   159
Let's start with:
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   160
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   161
\begin{itemize}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   162
\item a web-crawler
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   163
\item an email harvester
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   164
\item a web-scraper
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   165
\end{itemize}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   166
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   167
\begin{textblock}{6}(10,7)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   168
\begin{tikzpicture}[scale=0.38]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   169
\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
   170
    xlabel=n,
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   171
    enlargelimits=0.05,
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   172
    ybar interval=0.7, legend style=small]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   173
\addplot file {interpreted2.data};
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   174
\addplot file {compiled2.data};
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   175
%\legend{interpreted, compiled}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   176
\end{axis}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   177
\end{tikzpicture}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   178
\end{textblock}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   179
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   180
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   181
\end{frame}}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   182
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   183
2
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]
13
Christian Urban <urbanc@in.tum.de>
parents: 8
diff changeset
   187
\frametitle{\begin{tabular}{c}A Web-Crawler\end{tabular}}
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
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   191
\begin{enumerate}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   192
\item given an URL, read the corresponding webpage
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   193
\item extract all links from it
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   194
\item call the web-crawler again for all these links
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   195
\end{enumerate}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   196
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   197
\end{frame}}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   198
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   199
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
\mode<presentation>{
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   202
\begin{frame}[t]
13
Christian Urban <urbanc@in.tum.de>
parents: 8
diff changeset
   203
\frametitle{\begin{tabular}{c}A Web-Crawler\end{tabular}}
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   204
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   205
\mbox{}\\[10mm]
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   206
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   207
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   208
\begin{enumerate}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   209
\item given an URL, read the corresponding webpage
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   210
\item if not possible print, out a problem
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   211
\item if possible, extract all links from it
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   212
\item call the web-crawler again for all these links
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   213
\end{enumerate}\bigskip\pause
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   214
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   215
\small (we need a bound for the number of recursive calls)
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   216
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   217
\small (the purpose is to check all links on my own webpage)
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   218
\end{frame}}
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   219
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   220
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   221
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   222
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   223
\begin{frame}[c]
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   224
\frametitle{\begin{tabular}{c}Scala\end{tabular}}
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   225
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   226
\small a simple Scala function for reading webpages\\[-3mm]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   227
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   228
\footnotesize
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   229
{\lstset{language=Scala}\texttt{\lstinputlisting{../progs/app0.scala}}}\pause
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   230
{\lstset{language=Scala}\texttt{\lstinline{get_page("""http://www.inf.kcl.ac.uk/staff/urbanc/""")}}}\pause\bigskip
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   231
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   232
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   233
\small slightly more complicated for handling errors properly:\\[-3mm]
2
6e7da958ba8c updated
Christian Urban <urbanc@in.tum.de>
parents: 1
diff changeset
   234
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   235
\footnotesize
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   236
{\lstset{language=Scala}\texttt{\lstinputlisting{../progs/app1.scala}}}
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   237
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   238
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   239
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   240
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   241
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   242
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   243
\mode<presentation>{
98
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   244
\begin{frame}[c]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   245
\frametitle{\begin{tabular}{c}Why Scala?\end{tabular}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   246
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   247
\begin{textblock}{6}(1,3)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   248
\begin{tabular}{l}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   249
\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
   250
\includegraphics[scale=0.30]{pics/linked.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   251
\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
   252
\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
   253
\includegraphics[scale=0.30]{pics/suisse.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   254
\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
   255
\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
   256
\includegraphics[scale=0.30]{pics/foursquare.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   257
\includegraphics[scale=0.30]{pics/hsbc.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   258
{\large\bf ...}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   259
\end{tabular}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   260
\end{textblock}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   261
 
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   262
\only<2->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   263
\begin{textblock}{6}(6,3)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   264
\includegraphics[scale=0.35]{pics/jobgraph.png}\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   265
\end{textblock}}  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   266
  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   267
\only<3->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   268
\begin{textblock}{6}(7.3,9.2)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   269
\begin{tabular}{l}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   270
\footnotesize 2013: 1$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   271
\footnotesize 2014: 3$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   272
\footnotesize 2015: 9$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   273
\footnotesize 2016: 27$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   274
\footnotesize 2017: 81$\%$\\[-2mm]
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   275
\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
   276
\end{tabular}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   277
\end{textblock}} 
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<3->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   280
\begin{textblock}{6}(6,9.5)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   281
\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
   282
\end{textblock}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   283
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   284
\only<4->{  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   285
\begin{textblock}{11}(5,14.1)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   286
\textcolor{gray}{
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   287
\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
   288
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
   289
\end{textblock}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   290
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
\only<5->{
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   293
\begin{textblock}{1}(3,6)
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   294
\begin{tikzpicture}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   295
\draw (0,0) node[inner sep=2mm,fill=cream, ultra thick, draw=red, rounded corners=2mm] 
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   296
{\normalsize\color{darkgray}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   297
\begin{minipage}{8.5cm}\raggedright\normalsize
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   298
Scala is a functional and object-oriented programming language; compiles to the JVM; does not 
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   299
need null-pointer exceptions; a course on Coursera\\
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   300
\mbox{}\hfill\textcolor{blue}{\url{http://www.scala-lang.org}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   301
\end{minipage}};
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   302
\end{tikzpicture}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   303
\end{textblock}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   304
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   305
  
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   306
\end{frame}}
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   307
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   308
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   309
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   310
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1f3d89fe9820 updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 97
diff changeset
   311
\mode<presentation>{
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   312
\begin{frame}[t]
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   313
\frametitle{\begin{tabular}{c}A Regular Expression\end{tabular}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   314
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   315
\begin{itemize}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   316
\item \ldots{} is a pattern or template for specifying strings
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   317
\end{itemize}\bigskip
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   318
  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   319
\begin{center}  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   320
\only<1>{{\lstset{language=Scala}\fontsize{18}{19}\selectfont\bf
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   321
\texttt{"https?://[$\hat{\hspace{2mm}}$"]*"}}}%
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   322
\only<2>{{\lstset{language=Scala}\fontsize{18}{19}\selectfont\bf
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   323
\texttt{"""\textbackslash{}"https?://[$\hat{\hspace{2mm}}$\textbackslash{}"]*\textbackslash{}"""".r}}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   324
\end{center}\bigskip\bigskip
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   325
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   326
matches for example\\  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   327
\;{\lstset{language=Scala}\fontsize{12}{14}\selectfont\bf
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   328
\texttt{"http://www.foobar.com"}}\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   329
\;{\lstset{language=Scala}\fontsize{12}{14}\selectfont\bf
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   330
\texttt{"https://www.tls.org"}}\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   331
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   332
\end{frame}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   333
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   334
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   335
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   336
\mode<presentation>{
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   337
\begin{frame}[c]
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   338
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   339
{\lstset{language=Scala}\fontsize{18}{19}\selectfont\bf
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   340
\texttt{rexp.findAllIn(string)}}\medskip
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   341
  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   342
returns a list of all (sub)strings that match the regular expression\bigskip\bigskip  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   343
  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   344
{\lstset{language=Scala}\fontsize{18}{19}\selectfont\bf
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   345
\texttt{rexp.findFirstIn(string)}}\medskip
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   346
  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   347
returns either {\bf\texttt{None}} if no (sub)string matches 
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   348
or {\bf\texttt{Some(s)}} with the first (sub)string
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   349
  
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   350
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   351
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   352
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   353
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   354
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   355
\begin{frame}[c]
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   356
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   357
\small
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   358
{\lstset{language=Scala}\texttt{\lstinputlisting{../progs/app2.scala}}}\medskip
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   359
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   360
{\lstset{language=Scala}\texttt{crawl(some\_start\_URL, 2)}}\
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   361
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   362
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   363
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   364
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   365
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   366
\mode<presentation>{
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   367
\begin{frame}[c]
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   368
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   369
\footnotesize
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   370
a version that only ``crawls'' links in my domain:
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   371
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   372
\small
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   373
{\lstset{language=Scala}\texttt{\lstinputlisting{../progs/app3.scala}}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   374
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   375
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   376
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   377
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   378
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   379
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   380
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   381
\begin{frame}[c]
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   382
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   383
\footnotesize
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   384
a little email ``harvester'':
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   385
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   386
\small
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   387
{\lstset{language=Scala}\texttt{\lstinputlisting{../progs/app4.scala}}}\bigskip
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   388
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   389
\tiny
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   390
\textcolor{gray}{\url{http://net.tutsplus.com/tutorials/other/8-regular-expressions-you-should-know/}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   391
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   392
\end{frame}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   393
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   394
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   395
\newcommand{\bl}[1]{\textcolor{blue}{#1}}       
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   396
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   397
\mode<presentation>{
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   398
\begin{frame}[t]
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   399
\frametitle{\begin{tabular}{c}Regular Expressions\end{tabular}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   400
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   401
Their inductive definition:\medskip
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   402
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   403
\begin{textblock}{6}(2,5)
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   404
  \begin{tabular}{@ {}rrl@ {\hspace{13mm}}l}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   405
  \bl{r} & \bl{$::=$}  & \bl{$\varnothing$}  & null\\
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   406
         & \bl{$\mid$} & \bl{$\epsilon$}        & empty string / "" / []\\
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   407
         & \bl{$\mid$} & \bl{c}                         & character\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   408
         & \bl{$\mid$} & \bl{r$_1$ $\cdot$ r$_2$} & sequence\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   409
         & \bl{$\mid$} & \bl{r$_1$ + r$_2$}  & alternative / choice\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   410
         & \bl{$\mid$} & \bl{r$^*$}                   & star (zero or more)\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   411
  \end{tabular}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   412
  \end{textblock}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   413
  
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   414
\end{frame}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   415
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   416
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   417
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   418
\mode<presentation>{
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   419
\begin{frame}[t]
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   420
\frametitle{\begin{tabular}{c}Regular Expressions\end{tabular}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   421
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   422
\small
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   423
In Scala:
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   424
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   425
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   426
{\lstset{language=Scala}\fontsize{8}{10}\selectfont
95
dbe49327b6c5 added new stuff
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 93
diff changeset
   427
\texttt{\lstinputlisting{../progs/app51.scala}}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   428
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   429
  
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
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   433
\newcommand{\dn}{\stackrel{\mbox{\scriptsize def}}{=}}% for definitions
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   434
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   435
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   436
\begin{frame}[c]
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   437
\frametitle{\begin{tabular}{c}The Meaning of a\\[-2mm] Regular Expression\end{tabular}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   438
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   439
\begin{textblock}{15}(1,4)
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   440
 \begin{tabular}{@ {}rcl}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   441
 \bl{$L$($\varnothing$)}  & \bl{$\dn$} & \bl{$\varnothing$}\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   442
 \bl{$L$($\epsilon$)}        & \bl{$\dn$} & \bl{$\{$""$\}$}\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   443
 \bl{$L$(c)}                         & \bl{$\dn$} & \bl{$\{$"c"$\}$}\\
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   444
 \bl{$L$(r$_1$ + r$_2$)} & \bl{$\dn$} & \bl{$L$(r$_1$) $\cup$ $L$(r$_2$)}\\
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   445
 \bl{$L$(r$_1$ $\cdot$ r$_2$)}  & \bl{$\dn$} & \bl{$\{$ s$_1$ @ s$_2$ $|$ s$_1$ $\in$ $L$(r$_1$) $\wedge$ s$_2$ $\in$ 
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   446
     $L$(r$_2$) $\}$}\\
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   447
 \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
   448
  \end{tabular}\bigskip
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   449
  
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   450
\onslide<2->{
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   451
\hspace{5mm}\bl{$L$(r)$^0$ $\;\dn\;$ $\{$""$\}$}\\
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   452
\bl{$L$(r)$^{n+1}$ $\;\dn\;$ $L$(r) @ $L$(r)$^n$}\hspace{9mm}\onslide<3->{\small\textcolor{gray}{(append on sets)}\\
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   453
\small\hspace{5cm}\textcolor{gray}{$\{$ s$_1$ @ s$_2$ $|$ s$_1$ $\in$ $L$(r) $\wedge$ s$_2$ $\in$ 
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   454
     $L$(r)$^n$ $\}$}}
4
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   455
}  
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   456
    \end{textblock}
Christian Urban <urbanc@in.tum.de>
parents: 3
diff changeset
   457
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   458
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   459
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   460
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   461
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   462
\mode<presentation>{
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   463
\begin{frame}[c]
8
Christian Urban <urbanc@in.tum.de>
parents: 7
diff changeset
   464
\frametitle{\begin{tabular}{c}The Meaning of Matching\end{tabular}}
5
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   465
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   466
\large
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   467
a regular expression \bl{r} matches a string \bl{s} is defined as
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   468
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   469
\begin{center}
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   470
\bl{s $\in$ $L$(r)}\\ 
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   471
\end{center}
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   472
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   473
\end{frame}}
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   474
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 4
diff changeset
   475
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   476
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   477
\mode<presentation>{
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   478
\begin{frame}[c]
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   479
\frametitle{\begin{tabular}{c}This Course\end{tabular}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   480
7
73cf4406b773 updated
Christian Urban <urbanc@in.tum.de>
parents: 6
diff changeset
   481
We will have a look at:
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   482
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   483
\begin{itemize}
7
73cf4406b773 updated
Christian Urban <urbanc@in.tum.de>
parents: 6
diff changeset
   484
\item regular expressions / regular expression matching
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   485
\item derivatives 
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   486
\item automata
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   487
\item parsing
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   488
\item grammars
97
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents: 95
diff changeset
   489
\item a small interpreter / compiler
3
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   490
\end{itemize}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   491
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   492
\end{frame}}
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   493
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
Christian Urban <urbanc@in.tum.de>
parents: 2
diff changeset
   494
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   495
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   496
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   497
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   498
\mode<presentation>{
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   499
\begin{frame}[c]
1
b606c9439fa6 new version
Christian Urban <urbanc@in.tum.de>
parents: 0
diff changeset
   500
\frametitle{\begin{tabular}{c}Exam\end{tabular}}
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   501
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   502
\begin{itemize}
7
73cf4406b773 updated
Christian Urban <urbanc@in.tum.de>
parents: 6
diff changeset
   503
\item The question ``Is this relevant for the exam?'' is not appreciated!\bigskip\\
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   504
14
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   505
Whatever is in the homework sheets (and is not marked ``optional'') is relevant for the
Christian Urban <urbanc@in.tum.de>
parents: 13
diff changeset
   506
exam.\\ No code needs to be written in the exam.
0
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   507
\end{itemize}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   508
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   509
\end{frame}}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   510
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   511
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   512
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   513
\end{document}
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   514
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   515
%%% Local Variables:  
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   516
%%% mode: latex
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   517
%%% TeX-master: t
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   518
%%% End: 
3a5e09a2ae54 initial comit
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
   519