Welcome! Log In Create A New Profile

Advanced

TG to RE: Tut answer method

Posted by Rbuys 
Announcements Last Post
Announcement SoC Curricula 09/30/2017 01:08PM
Announcement Demarcation or scoping of examinations and assessment 02/13/2017 07:59AM
Announcement School of Computing Short Learning Programmes 11/24/2014 08:37AM
Announcement Unisa contact information 07/28/2011 01:28PM
TG to RE: Tut answer method
November 15, 2010 12:33PM
I notice that in tut letter 102 Assignment 3, Question 1 answer, when turning the FA into a RE, the answer requires that you include the loop going back from state 2 to 1 to 2 as part of your RE. Isn't this redundant? Isn't that part of the forward loop (1 to 2 to 1) already? From what I can decipher from the text book, they would drop this second loop and only include your forward going transition (from state 1 to 2 to final state) and the loop from 1 to 2 to 1 as part of the self reference loop for state 1
Re: TG to RE: Tut answer method
November 15, 2010 04:06PM
Hi RBuys

Remember they want to get rid of state 2 and they need to add the path baa(a + b)*abb from state 1 to state 1 and the path abb(a + b)*baa from state 2 to state 2 that you see as redundant to allow the edge when they get rid of state 2 to generate the same kind of regex as what was available when state 2 still existed and was connected to state 1 through the abb transition edge and baa transition edge as seen on page 5 of tut letter 102.

So on the first diagram of page 5 that path baa(a + b)*abb may seem redundant, but as soon as you get rid of state 2 how will you be able to follow the path baa(a + b)*abb as many times as you want on state 1 before going to the final state?

I don't feel this question is a very good example on how to convert a TG to a REGEX because it is obvious that all possible words consisting of 0(Lambda) or more a’s and/or b’s are accepted thus the REGEX for the the TG is (a + b)* as stated in the 102 answer.
Re: TG to RE: Tut answer method
November 15, 2010 08:25PM
I'm not convinced, and feel I must disagree. Leaving (a+b)* aside, the abb - baa loop that you wish to assign to state two will only ever come after an initial baa from state 1 to state 2, it can't be found on its own. Thus you would always have baa -abb -baa. But that loop is already made with baa-abb-baa (from state1-state2-state1-state2 loop). See the argument on page 99 of Cohen, last paragraph.
Re: TG to RE: Tut answer method
November 15, 2010 09:27PM
In Cohen on page 104 we almost have the same example the only difference is state 2 is not a final state.

But have a look at when they eliminate state 2 they assign the whole path (ab+ba)(aa+bb)*(ab+ba) as a transition edge from state 1 to state 1 when they eliminate state 2 on page 104.

Now why we need to do the same for state 2 in Question 1 of Assignment 3 of letter 102 is because state 2 is a final state.

Hope it clears it up and good luck for tomorrow!
Re: TG to RE: Tut answer method
November 19, 2010 08:10PM
This post is late for revision purposes, but I also noticed that what's in the tut letter differs from what is in the text book. In the exam, I went with the way it was presented in the text book. I hope the markers will mark it right.
Sorry, only registered users may post in this forum.

Click here to login