1

I am reading this text book and it says that stay put turing machine recognizes the same languages as regular turing machine by just adding transition functions (without adding any new states or symbols). I am trying to figure that out.. But so far, no luck. I think the key here is "recognizes" rather than "decides"? How do i prove this? Thanks

frazman
  • 113
  • 4

1 Answers1

4

No, the key terms are not "recognizes" and "decides", but rather "simulates". Given a Turing machine that can stay put, you can simulate it using a Turing machine that doesn't stay put. Given a transition of the form:

  • On state $s_1$, if the symbol under the head is $\alpha_1$ then change it to $\alpha_2$, stay put and transition to state $s_2$

you replace it with a pair of transitions

  • On state $s_1$, if the symbol under the head is $\alpha_1$ then change it to $\alpha_2$, move right and transition to $s'$
  • For every symbol $\beta$: On state $s'$, if the symbol under the head is $\beta$ then change it to $\beta$, move left and transition to state $s_2$

Here $s'$ is a new state that is used only to handle this transition.

The new Turing machine doesn't stay put but simulates the original Turing machine.


As the OP points out, we can actually improve this simulation by not adding new states at all (except for possibly one more state, a "stuck" state). Suppose we are at state $s_1$, see the symbol $\alpha_1$, and stay put. Let us continue to follow the machine. Either the machine never moves away from its spot, or it eventually moves either left or right, transitioning to state $s_2$ after changing the original symbol to $\alpha_2$. In the latter case, we can change the transition to a simple transition to $s_2$. In the former case, we can move instead to a special "stuck" state in which the Turing machine finds itself in an infinite loop; this state can be common for all "stuck" situations.

If we are guaranteed that the original Turing machine never gets stuck, and this is probably the assumption in your textbook, then we can do away with the "stuck" state, so that no new states are needed at all.

Yuval Filmus
  • 276,994
  • 27
  • 311
  • 503
  • But the claim is you can do this without adding a new state.. and just using transition functions – frazman Jan 17 '15 at 10:08
  • and since new state is not allowed, I am guessing there is this weaker claim of "recognizibility" rather than decidability.. By the way, whats the difference between "deciding" and simulating? – frazman Jan 17 '15 at 10:09
  • 1
    See my response. You might have to add one more state, though if you know ahead of time that the machine always halts, this won't be needed. – Yuval Filmus Jan 17 '15 at 11:05
  • 1
    Simulation is an altogether different concept. It's a proof technique. Suppose you want to show that everything that can be done with X machines can also be done with Y machines. One way of showing this is to show how a Y machine can simulate the operation of an X machine. A good example is compilation, which simulates a high-level programming language in assembly language. – Yuval Filmus Jan 17 '15 at 11:10
  • Why can't the state be changed to even in stay-put condition.. (say $$\delta(q_1,\alpha_1) \rightarrow (q_2, \alpha_2, S)$$.. that is also valid?? – frazman Jan 18 '15 at 03:34
  • It can be changed all right, and this figures in the new transitions. – Yuval Filmus Jan 18 '15 at 10:27
  • suppose I have a tape like

    $01q_10010$ $\delta(q_1,0) \rightarrow (q_2,1,S)$ will result in $01q_21010$ and lets say $\delta(q_2,1) \rightarrow (q_a,0,R)$ This will result in accepting the above string.. now in regular TM, how do i simulate the above.. $\delta(q_1,0) \rightarrow (q_2,1,R)$ will give me $011q_2010$ But it is possible that we have a transition function $\delta(q_2,0) \rightarrow (q_r,0,R)$ Now, the same string will be rejected?? how do i reason for such moves?

    – frazman Jan 19 '15 at 02:16
  • The simulation is $\delta(q_1,0) \to (q_a,0,R)$ (if I understand your notation correctly). This is the final outcome of the two transitions you describe ($q_1 \to q_2 \to q_a$). – Yuval Filmus Jan 19 '15 at 02:24
  • So sorry for repeated comments.. but in regular TM.. when I made the transition from $q_1 \rightarrow q_2$, with R move, the head is now reading 0.. right?? which can lead to reject state?? I think, I am lacking something very fundamental.. Am i making any sense? – frazman Jan 19 '15 at 03:24
  • 1
    hmm.. rereading your comment again.. is it that we can change the transition functions completely... so basically.. $\delta_M(q_i, x_1) = (q_j, x_2, S)$ can be replaced by $\delta_N(q_i, x_1) = (q_j, x_2, R), \delta_N(q_i, x) = (qj, x, L)$ – frazman Jan 19 '15 at 03:28
  • Yes, something of that sort. It's better if you worked it out yourself. – Yuval Filmus Jan 19 '15 at 04:44