SlideShare a Scribd company logo
13
Most read
14
Most read
15
Most read
1
Recap Lecture 4
Regular expression of EVEN-EVEN language,
Difference between a* + b* and (a+b)*,
Equivalent regular expressions; sum, product
and closure of regular expressions; regular
languages, finite languages are regular,
introduction to finite automaton, definition of FA,
transition table, transition diagram.
2
Note
It may be noted that to indicate the initial state,
an arrow head can also be placed before that
state and that the final state with double circle,
as shown below. It is also to be noted that while
expressing an FA by its transition diagram, the
labels of states are not necessary.
a, b
a, b
3
Example
Σ = {a,b}
States: x, y, where x is both initial and final
state.
Transitions:
1.At state x reading a or b go to state y.
2.At state y reading a or b go to state x.
4
Example Continued …
These transitions can be expressed by the
following transition table
Old States New States
Reading
a
Reading
b
x ± y y
y x x
5
Example Continued …
It may be noted that the previous transition table
may be depicted by the following transition
diagram.
y
a, b
x ±
a, b
6
Example Continued …
The previous transition diagram is an FA
accepting the language of strings, defined over
Σ={a, b} of even length. It may be noted that
this language may be expressed by the regular
expression
((a+ b) (a + b))*
7
TASK
Build an FA for the language L of strings,
defined over Σ={a, b}, of odd length.
8
Solution of Task
+
a,b
–
a,b
9
Example: Consider the language L of strings,
defined over Σ={a, b}, starting with b. The
language L may be expressed by RE b(a + b)*
,
may be accepted by the following FA
a,b
a,b
b
a
–– +
1
10
Example:
Consider the language L of strings, defined
over Σ={a, b}, ending in a. The language L
may be expressed by RE
(a+b)*
a
This language may be accepted by the following
FA
11
Example Continued …
There may be another FA corresponding to the
given language.
ab
+
b
–
a
12
Example continued …
a
b
b
ba
+
a
––
13
Note
It may be noted that corresponding to a given
language there may be more than one FA
accepting that language, but for a given FA
there is a unique language accepted by that FA.
14
Note
It is to be noted that given the languages L1
and
L2
,where
L1
= The language of strings, defined over
Σ={a, b}, beginning with a
L2
= The language of strings, defined over
Σ={a, b}, not beginning with b
The Λ does not belong to L1
while it does belong to
L2
. This fact may be depicted by the
corresponding transition diagrams of L1
and L2
.
15
FA1
Corresponding to L1
The language L1
may be expressed by the
regular expression a(a + b)*
a,b
a
b a,b
–– +
16
FA2
Corresponding to L2
The language L2
may be expressed by the
regular expression a (a + b)*
+ Λ
a,b
a,b
a
b
± +
17
Example
Consider the Language L of Strings of length
two or more, defined over Σ = {a, b},
beginning with and ending in same
letters.
The language L may be expressed by the
following regular expression
a (a + b)*
a + b (a + b)*
b
It is to be noted that if the condition on the
length of string is not imposed in the above
language then the strings a and b will then
belong to the language.
This language L may be accepted by the
18
Example Continued …
b
a
a
b
+
ab
b
a
+
b
a–
19
Task
Build an FA accepting the Language L of
Strings, defined over Σ = {a, b}, beginning
with and ending in same letters.
20
Summing Up
Different notations of transition diagrams,
languages of strings of even length, Odd
length, starting with b, ending in a,
beginning with b, not beginning with b,
beginning and ending in same letters;

More Related Content

PPT
PPT
Lecture 3,4
PPT
Lecture 6
PPT
PPT
Lecture 5
PPT
Theory of Automata Lesson 02
PPT
PPT
Lecture 1,2
Lecture 3,4
Lecture 6
Lecture 5
Theory of Automata Lesson 02
Lecture 1,2

What's hot (20)

