log in
Formal
Languages
and the
Theory of
Computation
Spring 2006
course
home
wiki
syllabus
assignments
navigation
help
.. /
. /
Regular Expressions to CFG
Regular Expressions embedded in a CFG can be converted to normal CFG rules as follows:
For X -> A* :
X -> e X -> D X -> DD D -> A
For Y -> A.B :
Y -> AB
For Z -> AUB :
Z -> A Z -> B
http://cs.marlboro.edu/
courses/
spring2006/formal_languages/
wiki/
Regular_Expressions_to_CFG
last modified Thursday August 31 2006 2:24 am EDT