slides/slides02.tex
changeset 120 3e71efb25ce9
parent 119 a6684e8961d0
child 121 43c116860e47
equal deleted inserted replaced
119:a6684e8961d0 120:3e71efb25ce9
   763 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
   763 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
   764 
   764 
   765 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   765 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   766 \mode<presentation>{
   766 \mode<presentation>{
   767 \begin{frame}[c]
   767 \begin{frame}[c]
   768 \frametitle{\begin{tabular}{c}Problem\end{tabular}}
   768 \frametitle{\begin{tabular}{c}A Problem\end{tabular}}
   769 
   769 
   770 We represented ``n-times'' as a sequence regular expression:
   770 We represented the ``n-times'' \bl{$a\{n\}$} as a sequence regular expression:
   771 
   771 
   772 \begin{center}
   772 \begin{center}
   773 \begin{tabular}{ll}
   773 \begin{tabular}{rl}
   774 1:
   774 1: & \bl{$a$}\\
       
   775 2: & \bl{$a\cdot a$}\\
       
   776 3: & \bl{$a\cdot a\cdot a$}\\
       
   777 & \ldots\\
       
   778 13: & \bl{$a\cdot a\cdot a\cdot a\cdot a\cdot a\cdot a\cdot a\cdot a\cdot a\cdot a\cdot a\cdot a$}\\
       
   779 & \ldots\\
       
   780 20:
   775 \end{tabular}
   781 \end{tabular}
   776 \end{center}
   782 \end{center}
   777 
   783 
   778 \end{frame}}
   784 This problem is aggravated with \bl{$a?$} being represented as \bl{$\epsilon + a$}.
   779 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
   785 \end{frame}}
       
   786 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
       
   787 
       
   788 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
       
   789 \mode<presentation>{
       
   790 \begin{frame}[c]
       
   791 \frametitle{\begin{tabular}{c}Solving the Problem\end{tabular}}
       
   792 
       
   793 What happens if we extend our regular expressions
       
   794 
       
   795 \begin{center}
       
   796 \begin{tabular}{rcl}
       
   797 \bl{$r$} & \bl{$::=$} & \bl{\ldots}\\
       
   798              & \bl{$\mid$} & \bl{$r\{n\}$}\\
       
   799              & \bl{$\mid$} & \bl{$r?$} 
       
   800 \end{tabular}
       
   801 \end{center}
       
   802 
       
   803 What is their meaning? What are the cases for \bl{$nullable$} and \bl{$der$}?
       
   804 \end{frame}}
       
   805 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
       
   806 
   780 
   807 
   781 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   808 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   782 \mode<presentation>{
   809 \mode<presentation>{
   783 \begin{frame}[t]
   810 \begin{frame}[t]
   784 \frametitle{\begin{tabular}{c}\bl{$(a?\{n\}) \cdot a\{n\}$}\end{tabular}}
   811 \frametitle{\begin{tabular}{c}\bl{$(a?\{n\}) \cdot a\{n\}$}\end{tabular}}