The ground rules of chess problems

Composing and solving chess problems is an ancient art, but there are still some debates about exactly what the ground rules surrounding them should be. It can get pretty complicated, and some of the rulebooks for chess problems have interesting ambiguities in them.

I’ll just take a look at one of those rulebooks: the one from Handbook of Chess Composition, version 8 (January 2021), in the “Codex” chapter (link). I’ll call this the “Codex.”

Preliminary notes

This post is about typical chess problems, of the type “white to play and win”, or “white to play and mate in N”. There are other standard types of problems to which it may apply as well.

The Codex is largely agnostic about which side moves first, but the usual convention is that it’s white, for composed problems. In this post, I’ll assume it’s white.

The chess problem composer may be allowed to stipulate different rules that only apply to that problem. But that’s not the topic of this post.

When I say a problem is “broken”, I mean that it doesn’t have a valid solution, in accordance with the relevant rulebook.

“Legal position” means the position can occur, with the correct player to move, by some sequence of legal moves in a standard chess game (whether we consider castling and en passant rights depends on context). A position being legal is independent of whether the problem is broken.

Many chess problems have been published whose position is technically not legal, often because of an impossible pawn structure. While there’s nothing necessarily wrong with that, it’s impossible to do retrograde analysis on such a position. If the rules tolerate such problems, they have to be dealt with as a special case.

The Codex prohibits illegal positions in general (Article 14 paragraph 2).

First-order castling and en passant conventions

Regarding castling and en passant moves, Article 16 of the Codex covers the usual conventions:

  • Castling rights exist unless it can be proven, by retrograde analysis, that they must not exist.
  • White is not allowed to capture en passant on the first move, unless it can be proven, by retrograde analysis, that black’s previous move made the en passant capture possible.

I’ll call these the “first-order” rules (my terminology).

But there’s a problem: These rights can be interdependent.

“Enumeration of states” problems

Consider this mate in 2 problem:

White to play and mate in 2 (?)

White would like to play Qxc7 or Qxg7, and checkmate on the next move. But black can escape by castling in the opposite direction of the queen’s move. So we have to figure out if castling is permitted.

Black’s previous move must have been with his king or a rook; therefore at least one of the two castling moves is illegal. But we don’t know which one.

Here’s part of what the Codex says about such interdepencencies:

[Partial Retrograde Analysis (PRA) convention] Where the rights to castle and/or to capture en-passant are mutually dependent, the solution consists of several mutually exclusive parts. All possible combinations of move rights, taking into account the castling convention and the en-passant convention, form these mutually dependent parts.

I understand the type of problem they’re trying to permit with this rule, but I just don’t think the rule is written very clearly. How exactly do we “take into account” the other conventions? Do we really have to solve every possible state? Or is it more like we apply as many of the first-order conventions as we can in every possible order, leaving us with a set of maximally constrained states to solve?

The main issue I’m thinking of exists in my example. The easiest of the possible states, in which neither castling move is permitted, has two possible first moves. A non-unique first move is a Bad Thing in chess problems, and the problem would be considered “cooked”. Does that mean the whole problem is cooked, or can we skip that state because it is dominated by a more difficult state? I don’t know.

“Collapse the waveform” problems

Here’s another mate in 2 problem:

White to play and mate in 2 (?) [H. Hultberg, 1944]

White wants to move the h1 rook to f1, then play Rf8 to checkmate the black king. But black can escape by castling.

It can be proven that if white can castle, then black can NOT castle. (If white can castle, the f3 rook must be a promoted piece, whose promotion and escape would have required the black king or rook to move.)

Interesting, but none of the rules we’ve seen so far make the problem solvable. The case where black can castle and white can’t has no solution. In other words, a solution is not possible according to the PRA convention.

But there is more to the Codex than that. It continues:

If in the case of mutual dependency of castling rights a solution is not possible according to the PRA convention, then the Retro-Strategy (RS) convention should be applied: whichever castling is executed first is deemed to be permissible.

I must say, this is a very odd way to write a rulebook. The problem solver is required to first determine whether a sub-problem has a solution, before he can even know which part of the rulebook is applicable to the main problem.

The solution, then, is to first prove that there is no solution under the PRA convention, thus allowing you to use the RS convention. Then, white castles on the first move, which establishes that we are in a universe in which black does not have castling rights. Then, white plays Rf8 mate on the next move.

“Strong retroactive causality” problems

The following problem is said to be broken in some mundane way. But I don’t know of another example, and the retrograde analysis is presumably correct, so I’ll go with it.

White to play and win (?) [N. Petrović, 1967]

White can only win by capturing the g5 pawn en passant. But is that permitted?

It’s very complicated, but it can be proven that if white has castling rights, then white can capture en passant.

Since an interdependency exists, we have to consider the special rules. My interpretation is that this problem would, by the Codex rules we’ve seen so far, be considered to have no solution. The PRA rule doesn’t work, because not all the possible states have a solution. And the RS rule doesn’t work, because it offers no way to legalize the initial en passant capture.

“That’s where you’re wrong!” says the clever problem solver. On the first move, he captures en passant anyway, even though it is illegal. Then, on some later move, he castles. (And then goes on to win from that position.) By castling along the way, he “proves” that castling rights existed at the beginning of the problem, which means that capturing en passant on the first move retroactively becomes legal.

We could debate the soundness of this argument, but the real point is, a good rulebook ought to cover cases like this. Here’s what the Codex says:

Other conventions should be expressly stipulated, for example if in the course of the solution an en-passant capture has to be legalised by subsequent castling (a posteriori convention AP).

So it’s pretty clear that it disallows this problem under normal circumstances.

If I wrote the rules

I’m not sure what I would want the rules to be. I don’t want to spoil all the fun, but I don’t like the feeling of we’re-just-making-up-the-rules-as-we-go that I get when I read about this stuff.

I’d at least consider clarifying the first-order castling and en passant conventions, maybe something like this.

Evaluate these five things independently, in parallel:

  • (1) Is there a black pawn that can be proven to be capturable en passant on white’s first move? If so, then let white have the rights to capture that pawn en passant.
  • (2-5) For each of the four possible castling moves, if it’s possible that those particular castling rights exist, then let those particular castling rights exist.

Combine these rights, or lack thereof, into a single position. If that position is legal, then that is the position to use. If it’s not legal, then either the problem is broken, or we can decide to have some special interdependency rules, and let the craziness begin.

Leave a comment