Chess 4: How Is Castling Possible Again?

These chess problems require you to understand the rules of chess. Assume White is on the bottom.

Expected difficulty MediumComment/E-mail if you want a solution to be published

Stipulation (12+13) White can still castle. Which unit made White’s last move? (Note that you’re not told whose move it is.)

Here’s one more. Apparently constructing chess compositions is harder than constructing logic puzzles…

Chess 3: Weirdest Stipulation Ever

These chess problems require you to understand the rules of chess.

Expected difficulty MediumComment/E-mail if you want a solution to be published

Stipulations Color the pieces so that there exists a game where this position is illegal due to FIDE Chess Law 5.2b (also known as Dead Reckoning), but legal otherwise.

Made from phone, so it’s hard to add comments, but it’s basically a really stupid problem. I might put the solution soon. And I’m expecting a cook here, that there exists other solutions I didn’t consider or something. But if there’s none then, well, good.

Chess 2: Missing Piece

These chess problems require you to understand the rules of chess.

Expected difficulty MediumComment/E-mail if you want a solution to be published

Stipulations a) On what square was the rook on f1 at the beginning of the game? b) What color and piece is on h2 (the black circle)? Mention all pieces that can be on that square. (Just so part a is well-defined, I assure you at least one piece works.)

So here’s another one, which I should say is the best piece I’ve ever composed to date. (Yes, if this is the best piece then you know how beginner I am in compositions.) I might post some problems that aren’t composed by me, but I find interesting nevertheless…

Chess 1: A Long First Step

These chess problems require you to understand the rules of chess. Assume White is on the bottom.

Expected difficulty EasyComment/E-mail if you want a solution to be published

Stipulations a) Is the position legal? b) Move pawn f7 to g7; is the position legal?

EDIT: Puzzle edited on 7 February.

I call this Chess 0. 😛

Yes, with at least one positive feedback, I’m starting to post these. I’m also a relatively newcomer to the field, so my difficulty rating will be based on my current knowledge at the time of the posts. And don’t expect a lot of stuff, since constructing these is way harder than constructing the usual deductive logic puzzle content. Expect more retro chess problems (or perhaps helpmates and similar), those that don’t require thinking like chess players.

Also, I might consider adding a new difficulty rating “Introductory”, which should be self-explanatory. (Retro 0 is Introductory.)

Chess 0: Chess Problems Begin!

This blog is partially known by its puzzle content. But it’s still my creation, so I still post content according to what I like.

Lately I’m interested in retrograde analysis; that is, analyzing chess positions and problems that require looking to the past. Say, can you figure out the last move (precisely; the piece, the squares moved from and to, the piece captured if any, and any other stuff) from this position?

I’m interested on knowing how many of you like this kind of content. If there’s nobody, I might post my problems only on Chess.com, or something…just see. 😛

Greedy Queens Problem

In the famous Queens Problem, you need to put n chess queens on an n x n chessboard so no two queens attack each other. It has been proven that a solution exists for all n except n=2,3.

One of the methods (albeit an ineffective one) to solve it is by greedy algorithm, which does a depth-first search. In this case, a queen is placed on the first row, on the first column. The next queen is placed on the second row, starting from the first column. As it attacks a previous queen, it is moved to the second column, and again to the third column. Now as they don’t attack, a third queen is placed from the leftmost column rightward, and so on. When a queen cannot be placed, the previous queen is removed and placed to the next column. This guarantees a solution, as it checks every possible board as long as no conflict has been made.

For example, with n=4:
First queen tries a1.
Second queen tries a2. Conflict with a1.
Second queen tries b2. Conflict with a1.
Second queen tries c2.
Third queen tries a3,b3,c3,d3 in order but conflicts each time. Second queen is retracted.
Second queen tries d2.
Third queen tries a3, conflict with a1.
Third queen tries b3.
Fourth queen tries a4,b4,c4,d4, all conflict. Third queen is retracted.
Third queen tries c3,d3, all conflict. Third queen is retracted. Second queen is retracted (cannot go further).
First queen tries b1.

This algorithm is run until the solution b1,d2,a3,c4 is found (the first solution found). In total, there are 26 queen tries.

For n=5, it can be verified that it takes 15 queen tries to arrive at a1,c2,e3,b4,d5.

Can you compute the number of queen tries for a given n effectively? In other words, is this problem in P? (Naively executing the algorithm gives a possible n^n steps, so it’s not polynomial. You need a better way.)

Extra Problem

A revised version of the algorithm doesn’t put a queen when it makes a conflict. So, for the n=4 example above, we have:

First queen on a1.
Second queen can’t go on a2,b2. Second queen on c2.
Third queen can’t go anywhere, second queen is retracted and go on d2.
Third queen on b3.
Fourth queen can’t go anywhere. Third queen retracted. Second queen retracted. First queen on b1.
And so on.

It takes 8 queen tries now. For n=5, it takes 5 queen tries, or in other words the exact number required.

Can you compute this number effectively too?