R
roxorsoxor2345
I am very sorry if this is not the appropriate group to post this
question.
I currently have a program that tests strings to see if they are
palindromes. My input file looks something like this:
0 a # R 1 (# is representation for a blank)
0 b b R 1
0 # # L 2
1 a a R 2
..
..
..etc... (followed by a list of strings i wish to test)
This is a transition table that works like this:
column 1 is the current state
column 2 is the currenty symbol on the tape (the tape contains my
string to test)
column 3 is what the new symbol should be
column 4 tells the head of the tape to move left, right, or stay still.
column 5 tells me what the new state is.
Like I said, I have a program that works for palindromes, however I
need to modify it to accept strings of the type (a^n)(b^2n)(c^n)
All I need is a new transition table, and new strings to test, and I'm
set. However I am having a tough time coming up with a working
transition table for this problem. I know that if I could draw the
picture I could come up with the transition table, but I can not get my
turing machine quite right. Any help would be appreciated.
question.
I currently have a program that tests strings to see if they are
palindromes. My input file looks something like this:
0 a # R 1 (# is representation for a blank)
0 b b R 1
0 # # L 2
1 a a R 2
..
..
..etc... (followed by a list of strings i wish to test)
This is a transition table that works like this:
column 1 is the current state
column 2 is the currenty symbol on the tape (the tape contains my
string to test)
column 3 is what the new symbol should be
column 4 tells the head of the tape to move left, right, or stay still.
column 5 tells me what the new state is.
Like I said, I have a program that works for palindromes, however I
need to modify it to accept strings of the type (a^n)(b^2n)(c^n)
All I need is a new transition table, and new strings to test, and I'm
set. However I am having a tough time coming up with a working
transition table for this problem. I know that if I could draw the
picture I could come up with the transition table, but I can not get my
turing machine quite right. Any help would be appreciated.