PPT
Lecture 8
PPT
Lesson 03
PPT
Lecture 7
PPT
PPT
DOC
Generalized transition graphs
DOCX
Automata theory
PPT
Lecture 3,4
PPTX
Deterministic Finite Automata
PPT
Theory of Automata
PDF
Language
PPT
PPTX
Theory of automata and formal language
PDF
Flat unit 3
PPTX
Regular expressions
PDF
Chapter1 Formal Language and Automata Theory
PPTX
Context Free Grammar
DOCX
Introduction to Computer theory (Automata Theory) 2nd Edition By Denial I.A. ...
PPT
PPT
Kleene's theorem
Lecture 8
Lesson 03
Lecture 7
Generalized transition graphs
Automata theory
Lecture 3,4
Deterministic Finite Automata
Theory of Automata
Language
Theory of automata and formal language
Flat unit 3
Regular expressions
Chapter1 Formal Language and Automata Theory
Context Free Grammar
Introduction to Computer theory (Automata Theory) 2nd Edition By Denial I.A. ...
Kleene's theorem
Ad

Similar to Lesson 05 (20)

PPT
PPT
Theory of Automata Power Point Slides Lecture 05.ppt
PPTX
DFA Assignment solution.pptx
PPT
To lec 03
PDF
Equal regular expression / for theory of automsta.pdf
PPTX
Resumen material MIT
PDF
F_Autómatas_MIT_2010--------------------
PPTX
introductory Discrete structure workshop.pptx
PPTX
Formal methods 2 - languages and machines
PPTX
Theory of automata and formal language
PPT
Closure Properties of Regular Languages.ppt
PDF
Automata_Theory_and_compiler_design_UNIT-1.pptx.pdf
PPTX
Unit2 Toc.pptx
PPTX
theory of computaion Finite Automata.pptx
PPT
Finite automata(For college Seminars)
PDF
Lecture: Regular Expressions and Regular Languages
PDF
Chapter 3 REGULAR EXPRESSION.pdf
PPTX
BCS503 TOC Module 2 PPT.pptx VTU academic Year 2024-25 ODD SEM
PPTX
Chapter 4_Regular Expressions in Automata.pptx
PPT
Compiler Design in Engineering for Designing
Theory of Automata Power Point Slides Lecture 05.ppt
DFA Assignment solution.pptx
To lec 03
Equal regular expression / for theory of automsta.pdf
Resumen material MIT
F_Autómatas_MIT_2010--------------------
introductory Discrete structure workshop.pptx
Formal methods 2 - languages and machines
Theory of automata and formal language
Closure Properties of Regular Languages.ppt
Automata_Theory_and_compiler_design_UNIT-1.pptx.pdf
Unit2 Toc.pptx
theory of computaion Finite Automata.pptx
Finite automata(For college Seminars)
Lecture: Regular Expressions and Regular Languages
Chapter 3 REGULAR EXPRESSION.pdf
BCS503 TOC Module 2 PPT.pptx VTU academic Year 2024-25 ODD SEM
Chapter 4_Regular Expressions in Automata.pptx
Compiler Design in Engineering for Designing
Ad

Recently uploaded (20)

PPTX
Geodesy 1.pptx...............................................
PPTX
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
PPTX
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
PPTX
Internet of Things (IOT) - A guide to understanding
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PPTX
Strings in CPP - Strings in C++ are sequences of characters used to store and...
PPTX
bas. eng. economics group 4 presentation 1.pptx
PPT
Mechanical Engineering MATERIALS Selection
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PPTX
OOP with Java - Java Introduction (Basics)
PDF
Digital Logic Computer Design lecture notes
PDF
Well-logging-methods_new................
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
DOCX
573137875-Attendance-Management-System-original
PPTX
Lecture Notes Electrical Wiring System Components
PPTX
Construction Project Organization Group 2.pptx
PPTX
CYBER-CRIMES AND SECURITY A guide to understanding
PDF
PPT on Performance Review to get promotions
Geodesy 1.pptx...............................................
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
Internet of Things (IOT) - A guide to understanding
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
Strings in CPP - Strings in C++ are sequences of characters used to store and...
bas. eng. economics group 4 presentation 1.pptx
Mechanical Engineering MATERIALS Selection
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
Model Code of Practice - Construction Work - 21102022 .pdf
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
OOP with Java - Java Introduction (Basics)
Digital Logic Computer Design lecture notes
Well-logging-methods_new................
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
573137875-Attendance-Management-System-original
Lecture Notes Electrical Wiring System Components
Construction Project Organization Group 2.pptx
CYBER-CRIMES AND SECURITY A guide to understanding
PPT on Performance Review to get promotions

