Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Exam (elaborations)

Theoretical Computer Science II COS2601 Semester 1 School of Computing

Rating
-
Sold
-
Pages
11
Grade
A+
Uploaded on
08-03-2022
Written in
2021/2022

Theoretical Computer Science II COS2601 Semester 1 School of Computing

Institution
Course

Content preview

COS2601/203/1/2017




Tutorial letter 203/1/2017

Theoretical Computer Science II
COS2601

Semester 1


School of Computing


Discussion of Assignment 3




BARCODE

, Dear student

Solutions to the questions of assignment 3 are provided in this tutorial letter.

Regards
COS2601 team

Question 1
Kleene’s theorem can be used to turn a transition graph (TG) into a regular expression. Which one of the
following regular expressions would generate a language that would be equivalent to the language
described by the following TG?




1. aab*a + bba*
2. (aa + bb)(b + a)*a
3. aabb(a + b)*a
4. (bba*)* + (aab*a)* + ba

Answer: Option 1

Discussion
The b-loop at x2 can be written as b* and the a-loop at x4 as a*.
One path from start to final state (x1 to x3) is thus: aab*a.
The second path from start to final state (x1 to x4) is thus: bba*.
The ba-edge from x1 to x5 can be ignored as it does not lead to a final state.

It is now simply a matter of combining these parts of the regular expression to get to
aab*a + bba*
From this, it is clear that option 1 is the correct option.

The other options misinterpret the paths to final states, often incorrectly concatenating paths.

Question 2
Given FA1 (with regular expression r1) and FA2 (with regular expression r2), a transition table is being put
together to build an FA for r1 + r2.

New state Read an a Read an b
-z1 +z2 z3
+z2




2

Written for

Course

Document information

Uploaded on
March 8, 2022
Number of pages
11
Written in
2021/2022
Type
Exam (elaborations)
Contains
Questions & answers

Subjects

$7.99
Get access to the full document:

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Get to know the seller

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
NURSMontero West Virgina University
Follow You need to be logged in order to follow users or courses
Sold
61
Member since
5 year
Number of followers
60
Documents
524
Last sold
9 months ago
FOR THE BEST EXAMS AND VERIFIED ANSWERS GURANTEED A+

Profession and have specialised in Nursing , Psychology and Humanities Courses

4.1

15 reviews

5
10
4
2
3
0
2
1
1
2

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions