2

We have grammar with nonterminals $ X_1,...X_n$ terminals $V_t$ and rewriting rules of form:

$X_i \rightarrow a \in V_t $

$X_i \rightarrow X_jX_k, \ i \ge j , \ i > k $

How can I show that language generated by this grammar is regular?

I don't think this is duplicate question, because:

  • I don't have concrete language, but set of nonterminals and set of terminals
  • I have to show, that for every possible combination of terminals and nonterminals I get only language which is regular

If I had been given particular language, I could prove it by giving DFA, showing that rules are only of linear type,etc....

D.W.
  • 167,959
  • 22
  • 232
  • 500

1 Answers1

1

Prove by backwards complete induction that each $X_i$ generates a regular language (backwards induction means that you first prove it for $X_n$, then for $X_{n-1}$, and so on, until you reach $X_1$; complete induction means that when proving this for $X_i$, you can use the induction hypothesis for all of $X_{i+1},\ldots,X_n$).

Perhaps the easiest way to carry out the inductive proof is to give a regular expression for the language generated by each $X_i$.

The only non-trivial part is handling productions of the form $X \to XY$. Here you need to use Arden's rule, which states that if the only productions having $X$ at the left-hand side are $X \to XY \mid Z$ then $$ L(X) = L(Z)L(Y)^*, $$ where $L(X)$ is the language generated by $X$.

Yuval Filmus
  • 280,205
  • 27
  • 317
  • 514