state machine
noun
°A formalism for describing computation, consisting of a set of states and a transition function describing when to move from one state to another.
"This algorithm will produce a state machine for parsing a given context-free grammar."