skip to content
camaleon's log Adapting's Blog

The rationals are all you need

/ 5 min read

Sometimes insight comes not from discovering new stuff, but from coming back to the basics with a new lens. Let’s consider the numbers.

Question: how do we define the numbers?

1. What closure is and why it matters

Closure means that when we manipulate elements of a set, we end up with another element of that set; that is, we do not leave the set. Why is this useful? All we have to do is study the elements on our set, and then we already have a solid basis for understanding what comes out when we start playing around.

Think of chemical reactions, we mix some chemicals we get some other chemicals, if we know our chemistry we can easily understand the output. If instead we somehow got something radically different every time, chemistry would be very hard. The every time is important.

Gustavo Bueno said the fields of science are defined by categorical closure. Why is chemistry a thing? Why is not all just science? Because if you are concerned with reactions in the lab, it suffices to know all the things we englobe under the chemistry label to do your job most of the time. So the process is something like this:

  1. We are interested in a certain operation, let’s say mixing reactive stuff.
  2. We list all the elements that can come out of that operation to guarantee closure.
  3. We make those elements (and the operations) the object of study of a field, which we give a name: be it physics, chemistry or math.

This is sometimes called causal closure, meaning that you can explain most of the cause-effect relationships without leaving the field. For instance the notion of software is based on causal closure, you can write valuable code without having a clue of how transistors work; that is, you can abstract from hardware1. Similarly, psychologists or engineers work just fine without knowing quantum mechanics, despite brains and bridges being made of subatomic particles after all.

2. Building numbers. It’s all about closure

You have to start somewhere, and that somewhere is often the real world. We can count stuff, for instance: 1, 2, 3, …, n apples. These are the natural numbers, and there’s of course infinitely many of them.

Let’s say we want to combine two sets of elements and see how many there are in the combination. Easy, just sum. Summing is nice, when we sum two natural numbers, we get a natural number. Closure checked.

Now we want to do things backwards. We combined our set with another friend’s set, we know how much we put and the total we got, and we want to know how much they put. Easy again, subtraction. Subtraction is not nice, you can subtract two natural numbers and get something like -2 which doesn’t look very natural.

Easy fix, expand the set of numbers to include 0 and the negatives (also called addition inverses) of the natural numbers. These are the integers, which are closed under addition and subtraction. And multiplication too! 5x6=30, not a solid proof but looks nice. Now you see what’s coming, division (multiplication inverse) brings trouble again, 5/6 is not an integer.

You know the drill. Easy fix, expand the set of numbers to include all ratios, here we have the rationals. It looks like we got everything under control now but we are not done yet.

This is not as straightforward but another thing we want to often do with numbers is build sequences and see where they’ll end. Exponentiation (particularly of non-integers) can be understood as taking the limit of one of this sequences. It turns out the rationals are not closed under this kind of operation; who would’ve thought. It’s like they where filled with holes, called irrational numbers, which in fact are huge. If you sampled a number randomly in the interval [0, 1], the probability of getting an irrational number is 1! This brings us to the real numbers, where we can finally take a rest.

3. Back to the real world

Note you could never run the aforementioned sampling experiment to check if it’s true because computers cannot represent irrational numbers!2. So yes, all of our technology is based on a “negligible” fraction of the real numbers. But we seem to be doing just fine.

Thanks to a thing called mathematical density (different from physical density), we can approximate any real number arbitrarily well with a rational number; and since when it comes to the real world, we gave up on exact solutions a long time ago, this suffices.

References

For an interesting read on the definition of software and it’s link to causal closure see:

  • Rosas, F. E., Geiger, B. C., Luppi, A. I., Seth, A. K., Polani, D., Gastpar, M., & Mediano, P. A. (2024). Software in the natural world: A computational approach to hierarchical emergence. arXiv preprint arXiv:2402.09090.

Footnotes

  1. In the real world things aren’t so tidy so if you are writing very low level code you often need to be hardware aware. In some way there’s a single continuum where everything is made of the same fundamental building blocks, but when you compare things at very different levels of abstraction they are pretty much (causally) disconnected. I heard a Faroese speaker can understand a Icelandic and Norwegian, but Norwegians cannot understand Icelandic nor the other way around. Causal closure is a little bit like that.

  2. You can using strings, but you know what I mean.