Professional Documents
Culture Documents
AUTOMATA
AUTOMATA
language.
A right regular grammar (also called right linear grammar) is a formal grammar (N, Σ, P, S) such
that all the production rules in P are of one of the following forms:
3. B → ε - where B is in N and ε denotes the empty string, i.e. the string of length 0.
In a left regular grammar (also called left linear grammar), all rules obey the forms
An example of a right regular grammar G with N = {S, A}, Σ = {a, b, c}, P consists of the
following rules
S → aS
S → bA
A→ε
A → cA
and S is the start symbol. This grammar describes the same language as the regular expression
a*bc*.
An extended right regular grammar is one in which all rules obey one of
An extended left regular grammar is one in which all rules obey one of
There is a direct one-to-one correspondence between the rules of a (strictly) left regular grammar
and those of a nondeterministic finite state automaton, such that the grammar generates exactly
the language the automaton accepts. Hence, the left regular grammars generate exactly all
regular languages. The right regular grammars describe the reverses of all such languages, that
is, exactly the regular languages as well.
REGULAR SETS
Now for some general cases. If α and β are regular expressions representing the
The sets which can be represented by regular expressions are called regular
sets. When writing down regular expressions to represent regular sets we shall
often drop parentheses around concatenations. Some examples are 11(0 + 1)*
(the set of strings beginning with two ones), 0*1* (all strings which contain a