Professional Documents
Culture Documents
Computation Theory
Computation Theory
Theory of Computation
2022/2023 2022/2023 2022/2023
Prepared By
30210061601189 30210061601189 30210061601189
68
ﻣﻴﺮﻧﺎ ﻣﺤﻤﺪ ﻋﺒﺪﺍﻟﻤﻨﻌﻢ ﻋﻄﺎﺍﻟﻠﻪ
Exercises Chapter 2
2.1 For each of the following languages, construct a DFA that accepts the language. In
2.2 For2022/2023
each of the following languages, construct
2022/2023 an NFA, with the2022/2023
specified number of
states, that accepts the language. In all cases, the alphabet is {0, 1}.
3. The language {w : w contains an odd number of 1s or exactly two 0s} with six
states.
2.3 For each of the following languages, construct an NFA that
30210061601189 30210061601189 30210061601189
accepts the language. In all cases, the alphabet is {0, 1}.
68
merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg
εb a
,
b
2 3
2022/2023 a
2022/2023 2022/2023
a b
2.7 In the proof of Theorem 2.6.3, we introduced a new start state q0, which is also an
accept state. Explain why the following is not a valid proof of Theorem 2.6.3:
Let N = (Q1, Σ, δ1, q1, F1) be an NFA, such that A = L(N).
Define the NFA M = (Q1, Σ, δ, q1, F ), where
68
merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg
ﻣﻴﺮﻧﺎ ﻣﺤﻤﺪ ﻋﺒﺪﺍﻟﻤﻨﻌﻢ ﻋﻄﺎﺍﻟﻠﻪ
68
merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg
ﻣﻴﺮﻧﺎ ﻣﺤﻤﺪ ﻋﺒﺪﺍﻟﻤﻨﻌﻢ ﻋﻄﺎﺍﻟﻠﻪ
68
merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg
ﻣﻴﺮﻧﺎ ﻣﺤﻤﺪ ﻋﺒﺪﺍﻟﻤﻨﻌﻢ ﻋﻄﺎﺍﻟﻠﻪ
68
ﻣﻴﺮﻧﺎ ﻣﺤﻤﺪ ﻋﺒﺪﺍﻟﻤﻨﻌﻢ ﻋﻄﺎﺍﻟﻠﻪ
68
merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg
ﻣﻴﺮﻧﺎ ﻣﺤﻤﺪ ﻋﺒﺪﺍﻟﻤﻨﻌﻢ ﻋﻄﺎﺍﻟﻠﻪ
68
merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg merna_31139888@ics.tanta.edu.eg
ﻣﻴﺮﻧﺎ ﻣﺤﻤﺪ ﻋﺒﺪﺍﻟﻤﻨﻌﻢ ﻋﻄﺎﺍﻟﻠﻪ
68