Finite Automata Part One

Size: px
Start display at page:

Download "Finite Automata Part One"

Transcription

1 Finite Automata Part One

2 Computability Theory

3 What problems can we solve with a computer?

4 What problems can we solve with a computer? What kind of computer?

5 Computers are Messy

6 Computers are Messy

7 Computers are Messy

8 Computers are Messy

9 Computers are Messy That messiness makes it hard to rigorously say what we intuitively know to be true: that, on some fundamental level, diferent brands of computers or programming languages are more or less equivalent in what they are capable of doing. C vs C++ vs Java vs Python

10 We need a simpler way of discussing computing machines.

11 An automaton (plural: automata) is a mathematical model of a computing device.

12 Computers are Messy

13 Automata are Clean q q

14 Computers are Messy

15 Automata are Clean q q

16 Computers are Messy

17 Automata are Clean q q

18 Computers are Messy

19 Automata are Clean q q

20 Why Build Models? Mathematical simplicity. It is signifcantly easier to manipulate our abstract models of computers than it is to manipulate actual computers. Intellectual robustness. If we pick our models correctly, we can make broad, sweeping claims about huge classes of real computers by arguing that they're just special cases of our more general models.

21 Why Build Models? The models of computation we will explore in this class correspond to diferent conceptions of what a computer could do. Finite automata (next two weeks) are an abstraction of computers with fnite resource constraints. Provide upper bounds for the computing machines that we can actually build. Turing machines (later) are an abstraction of computers with unbounded resources. Provide upper bounds for what we could ever hope to accomplish.

22 What problems can we solve with a computer?

23 What problems can we solve with a computer? What is a problem?

24 Problems with Problems Before we can talk about what problems we can solve, we need a formal defnition of a problem. We want a defnition that corresponds to the problems we want to solve, captures a large class of problems, and is mathematically simple to reason about. No one defnition has all three properties.

25 Formal Language Theory

26 Strings An alphabet is a fnite, nonempty set of symbols called characters. Typically, we use the symbol Σ to refer to an alphabet. A string over an alphabet Σ is a fnite sequence of characters drawn from Σ. Example: If Σ = {a, b}, here are some valid strings over Σ: a aabaaabbabaaabaaaabbb abbababba The empty string has no characters and is denoted ε. Calling attention to an earlier point: since all strings are fnite sequences of characters from Σ, you cannot have a string of infnite length.

27 Languages A formal language is a set of strings. We say that L is a language over Σ if it is a set of strings over Σ. Example: The language of palindromes over Σ = {a, b, c} is the set {ε, a, b, c, aa, bb, cc, aaa, aba, aca, bab, } The set of all strings composed from letters in Σ is denoted Σ*. Formally, we say that L is a language over Σ if L Σ*.

28 How Howmany manyof ofthe thefollowing followingstatements statementsare aretrue? true? Alphabets Alphabetsare aresequences sequencesof ofcharacters. characters. Languages are sets of strings. Languages are sets of strings. Strings are sets of characters. Strings are sets of characters. Characters are individual symbols. Characters are individual symbols. Languages are sequences of characters. Languages are sequences of characters. Answer Answerat atpollev.com/cs3 PollEv.com/cs3or or text CS3 to once to join, then a text CS3 to once to join, then anumber. number.

29 To Recap Languages are sets of strings. Strings are sequences of characters. Characters are individual symbols. Alphabets are sets of characters. Languages are sets of Strings Alphabets are nonempty, finite sets of are finite sequeences of Characters

30 The Model Fundamental Question: For what languages L can you design an automaton that takes as input a string, then determines whether the string is in L? The answer depends on the choice of L, the choice of automaton, and the defnition of determines. In answering this question, we ll go through a whirlwind tour of models of computation and see how this seemingly abstract question has very real and powerful consequences.

31 To Summarize An automaton is an idealized mathematical computing machine. A language is a set of strings, a string is a (fnite) sequence of characters, and a character is an element of an alphabet. Goal: Figure out in which cases we can build automata for particular languages.

32 What problems can we solve with a computer?

33 Finite Automata

34 A fnite automaton is a simple type of mathematical machine for determining whether a string is contained within some language.

35 Each fnite automaton consists of a set of states connected by transitions.

36 A Simple Finite Automaton q q

37 A Simple Finite Automaton q q Each Each circle circle represents represents aa state state of of the the automaton. automaton.

38 A Simple Finite Automaton q q

39 A Simple Finite Automaton q q One One special special state state isis designated designated as as the the state. state.

40 A Simple Finite Automaton q q

41 A Simple Finite Automaton q q

42 A Simple Finite Automaton q The The automaton automaton isis run run on on an an input input string string and and answers answers yes yes or or no. no. q

43 A Simple Finite Automaton q q

44 A Simple Finite Automaton q q

45 A Simple Finite Automaton q The The automaton automaton can can a be in one state at be in one state at a time. time. It It begins begins inin the the state. state. q

46 A Simple Finite Automaton q q

47 A Simple Finite Automaton q q

48 A Simple Finite Automaton q The The automaton automaton now now begins begins processing processing characters characters inin the the order order inin which which they they appear. appear. q

49 A Simple Finite Automaton q q

50 A Simple Finite Automaton q q

51 A Simple Finite Automaton q q Each Each arrow arrow inin this this diagram diagram represents represents aa transition. transition. The The automaton automaton always always follows follows the the transition transition corresponding corresponding to to the the current current symbol symbol being being read. read.

52 A Simple Finite Automaton q q

53 A Simple Finite Automaton q q

54 A Simple Finite Automaton q q

55 A Simple Finite Automaton q q

56 A Simple Finite Automaton q q After After transitioning, transitioning, the the automaton automaton considers considers the the next next symbol symbol inin the the input. input.

57 A Simple Finite Automaton q q

58 A Simple Finite Automaton q q

59 A Simple Finite Automaton q q

60 A Simple Finite Automaton q q

61 A Simple Finite Automaton q q

62 A Simple Finite Automaton q q

63 A Simple Finite Automaton q q

64 A Simple Finite Automaton q q

65 A Simple Finite Automaton q q

66 A Simple Finite Automaton q q

