Skip to content

Why real numbers are not.

October 5, 2015

Have you ever encountered mathematicians who do not believe in “real numbers”? Well there are some, mainly those who come form a computer science ideology. I am starting to understand why they do not think real numbers are real or useful as a concept. Firstly what do we mean by a real number? It comes from looking at the number line as a continuum. It is treating the number line consisting of infinite number of points. For example the numbers between 0 and 1 – there are infinite “real numbers” there.

Take an example of a so called real number \pi. It is written as 3.141592653589793… Now notice the ellipses in the number. They are there to say that the decimals after the last 3 as printed is infinitely long. So people think that a real number can be represented by those dot dot dot and so the real numbers have unending decimal series. In actuality the symbol \pi is the limit of that series of decimals once considered.

Now I can appreciate why A/Prof. N. Wildberger insists the need for something to be written down, and we will explain the reason why later. If you think for a moment, we are not capable of writing a real number down. Those dot dot dots are a semantic idea to signify to us that the digits following goes into an infinite series. That is not really writing a number down. Why do we need to be able to write something down with finality?

Well it is because we can put the process of writing into an algorithm. We can put it into a function. So imagine again \pi. The fact that we can not write the number down with completion means we can not put that generation of the numbers into an algorithm that will stop. It can not and we won’t let it stop precisely because the number of decimals in the tail end is infinite. So an algorithm that goes into an infinite loop, making it useless. Since  we can not locate precisely where \pi is in the continuum line we can not even have a function to compute it. In a sense the digits following are not decidable.

From a computer science point of view, the algorithm must terminate and if it does not, then the function is undefined at that point. The problem stems from the idea of infinity of points present in the number line. Yet in practice we can not really even locate real numbers in the number line. You can have the function stop at the 100th position of \pi but that is not \pi itself. This is the best we can do but that number is not exactly \pi rather it is “something like or close to \pi“.

So real numbers are unreal, man.

In maths, your intuition can mislead you

July 26, 2015

This year I began doing private maths tutoring and I have been learning a lot about the deficiencies in mathematics education that are encountered by our high school students. I am very skeptical about this “new maths” approach. For one thing, the students are not taught to use pen and paper to write out their reasoning and calculation. For another, they make the student rely heavily on intuition. Sometimes intuition helps but other times, intuition can mislead.

Let me illustrate this problem, not original to me.

Assume we have 3 cards with two faces. One card is colored black on both sides, the other is colored white on either side, and the last has black on one side and white on the other. Let us drop the cards in a hat and then choose a card, and then when we get a card,  we choose a side to see at random too. Question: If the side we see is black, what is the probability the other side is black also?  Did you answer 1/2? Your intuition has misled you. You probably thought, by this data we can dismiss the possibility of the card with both white colors (the second card definition)  and just deal with the first and last card. This is not the true situation.

Here is our analysis. The sample space \Omega = \{ BB, WW,BW \} describes the possible color combination of our cards, e.g. BB means one side is black and the other side is black also, etc.  Let \beta_s =  “the side we see is black”, \beta_o = “the other side is black”.

So the situation is asking what is P(\beta_o | \beta_s)?

= \frac {P(\beta_o \cap \beta_s)} {P(\beta_s)}= \frac {1/3} {3/6}= 2/3

P(\beta_s) actually has 3 ways of getting  a black out of 6 ways of getting a face. Then also P(\beta_o \cap \beta_s) is tantamount to getting the first card in our description which is 1 out of 3.

So the moral of the story is that intuition can not be a substitute for formalism. Formalism actually yields a more accurate result. Our intuition is trumped by the formal analysis, which is a better way of approaching the problem.

To R or to Python

January 30, 2015

It is a common question asked in data science or data analysis forums if one should use Python or R one’s data work. So far, I myself have managed not to learn Python. I have managed to ward off the urge to do so. Now I have learned plenty of programming languages and have actual work experience in the following: C,C++,Java,Perl, PHP, Tcl, VBA. If I look further back, I should mention COBOL, Fortran, Assembler, Algol and BPL – ancient Burroughs programming language based on Algol hence, BPL. In fact, I should name Scheme/Lisp and Ocaml (see older posts) as one of the languages I can code and program. Currently, I am playing around Clojure . I can really learn Python if I wanted to. However, I don’t.

Oh please, not another language to learn!

Why? Because for statistical type of work R is enough, yes, I can even use R for data cleansing and munging, where Python could probably help. However for that type of task, R has so many functions I can avail of without touching Python. Anyway, which one is close to statistics? Python or R? It is R and if I want to do any general purpose computation I can do it all in R because of those functions. Lastly, the nice thing is that R takes some of those functional programming insights into its philosophy, it took its inspiration from Scheme.

OK Theoremus is ready for download

January 7, 2015

You can get a copy of this textbook here.
Your interest and comments will be most welcomed.

I am working to release it at Amazon, CreatSpace and in Kindle.

The Internet is the “computer”

October 27, 2014


A few days ago, I went to a seminar conducted by one of my former professors on the Internet of Things and I learned how we now have plenty of sensors which can publish data into the Internet. Name it what you will, it can be traffic cameras, or weather stations etc, they can all tap into the Net.

During the seminar, my mind wondered off and I started imagining the movie Terminator. The reality of Skynet may no longer be confined to the movie franchise. Then today I stumbled on this article of Elon Musk.

Read it and let me know what you think.

Theoremus – the first draft of my booklet, available and ready for review

July 18, 2014

Front Cover of Theoremus

Front Cover of Theoremus


The first draft of my booklet called Theoremus is ready for review – if anyone is interested. I will gratefully thank you in the acknowledgment section for any critiques you may have of it. It is not a thick booklet – it is only 70 pages long and targets for an A5 size print. So an expert can finish reviewing it in a couple of days.

It’s aim is to coach a First Year In Maths student on how to make their proofs more rigorous and thus convincing. That is the broad theme of this booklet – the idea of being rigorous.
After all, why would teachers want you to prove theorems if they do not want you to prove them a bit more rigorously? Surely that should be preferred.

The booklet is suitable for any first year university student who will likely be required to put more solid maths in their course. For example, Comp Sci and Engineering students, like those doing Software and Systems Engineering. It should also be suitable for students of Economics, Finance, Physics, Linguistics, Chemistry and perhaps Biology. Well, of course, it should be for the Maths and Stats students too :-)

Please let me know if you have an interest in reviewing it – your suggestions will be welcomed no matter what angle they come from. Just drop me a line in the comments side of this post and I will send you the draft in PDF. Thank you in advance.


Convergence Theorem for Programming Languages

July 1, 2014

Let L = the LISP language. Let P = a programming language different from L, i.e. L \cap P = \oslash. Let t = time. Then \lim_{t \to \infty} P = L.

Trivial, just look at the extensions they are making on Python, Ruby, Java, C# and C++11.



Get every new post delivered to your Inbox.