-1

I am trying to see if infinite languages are always decidable. I believe it is not always decidable because there will not be a maximum length of string for the Turing machine to halt. Am I on the right path? I am having difficulty coming up with an example infinite language That is decidable.

Jake
  • 1
  • 1

1 Answers1

3

There are many infinite languages which are decidable, for example $\Sigma^*$, or the language of all (binary representations of) primes. However, in some sense "most" languages are undecidable, since there are uncountably many languages, but only countably many decidable languages. We also know many explicit undecidable languages, such as the language of (encodings of) Turing machines which halt on the empty input.

All finite languages, on the other hand, are decidable.

Yuval Filmus
  • 276,994
  • 27
  • 311
  • 503
  • So you are saying the complement of a finite language is decidable? – Jake May 08 '15 at 20:47
  • I wasn't saying that, but that's definitely true. – Yuval Filmus May 08 '15 at 20:47
  • Oh ok thank you. Also you say in your answer all finite languages are decidable could you elaborate a little further on that? – Jake May 08 '15 at 21:10
  • Yes. All finite languages are decidable. Make sure that you understand what decidable means. Give it a few hours before asking any more questions here - I'm sure you'll get it by then. – Yuval Filmus May 08 '15 at 21:12
  • @Jake Think about how you'd write a computer program that checks if a word is in a specified finite language. It doesn't have to be a smart program; it doesn't have to be efficient. Once you've convinced yourself that there's a computer program that can do that, you've convinced yourself that the problem is decidable. – David Richerby May 09 '15 at 10:09