1 Turing Machines
Computation and programming
Turing Machine as Transducer
Transducer -- any device that converts
a signal from one form to another
Turning machine
Converts input to output Start with string on the tape After acceptance string left on the tape
Computation with Turing Machines
Computing functions with TMs
The result of the function applied to an
input string x, will be left on the tape when the machine accepts.
Functions with multiple arguments can be
placed on the input tape with arguments separated by some character.
Computation with Turing Machines
Turing’s original use of his machine was to
calculate integer valued functions.
Integers were represented in unary as blocks of a
single symbol.
Example
111111 would represent 6 1111 would represent 4
In our text
1s are used as the unary symbol 0s are used to separate arguments
Computation with Turing Machines
Computing functions with TMs
Formally,
Let M = (Q, Σ, Γ , δ, q0, , F) be a TM and let
f be a partial function on Σ*. We say T computes f (or f is Turing-computable) if for every x ∈ Σ* where f is defined:
q0x a
* pf(x) Where p ∈ F And for every other x, T rejects on input x.
Computation with Turing Machines
Computing functions with TMs
Formally (with multiple arguments)
Let M = (Q, Σ, Γ , δ, q0, , F) be a TM and let f be a
partial function on (Σ*) k. We say T computes f (or f is Turing-computable) if for every (x1, x2. …, xk) where f is defined:
q0x1 0x2… 0xk a * pf(x1, x2. …, xk) Where p ∈ F And for every other k-tuple, T rejects on input x.