You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
This module implements a Nondeterministic Finite Automaton (NFA) in Haskell, following the concepts of automata theory and based on Kleene’s Theorem, which asserts the equivalence of regular expressions and NFAs.
📚 Overview
An NFA is a computational model used to recognize regular languages. This implementation supports:
Creation of an NFA with states and transitions
Input simulation and state transitions
Final state verification
Transition table printing
🔧 Data Types
type State = Int
An alias for state identifiers.
type Symbol = String
An alias for input symbols.
type TransitionInput = (State, Symbol)
Defines the key for the transition function: a state and an input symbol.
type DestStates = Set State
The set of destination states for a given transition.