Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Attached below (12 points) Given the following regular expression over the alphabet {a,b}, (ba)*(a+b) to transform it to a regular grammar, we first transform it

Attached below

image text in transcribedimage text in transcribedimage text in transcribed

(12 points) Given the following regular expression over the alphabet {a,b}, (ba)*(a+b) to transform it to a regular grammar, we first transform it to an NFA as the one shown below. Instead of converting this NFA to a regular grammar directly, we convert it to a DFA first and then convert the DFA to a regular grammar (why?). So we construct -closures of the above NFA, (0)={0,1,3}(1)={1,3}(2)={2}(3)={3}(4)={4}()= and build the following tree, ( 3 points) so that the following nodes of the tree can be used to build a DFA. Fill out the following blanks and blanks in the above tree. {0,1,3} (0.75 points) With the selected nodes from the above tree, we build a DFA by constructing the following transition table (the table on the left), and renaming the states as S (start state), I, J, K and L:(3.25 points) Then convert the table representation to a digraph representation as follows. Fill out the blanks in the following digraph. (1.25 points) However, we don't need the portion circled in the above digraph representation of the DFA (why?). By removing that portion, the FA is like the one shown on the left side of the following figure (no points for this FA). By constructing production rules from this FA, we get the production set of the regular grammar on the right side of the above figure. Fill out the blanks in the above figure. 1.75 points for the production set) Regular expression of the above FA is (2 points) which is equal to the given regular expression (ba)*(a+b). (Why?)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beyond Big Data Using Social MDM To Drive Deep Customer Insight

Authors: Martin Oberhofer, Eberhard Hechler

1st Edition

0133509796, 9780133509793

More Books

Students also viewed these Databases questions

Question

What is electric dipole explain with example

Answered: 1 week ago

Question

What is polarization? Describe it with examples.

Answered: 1 week ago

Question

=+Are they specific or general in nature?

Answered: 1 week ago

Question

=+ What is the nature of the contracts or agreements with unions?

Answered: 1 week ago

Question

=+What is the procedure for labor relations in the workplace?

Answered: 1 week ago