Alien number systems (by alaric)
An interesting question came up on Twitter, and it started to be hard to fit what I wanted to say in tweets, so I decided to write it up on here.
Basically, the brief (as I read it) was to design a writing system for numbers that might be used by a civilisation who used numbers to measure physical quantities, rather than to count things. My theory is that we developed positional number systems as they make it easy to add up totals in columns, and that accounting was the original driving force behind our development of numbers.
Now, scientists and engineers like to use "scientific notation", which means you write a number like "1.57 * 10^5"; generally three or so digits, written in the form of a single digit, a decimal place, then two or so more digits, then a multiplier by a power of ten. That's convenient because measurements of the real world generally have a given precision, easily expressed as a number of digits that can be obtained, independent of their magnitude, which is then easily expressed as an exponent.
So, I reckon, a civilisation that built its number system for scientific notation might do things a bit differently.
So here's what I came up with.
Let's have ten digits; I'll write them as 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 as that's a convenient set of symbols on my keyboard, but to avoid confusion, I'll write numbers in my proposed system inside curly brackets, like so: {943}.
The digits represent powers of two. 9 is 2^9, or 512; 0 is 2^0, or 1. To write a number in the range 1 to 1023, we turn it into binary and write the digits corresponding to the bits that are one, in descending order. So the number {943} means 2^9 + 2^4 + 2^3, or 536. You always write the digits in descending order.
You can't write zero that way, except as an empty string, but that can be mistaken for "nothing has yet been written", so let's use a separate symbol for zero: say {X}.
If we want to express fractions, we use a radix point. The digits after the radix point are another number that is, basically, divided by 1024; so one and a half would be written {0.9}. If you need more than ten bits of precision after the radix point, use another one; {0..9} would mean 1+1/2048. I'm tempted to reverse the order of the digits on the right of the radix point, making 0 represent 512 and 1 represent 256 and so on, so that {0.0} represents one and a half; but perhaps that's just more complicated.
But the way of representing very small numbers, or very large numbers, is to use exponential notation. But because the exponent of a number is more significant than the mantissa (the bit we've already discussed so far), it should go first, with a separator symbol. We write the exponent as a number in the above format; 1024 is raised to that number and then multiplied by the mantissa.
So if we use {$} as our separator symbol, one is written {0}, three is written {10}, 3*1024 is written {0$10}, and so on.
Very small numbers are written using a dividing exponent, which comes AFTER the mantissa and uses a different separator (say {/}). So {10/0} is 3/1024.
A number like 1023 is awkward to write - it's {9876543210}. But unless you need that level of precision, the entire ten bits, you'd normally just round it to 1024 - {0$0}.
I chose ten digits, not because I happen to have ten of them on my keyboard, but because it means that the simple form with no radix points gives you a range from 0..1023, which is about three significant figures in decimal; the precision to which higher-precision engineering measurements are made to. It's just plain difficult to be more precise than that with mass-produced instruments (you can, but the instruments tend to be very fussy about being calibrated and looked after). A civilisation with better technology than us might routinely use ten bits of precision by default for day to day calculations, I reckon.
The reason I went for the powers-of-two-as-digits representation is that you use more digits to represent more accuracy, rather than larger numbers as we do in our positional number system. However, there's some wasted space; I mandated that the digits be listed in descending order, so my number system doesn't have a meaning for a digit sequence like {123}. Perhaps that could be used for something?