Troubleshooting X+y Turing Machine Example

Click For Summary

Homework Help Overview

The discussion revolves around understanding a Turing machine example for computing the function x+y, specifically using the specifications provided in a computability textbook. The original poster is attempting to verify the operation of the machine with specific input values.

Discussion Character

  • Exploratory, Conceptual clarification, Problem interpretation

Approaches and Questions Raised

  • The original poster describes their attempt to simulate the Turing machine with specific input values and expresses confusion about the starting state and position on the tape. They question the correctness of their simulation results.
  • Another participant seeks clarification on the meaning of the specifications provided for the Turing machine.
  • A participant explains the format of the specifications and how they dictate the machine's operations, indicating their own uncertainty about the starting conditions.
  • One participant suggests a possible correction to the specifications, implying that there may be an error in the original setup.

Discussion Status

Contextual Notes

Participants are navigating potential misunderstandings regarding the Turing machine's specifications and the implications for its operation. There is a focus on verifying the correctness of the initial setup and the actions dictated by the machine's states.

wheezyg
Messages
5
Reaction score
0
I am working out of Cutlands computability book and I am having trouble understanding the following example:

"The function x+y is Turing-computable." Then the example lists the following specifications:
q_1 1 B q_1
q_1 B R q_2
q_2 1 B q_3
q_2 B R q_2


I wanted to verify this worked for, say, x=2 and y=1. I should end up with three. I started by writing out the tape the machine should begin with (blank marked by B):
...| 1 | 1 | B | 1 | B | ...

The first problem I am having is not understanding where I should start and what state it the start should be. When I start with the following square (marked with * to the right of the number in the square) at state q_1, I get the following:

Start ...| 1* | 1 | B | 1 | B | ...
End ...| B | B | B | 1 | B | ...

Which cannot be correct since I am attempting to add 2&1 not subtract 1 from 2. Can someone please point out what I am doing wrong?

Thank you!
 
Last edited by a moderator:
Physics news on Phys.org
No help for your question, but for future reference, the word is Turing, after Alan Turing, a British mathematician who was on the team during WW II that decrypted the messages encoded by the German Enigma machine.
 
wheezyg said:
"The function x+y is Turing-computable." Then the example lists the following specifications:
q_1 1 B q_1
q_1 B R q_2
q_2 1 B q_3
q_2 B R q_2
What does a row of this table actually mean?
 
They are just the quadruples that give the specification for the machine.

These can be of the form q_i s_j s_k q_l where the action is specified for the Turing machine in state q_i containing the symbol s_j. If s_k is another symbol, we replace s_j with s_k, if s_k = L (or R) we move one square to the left (or right). The final q_l tells us that we now change the state of q_i to q_l.

So q_2 1 B q_3 (row three) tells me to change the value of 1 in the square of state q_2 to B (blank) then change its state to q_3.

I am stuck on the example since I don't know if I am starting in the correct square in e correct state.
 
Last edited:
Are you sure the turing machine wasn't supposed to be:
Code:
q1 1 B q1
q1 B R q2
q2 B 1 q3
q2 1 R q2
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 25 ·
Replies
25
Views
4K
  • · Replies 3 ·
Replies
3
Views
2K
Replies
29
Views
6K
  • · Replies 0 ·
Replies
0
Views
1K
  • · Replies 0 ·
Replies
0
Views
1K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
1
Views
1K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K