0% found this document useful (0 votes)
41 views5 pages

Fall 2014 - CS402 - 2 - SOL

The document provides instructions for Assignment #2 of the Theory of Automata course. It states that the assignment is due on December 4, 2014 and outlines the rules for marking, including that assignments submitted late or in incorrect formats will not be accepted. It also provides contact information for any queries and contains two questions - the first asks to draw the transition graph for a regular expression, and the second asks to draw finite automata for two languages and their concatenation.

Uploaded by

Anam Manzoor
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
41 views5 pages

Fall 2014 - CS402 - 2 - SOL

The document provides instructions for Assignment #2 of the Theory of Automata course. It states that the assignment is due on December 4, 2014 and outlines the rules for marking, including that assignments submitted late or in incorrect formats will not be accepted. It also provides contact information for any queries and contains two questions - the first asks to draw the transition graph for a regular expression, and the second asks to draw finite automata for two languages and their concatenation.

Uploaded by

Anam Manzoor
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

Theory of Automata (CS402)

Assignment # 2(Graded)
Total marks = 20
Deadline Date = Dec 04,
2014

Please carefully read the following instructions before attempting


assignment.

Rules for Marking


It should be clear that your assignment would not get any credit if:

The assignment is submitted after the due date.


The submitted assignment does not open or file is corrupt.
Strict action will be taken if submitted solution is copied from any other
student or from the internet.

1 You should concern recommended books to clarify your concepts as


handouts are not sufficient.
2 You are supposed to submit your assignment in .doc format. Any other
formats like scan images, PDF, zip, rar, bmp etc will not be accepted.

Note:
No assignment will be accepted after the due date via email in any case
(whether it is the case of load shedding or internet malfunctioning etc.).
Hence refrain from uploading assignment in the last hour of deadline. It is
recommended to upload solution file at least two days before its closing
date.

For any query, feel free to email at:


[email protected]
Q.1: Consider the following Regular Expression (RE):
zx(y + z)* x (x + y+ z)*y + zy(x + z)* x (x + y+ z)*y + zz(x + y)* x (x
+ y+ z)*y
Draw transition graph for the above RE.
[Marks 4]
Solution:

Q.2: Consider the following languages defined over = {a, b}


L1={^,aa, bb}
L2={a, b, ab}

a) Draw Finite Automaton (FA) for L1 and L2.


b) Draw FA for the concatenation of L1 and L2
[Marks 3+3+10]
Solution:

FA for L1

FA for L2

Transition Table:
Old States

z1-=(x1,y1)
z2+=(x2,y2)
z3+=(x4,y3)
z4=(x5,y1,y4)
z5+=(x3,y5)
z6=(x3,y4)
z7=(x6,y1,y4)
z8+=(x3,y2,y4)
z9+=(x3,y3,y4)
z10+=(x3,y2,y4)
z11+=(x3,y5,y4)

FA for L1*L2

New States after reading


a
b

(x2,y2)=z2
(x5,y1,y4)=z4
(x3,y4)=z6
(x3,y2,y4)=z8
(x3,y4)=z6
(x3,y4)=z6
(x3,y2,y4)=z10
(x3,y4)=z6
(x3,y4)=z6
(x3,y4)=z6
(x3,y4)=z6

(x4,y3)=z3
(X3,Y5)=z5
(x6,y1,y4)=z7
(x3,y3,y4)=z9
(x3,y4)=z6
(x3,y4)=z6
(x3,y3,y4)=z9
(x3,y5,y4)=z11
(x3,y4)=z6
(x3,y5,y4)=z11
(x3,y4)=z6

You might also like