# Turing machines with a single tape.

• Nov 14th 2010, 03:00 PM
girgishf
Turing machines with a single tape.
In this question, we consider Turing machines with a single tape. suppose we modify the machine to be a Splicing Turing machine STM. when a STM cuts a square out of the tape, it cuts the square where the head is currently located. After the cut, the head is located just to the right of the place where the square was cut out. For example, suppose the tape contents are abcde and the head is located at the d. If the STM inserts one square, then moves left two squares and cuts out one square, the resulting tape contents would be acd_e (where _ indicates a blank) and the head would be at the c.

a) briefly describe hoe every STM can be simulated using an ordinary Turing Machine.

b) Suppose you had a STM algorithm that took at most T(n) steps on all inputs of length n. Inserting a square into the tape or cutting a square out of the tape counts as a single step of the STM. Give a good upper bound on the number of steps an ordinary Turing machine would take when simulating the STM using the simulation you gave in part (a). If you like, you may use big-O notation to state your bound; you do not have to worry about constant factors. Explain Your answer please.
• Nov 15th 2010, 06:38 AM
emakarov
To simulate insertion of the new square, copy the portion of the tape that is right of the head one square to the right. Similarly, to simulate cutting of a square, copy the right portion one square to the left. This takes O(n) steps where n is the tape length.

If the initial tape length is n and the machine makes T(n) steps, the maximal tape length is n + T(n). Thus, each of the T(n) steps of an STM can be simulated by O(n + T(n)) steps of a regular TM. To get the final big-O estimate, it may be convenient to assume that T(n) is non-decreasing and to consider two cases: n is O(T(n)) and T(n) is O(n). (Though this is not necessary.)
• Nov 15th 2010, 06:41 AM
girgishf
Thank you :)