0% found this document useful (0 votes)
69 views

TOC Assignment

This document contains 6 questions regarding deterministic finite automata (DFAs) and non-deterministic finite automata (NFAs). The questions ask to: 1) prove a property of DFA states using induction, 2) design DFAs for languages over {0,1}, 3) design DFAs for languages with constraints on block/symbol positions, 4) convert an NFA to a DFA, 5) compute epsilon closures and strings accepted by a 2-NFA, and 6) design 2-NFAs for specified languages.

Uploaded by

mridul
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
69 views

TOC Assignment

This document contains 6 questions regarding deterministic finite automata (DFAs) and non-deterministic finite automata (NFAs). The questions ask to: 1) prove a property of DFA states using induction, 2) design DFAs for languages over {0,1}, 3) design DFAs for languages with constraints on block/symbol positions, 4) convert an NFA to a DFA, 5) compute epsilon closures and strings accepted by a 2-NFA, and 6) design 2-NFAs for specified languages.

Uploaded by

mridul
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Assignment 2

September 1, 2016

Q1. Let A be a DFA and q a particular state of A, such that (q, a) = q for
all input symbols a. Show by induction on the length of the input that for all
input string w, (q, a) = q.

(q,w)

Q2. Give DFAs accepting the following languages over the alphabets {0,1}:
The set of all strings beginning with 1 that, when interpreted as a binary
integer, is a multiple of 5. For example, strings 101, 1010 and 1111 are in
the language; 0, 100 and 111 are not.
The set of all strings that, when interpreted in reverse as a binary integer,
is divisible by 5. Example of string in the language are 0,10011, 1001100
and 0101.
Q3. Give DFAs accepting the following languages over the alphabets {0,1}:
The set of all strings such that each block of five consecutive symbols
contain atleast two 0s.
The set of all strings whose tenth symbol from the right end is a 1.
The set of strings that either begin or end (or both) with 01.
The set of strings such that the number of 0s is divisible by five, and the
number of 1s is divisible by 3.
Q4. Convert the following NFA to a DFA and informally describe the language
it accepts.
!p
q
r
*s
*t

0
{ p,q }
{ r,s }
{ p,r }

1
{p}
{t}
{t}

Q5. Consider the following 2-NFA.


!p
q
*r

a
{p}
{q}
{r}

{p}
{q}

b
{q}
{r}

Compute the 2- closure of each state.


Give all strings of length three or less accepted by the automaton.
Convert the automaton to a DFA.
Q6. Design 2- NFAs for the following languages. Try to use 2-transitions to
simplify your design.
The set of strings consisting of zero or more as followed by zero or more
bs, followed by zero or more cs.

01

The set of strings that consist of either 0 repeated one or more times or
010 repeated one or more times.
The set of strings of 0s and 1s such that at least one of the last ten
position is a 1.

c
{r}
{p}

You might also like