224 views
0 votes
0 votes

Write the Regular expression using arden’s lemma

2 Answers

Best answer
0 votes
0 votes
A→ epsilon      (1)
B→ Aa + Da     (2)
C→ Bb             (3)
D→ Ab + Bb      (4)

Sub (1) in (2) and (1) in (4)

B→ a + Da  (5)

D→ b + Bb  (6)

Sub (6) in (5)

B→ a + (b + Bb)a

B→ a + ba + Bba

B→ (a+ba)(ba)*    (7)[On applying lemma]

Sub (7) in (3)

C→ (a+ba)(ba)*b

Regular Expression is the sum of final states

RE = A + C = epsilon + (a+ba)(ba)*b
0 votes
0 votes
From the above diagram, Starting state is A which takes epsilon as the value, since it is the final state as well either it will end here or it will take another value a which leads to state B or b which leads to state C I.e A- epsilon B- A(a) + D(a) C- B(b) D- A(a) + B(b) The string will continue as a+ba)(ba)* from state B and end at C by taking b as final value Final answer is.. ^+(a+ba)(ba)*b

Related questions

0 votes
0 votes
1 answer
1
Biswajit Kumar asked Sep 13, 2023
203 views
Consider the following language definition:L= {(M) | M is a DFA and M accepts some string of the form ww^R for some w€ ΣL isA. RegularB. Context-free but not regularC....
0 votes
0 votes
0 answers
2
Mk15 asked Nov 2, 2021
206 views
Construct a Reduced Grammer equivalent to the grammerS → aS/A/CC → aCbA → aB → aa
0 votes
0 votes
3 answers
3
Mk15 asked Nov 2, 2021
350 views
Remove the Null ProductionsS → XYX → ZbY → bWZ → ABW → ZA → aA | bA | ΛB → Ba | Bb | Λ
1 votes
1 votes
0 answers
4
Abhishek Kumar 40 asked Aug 7, 2018
758 views
can 0*1+1* generate 01 and 11 and 011?what would be the minimal dfa ?