Week 2
Week 2
Σ* = set of all possible strings of all lengths over alphabet Σ (an infinite set).
Σ* = Σ0 ∪ Σ1 ∪ Σ2 ∪ Σ3 ∪ …
Finite automata are good models for computers with an extremely limited
amount of memory.
What can a computer do with such a small memory? Many useful things!
In fact, we interact with such computers all the time, as they lie at the heart
of various electromechanical devices.
𝑀1 = (𝑄, Σ, 𝛿, 𝑞1, 𝐹)
𝛿= 0 1
𝑄 = {𝑞1, 𝑞2, 𝑞3}
𝑞1 𝑞1 𝑞2
Σ = {0, 1}
𝑞2 𝑞1 𝑞3
q1 is start state 𝑞3 𝑞3 𝑞3
𝐹 = {𝑞3}
Finite Automata – Recognizing languages
Recognizing languages
- 𝐿(𝑀) = {𝑤| 𝑀 accepts 𝑤}
- 𝐿(𝑀) is the language of 𝑀
- 𝑀 recognizes 𝐿(𝑀)
Say that 𝐴 is the language of 𝑀 and that 𝑀 recognizes 𝐴 and that 𝐴 = 𝐿(𝑀).
Finite Automata – Computation
M3
M3 accepts all strings that end in a 1. Thus L(M3) = {w| w ends in a 1}.
Finite Automata – Examples
MM
3
4
Note that because the start state is also an accept state, M4 accepts the empty
string ε. As soon as a machine begins reading the empty string, it is at the end; so if
the start state is an accept state, ε is accepted.
Finite Automata – Examples
MM
3
4
M5
M5 accepts all strings that start and end with a or that start and end with b.
In other words, M5 accepts strings that start and end with the same symbol.