It’s nearly Christmas, and despite illness hitting our house this year, we’re still managing to play games. One of the games I enjoy playing with my family is Star Realms, however the built-in mechanism for keeping track of life total – known in this game as “Authority” – is a little clunky, and so my son and I quickly decided to use spin-down life counters from Magic: The Gathering instead.
Authority starts at 50, and it can go up and down during a game of Star Realms. This means we need at least three spin down life counters to represent our Authority, assuming that the total authority is equal to the sum of the values displayed on the life counters. We did briefly consider using one to represent tens and one to represent units, but this was too fiddly to operate in practice.
Over the years, I’ve had many disputes with my son and wife over how I choose to represent my Authority total. If they have a total Authority of , then they like to have spin-downs on the battlefield. For , if is not a multiple of , then they keep precisely of these spin downs at Authority, with the remaining one at . They get very annoyed with me, as that’s not how I keep them at all: I choose a seemingly random collection of values that adds up to .
But there is method in my madness. When I want to deduct, say, 10 authority from a total represented as , it’s easy for me: I find a spin down with at least the amount I wish to deduct (if one exists) and deduct it from only that one, so I’d get . In the same position, they’d to deduct the , remove that spin down from the battlefield, and then deduct the remaining from the final spin down to get a single spin down showing .
They complain that it’s hard to figure out how much Authority I have and whether I’m in the lead or not. And they’re right. In my system, arithmetic tends to be easier – I tend to need to flip fewer spin downs – but comparison is harder.
This is exactly the same situation, for essentially exactly the same reason, as one is faced with in computer arithmetic. They have chosen a canonical number representation, leading to efficient storage (few spin downs on the table) and efficient comparison. I have chosen a redundant number system, leading to fast computation but complex comparison.
Such redundant number systems have a long history. My friend and colleague Miloš Ercegovac, who is an expert in this field, has pointed out to me that an account of such a system was described in a 1726 paper by Mr John Colson FRS (please do download the PDF – the language is a joy). More recently, Miloš developed a deep and profoundly appealing system known as online arithmetic based on exploiting the properties of redundancy in computer arithmetic, a topic we continue to work on to this day. I strongly recommend Miloš’s book for details on this arithmetic and much much more.
Computer arithmetic pops up everywhere. Even when ill and on a Christmas holiday!
(Fellow gamers who also like spin down life counters might also be interested in this paper my son and I published some years ago.)