Regex-to-Nfa is a Haskell project implementing the regular expression to nondeterministic automata (NFA) conversion algorithm.
Use the build tool Haskell Tool Stack to run Regex-to-Nfa.
stack build
stack run regex-to-nfa -- runs project on multiple given examples
stack ghci
:l main.hs
let re = "(ab)*a|c"
testOne re -- prints NFA for regex given above
Matching capability in progress, not fully implemented
Email rwilliams1@gm.slc.edu with any known issues.
Eventually aim to implement matching (i.e. is a given string accepted in the regex's language), conversion from NFA to DFA, and pretty printing for NFAs and DFAs alike.
Pull requests are welcome.
Written by Rachel Williams, with the help of Michael Siff.