Setting up deterministic finite automata and transitions