Lesson 05

  • 1. 1 Recap Lecture 4 Regular expression of EVEN-EVEN language, Difference between a* + b* and (a+b)*, Equivalent regular expressions; sum, product and closure of regular expressions; regular languages, finite languages are regular, introduction to finite automaton, definition of FA, transition table, transition diagram.
  • 2. 2 Note It may be noted that to indicate the initial state, an arrow head can also be placed before that state and that the final state with double circle, as shown below. It is also to be noted that while expressing an FA by its transition diagram, the labels of states are not necessary. a, b a, b
  • 3. 3 Example Σ = {a,b} States: x, y, where x is both initial and final state. Transitions: 1.At state x reading a or b go to state y. 2.At state y reading a or b go to state x.
  • 4. 4 Example Continued … These transitions can be expressed by the following transition table Old States New States Reading a Reading b x ± y y y x x
  • 5. 5 Example Continued … It may be noted that the previous transition table may be depicted by the following transition diagram. y a, b x ± a, b
  • 6. 6 Example Continued … The previous transition diagram is an FA accepting the language of strings, defined over Σ={a, b} of even length. It may be noted that this language may be expressed by the regular expression ((a+ b) (a + b))*
  • 7. 7 TASK Build an FA for the language L of strings, defined over Σ={a, b}, of odd length.
  • 9. 9 Example: Consider the language L of strings, defined over Σ={a, b}, starting with b. The language L may be expressed by RE b(a + b)* , may be accepted by the following FA a,b a,b b a –– + 1
  • 10. 10 Example: Consider the language L of strings, defined over Σ={a, b}, ending in a. The language L may be expressed by RE (a+b)* a This language may be accepted by the following FA
  • 11. 11 Example Continued … There may be another FA corresponding to the given language. ab + b – a
  • 13. 13 Note It may be noted that corresponding to a given language there may be more than one FA accepting that language, but for a given FA there is a unique language accepted by that FA.
  • 14. 14 Note It is to be noted that given the languages L1 and L2 ,where L1 = The language of strings, defined over Σ={a, b}, beginning with a L2 = The language of strings, defined over Σ={a, b}, not beginning with b The Λ does not belong to L1 while it does belong to L2 . This fact may be depicted by the corresponding transition diagrams of L1 and L2 .
  • 15. 15 FA1 Corresponding to L1 The language L1 may be expressed by the regular expression a(a + b)* a,b a b a,b –– +
  • 16. 16 FA2 Corresponding to L2 The language L2 may be expressed by the regular expression a (a + b)* + Λ a,b a,b a b ± +
  • 17. 17 Example Consider the Language L of Strings of length two or more, defined over Σ = {a, b}, beginning with and ending in same letters. The language L may be expressed by the following regular expression a (a + b)* a + b (a + b)* b It is to be noted that if the condition on the length of string is not imposed in the above language then the strings a and b will then belong to the language. This language L may be accepted by the
  • 19. 19 Task Build an FA accepting the Language L of Strings, defined over Σ = {a, b}, beginning with and ending in same letters.
  • 20. 20 Summing Up Different notations of transition diagrams, languages of strings of even length, Odd length, starting with b, ending in a, beginning with b, not beginning with b, beginning and ending in same letters;