On tafl

While I attempt to dream up suitable procurement challenges for Parvusimperator, who is much harder to challenge than I am, I have some side projects in flight. One of those is a computer implementation of tafl.

Tafl is an Old Norse board game. The name means ‘table’, and the game and its variants are also known by some others: hnefatafl (King’s Table, to my best guess), brandubh, tablut, alea evangelii, ard ri, and likely some I’m forgetting. It is mainly notable for being the best-developed asymmetric abstract strategy game of which I am aware. Common across all the varians is the central goal: one side, the king’s side, starts in the center of the board. Its goal is to get its king to escape. The other side, the besieging side, plays to prevent the king from escaping. The king escapes on edge spaces in some variants, and on corner spaces in others.

Taflmen are moved like the rook in chess, orthogonally, any number of spaces. Captures are made by surrounding opposing taflmen on two sides, though some variants require that the king be surrounded by four opposing taflmen to be captured, and others do not allow the king to take part in captures.

Some modern variants introduce innovations aimed at a more balanced game, or one less likely to stalemate: pieces in a line on a board edge can be captured by lining up your own pieces opposite them and surrounding them to the sides, or the king can escape by means of a similar formation, if he is able to move inside the surrounding formation. Other modern variants go even further from the original rules, introducing pieces which can jump to move or jump to capture, and the ‘berserker rule’: a piece which makes a capture can move repeatedly, so long as each subsequent move also makes a capture. (That one is going to be a huge pain to implement. Just saying.)

Anyway, besides its obscurity and its Viking flavor, I find two other things to like about tafl games: first, the unchartedness of the territory. Tafl is still an enthusiast community, and although it seems to be growing, research into the game is still in its infancy. It’s a chance to break some new ground in human understanding, a compelling reason to work on it.

The second reason is the probable computational complexity of tafl games. Though the rules are simpler than those of chess, it’s my suspicion that, in terms of raw possible games and average branching factor, tafl is a harder game to model than chess. Consider: concretely, taflmen move as freely as the second tier of chess pieces (the rooks and bishops), and the tafl board is bigger (attested variants range from 7×7 to 17×17 or 19×19, depending on your interpretation of the rules). Qualitatively, it feels to me like tafl is a busier game: the capture rules mean that it’s more difficult to make captures while keeping strong positions, and the escape/surround duality in objectives means that material advantage is, to a certain point, less important. Pinning a piece in place so that a piece behind it can’t deliver an attack is fundamental to chess tactics, but two taflmen in the same vicinity build upon each other, and their interchangeability means that sacrificing one taflman so that another can move into a better position requires much less care than chess tactics do.

I suppose, speaking in the most general terms, chess between evenly-matched players is a game of materiel before a game of position: gains in material advantage are easily parlayed into gains in positional advantage, because it’s easier to fix an opponent’s powerful pieces in place relative to tafl. Tafl between evenly-matched players is a game of position before materiel. It isn’t uncommon to see high-level tafl players decline to take ‘freebie captures’—when the opponent places a piece into a position where it can be captured without retaliation—because a small material gain is not worth losing a turn in the race for position elsewhere on the board.

Anyway, that’s all I have for today. As I get OpenTafl more ready for a release, I intend to go into more specifics about its variations, its strategy, and my implementation of its more curious features and work toward a reasonable AI. I’ll see you then. (Or probably before then, when I tell you which things I’ve chosen for Parvusimperator’s unseemly gauntlet-throwing.)

One thought on “On tafl

  1. Pingback: Many Words » von Rundstedt wins!

Comments are closed.