Note: this article makes use of MathML, the standard XML markup for math formulas. Sadly, this is not properly supported on some allegedly ‘modern’ and ‘feature-rich’ browsers. If the formulas don't make sense in your browser, consider reporting the issue to the respective developers and/or switching to a standard-compliant browser.

Nation, flags and memory card games

One of the “portable” games offered by Flying Tiger is a memory card game with national flags as a theme. The game has 68 cards (34 national flags) and I like it not only because it's one of the largest memory games I've seen, if not the largest (about 50 cards or fewer being the norm, for what I can see), but also because of its educational side-effect, as each card features not only the flag, but also (in the “native” language as well as in English) the name of the nation and the name of the capital city.

After the first play, my first consideration was that Mexico was missing from the flags/nations (why Mexico? personal reasons). The next thing I noticed was that the selection of nations is essentially centered around Europe, with only a handful of extra-European nations included. This is when I realized how small the selection is: 34 nations is less than a fifth of the nations of the world, even if you consider the smallest possible set (the 190 states whose sovereignity is undisputed).

So obviously, my next thought was: how large would such a memory card game be? 190 states (at least) means 190 pairs, or 380 cards. The Flying Tiger cards are squares (with rounded corners) with a side length of 55mm, and I don't think it's reasonable to go much smaller. In fact, considering the padding between cards that is needed for practical reasons when laying them down for playing, we can assume square tiles with a 6cm side. That's 36cm², or 0.0036m² per tile. 380 such tiles would cover an area of 1.368m².

Curiously, 380 is very close 19.562, which means that if the 190 pairs were laid out in a square, they would take up a square area with a side of almost exactly 117cm, or 1.17m. Even I would have troubles reaching the cards on the opposite side of the table. Of course, you can't actually do that, because 380 is not a perfect square, so you cannot tile the cards on a square: you would have to either have to do a 19×20 rectangle (with sides of length 1.14m and 1.2m respectively), or a 20×20 square with an empty diagonal.

The issue of placing the memory cards in a pleasing pattern has always fascinated me. My daughter has a 48-cards game, which I like because the card can be laid out in a 7×7 square with a hole in the center. My son has a 32-cards game that can be laid out as a 6×6 square with missing corners.

In fact, the 68-cards game that spurred these consideration is a bit annoying because 68=8×8+4, but the 4 extra cards cannot be placed in a nice symmetric way with good alignment because the sides of the square are even, not odd. Possible placemets are the “wheel” pattern (extending each of the sides with one card), the “shifted” pattern (place each extra card on the middle of each side, spanning the gap between the two central cards of the side), or the “versus” pattern, good when playing 1v1 games, with two extra cards on each of two opposing sides.

Obviously, the next question is: how many nations would you have to include to be able to tile out the cards in a “good” pattern?

Perfect squares

this solution can be achieved with 20×20=400 cards, or 200 states (note that without holes or extra cards, the square must be even); problem is, Wikipedia lists 206 states when including the ones with disputed sovereignity; we'd have to cherry-pick some, leaving out six of them;

The hole

an odd square can be made even by taking out a central hole;

a possible solution would be 19×19-1=360, but this would require removing 10 nations from the “uncontroversial” list;

the next one would be 21×21-1=440, which would require 220 states: can we find 14 other territories to add to the 206 states currently listed by Wikipedia?

Give or take more

good patterns can be obtained by removing the 4 corners, or by having 4 extra cards —particularly with an odd square;

20×20-4=396 would require 198 states, which could be assembled from the 193 UN member states, the 2 observer states, plus more (decisions, decisions);

21×21-1-4=436 would require 218 states: we'd only need to find 12 more than the ones listed by Wikipedia.

19×19-1+4=364 would require 182 states: still too little;

As it turns out, 380 isn't even that bad: since 19×19-1+4×5=361-1+20=380, a decent tiling can be found with a 19×19 square, without the center, plus 5 cards centered on each side.

And a long stick to pick the cards on the other side of the table.

But I want more

Revision 6.0 of the Unicode standard introduced Regional Indicator Symbols and their ligatures mapping to «emoji flag sequences». Of the 26×26=676 possible combinations, only 270 are considered valid, and if we ignore the 12 «deprecated region sequences», this leaves us with 256+2=258 “current” region sequences. We could use this as the basis for our memory card game!

With 258 regions we have 258×2=516 cards. What would be a good pattern? We have 516=22×22+32=22×22+4×8 which actually lends itself to a decent layout: a 22×22 square, plus 8 cards centered on each side.

How large would such a memory game be? At 6cm per tile, the main square wold be 1.32m wide. The extra cards on each side would make it 1.44m wide, which is actually a pretty nice number1 —if unwieldy in practice. Still, if we're basing our choice on what Unicode supports, why not build such a game around computers? You'd need lots of players to make sense of it anyway.

  1. anybody familiar with TEX would recognize 1.44 as “magnification step 2”, per Knuth's recommendation of scaling sizes by a geometric progression of ratio 1.2. ↩