Professional Documents
Culture Documents
The two popular methods for converting a FA to its regular expression are:
● Arden’s Method
● State Elimination Method
……………………………………………………………………………………………………………………………….
Arden’s Method:
It states that-
Let P and Q be two regular expressions over ∑.
If P does not contain a null string ∈ , then:
R = Q + RP has a unique solution i.e. R = QP*
Steps:
Step 01:
● Form an equation for each state considering the transitions which come
towards that state.
● Add ‘∈’ in the equation of initial state.
Step 02:
Bring the final state in the form R = Q + RP to get the required regular expression.
----------------------------------------------OR-------------------------------------------
Step 01:
Create equations as the following form for all the states of the DFA having n states with
initial state q1.
q1 = q1R11 + q2R21 + … + qnRn1 + ε
q2 = q1R12 + q2R22 + … + qnRn2
…………………………
qn = q1R1n + q2R2n + … + qnRnn
Rij represents set of labels of edges from qi to qj, if no such edge exists, then Rij = ∅
Step 02:
Solve these equations to get the equation for the final state in terms of Rij
**Important**
Note 1:
Arden’s Theorem can be used to find a regular expression for both DFA and NFA
Note 2:
If there exists multiple final states, then-
..………………………………………………………………………………………………………………………….
Steps:
Step 01:
The initial state of the DFA must not have any incoming edge
If there exists any incoming edge to the initial state, then create a new initial state
having no incoming edge to it. and add an €-transition between them
Step 02:
There must exist only one final state in the DFA.
If there is more than one final state or if the single final state has transitions out, add a
new accepting state, make all other states non-accepting, and add an €-transition from
each former accepting state to the new accepting state.
Step 04:
In the end,
The state elimination method can be applied to any finite automata (NFA, ∈-NFA, DFA etc)
initial state]
tq 410 t £ adel e an it u
29a 9q
ca3 9090+93
*Rom cauoiom1:
Applyuma Prdum's ThaoemR tRP R= 9P*|
* am eauation d2.
Sulssitultca.44 volua inca
q 01+ 9a y Adans ThLorsmn
a 0I -(5S)
tom equaiom 3
Susttut valu om e9
By Arcum'A Thi0xUm
011O(bt1)
xamplta
n i i a l atat
Rhal todte
3)-3 0
Subabtu eq 3 ualu in eq
a ( l t ol) Aq Ptadun'a P OR
P9
4 ( 1(1t61)*
t
o o) +¬
(0{Ito1)
Atdun's Law
14D1* oo)
91 E o (
- (otLLito)* o o)*
Ex anpl S
yfnal tat
(13 ,0inubal gtat
4
-93 9aD90t 2
930t9.0 + 911
93
93
t ( o t1)-S
3
în S
S yt d o n ' s Thso e
98 (0+1)o*
ovn t9 2 nd aluu 9 -
alu
1191ot 4-0+l) o (7)
uk in e s )
RElo (ot11Do* )
Exomplu for Stadt Euminatuon muthoo
Exanmpl
O
StOxA
Thu încoming tamaiion to ne statiSo w mud
to mab taut
mu
atad
Thuu
u outgauma ttamatuon tom umal stau so nw
mastat niud to u made
(1a
elumi ratu
(1
h ininatt , 0,1
oos(1.)-
RLgula Expiisuon 0*]+0(0+1
Examplu 110
(132
(2
ol
O0
ElGrr noda
1tD1) o00 E
elrminata
-
Exomplu3 3
amtnation3
Eliminati q
11+0
luminot 3
(11+0jo*\
6Elmumatu
> (15
(