# HG changeset patch # User Christian Urban # Date 1382746941 -3600 # Node ID 77e8397ec2ecaf31cb79be5cc7b95e150fb82392 # Parent b6eee9571a63b3dec3e56f5dada15b9f6ab25c79 added diff -r b6eee9571a63 -r 77e8397ec2ec handouts/ho05.pdf Binary file handouts/ho05.pdf has changed diff -r b6eee9571a63 -r 77e8397ec2ec handouts/ho05.tex --- a/handouts/ho05.tex Sat Oct 26 01:02:59 2013 +0100 +++ b/handouts/ho05.tex Sat Oct 26 01:22:21 2013 +0100 @@ -228,14 +228,25 @@ \noindent In contrast to the function $nullable(r)$, which test whether a regular expression can match the empty string, the $zeroable$ function identifies whether a regular -expression cannot match anything at all. +expression cannot match anything at all. The mathematical way of stating this +is \begin{center} -\texttt{\Grid{$c_1$\VS{} true\VS{} then\VS{} x\VS{} else\VS{} y \ldots }} +$s \in zeroable(s)$ implies $L(r) = \varnothing$ \end{center} \noindent -The crucial idea of the algorithm is to build the derivative of all +Let us fix a set of regular expressions $rs$. +The crucial idea of the algorithm is to take the input string, say + +\begin{center} +\texttt{\grid{$c_1$}\grid{$c_2$}\grid{$c_3$}\grid{$c_4$}\grid{\ldots}} +\end{center} + +\noindent +and build the derivative of all regular expressions in $rs$ with respect +to the first character. Then we take the result and continue with $c_2$ +until we have either exhausted our input string or all of the regula \end{document}