Theory of Computation · Countability
Finite and Infinite Sets
Overview
Sets are classified as finite or infinite, and infinite sets are further split into countable infinite and uncountable infinite.
This classification matters because it establishes the size ordering finite < countable infinite < uncountable infinite, which is the tool used to prove that some languages are not recursively enumerable.
Key concepts
- Set: a collection of objects. Sets are of two types: finite and infinite.
- Finite set: a set with a countable (bounded) number of elements — 10 elements, 20 elements, or whatever the number is. The key idea is that there is an upper bound on the index/element count.
- Infinite set: there is no upper bound on the elements. Example: the set of strings with has no upper limit, so it is infinite.
- Countable infinite: a "smaller" infinity — the set is infinite but has "not too many" elements.
- Uncountable infinite: a "larger" infinity — the set is infinite and has "too many" elements.
- A countable infinite set is lesser compared to an uncountable infinite set. This ordering is not written formally anywhere, but it is the actual meaning to understand.
How it works
The intended size ordering of sets is:
The purpose of this whole theory (the goal to be proved):
- The set of all Turing machines is countable.
- The set of all languages is uncountable.
- Therefore the number of Turing machines is less than the number of languages.
- Therefore there are some languages which are not accepted by any Turing machine.
- Therefore there are some languages which are not recursively enumerable.
How to proceed with any given set:
- First distinguish whether the set is finite or infinite — this is easy and straightforward.
- Talking about finite sets is not very interesting; the interesting case is infinite sets.
- For infinite sets, the important distinction is between countable and uncountable.
Formulas
- — finite: is bounded above by .
- — infinite: there is no upper limit on .
- — the intended size ordering of sets.
Worked examples
- Example 1 (finite): . Even though there are enormously many elements, the set is still finite, because is bounded above by .
- Example 2 (infinite): . There is no upper limit on , so the set is infinite.
Comparison
| Type of set | Meaning | Relative size |
|---|---|---|
| Finite | Bounded number of elements (e.g. ) | Smallest |
| Countable infinite | Infinite, but "not too many" elements | Middle |
| Uncountable infinite | Infinite and "too many" elements | Largest |
Revision summary
- Sets are finite or infinite; infinite sets are countable infinite or uncountable infinite.
- Finite means an upper bound exists on the elements, however large the bound (e.g. ); infinite means no upper bound (e.g. , ).
- Intended size ordering: finite < countable infinite < uncountable infinite — understand it this way; it is not written formally anywhere.
- Final goal: Turing machines are countable, languages are uncountable, hence some languages are not accepted by any Turing machine, i.e. some languages are not recursively enumerable.
- For any given set: first decide finite vs infinite (easy), then for infinite sets decide countable vs uncountable — that is the important question.
Previous-year exam insights
- A set is countably infinite iff its elements can be placed in a one-to-one correspondence with the natural numbers (i.e., enumerated as a sequence); equivalently it has a bijection with N.
Asked inUGC NET 2013 - The set of all Turing machines is countably infinite because each TM has a finite description (a finite string over a finite alphabet), and the set of all finite strings over a finite alphabet is countably infinite.
Asked inUGC NET 2013 - The set of all languages over a non-empty finite alphabet is uncountable, since it equals the power set of the countably infinite set of strings (Cantor's theorem: |P(S)| > |S|).
Asked inUGC NET 2013 - Every subset of a countable set is countable; the union of countably many countable sets is countable; the Cartesian product of finitely many countable sets is countable.
- Recursive languages and recursively enumerable languages are both countable (each is a set of TMs/grammars with finite descriptions), so countability alone cannot separate them; the uncountability argument shows only that some languages are not RE.
Asked inUGC NET 2013 - Recursive languages are closed under complement, and the difference of two recursive languages is recursive; if L1 is recursive and L2 is RE then L2 − L1 is RE (since RE is closed under difference with a recursive set).
Asked inUGC NET 2013