Turing-machines
Question 1 |
L1 = {〈M〉|M takes at least 2016 steps on some input},
L2 = {〈M〉│M takes at least 2016 steps on all inputs} and
L3 = {〈M〉|M accepts ε},
where for each Turing machine M, 〈M〉 denotes a specific encoding of M. Which one of the following is TRUE?
L1 is recursive and L2, L3 are not recursive | |
L2 is recursive and L1, L3 are not recursive | |
L1, L2 are recursive and L3 is not recursive | |
L1, L2, L3 are recursive |
Since counting any number of steps can be always decided.
We can simulate TM (M) whether it takes more than 2016 steps on some input string, which has length upto 2016.
If it happens then reached to accepting (YES) state else reject (NO).
L2 is recursive:
Similarly, we can simulate TM (M) whether it takes more than 2016 steps on each input string which has length upto 2016.
If it happens then reached to accepting (YES) state else reject (NO).
L3 is not recursive:
If L3 is recursive then we must have a Turing machine for L3, which accept epsilon and reject all strings and always HALT.
Since Halting of Turing machine can’t be guaranteed in all the case.
Hence this language is not recursive.
Question 2 |
Let <M> be the encoding of a Turing machine as a string over Σ = {0, 1}. Let L = {<M> |M is a Turing machine that accepts a string of length 2014}. Then, L is
decidable and recursively enumerable | |
undecidable but recursively enumerable | |
undecidable and not recursively enumerable | |
decidable but not recursively enumerable |
Now, since total number of strings of length 2014 is finite, so M1 will run the encoding of M for the string of length 2014 and if the M accept the string then M1 will halt in ACCEPT state. But if M goes for infinte loop for every string of length 2014, then M1 also will go into infinite loop. Hence language L is recursively enumerable but not recursive, as in case of rejectance halting is not guaranteed.
Question 3 |
Define languages L0 and L1 as follows:
L0 = {〈M, w, 0〉 | M halts on w}
L1 = {〈M, w, 1〉 | M does not halts on w}
Here 〈M, w, i〉 is a triplet, whose first component. M, is an encoding of a Turing Machine, second component, w, is a string, and third component, i, is a bit.
Let L = L0∪L1. Which of the following is true?
![]() | |
![]() | |
![]() | |
![]() |
Question 4 |
Consider the following problem X.
Given a Turing machine M over the input alphabet Σ, any state q of M And a word w∈Σ*, does the computation of M on w visit the state q?
Which of the following statements about X is correct?
X is decidable | |
X is undecidable but partially decidable | |
X is undecidable and not even partially decidable | |
X is not a decision problem |
Question 5 |
Let a decision problem X be defined as follows:
X: Given a Turing machine M over Σ and nay word w ∈ Σ,
does M loop forever on w?
You may assume that the halting problem of Turing machine is undecidable but partially decidable.
- (a) Show that X is undecidable.
(b) Show that X is not even partially decidable.
Theory Explanation is given below. |
Question 6 |
(a) Show that Turing machines, which have a read only input tape and constant size work tape, recognize precisely the class or regular languages.
(b) Let L be the language of all binary strings in which the third symbol from the right is a1. Give a non-deterministic finite automaton that recognizes L. How many states does the minimized equivalent deterministic finite automaton have? Justify your answer briefly?
Theory Explanation. |
Question 7 |
A is recursive if both A and its complement are accepted by Turing machines.
True | |
False |




