I'm trying to convert the following finite automata (DFA) to its corresponding regular expression using state elimination algorithm.
For this I'm following this link. The answer of that question has following example.
But in this sample automata, there is no state between the two looping transitions. For example there is no state between transition q
to r
and back r
to q
. But in my question, there is three such cases as mentioned in the above 1st diagram. For example there is a state IV
between the transition III
to V
and back V
to III
, via a
. For another example, there is three intermediate states between transition I
to V
and back V
to I
via b
.
I've tried to search such case on INTERNET, but can't found such issue. I've tried to attempt this question and could eliminated the II
state, as following:
I'm stuck in eliminating state I
, III
and IV
. Suppose I remove state III
, than where should the transition from V
to III
via a
can be placed? If I eliminate state IV
, what will happen to transition IV
to I
?
Is there any general method for this type of cases? Any help will be appreciated.
Thank you very much in advance!