We can write a computer program that will successively print out the digits of the decimal expansion of pi. We can also write one that will list the digits of the decimal expansion of the square root of 2. Similarly, there are computer programs that will compute the square roots of integers, ones that will compute cube roots, etc. In fact, for the irrational numbers that you encounter in your day-to-day life, there are computer programs that will compute them as long as their defining characteristics can be “described” in some reasonable way.irrational numbers that you encounter in your day-to-day life, there are computer programs that will compute them as long as their defining characteristics can be “described” in some reasonable way.

So, for every given irrational number, does there always exist a computer program that will list the digits of that number?

Surprisingly, no! There are some irrational numbers whose decimal expansion cannot be computed!

**Presentation Suggestions:**

This is a good Fun Fact to do after the Fun Facts How Many Rationals? and Cantor Diagonalization, which give background on countable and uncountable sets

**The Math Behind the Fact:**

The proof of this fact is actually quite easy if you know the difference between countable and uncountable sets.

We first show that the set of all possible computer programs is a countable set. Why? Every computer program is a finite string of a finite set of symbols. So the set of all computer programs of length N is finite. The union over all N of such sets is the set of all computer programs, and it is therefore countable, since it can be “listed” as the countable union of finite sets.

However, the set of all irrational numbers is uncountable, so there must be some irrational number whose decimal expansion is not computable! In fact, since only countably many irrational numbers can be computed, “most” irrational numbers are not computable!

This fact comes as a shock to students and gives a great demonstration of the importance of understanding the difference between countable and uncountable sets.

**How to Cite this Page:**

Su, Francis E., et al. “Computability of Real Numbers.” *Math Fun Facts*.

**Fun Fact suggested by:**

Francis Su