You are on page 1of 4

(00:00)

Exactly the same tasks that we


have written in our algorithm.

(00:04)
So let's see here we have
the starting state, which is A.

(00:08)
Then we have stats B, C, and D,
and then we have the accept state

(00:14)
here we we have not mentioned the reject
state, but we presume that any missing

(00:19)
input in each state leads
us to the reject state.

(00:23)
And also, as you know that your
machine is deterministic.

(00:27)
So there should be transition
for each input symbol.

(00:31)
But we have not mentioned the missing
transitions, and we have presumed these

(00:36)
missing transitions in each state
will lead us to the reject state.

(00:42)
So now let us see how it works.

(00:45)
So we are in the start state

(00:49)
and we get the input zero.

(00:51)
So we replace zero with an X.

(00:56)
Now we are in state B and we move
to the right until we find the first one.

(01:05)
So instead B the state B help us
to find the first one.

(01:14)
How

(01:18)
instead B, if we find a zero, so zero will
remain zero and we have to move right.

(01:26)
And also if we encounter a Y, so Y will
remain Y and we have to move right.

(01:33)
But if we find a one,

(01:36)
then we replace that one with Y and we
move to the next state, which is C.

(01:42)
So in transition diagram, you see
that the transition one tends to Y L.

(01:49)
So this transition mean
that I replace one with a Y

(01:53)
and I move to the left.

(01:56)
So now

(01:58)
we are instead C state C help us

(02:01)
in finding the leftmost zero,
because when we encounter zero or Y

(02:06)
instead C, we change nothing
until we have find an X.

(02:12)
So when we encounter X,
we come to know that following this X is

(02:18)
my leftmost zero, so X remains X,
but we move one step to the right.

(02:24)
Now my tab head is over the leftmost zero,
and I am at state A again,

(02:30)
so I change zero with an X, and this
whole process will continue again.
(02:37)
So on encountering Y,

(02:39)
I have to change it to encountering one,
I have to change it to Y

(02:46)
and moving left to find the leftmost zero
and change it to X.

(02:54)
So we move left,
replacing each zero with an X,

(02:58)
and then move right
and replacing each one with a Y,

(03:05)
and we repeat these steps again and again

(03:10)
until we

(03:13)
replace all zeros with X
and all ones with Y's.

(03:20)
So unchanging the last one with Y.

(03:25)
I am instead C and the tape
head will move to the left.

(03:30)
So if I encounter Y,

(03:32)
I remain in state C and I don't
change nothing but keep moving left.

(03:38)
And when I encounter the first X,

(03:41)
I go to state A and here as
I don't have no more zeros.

(03:46)
Also, the tab head moves to the right
where I encounter with a Y.

(03:53)
So now I make transition from state A
(03:55)
to state D and my tab
head moves to the right.

(04:00)
The loop over state D indicates
that unencountering each y.

(04:05)
I don't replace it, but I keep moving
to the right until I find a blank symbol

(04:12)
and unencountering a blank symbol.

(04:16)
I go to the accept state that is,
my string is accepted and my tape head

(04:22)
moves to left so this string
0011 will be accepted.

(04:30)
So this was how the transition diagram
and tape and Tutoring machine works.

(04:35)
So hopefully.

(04:36)
So you now understand how Turing machine
is designed and how the tape works.

(04:43)
So thank you for watching
and see you in the next lecture.

(04:46)
Bye.

You might also like