Non-Deterministic Finite Automaton (NFA)
It might seem at a surface level that NFAs seem more powerful than DFAs, but they are not.
Non-Deterministic Finite Autonomaton
This is pretty much the same as the DFA, except for . A deterministic finite automaton (DFA) is a five-tuple where:
- is a finite set of symbols (the alphabet).
- is a finite set of states.
- is the start state.
- is the set of accepting states.
- is the transition function that, given a state and alphabet symbol , returns the new state to transition to after processing the symbol in state ( is the set of all subsets of )
-transitions
To make it easier to more systematically combine NFAs, we add -transitions. Whenever the NFA is in a state with an outgoing -transition, it may optionally choose to follow that transition without processing any symbols from the input word.
Using -transitions, we can combine the two DFAs without having to modify them, just by adding a new start state with -transitions to the former start states of the two DFAs, as shown in the following diagram:

From the new start state, a path through the NFA starts by following one of the -transitions to one of the former start states, depending on whether the input word is a decimal or hexadecimal number.
So the transition is optional. The example below illustrates this:
