Skip to main content

5. Regular Expressions

16/02/23

tools - grep, sed specify lexical syntax

DenotedProcedural
REDFA, NFA

Example of RE - (0+11+10101)(0+11+101*01)* Σ={0,1}\Sigma=\{0,1\}

Define REΣ\Sigma and given E:REΣ,E:RE\Sigma, .....

  • - is a regular expression
  • ϵ\epsilon - is a regular expression
  • LL∅ = {}
  • LL∅ = λ??False\lambda ?? False
  • LϵL\epsilon = {ϵ}\{\epsilon\}
  • ??

* just means all of the concatenations

For every E:REΣE:RE\Sigma we construct an NFA, NREE:NFAΣN^{RE}E:NFA\Sigma such that LREE=LNFA(NREE)L^{RE}E=L^{NFA}(N^{RE}E)