-
Notifications
You must be signed in to change notification settings - Fork 0
/
lec7.tex
91 lines (82 loc) · 2.2 KB
/
lec7.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
%% notes on web page
\subsection{Non-Regular Languages}
\label{subsec:nonreg_lang}
% --------------------------------------------------
Are there non-regular languages?
The answer is obviously ``Yes,'' but what are they?
Take binary strings as example, find
$L \subseteq \set{0,1}^*\ \text{s.t.}\ \forall\ \text{regex}\ E, L(E) \neq L$.
With symbols
$\set{ 0,1,\cdot,+(\cup),*,(,),\varnothing }$,
any regular language can be expressed,
\[
E = (0+1)^*.
\]
Map each of the symbols to
$
0 = 000,
1 = 001,
\cdot = 010,
\cdots
\varnothing = 111
$
and use function $\varphi$ to rewrite the regex above,
\[
\varphi(E) = 101\,000\,011\,001\,110\,100 \qquad \in \set{0,1}^*
\]
so
$
L(E) \subseteq \set{0,1}^*.
$
Then the non-regular language is
\[
L = \set{ \varphi(E) \mid \varphi(E) \notin L(E) },
\]
which is called the diagonal language (see \autoref{def:diagonal_language}).
\begin{definition}[Diagonal Language]
\label{def:diagonal_language}
\[
D = \set{
\varphi(E)
\mid
E \in \text{regex}\(\set{0,1}\) , \varphi(E) \notin L(E)
}
\]
\end{definition}
\begin{proof}[
Proof of $\varphi(''\varnothing'') = ''111'' \notin L(\varnothing) = \varnothing$
]
Assume for contradiction $L$ is regular, \\
Let $E$ s.t.\ $L(E) = L$. \\
\[
\varphi(E) \in L \leftrightarrow \varphi(E) \notin L(E) = L.
\]
\end{proof}
\subsection{Pumping Lemma}
% --------------------------------------------------
Every regular language satisfies property $P$,
if a language $L$ does not satisfy $P$ then $L$ is non-regular.
In proving, we will first assume $P(L)$ and lead to contradiction.
\begin{definition}[Property $P$]
\begin{align*}
&\exists p \ge 1 \qquad \text{(pumping length)} \\
&\forall w \in L, \abs{w} \ge p \\
&\exists x,y,z \in \Sigma^*, w = x \cdot y \cdot z
\end{align*}
and
\begin{compactitem}
\item
$
\forall i \ge 0, \quad
x \cdot y^i \cdot z = x \overbrace{yy \cdots y}^i z \in L
$,
\item
$
\abs{y} \ge 0 ( y \neq \varepsilon )
$,
\item
$
\abs{xy} \le p
$.
\end{compactitem}
\end{definition}