main.py
A regular expression R
-
The following regular expression conventions are recognized by this program:
- The only input characters permitted are lowercase letters a-z and numeric digits 0-9
- Parentheses may be used to manipulate order of operation
- Epsilon is represented using the symbol E
- A union is represented by the symbol +
- The Kleene star is represented by the standard symbol *
- Concatenation is represented by the symbol .
-
Note: implicit concatenation is not permitted, i.e. "aba" should be written as a.b.a
A string w
- Convert the regular expression R to an epsilon-NFA M1.
- Remove epsilon transitions to obtain epsilon-free NFA M2.
- Test if the string w is accepted by the epsilon-free NFA M2.
True/false: Whether or not the string w is the in the language of the regular expression R, i.e. if w is in L(R).