Nondeterminism Section 4 1 Deterministic FA required for
![Nondeterminism [Section 4. 1] (Deterministic) FA required for every state q and every symbol Nondeterminism [Section 4. 1] (Deterministic) FA required for every state q and every symbol](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-1.jpg)
![Formal definition of an NFA [Section 4. 1] A nondeterministic finite automaton (NFA) is Formal definition of an NFA [Section 4. 1] A nondeterministic finite automaton (NFA) is](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-2.jpg)
![Formal definition of an NFA [Section 4. 1] Defining the computation of an NFA Formal definition of an NFA [Section 4. 1] Defining the computation of an NFA](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-3.jpg)
![NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-4.jpg)
![NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-5.jpg)
![NFA’s vs. FA’s [Section 4. 1] Thm : For every NFA M = (Q, NFA’s vs. FA’s [Section 4. 1] Thm : For every NFA M = (Q,](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-6.jpg)
![NFA’s with Example : NFA accepting a*b*c*. [Section 4. 2] NFA’s with Example : NFA accepting a*b*c*. [Section 4. 2]](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-7.jpg)
![Formal definition of an NFA- [Section 4. 2] A nondeterministic finite automaton with -transitions Formal definition of an NFA- [Section 4. 2] A nondeterministic finite automaton with -transitions](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-8.jpg)
![Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA- Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA-](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-9.jpg)
![Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA- Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA-](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-10.jpg)
![[Section 4. 2] Formal definition of an NFA- Defining the computation of an NFA- [Section 4. 2] Formal definition of an NFA- Defining the computation of an NFA-](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-11.jpg)
![NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-12.jpg)
![NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-13.jpg)
![Proof of Kleene’s Thm [Section 4. 3] Kleene’s Thm: A language L over is Proof of Kleene’s Thm [Section 4. 3] Kleene’s Thm: A language L over is](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-14.jpg)
![Proof of Kleene’s Thm [Section 4. 3] Part 2 : Any language accepted by Proof of Kleene’s Thm [Section 4. 3] Part 2 : Any language accepted by](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-15.jpg)
![Proof of Kleene’s Thm [Section 4. 3] Claim : Let M=({1, 2, 3, …, Proof of Kleene’s Thm [Section 4. 3] Claim : Let M=({1, 2, 3, …,](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-16.jpg)
- Slides: 16
![Nondeterminism Section 4 1 Deterministic FA required for every state q and every symbol Nondeterminism [Section 4. 1] (Deterministic) FA required for every state q and every symbol](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-1.jpg)
Nondeterminism [Section 4. 1] (Deterministic) FA required for every state q and every symbol of the alphabet to have exactly one arrow out of q labeled . What happens when we drop this requirement ? L = { w 2{a, b}* | w contains abba as a substring } Transition diagram (of this new type) :
![Formal definition of an NFA Section 4 1 A nondeterministic finite automaton NFA is Formal definition of an NFA [Section 4. 1] A nondeterministic finite automaton (NFA) is](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-2.jpg)
Formal definition of an NFA [Section 4. 1] A nondeterministic finite automaton (NFA) is a 5 -tuple (Q, , q 0, A, ) where - Q is a finite set of states - is a finite alphabet (input symbols) - qo 2 Q is the initial state - A µ Q is a set of accepting states - : Q£ ___ is the transition function Give a formal definition of the NFA from the previous slide.
![Formal definition of an NFA Section 4 1 Defining the computation of an NFA Formal definition of an NFA [Section 4. 1] Defining the computation of an NFA](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-3.jpg)
Formal definition of an NFA [Section 4. 1] Defining the computation of an NFA M=(Q, , q 0, A, ). Extended transition function * : Q£ * ____ : 1) For every q 2 Q, let *(q, ) = 2) For every q 2 Q, y 2 *, and 2 , let *(q, y ) = We say that a string x 2 * is accepted by M if ____. A string which is not accepted by M is rejected by M. The language accepted by M, denoted by L(M) is the set of all strings accepted by M.
![NFAs vs FAs Section 4 1 Is the following statement true For every NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-4.jpg)
NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every FA M = (Q, , q 0, A, ) there exists an NFA M 1 = (Q 1, , q 1, A 1, 1) such that L(M) = L(M 1).
![NFAs vs FAs Section 4 1 Is the following statement true For every NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-5.jpg)
NFA’s vs. FA’s [Section 4. 1] Is the following statement true ? For every NFA M = (Q, , q 0, A, ) there exists an FA M 1 = (Q 1, , q 1, A 1, 1) such that L(M) = L(M 1). Example : a a a, b b
![NFAs vs FAs Section 4 1 Thm For every NFA M Q NFA’s vs. FA’s [Section 4. 1] Thm : For every NFA M = (Q,](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-6.jpg)
NFA’s vs. FA’s [Section 4. 1] Thm : For every NFA M = (Q, , q 0, A, ) there exists an FA M 1 = (Q 1, , q 1, A 1, 1) such that L(M) = L(M 1). Construction of M 1 : Proof that L(M) = L(M 1) :
![NFAs with Example NFA accepting abc Section 4 2 NFA’s with Example : NFA accepting a*b*c*. [Section 4. 2]](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-7.jpg)
NFA’s with Example : NFA accepting a*b*c*. [Section 4. 2]
![Formal definition of an NFA Section 4 2 A nondeterministic finite automaton with transitions Formal definition of an NFA- [Section 4. 2] A nondeterministic finite automaton with -transitions](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-8.jpg)
Formal definition of an NFA- [Section 4. 2] A nondeterministic finite automaton with -transitions (NFA - ) is a 5 -tuple (Q, , q 0, A, ) where - Q is a finite set of states - is a finite alphabet (input symbols) - qo 2 Q is the initial state - A µ Q is a set of accepting states - : is the transition function Give a formal definition of the NFA- from the previous slide.
![Formal definition of an NFA Section 4 2 Defining the computation of an NFA Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA-](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-9.jpg)
Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA- M=(Q, , q 0, A, ). Extended transition function * : ____ : 1) For every q 2 Q, let *(q, ) = 2) For every q 2 Q, y 2 *, and 2 , let *(q, y ) =
![Formal definition of an NFA Section 4 2 Defining the computation of an NFA Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA-](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-10.jpg)
Formal definition of an NFA- [Section 4. 2] Defining the computation of an NFA- M=(Q, , q 0, A, ). Extended transition function * : Q£ * 2 Q : 1) For every q 2 Q, let *(q, ) = { q } 2) For every q 2 Q, y 2 *, and 2 , let *(q, y ) = -closure of a set S µ Q, denoted (S), is the set of all states reachable from S by a sequence of -transitions. Define (S) :
![Section 4 2 Formal definition of an NFA Defining the computation of an NFA [Section 4. 2] Formal definition of an NFA- Defining the computation of an NFA-](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-11.jpg)
[Section 4. 2] Formal definition of an NFA- Defining the computation of an NFA- M=(Q, , q 0, A, ). Extended transition function * : Q£ * 2 Q : 1) For every q 2 Q, let *(q, ) = { q } 2) For every q 2 Q, y 2 *, and 2 , let *(q, y ) = [p 2 *(q, y) ( (p, )) We say that a string x 2 * is accepted by M if ____. A string which is not accepted by M is rejected by M. The language accepted by M, denoted by L(M) is the set of all strings accepted by M.
![NFA s vs NFAs Section 4 2 Is the following statement true For NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-12.jpg)
NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For every NFA M = (Q, , q 0, A, ) there exists an NFA- M 1 = (Q 1, , q 1, A 1, 1) such that L(M) = L(M 1).
![NFA s vs NFAs Section 4 2 Is the following statement true For NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-13.jpg)
NFA- ’s vs. NFA’s [Section 4. 2] Is the following statement true ? For every NFA- M = (Q, , q 0, A, ) there exists an NFA M 1 = (Q 1, , q 1, A 1, 1) such that L(M) = L(M 1).
![Proof of Kleenes Thm Section 4 3 Kleenes Thm A language L over is Proof of Kleene’s Thm [Section 4. 3] Kleene’s Thm: A language L over is](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-14.jpg)
Proof of Kleene’s Thm [Section 4. 3] Kleene’s Thm: A language L over is regular iff there exists a finite automaton that accepts L. Part 1 : For every regular language there exists an NFA- accepting it.
![Proof of Kleenes Thm Section 4 3 Part 2 Any language accepted by Proof of Kleene’s Thm [Section 4. 3] Part 2 : Any language accepted by](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-15.jpg)
Proof of Kleene’s Thm [Section 4. 3] Part 2 : Any language accepted by an FA is regular. Let M=({1, 2, 3, …, k}, , q 0, A, ) be an FA. We will show that for every p, q, r 2 Q, the following language is regular : L(p, q, r) = { x 2 * | *(p, x)=q and for every prefix y of x other than and x we have *(p, y) · r } Can we then conclude that L(M) is regular ?
![Proof of Kleenes Thm Section 4 3 Claim Let M1 2 3 Proof of Kleene’s Thm [Section 4. 3] Claim : Let M=({1, 2, 3, …,](https://slidetodoc.com/presentation_image_h/f71b845f448ff2e29a22930f964e92c7/image-16.jpg)
Proof of Kleene’s Thm [Section 4. 3] Claim : Let M=({1, 2, 3, …, k}, , q 0, A, ) be an FA. For every p, q, r 2 Q, the following language is regular : L(p, q, r) = { x 2 * | *(p, x)=q and for every prefix y of x other than and x we have *(p, y) · r }