Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

I do not understand the concept of Non Deterministic Turing Machine [closed]

I do not the understand the concept of Non Deterministic Turing Machine. I guess I understand the term Non deterministic algorithm : (nondeterministic algorithm is an algorithm that can exhibit different behaviors on different runs, as opposed to a deterministic algorithm.) So the algorithm could be like :

a = fromSomeAlgo();  if(a > foo)    stateA(); else    stateB(); 

But for non-deterministic turing machine I read , it can be in more than one state at a given time. Also a wikipedia article suggests "A non-deterministic Turing machine (NTM), may have a set of rules that prescribes more than one action for a given situation".

What does that mean ? ..More than one action for a given stituation...multiple states... I simply do not understand this.

like image 372
Suhail Gupta Avatar asked Nov 23 '12 06:11

Suhail Gupta


People also ask

Which is the correct definition for non deterministic Turing machine?

In theoretical computer science, a nondeterministic Turing machine (NTM) is a theoretical model of computation whose governing rules specify more than one possible action when in some given situations.

Do non-deterministic Turing machines exist?

The concept of Non Deterministic Turing Machine is purely theoretical - there is no non-deterministic turing machine available.

Which is not a non deterministic Turing machine?

5. Which of the following is not a Non deterministic turing machine? Explanation: A read only turing machine or 2 way deterministic finite automaton is a class of model of computability that behaves like a turing machine, and can move in both directions across input, except cannot write to its input tape. 6.


1 Answers

In a Non Deterministic Turing machine, in each branch - you do both possibilities - and only when you are done you "choose" which one is the one you need for the solution (if one exists).

For example, let's look at the subset sum problem, with S = {a,b,c... }. The Non Deterministic Turing machine has a linear solution:

for each element:    "guess" if it is in the subset check if the subset has the specified sum 

The tree generated will be something like that:

                                       start                  with a                                      without a                /         \                                   /          \               /           \                                 /            \              /             \                               /              \       with b               without b                  with b              without b       /     \               /       \                 /     \             /        \   with c    without c    with c     without c     with c    without c    with c     without c 

It is enough that one calculation (path in the tree) is correct in order for the algorithm to yield "true". It yields "false" only if there is no such calculation.

The concept of Non Deterministic Turing Machine is purely theoretical - there is no non-deterministic turing machine available.

Bonus:
Note that everything that can be done with Non Deterministic Turing Machine - can be done with a Deterministic Turing Machine (and vise versa) - for example, the Halting Problem is not decideable in either. However, NPC problems can be done polynomially in Non Deterministic Turing Machines, and we do not know (and we assume we cannot) how to do it polynomially on Deterministic Turing Machines.

like image 91
amit Avatar answered Oct 04 '22 00:10

amit