Question 1
To show that a DFA has an empty language, we must show that it never reaches an accepting state.
Algorithm:
- Run BFS or DFS from the starting position.
- If we find an accepting state, terminate and return false.
- If we do not end up finding any accepting state, return true.
We know that the DFA is finite of some states. We can simply implement the search using a Turing Machine. As we can create a Turing Machine for our algorithm prior, this means the problem is decidable and hence the Emptiness problem for DFAs is decidable.
Question 2
Hence we can decide if the two languages are equivalent if the last line is false. This proves the Equivalence problem is decidable as we already proved that the Emptiness problem is decidable.
rewrite to make it look nicer
Question 3
Assume there is an algorithm accept(code(M), w) that is decidable, which means it is:
- Sound
- Complete
- Terminating
And it is defined as such:
Create a new machine :

For the rejecting problem, we would want to output for and for .
Similarly for the finite space problem.
We want to run :
- If then .
- If then . This is a contradiction, which means the accepting problem for Turing machines is undecidable.