67 A Simple Finite Automaton q q

68 A Simple Finite Automaton q q

69 A Simple Finite Automaton q q

70 A Simple Finite Automaton q q

71 A Simple Finite Automaton q q

72 A Simple Finite Automaton q q

73 A Simple Finite Automaton q q

74 A Simple Finite Automaton q q

75 A Simple Finite Automaton q q

76 A Simple Finite Automaton q q

77 A Simple Finite Automaton q q

78 A Simple Finite Automaton Now Now that that the the automaton automaton has has q whether whether to to say say yes yes or or no. no. looked looked at at all all this this input, input, itit can can decide decide q

79 A Simple Finite Automaton Now Now that that the the automaton automaton has has q whether whether to to say say yes yes or or no. no. looked looked at at all all this this input, input, itit can can decide decide q The The double double circle circle indicates indicates that that this this state state isis an an accepting accepting state, state, so so the the automaton automaton outputs outputs yes. yes.

80 A Simple Finite Automaton Now Now that that the the automaton automaton has has q whether whether to to say say yes yes or or no. no. looked looked at at all all this this input, input, itit can can decide decide q The The double double circle circle indicates indicates that that this this state state isis an an accepting accepting state, state, so so the the automaton automaton outputs outputs yes. yes.

81 A Simple Finite Automaton Now Now that that the the automaton automaton has has q whether whether to to say say yes yes or or no. no. looked looked at at all all this this input, input, itit can can decide decide q The The double double circle circle indicates indicates that that this this state state isis an an accepting accepting state, state, so so the the automaton automaton outputs outputs yes. yes.

82 A Simple Finite Automaton q q

83 A Simple Finite Automaton q q

84 A Simple Finite Automaton q q

85 A Simple Finite Automaton q q

86 A Simple Finite Automaton q q

87 A Simple Finite Automaton q q

88 A Simple Finite Automaton q q

89 A Simple Finite Automaton q q

90 A Simple Finite Automaton q q

91 A Simple Finite Automaton q q

92 A Simple Finite Automaton q q

93 A Simple Finite Automaton q q

94 A Simple Finite Automaton q q

95 A Simple Finite Automaton q q

96 A Simple Finite Automaton q q

97 A Simple Finite Automaton q q

98 A Simple Finite Automaton q q

99 A Simple Finite Automaton q q

100 A Simple Finite Automaton q q

101 A Simple Finite Automaton q q

102 A Simple Finite Automaton q q

103 A Simple Finite Automaton q q

104 A Simple Finite Automaton q q

105 A Simple Finite Automaton q q

106 A Simple Finite Automaton q q

107 A Simple Finite Automaton q q

108 A Simple Finite Automaton q q

109 A Simple Finite Automaton q q

110 A Simple Finite Automaton q This This state state isis not not an an accepting accepting state state (it s (it s aa rejecting rejecting state), state), so so the the automaton automaton says says no. no. q

111 A Simple Finite Automaton q This This state state isis not not an an accepting accepting state state (it s (it s aa rejecting rejecting state), state), so so the the automaton automaton says says no. no. q

112 A Simple Finite Automaton q This This state state isis not not an an accepting accepting state state (it s (it s aa rejecting rejecting state), state), so so the the automaton automaton says says no. no. q

113 A Simple Finite Automaton q q

114 A Simple Finite Automaton q Try Tryitityourself! yourself! Does Doesthis thisautomaton automaton accept accept(vote (votea) A) or orreject reject(vote (voter)? R)? q Answer Answerat atpollev.com/cs3 PollEv.com/cs3or or text textcs3 CS3to to once onceto tojoin, join,then thenaaor orr. R.

115 The Story So Far A fnite automaton is a collection of states joined by transitions. Some state is designated as the state. Some states are designated as accepting states. The automaton processes a string by beginning in the state and following the indicated transitions. If the automaton ends in an accepting state, it accepts the input. Otherwise, the automaton rejects the input.

116 Time-Out For Announcements!

117 Girl This summer, I ll be running our sixth iteration of Girl from July 9th July 2st. We invite high-school girls (primarily from low- to middle-income schools in majority-minority areas) to come to campus for two weeks to learn CS, meet researchers, and talk to folks from industry. We re looking for Stanford students to serve as Workshop Assistants during the program. We pay competitively (roughly $3, over two weeks). Interested? Learn more and apply using this link: All current Stanford students are invited to apply. Feel free to forward this link around!

118

119 Back to CS3!

120 Just Passing Through q q q4

121 Just Passing Through q q q4

122 Just Passing Through q q q4

123 Just Passing Through q q q4

124 Just Passing Through q q q4

125 Just Passing Through q q q4

126 Just Passing Through q q q4

127 Just Passing Through q q q4

128 Just Passing Through q q q4

129 Just Passing Through q q q4

130 Just Passing Through q q q4

131 Just Passing Through q q q4

132 Just Passing Through q q q4

133 Just Passing Through q q q4

134 A fnite automaton does not accept as soon as it enters an accepting state. A fnite automaton accepts if it ends in an accepting state.

135 What Does This Accept? q q q4

136 What Does This Accept? q q q4

137 What Does This Accept? q q q4

138 What Does This Accept? q q q4

139 What Does This Accept? q q q4

140 What Does This Accept? q q q4

141 What Does This Accept? q q q4

142 What Does This Accept? q No No matter matter where where we we in in the the automaton, automaton, q after after seeing seeing two two 's, 's, we we end end up up in in accepting accepting state state q.3. q4

143 What Does This Accept? q q q4

144 What Does This Accept? q q q4

145 What Does This Accept? q q q4

146 What Does This Accept? q q q4

147 What Does This Accept? q q q4

148 What Does This Accept? q q q4

149 What Does This Accept? q No No matter matter where where we we in in the the automaton, automaton, q after after seeing seeing two two 's, 's, we we end end up up in in accepting accepting state state qq5.5. q4

150 What Does This Accept? q q q4

151 What Does This Accept? q This This automaton automaton accepts accepts aa string string in in q {, {,}* }* if if the the string string ends ends in in or or.. q4

