Question

I found the following explanation from Math exchange

A language is Recognizable iff there is a Turing Machine which will halt and accept only the strings in that language and for strings not in the language, the TM either rejects, or does not halt at all. Note: there is no requirement that the Turing Machine should halt for strings not in the language.

A language is Decidable iff there is a Turing Machine which will accept strings in the language and reject strings not in the language."

I really don't see the difference in two. what's the difference between a Turing machine that ONLY accepts string in a languages vs a Turing machine that accepts strings in a language? does that mean any Turing Machine can accept anything?

Was it helpful?

Solution

I really don't see the difference in two.

The difference is that for a Decidable language you can build a compiler that can always distinguish between valid and invalid "utterances". By contrast, if the language is only Recognizable, then there are invalid "utterances" that will cause a compiler to go into an infinite loop.

Note that by expressing this in terms of Turing machines, they are talking about what is theoretically possible; i.e. any theoretically possible compiler for the language, not just a specific one.

And the language "iff there is a Turing Machine ..." means that it is possible to formulate such a Turning Machine. It is not talking about all Turing Machines. A Turing Machine designed to (say) tell you if a number is odd obviously won't act as a language recognizer.

(If you don't understand why that is obviously so, you need to do some more background reading on the subject. I suggest you start with Wikipedia.)

OTHER TIPS

The difference is that the Decider (TM that decides) is ALWAYS halts on any input (whether accepts or rejects) while the Recognizer could be loop forever besides halt. When it loops forever, recognizer can decides only when after some 'forever' times. That is why we call it recognizer rather than decider, since it sometimes just can't decide.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top