Fix a deterministic, single-tape Turing machine with tape cells indexed by the integers. A precise definition is the tuple
Here is a nonempty finite set of control states, a finite tape alphabet with a designated blank symbol , the input alphabet, the initial control state, and distinct halting control states. The transition function is total on the displayed domain. The Turing machine instruction means to write over the scanned , enter control state , and move the head one cell in direction .
A Turing machine configuration is , where , is the head position, and is the tape-content function, equal to outside a finite set. Its next-configuration relation is
if , with for and for , and
There is no successor to either halting Turing machine configuration.
For input , the initial Turing machine configuration is , where for and is blank elsewhere. In particular, the initial tape for the empty word is entirely blank. The recognized formal language is
The relation permits any finite number of transitions. An input outside may reach the rejecting control state or run forever; recognition does not require halting on every input.