152 The language of an automaton is the set of strings that it accepts. If D is an automaton that processes characters from the alphabet Σ, then ℒ(D) is formally defned as ℒ(D) = { w Σ* D accepts w }

153 How Howmany manyof ofthe thefollowing followingstatements statementsare aretrue? true? --AAlanguage languageof ofan anautomaton automatoncan canhave havean aninfnitely infnitely long longstring string(or (ormany manyof ofthem) them)in init. it. --AAlanguage languageof ofan anautomaton automatoncan cancontain containinfnitely infnitely many manystrings. strings. --AAlanguage languageof ofan anautomaton automatoncan cancontain containno nostrings. strings. Answer Answerat atpollev.com/cs3 PollEv.com/cs3or or text CS3 to once to join, then a text CS3 to once to join, then anumber. number.

154 A Small Problem q q

155 A Small Problem q q

156 A Small Problem q q

157 A Small Problem q q

158 A Small Problem q q

159 A Small Problem q q

160 A Small Problem q q

161 A Small Problem q q

162 A Small Problem q q

163 Another Small Problem, q, q,

164 Another Small Problem, q, q,

165 Another Small Problem, q, q,

166 Another Small Problem, q, q,

167 Another Small Problem, q, q,

168 Another Small Problem, q, q,

169 Another Small Problem, q, q,

170 Another Small Problem, q, q,

171 The Need for Formalism In order to reason about the limits of what fnite automata can and cannot do, we need to formally specify their behavior in all cases. All of the following need to be defned or disallowed: What happens if there is no transition out of a state on some input? What happens if there are multiple transitions out of a state on some input?

172 DFAs A DFA is a Deterministic Finite Automaton DFAs are the simplest type of automaton that we will see in this course.

173 DFAs A DFA is defned relative to some alphabet Σ. For each state in the DFA, there must be exactly one transition defned for each symbol in Σ. This is the deterministic part of DFA. There is a unique state. There are zero or more accepting states.

174 How Howmany manyof ofthese theseare aredfas DFAsover over{, {,}? }? q q q, q q q q, q,, q, q, q4, Answer Answerat atpollev.com/cs3 PollEv.com/cs3or or text textcs3 CS3to to once onceto tojoin, join,then thenaanumber. number.

175 Is this a DFA?

176 Is this a DFA?

177 Is this a DFA? Drinking Family of Aardvarks

178 Designing DFAs At each point in its execution, the DFA can only remember what state it is in. DFA Design Tip: Build each state to correspond to some piece of information you need to remember. Each state acts as a memento of what you're supposed to do next. Only fnitely many diferent states means only fnitely many diferent things the machine can remember.

179 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three }

180 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } q

181 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q

182 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q b q

183 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q a b q

184 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q a b q b

185 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q a b q a b

186 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q a b q b a b

187 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q a b q b a b

188 Recognizing Languages with DFAs L = { w {a, b}* the number of b's in w is congruent to two modulo three } a q a b q a b b Each Each state state remembers remembers the the remainder remainder of of the the number number of of bbss seen seen so so far far modulo modulo three. three.

189 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring }

190 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } q

191 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q

192 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q a q

193 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q a b q

194 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q a b q a

195 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q a b q a

196 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q a, b a b q a

197 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q a, b a b q a

198 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q Σ a b q a

199 Recognizing Languages with DFAs L = { w {a, b}* w contains aa as a substring } b q Σ a b q a

