Type a regular expression
Use the Regex panel to build an NFA from an expression, or draw an NFA here and turn it into an expression.
Double-click anywhere on the canvas to add your first state.
Regex ⇄ NFA · Chapter 1.3
Use the Regex panel to build an NFA from an expression, or draw an NFA here and turn it into an expression.
Double-click anywhere on the canvas to add your first state.
A language is regular exactly when a regular expression describes it, and exactly when a finite automaton recognizes it. This page lets you move between the two the way Sipser does in Chapter 1.3: build an NFA from any regular expression, piece by piece, and turn any NFA into a regular expression by removing states from a generalized NFA.
| Type | Means |
|---|---|
a|b or a∪b | a or b (union) |
ab | a followed by b |
a* | zero or more a's |
a+ | union or “one or more”, your choice in the panel |
ε, \epsilon or () | the empty string |
∅ or \emptyset | the empty language |
Σ or \Sigma | any one symbol of the alphabet |
(a|b)*abb.