I am fairly new to automata, regular expressions and regular grammar. I am struggling to understand how to define the regular expression (abc)* into one or several regular grammar expressions. Following production rules are applied
- N={S,A,B}
- Σ={a, b c}
- S being the start symbol
So far i have found these two.
S → aA
A → bB
B → cS
S → ε
and
S → Ac
A → Bb
B → Sa
S → ε
Are both of the grammars over correct or do i have the wrong idea? I just dont understand why the two grammars over are correct while the bottom two are not.
S → aA
A → bB
B → cS
B → c
and
S → Ac
A → Bb
B → Sa
B → a