200 More Elaborate DFAs L = { w {a, *, /}* w represents a C-style comment } Let s Let s have have the the aa symbol symbol be be aa placeholder placeholder for for some some character character that that isn t isn t aa star star or or slash. slash. Try Try designing designing aa DFA DFA for for comments! comments! Here s Here s some some test test cases cases to to help help you you check check your your work: work: Accepted: Rejected: /*a*/ /**/ /***/ /*aaa*aaa*/ /*a/a*/ /** /**/a/*aa*/ aaa/**/aa /*/ /**a/ //aaaa

201 More Elaborate DFAs L = { w {a, *, /}* w represents a C-style comment } Σ a, * Σ q5 /, a * q / q * a a, / / * q4

Finite Automata Part One

Finite Automata Part One Finite Automata Part One Computability Theory What problems can we solve with a computer? What kind of computer? Computers are Messy http://en.wikipedia.org/wiki/file:eniac.jpg Computers are Messy That

More information

Finite Automata Part One

Finite Automata Part One Finite Automata Part One Computability Theory What problems can we solve with a computer? What problems can we solve with a computer? What kind of computer? Computers are Messy http://www.intel.com/design/intarch/prodbref/27273.htm

More information

Finite Automata Part One

Finite Automata Part One Finite Automata Part One Computability Theory What problems can we solve with a computer? What kind of computer? Computers are Messy http://www.intel.com/design/intarch/prodbref/27273.htm We need a simpler

More information

Announcements. Problem Set Four due Thursday at 7:00PM (right before the midterm).

Announcements. Problem Set Four due Thursday at 7:00PM (right before the midterm). Finite Automata Announcements Problem Set Four due Thursday at 7:PM (right before the midterm). Stop by OH with questions! Email cs3@cs.stanford.edu with questions! Review session tonight, 7PM until whenever

More information

Finite Automata Part Two

Finite Automata Part Two Finite Automata Part Two Recap from Last Time Old MacDonald Had a Symbol, Σ-eye-ε-ey, Oh! You may have noticed that we have several letter- E-ish symbols in CS103, which can get confusing! Here s a quick

More information

CS 154, Lecture 2: Finite Automata, Closure Properties Nondeterminism,

CS 154, Lecture 2: Finite Automata, Closure Properties Nondeterminism, CS 54, Lecture 2: Finite Automata, Closure Properties Nondeterminism, Why so Many Models? Streaming Algorithms 0 42 Deterministic Finite Automata Anatomy of Deterministic Finite Automata transition: for

More information

Turing Machines Part One

Turing Machines Part One Turing Machines Part One What problems can we solve with a computer? Regular Languages CFLs Languages recognizable by any feasible computing machine All Languages That same drawing, to scale. All Languages

More information

Turing Machines Part Two

Turing Machines Part Two Turing Machines Part Two Recap from Last Time Our First Turing Machine q acc a start q 0 q 1 a This This is is the the Turing Turing machine s machine s finiteisttiteiconntont. finiteisttiteiconntont.

More information

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY 5-453 FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY NON-DETERMINISM and REGULAR OPERATIONS THURSDAY JAN 6 UNION THEOREM The union of two regular languages is also a regular language Regular Languages Are

More information

CS 154. Finite Automata, Nondeterminism, Regular Expressions

CS 154. Finite Automata, Nondeterminism, Regular Expressions CS 54 Finite Automata, Nondeterminism, Regular Expressions Read string left to right The DFA accepts a string if the process ends in a double circle A DFA is a 5-tuple M = (Q, Σ, δ, q, F) Q is the set

More information

Finite Automata Part Two

Finite Automata Part Two Finite Automata Part Two DFAs A DFA is a Deterministic Finite Automaton A DFA is defined relative to some alphabet Σ. For each state in the DFA, there must be exactly one transition defined for each symbol

More information

Chapter Two: Finite Automata

Chapter Two: Finite Automata Chapter Two: Finite Automata In theoretical computer science, automata theory is the study of abstract machines (or more appropriately, abstract 'mathematical' machines or systems) and the computational

More information

Turing Machines Part III

Turing Machines Part III Turing Machines Part III Announcements Problem Set 6 due now. Problem Set 7 out, due Monday, March 4. Play around with Turing machines, their powers, and their limits. Some problems require Wednesday's

More information

Nonregular Languages

Nonregular Languages Nonregular Languages Recap from Last Time Theorem: The following are all equivalent: L is a regular language. There is a DFA D such that L( D) = L. There is an NFA N such that L( N) = L. There is a regular

More information

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION CSE 105 THEORY OF COMPUTATION "Winter" 2018 http://cseweb.ucsd.edu/classes/wi18/cse105-ab/ Today's learning goals Sipser Section 1.1 Design an automaton that recognizes a given language. Specify each of

More information

CSC236 Week 10. Larry Zhang

CSC236 Week 10. Larry Zhang CSC236 Week 10 Larry Zhang 1 Today s Topic Deterministic Finite Automata (DFA) 2 Recap of last week We learned a lot of terminologies alphabet string length of string union concatenation Kleene star language

More information

CSC236 Week 11. Larry Zhang

CSC236 Week 11. Larry Zhang CSC236 Week 11 Larry Zhang 1 Announcements Next week s lecture: Final exam review This week s tutorial: Exercises with DFAs PS9 will be out later this week s. 2 Recap Last week we learned about Deterministic

More information

Nondeterminism. September 7, Nondeterminism

Nondeterminism. September 7, Nondeterminism September 7, 204 Introduction is a useful concept that has a great impact on the theory of computation Introduction is a useful concept that has a great impact on the theory of computation So far in our

More information

CS 154, Lecture 3: DFA NFA, Regular Expressions

CS 154, Lecture 3: DFA NFA, Regular Expressions CS 154, Lecture 3: DFA NFA, Regular Expressions Homework 1 is coming out Deterministic Finite Automata Computation with finite memory Non-Deterministic Finite Automata Computation with finite memory and

More information

CSE 311 Lecture 23: Finite State Machines. Emina Torlak and Kevin Zatloukal

CSE 311 Lecture 23: Finite State Machines. Emina Torlak and Kevin Zatloukal CSE 3 Lecture 3: Finite State Machines Emina Torlak and Kevin Zatloukal Topics Finite state machines (FSMs) Definition and examples. Finite state machines with output Definition and examples. Finite state

More information

Nondeterministic Finite Automata and Regular Expressions

Nondeterministic Finite Automata and Regular Expressions Nondeterministic Finite Automata and Regular Expressions CS 2800: Discrete Structures, Spring 2015 Sid Chaudhuri Recap: Deterministic Finite Automaton A DFA is a 5-tuple M = (Q, Σ, δ, q 0, F) Q is a finite

More information

Languages. A language is a set of strings. String: A sequence of letters. Examples: cat, dog, house, Defined over an alphabet:

Languages. A language is a set of strings. String: A sequence of letters. Examples: cat, dog, house, Defined over an alphabet: Languages 1 Languages A language is a set of strings String: A sequence of letters Examples: cat, dog, house, Defined over an alphaet: a,, c,, z 2 Alphaets and Strings We will use small alphaets: Strings

More information

Griffith University 3130CIT Theory of Computation (Based on slides by Harald Søndergaard of The University of Melbourne) Turing Machines 9-0

Griffith University 3130CIT Theory of Computation (Based on slides by Harald Søndergaard of The University of Melbourne) Turing Machines 9-0 Griffith University 3130CIT Theory of Computation (Based on slides by Harald Søndergaard of The University of Melbourne) Turing Machines 9-0 Turing Machines Now for a machine model of much greater power.

More information

CHAPTER 1 Regular Languages. Contents

CHAPTER 1 Regular Languages. Contents Finite Automata (FA or DFA) CHAPTER Regular Languages Contents definitions, examples, designing, regular operations Non-deterministic Finite Automata (NFA) definitions, euivalence of NFAs and DFAs, closure

More information

Theory of computation: initial remarks (Chapter 11)

Theory of computation: initial remarks (Chapter 11) Theory of computation: initial remarks (Chapter 11) For many purposes, computation is elegantly modeled with simple mathematical objects: Turing machines, finite automata, pushdown automata, and such.

More information

T (s, xa) = T (T (s, x), a). The language recognized by M, denoted L(M), is the set of strings accepted by M. That is,

T (s, xa) = T (T (s, x), a). The language recognized by M, denoted L(M), is the set of strings accepted by M. That is, Recall A deterministic finite automaton is a five-tuple where S is a finite set of states, M = (S, Σ, T, s 0, F ) Σ is an alphabet the input alphabet, T : S Σ S is the transition function, s 0 S is the

More information

UNIT-III REGULAR LANGUAGES

UNIT-III REGULAR LANGUAGES Syllabus R9 Regulation REGULAR EXPRESSIONS UNIT-III REGULAR LANGUAGES Regular expressions are useful for representing certain sets of strings in an algebraic fashion. In arithmetic we can use the operations

More information

Nondeterministic Finite Automata

Nondeterministic Finite Automata Nondeterministic Finite Automata Not A DFA Does not have exactly one transition from every state on every symbol: Two transitions from q 0 on a No transition from q 1 (on either a or b) Though not a DFA,

More information

Formal Definition of Computation. August 28, 2013

Formal Definition of Computation. August 28, 2013 August 28, 2013 Computation model The model of computation considered so far is the work performed by a finite automaton Finite automata were described informally, using state diagrams, and formally, as

More information

Automata: a short introduction

Automata: a short introduction ILIAS, University of Luxembourg Discrete Mathematics II May 2012 What is a computer? Real computers are complicated; We abstract up to an essential model of computation; We begin with the simplest possible

More information

Author: Vivek Kulkarni ( )

Author: Vivek Kulkarni ( ) Author: Vivek Kulkarni ( vivek_kulkarni@yahoo.com ) Chapter-2: Finite State Machines Solutions for Review Questions @ Oxford University Press 2013. All rights reserved. 1 Q.1 Construct Mealy and Moore

More information

UNIT-I. Strings, Alphabets, Language and Operations

UNIT-I. Strings, Alphabets, Language and Operations UNIT-I Strings, Alphabets, Language and Operations Strings of characters are fundamental building blocks in computer science. Alphabet is defined as a non empty finite set or nonempty set of symbols. The

More information

Theory of Computation

Theory of Computation Theory of Computation Lecture #2 Sarmad Abbasi Virtual University Sarmad Abbasi (Virtual University) Theory of Computation 1 / 1 Lecture 2: Overview Recall some basic definitions from Automata Theory.

More information

Chapter Five: Nondeterministic Finite Automata

Chapter Five: Nondeterministic Finite Automata Chapter Five: Nondeterministic Finite Automata From DFA to NFA A DFA has exactly one transition from every state on every symbol in the alphabet. By relaxing this requirement we get a related but more

More information

Languages, regular languages, finite automata

Languages, regular languages, finite automata Notes on Computer Theory Last updated: January, 2018 Languages, regular languages, finite automata Content largely taken from Richards [1] and Sipser [2] 1 Languages An alphabet is a finite set of characters,

More information

Formal Definition of a Finite Automaton. August 26, 2013

Formal Definition of a Finite Automaton. August 26, 2013 August 26, 2013 Why a formal definition? A formal definition is precise: - It resolves any uncertainties about what is allowed in a finite automaton such as the number of accept states and number of transitions

More information

CSC173 Workshop: 13 Sept. Notes

CSC173 Workshop: 13 Sept. Notes CSC173 Workshop: 13 Sept. Notes Frank Ferraro Department of Computer Science University of Rochester September 14, 2010 1 Regular Languages and Equivalent Forms A language can be thought of a set L of

More information

Automata Theory. Lecture on Discussion Course of CS120. Runzhe SJTU ACM CLASS

Automata Theory. Lecture on Discussion Course of CS120. Runzhe SJTU ACM CLASS Automata Theory Lecture on Discussion Course of CS2 This Lecture is about Mathematical Models of Computation. Why Should I Care? - Ways of thinking. - Theory can drive practice. - Don t be an Instrumentalist.

More information

Recap DFA,NFA, DTM. Slides by Prof. Debasis Mitra, FIT.

Recap DFA,NFA, DTM. Slides by Prof. Debasis Mitra, FIT. Recap DFA,NFA, DTM Slides by Prof. Debasis Mitra, FIT. 1 Formal Language Finite set of alphabets Σ: e.g., {0, 1}, {a, b, c}, { {, } } Language L is a subset of strings on Σ, e.g., {00, 110, 01} a finite

More information

Recap from Last Time

Recap from Last Time Regular Expressions Recap from Last Time Regular Languages A language L is a regular language if there is a DFA D such that L( D) = L. Theorem: The following are equivalent: L is a regular language. There

More information

Nondeterministic finite automata

Nondeterministic finite automata Lecture 3 Nondeterministic finite automata This lecture is focused on the nondeterministic finite automata (NFA) model and its relationship to the DFA model. Nondeterminism is an important concept in the

More information

CMP 309: Automata Theory, Computability and Formal Languages. Adapted from the work of Andrej Bogdanov

CMP 309: Automata Theory, Computability and Formal Languages. Adapted from the work of Andrej Bogdanov CMP 309: Automata Theory, Computability and Formal Languages Adapted from the work of Andrej Bogdanov Course outline Introduction to Automata Theory Finite Automata Deterministic Finite state automata

More information

Clarifications from last time. This Lecture. Last Lecture. CMSC 330: Organization of Programming Languages. Finite Automata.

Clarifications from last time. This Lecture. Last Lecture. CMSC 330: Organization of Programming Languages. Finite Automata. CMSC 330: Organization of Programming Languages Last Lecture Languages Sets of strings Operations on languages Finite Automata Regular expressions Constants Operators Precedence CMSC 330 2 Clarifications

More information

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION CSE 105 THEORY OF COMPUTATION Spring 2017 http://cseweb.ucsd.edu/classes/sp17/cse105-ab/ Review of CFG, CFL, ambiguity What is the language generated by the CFG below: G 1 = ({S,T 1,T 2 }, {0,1,2}, { S

More information

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION CSE 105 THEORY OF COMPUTATION "Winter" 2018 http://cseweb.ucsd.edu/classes/wi18/cse105-ab/ Today's learning goals Sipser Section 1.1 Determine if a language is regular Apply closure properties to conclude

More information

CISC 4090: Theory of Computation Chapter 1 Regular Languages. Section 1.1: Finite Automata. What is a computer? Finite automata

CISC 4090: Theory of Computation Chapter 1 Regular Languages. Section 1.1: Finite Automata. What is a computer? Finite automata CISC 4090: Theory of Computation Chapter Regular Languages Xiaolan Zhang, adapted from slides by Prof. Werschulz Section.: Finite Automata Fordham University Department of Computer and Information Sciences

More information

Grade 6 Math Circles October 20/21, Formalism and Languages: Beyond Regular Languages

Grade 6 Math Circles October 20/21, Formalism and Languages: Beyond Regular Languages Faculty of Mathematics Waterloo, Ontario N2L 3G1 Centre for Education in Mathematics and Computing Grade 6 Math Circles October 20/21, 2015 Formalism and Languages: Beyond Regular Languages Dr. Troy Vasiga

More information

Part 4 out of 5 DFA NFA REX. Automata & languages. A primer on the Theory of Computation. Last week, we showed the equivalence of DFA, NFA and REX

Part 4 out of 5 DFA NFA REX. Automata & languages. A primer on the Theory of Computation. Last week, we showed the equivalence of DFA, NFA and REX Automata & languages A primer on the Theory of Computation Laurent Vanbever www.vanbever.eu Part 4 out of 5 ETH Zürich (D-ITET) October, 12 2017 Last week, we showed the equivalence of DFA, NFA and REX

More information

Finite-state machines (FSMs)

Finite-state machines (FSMs) Finite-state machines (FSMs) Dr. C. Constantinides Department of Computer Science and Software Engineering Concordia University Montreal, Canada January 10, 2017 1/19 Finite-state machines (FSMs) and state

More information

Computer Sciences Department

Computer Sciences Department 1 Reference Book: INTRODUCTION TO THE THEORY OF COMPUTATION, SECOND EDITION, by: MICHAEL SIPSER 3 objectives Finite automaton Infinite automaton Formal definition State diagram Regular and Non-regular

More information

GEETANJALI INSTITUTE OF TECHNICAL STUDIES, UDAIPUR I

GEETANJALI INSTITUTE OF TECHNICAL STUDIES, UDAIPUR I GEETANJALI INSTITUTE OF TECHNICAL STUDIES, UDAIPUR I Internal Examination 2017-18 B.Tech III Year VI Semester Sub: Theory of Computation (6CS3A) Time: 1 Hour 30 min. Max Marks: 40 Note: Attempt all three

More information

CS:4330 Theory of Computation Spring Regular Languages. Finite Automata and Regular Expressions. Haniel Barbosa

CS:4330 Theory of Computation Spring Regular Languages. Finite Automata and Regular Expressions. Haniel Barbosa CS:4330 Theory of Computation Spring 2018 Regular Languages Finite Automata and Regular Expressions Haniel Barbosa Readings for this lecture Chapter 1 of [Sipser 1996], 3rd edition. Sections 1.1 and 1.3.

More information

Finite Automata (contd)

Finite Automata (contd) Finite Automata (contd) CS 2800: Discrete Structures, Fall 2014 Sid Chaudhuri Recap: Deterministic Finite Automaton A DFA is a 5-tuple M = (Q, Σ, δ, q 0, F) Q is a fnite set of states Σ is a fnite input

More information

Theory of computation: initial remarks (Chapter 11)

Theory of computation: initial remarks (Chapter 11) Theory of computation: initial remarks (Chapter 11) For many purposes, computation is elegantly modeled with simple mathematical objects: Turing machines, finite automata, pushdown automata, and such.

More information

Chapter 5. Finite Automata

Chapter 5. Finite Automata Chapter 5 Finite Automata 5.1 Finite State Automata Capable of recognizing numerous symbol patterns, the class of regular languages Suitable for pattern-recognition type applications, such as the lexical

More information

CS 154 Introduction to Automata and Complexity Theory

CS 154 Introduction to Automata and Complexity Theory CS 154 Introduction to Automata and Complexity Theory cs154.stanford.edu 1 INSTRUCTORS & TAs Ryan Williams Cody Murray Lera Nikolaenko Sunny Rajan 2 Textbook 3 Homework / Problem Sets Homework will be

More information

COM364 Automata Theory Lecture Note 2 - Nondeterminism

COM364 Automata Theory Lecture Note 2 - Nondeterminism COM364 Automata Theory Lecture Note 2 - Nondeterminism Kurtuluş Küllü March 2018 The FA we saw until now were deterministic FA (DFA) in the sense that for each state and input symbol there was exactly

More information

Turing machines and linear bounded automata

Turing machines and linear bounded automata and linear bounded automata Informatics 2A: Lecture 30 John Longley School of Informatics University of Edinburgh jrl@inf.ed.ac.uk 25 November 2016 1 / 17 The Chomsky hierarchy: summary Level Language

More information

PS2 - Comments. University of Virginia - cs3102: Theory of Computation Spring 2010

PS2 - Comments. University of Virginia - cs3102: Theory of Computation Spring 2010 University of Virginia - cs3102: Theory of Computation Spring 2010 PS2 - Comments Average: 77.4 (full credit for each question is 100 points) Distribution (of 54 submissions): 90, 12; 80 89, 11; 70-79,

More information

CS 154. Finite Automata vs Regular Expressions, Non-Regular Languages

CS 154. Finite Automata vs Regular Expressions, Non-Regular Languages CS 154 Finite Automata vs Regular Expressions, Non-Regular Languages Deterministic Finite Automata Computation with finite memory Non-Deterministic Finite Automata Computation with finite memory and guessing

More information

How do regular expressions work? CMSC 330: Organization of Programming Languages

How do regular expressions work? CMSC 330: Organization of Programming Languages How do regular expressions work? CMSC 330: Organization of Programming Languages Regular Expressions and Finite Automata What we ve learned What regular expressions are What they can express, and cannot

More information

Join. Visit us at the HMC club fair and the 5c turf dinner. Company sponsored tech talks and events Resume Workshops / Interview Prep

Join. Visit us at the HMC club fair and the 5c turf dinner. Company sponsored tech talks and events Resume Workshops / Interview Prep Join Company sponsored tech talks and events Resume Workshops / Interview Prep Meet other students in CS! Dinners with cool profs (like the one standing in front of you!) Students of all gender identities

More information

Mathematical Logic Part One

Mathematical Logic Part One Mathematical Logic Part One Question: How do we formalize the defnitions and reasoning we use in our proofs? Where We're Going Propositional Logic (Today) Basic logical connectives. Truth tables. Logical

More information

CISC4090: Theory of Computation

CISC4090: Theory of Computation CISC4090: Theory of Computation Chapter 2 Context-Free Languages Courtesy of Prof. Arthur G. Werschulz Fordham University Department of Computer and Information Sciences Spring, 2014 Overview In Chapter

More information

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION CSE 105 THEORY OF COMPUTATION Spring 2016 http://cseweb.ucsd.edu/classes/sp16/cse105-ab/ Today's learning goals Sipser Ch 2 Design a PDA and a CFG for a given language Give informal description for a PDA,

More information

Finite Automata. Finite Automata

Finite Automata. Finite Automata Finite Automata Finite Automata Formal Specification of Languages Generators Grammars Context-free Regular Regular Expressions Recognizers Parsers, Push-down Automata Context Free Grammar Finite State

More information

CISC 4090 Theory of Computation

CISC 4090 Theory of Computation 9/2/28 Stereotypical computer CISC 49 Theory of Computation Finite state machines & Regular languages Professor Daniel Leeds dleeds@fordham.edu JMH 332 Central processing unit (CPU) performs all the instructions

More information

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION CSE 105 THEORY OF COMPUTATION Spring 2016 http://cseweb.ucsd.edu/classes/sp16/cse105-ab/ Today's learning goals Sipser Ch 2 Define push down automata Trace the computation of a push down automaton Design

More information

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY 15-453 FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY REVIEW for MIDTERM 1 THURSDAY Feb 6 Midterm 1 will cover everything we have seen so far The PROBLEMS will be from Sipser, Chapters 1, 2, 3 It will be

More information

CS 133 : Automata Theory and Computability

CS 133 : Automata Theory and Computability CS 133 : Automata Theory and Computability Lecture Slides 1 Regular Languages and Finite Automata Nestine Hope S. Hernandez Algorithms and Complexity Laboratory Department of Computer Science University

More information

Lecture Notes On THEORY OF COMPUTATION MODULE -1 UNIT - 2

Lecture Notes On THEORY OF COMPUTATION MODULE -1 UNIT - 2 BIJU PATNAIK UNIVERSITY OF TECHNOLOGY, ODISHA Lecture Notes On THEORY OF COMPUTATION MODULE -1 UNIT - 2 Prepared by, Dr. Subhendu Kumar Rath, BPUT, Odisha. UNIT 2 Structure NON-DETERMINISTIC FINITE AUTOMATA

More information

Fooling Sets and. Lecture 5

Fooling Sets and. Lecture 5 Fooling Sets and Introduction to Nondeterministic Finite Automata Lecture 5 Proving that a language is not regular Given a language, we saw how to prove it is regular (union, intersection, concatenation,

More information

Recap from Last Time

Recap from Last Time Regular Expressions Recap from Last Time Regular Languages A language L is a regular language if there is a DFA D such that L( D) = L. Theorem: The following are equivalent: L is a regular language. There

More information

CSE 105 Homework 1 Due: Monday October 9, Instructions. should be on each page of the submission.

CSE 105 Homework 1 Due: Monday October 9, Instructions. should be on each page of the submission. CSE 5 Homework Due: Monday October 9, 7 Instructions Upload a single file to Gradescope for each group. should be on each page of the submission. All group members names and PIDs Your assignments in this

More information

CS 301. Lecture 18 Decidable languages. Stephen Checkoway. April 2, 2018

CS 301. Lecture 18 Decidable languages. Stephen Checkoway. April 2, 2018 CS 301 Lecture 18 Decidable languages Stephen Checkoway April 2, 2018 1 / 26 Decidable language Recall, a language A is decidable if there is some TM M that 1 recognizes A (i.e., L(M) = A), and 2 halts

More information

HKN CS/ECE 374 Midterm 1 Review. Nathan Bleier and Mahir Morshed

HKN CS/ECE 374 Midterm 1 Review. Nathan Bleier and Mahir Morshed HKN CS/ECE 374 Midterm 1 Review Nathan Bleier and Mahir Morshed For the most part, all about strings! String induction (to some extent) Regular languages Regular expressions (regexps) Deterministic finite

More information

Mathematical Induction Part Two

Mathematical Induction Part Two Mathematical Induction Part Two Recap from Last Time Let P be some predicate. The principle of mathematical induction states that if If it starts true and it stays P(0) is true true and k ℕ. (P(k) P(k+1))

More information

Deterministic Finite Automaton (DFA)

Deterministic Finite Automaton (DFA) 1 Lecture Overview Deterministic Finite Automata (DFA) o accepting a string o defining a language Nondeterministic Finite Automata (NFA) o converting to DFA (subset construction) o constructed from a regular

More information

Proofs, Strings, and Finite Automata. CS154 Chris Pollett Feb 5, 2007.

Proofs, Strings, and Finite Automata. CS154 Chris Pollett Feb 5, 2007. Proofs, Strings, and Finite Automata CS154 Chris Pollett Feb 5, 2007. Outline Proofs and Proof Strategies Strings Finding proofs Example: For every graph G, the sum of the degrees of all the nodes in G

More information

Automata and Computability

Automata and Computability Automata and Computability Fall 207 Alexis Maciel Department of Computer Science Clarkson University Copyright c 207 Alexis Maciel ii Contents Preface vii Introduction 2 Finite Automata 5 2. Turing Machines...............................

More information

1. (a) Explain the procedure to convert Context Free Grammar to Push Down Automata.

1. (a) Explain the procedure to convert Context Free Grammar to Push Down Automata. Code No: R09220504 R09 Set No. 2 II B.Tech II Semester Examinations,December-January, 2011-2012 FORMAL LANGUAGES AND AUTOMATA THEORY Computer Science And Engineering Time: 3 hours Max Marks: 75 Answer

More information

(Refer Slide Time: 0:21)

(Refer Slide Time: 0:21) Theory of Computation Prof. Somenath Biswas Department of Computer Science and Engineering Indian Institute of Technology Kanpur Lecture 7 A generalisation of pumping lemma, Non-deterministic finite automata

More information

September 7, Formal Definition of a Nondeterministic Finite Automaton

September 7, Formal Definition of a Nondeterministic Finite Automaton Formal Definition of a Nondeterministic Finite Automaton September 7, 2014 A comment first The formal definition of an NFA is similar to that of a DFA. Both have states, an alphabet, transition function,

More information

CS 121, Section 2. Week of September 16, 2013

CS 121, Section 2. Week of September 16, 2013 CS 121, Section 2 Week of September 16, 2013 1 Concept Review 1.1 Overview In the past weeks, we have examined the finite automaton, a simple computational model with limited memory. We proved that DFAs,

More information

CS5371 Theory of Computation. Lecture 10: Computability Theory I (Turing Machine)

CS5371 Theory of Computation. Lecture 10: Computability Theory I (Turing Machine) CS537 Theory of Computation Lecture : Computability Theory I (Turing Machine) Objectives Introduce the Turing Machine (TM) Proposed by Alan Turing in 936 finite-state control + infinitely long tape A stronger

More information

FABER Formal Languages, Automata. Lecture 2. Mälardalen University

FABER Formal Languages, Automata. Lecture 2. Mälardalen University CD5560 FABER Formal Languages, Automata and Models of Computation Lecture 2 Mälardalen University 2010 1 Content Languages, g Alphabets and Strings Strings & String Operations Languages & Language Operations

More information

Accept or reject. Stack

Accept or reject. Stack Pushdown Automata CS351 Just as a DFA was equivalent to a regular expression, we have a similar analogy for the context-free grammar. A pushdown automata (PDA) is equivalent in power to contextfree grammars.

More information

CMPSCI 250: Introduction to Computation. Lecture #22: From λ-nfa s to NFA s to DFA s David Mix Barrington 22 April 2013

CMPSCI 250: Introduction to Computation. Lecture #22: From λ-nfa s to NFA s to DFA s David Mix Barrington 22 April 2013 CMPSCI 250: Introduction to Computation Lecture #22: From λ-nfa s to NFA s to DFA s David Mix Barrington 22 April 2013 λ-nfa s to NFA s to DFA s Reviewing the Three Models and Kleene s Theorem The Subset

More information

Decision, Computation and Language

Decision, Computation and Language Decision, Computation and Language Non-Deterministic Finite Automata (NFA) Dr. Muhammad S Khan (mskhan@liv.ac.uk) Ashton Building, Room G22 http://www.csc.liv.ac.uk/~khan/comp218 Finite State Automata

More information

CSE 311: Foundations of Computing. Lecture 26: More on Limits of FSMs, Cardinality

CSE 311: Foundations of Computing. Lecture 26: More on Limits of FSMs, Cardinality CSE 311: Foundations of Computing Lecture 26: More on Limits of FSMs, Cardinality Last time: Languages and Representations All Context-Free??? Prove there is Regular a context-free DFA language 0* NFA

More information

Turing Machines Part Three

Turing Machines Part Three Turing Machines Part Three What problems can we solve with a computer? What kind of computer? Very Important Terminology Let M be a Turing machine. M accepts a string w if it enters an accept state when

More information

CPS 220 Theory of Computation REGULAR LANGUAGES

CPS 220 Theory of Computation REGULAR LANGUAGES CPS 22 Theory of Computation REGULAR LANGUAGES Introduction Model (def) a miniature representation of a thing; sometimes a facsimile Iraq village mockup for the Marines Scientific modelling - the process

More information

acs-04: Regular Languages Regular Languages Andreas Karwath & Malte Helmert Informatik Theorie II (A) WS2009/10

acs-04: Regular Languages Regular Languages Andreas Karwath & Malte Helmert Informatik Theorie II (A) WS2009/10 Regular Languages Andreas Karwath & Malte Helmert 1 Overview Deterministic finite automata Regular languages Nondeterministic finite automata Closure operations Regular expressions Nonregular languages

More information

Theory of Computation (II) Yijia Chen Fudan University

Theory of Computation (II) Yijia Chen Fudan University Theory of Computation (II) Yijia Chen Fudan University Review A language L is a subset of strings over an alphabet Σ. Our goal is to identify those languages that can be recognized by one of the simplest

More information

Automata Theory (2A) Young Won Lim 5/31/18

Automata Theory (2A) Young Won Lim 5/31/18 Automata Theory (2A) Copyright (c) 2018 Young W. Lim. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later

More information

Theory of Computation p.1/?? Theory of Computation p.2/?? Unknown: Implicitly a Boolean variable: true if a word is

Theory of Computation p.1/?? Theory of Computation p.2/?? Unknown: Implicitly a Boolean variable: true if a word is Abstraction of Problems Data: abstracted as a word in a given alphabet. Σ: alphabet, a finite, non-empty set of symbols. Σ : all the words of finite length built up using Σ: Conditions: abstracted as a

More information

The Turing machine model of computation

The Turing machine model of computation The Turing machine model of computation For most of the remainder of the course we will study the Turing machine model of computation, named after Alan Turing (1912 1954) who proposed the model in 1936.

More information

Great Theoretical Ideas in Computer Science. Lecture 4: Deterministic Finite Automaton (DFA), Part 2

Great Theoretical Ideas in Computer Science. Lecture 4: Deterministic Finite Automaton (DFA), Part 2 5-25 Great Theoretical Ideas in Computer Science Lecture 4: Deterministic Finite Automaton (DFA), Part 2 January 26th, 27 Formal definition: DFA A deterministic finite automaton (DFA) M =(Q,,,q,F) M is

More information

Deterministic Finite Automata. Non deterministic finite automata. Non-Deterministic Finite Automata (NFA) Non-Deterministic Finite Automata (NFA)

Deterministic Finite Automata. Non deterministic finite automata. Non-Deterministic Finite Automata (NFA) Non-Deterministic Finite Automata (NFA) Deterministic Finite Automata Non deterministic finite automata Automata we ve been dealing with have been deterministic For every state and every alphabet symbol there is exactly one move that the machine

More information

Equivalence of DFAs and NFAs

Equivalence of DFAs and NFAs CS 172: Computability and Complexity Equivalence of DFAs and NFAs It s a tie! DFA NFA Sanjit A. Seshia EECS, UC Berkeley Acknowledgments: L.von Ahn, L. Blum, M. Blum What we ll do today Prove that DFAs

More information