# Question
Title: How can I know the Elo rating of my chess engine?
I built an uci compatible chess engine, and I would like to know its Elo rating. What is the easiest way to get it?

I would like something that works both on Linux and Windows.

# Answer
Easy question. Announce your engine on the chess programming forum (http://talkchess.com/forum/index.php). There'll be engine testers adding your engine to their rating list, such as CCRL. But please and please provide a working compiled binary.

Announce your engine, upload a compiled binary to somewhere like Dropbox. You'll hear feedback.

EDIT

cutechess is a popular tool for automating computer engine-to-engine matches. The only and only way to test your changes is to make your engine to play games. You can make it to play with an older version or another engine.

https://www.chessprogramming.org/Cutechess-cli
> 11 votes

# Answer
Lichess.org has a bot API and allows bot accounts to play rated games against human players.

See this article.
> 4 votes

# Answer
Test it at

http://www.elometer.net

This is a scientific test based on problem solving and statistical computation.
> -2 votes

---
Tags: engines, programming, uci
---


# Question
Title: I developed all the pieces I could. Now what?
I was playing chess against an AI, and found myself in this position (Black/me to move):

```
r1b2rk1/4n3/p1p1p1p1/1p1pPp1p/1PnN1P2/2NB4/2PP2PP/1RB2RK1 b - - 0 1

```

The only moves I could think of were either obviously bad (e.g. trying to move the knight on c4), obviously pointless (e.g. shuffling the king around), or would mess up my pawn structure.

I tried plugging this into an analysis engine, and it suggested 1. ... a5 (which, now that I look at it properly, makes a great deal of sense to me). It also said that I'm down about four pawns in evaluation, which is unsurprising as I'm down a bishop, the other bishop is bad, and neither of my knights has much freedom of movement. Meanwhile, White's bishop and knights are active and greatly limiting my options. So, on the whole, this game does not seem to be going well for me.

But my broader question is not "what specific move should I be making?" Instead, **what should I be trying to accomplish, in general terms?** Because on this board, in this position, I really have no idea what my next goal should be. I feel like most of my pieces are either already developed, or impractical to (further) develop; I cannot see any reasonable lines of attack that might actually yield an advantage; and it's also rather difficult for me to infer what White should be doing, so I can't even effectively defend myself.

The AI doesn't allow draw offers. Should I just shuffle the king around and count to 50, or do I actually have a chance of pulling this one back?

(Lest anyone accuse me of cheating against an AI, the game is already over, but I still find this position utterly baffling.)

# Answer
Let's look at the position and try to evaluate the situation on the board. This is always a good idea, especially if you're struggling to come up with a concrete plan.

```
r1b2rk1/4n3/p1p1p1p1/1p1pPp1p/1PnN1P2/2NB4/2PP2PP/1RB2RK1 b - - 0 1

```

**HOW TO EVALUATE THIS POSITION?**

In this position black is a piece down for a pawn, so this in and of itself should be cause for concern. But this is actually not the only issue with black's position, although the material situation is of course the easiest thing to consider in a position since it doesn't require anything besides basic arithmetics to calculate.

Factors that are just as important, but often much harder to appreciate for beginners, include king safety, piece activity and coordination, pawn structure, space, etc. Let's begin by looking at black's pawn structure, as it will make clear just how problematic black's position really is.

The "sawtooth" kind of structure that black has set up is something I often see beginners play for, as they feel like it's easy to make sure that everything's protected. But the structure has some serious flaws. First off, the pawns in the back of the structure (g6, e6, c6, a6) are at serious risk of becoming weak since there is no way to defend them with other pawns and it's very hard to advance them without losing them; for instance, moving the g- or c-pawn forward here just lets white capture the pawns for free. But this is not where the problems end. The pawns that are further advanced (h5, f5, d5, b5) are also virtually immobilized; if they were to move forward they would immediately lose support and be vulnerable to attack (imagine if black were to play ...h4, then white would win that pawn if they just manage to threaten it somehow). So in the end, black's pawn structure is rigid and inflexible, and much weaker than it seems at first glance. Another problem with this structure is that it leaves your dark squares very weak. If you want to defend a dark square it has to be done with a piece, and since you're lacking a dark-squared bishop it will be difficult to do this efficiently.

The inflexible pawn structure causes a lot of other headaches for black as well. For instance, black already controls less space than white (in this case it can be clearly seen by the fact that black is relegated to play on the 6th to 8th rank with almost all of their pieces, while white's pieces have a lot more opportunity for movement). This means that black will have less space available to move around their pieces. This, in turn, makes it harder for black's pieces to coordinate without stepping on each others' toes which makes it harder for black to react to white's threats in the long term.

So, to summarize, black is material down and has a weak and inflexible pawn structure which makes their position cramped and gives their pieces a harder time to move effectively (the bishop on c8 is especially terrible here). The only "good" thing about black's position is that their king is pretty safe at the moment. Therefore your aim in this position as black is to draw, since winning is out of the question as long as white doesn't blunder something serious.

**HOW DOES WHITE WIN?**

Depending on the opposition a draw for black can be easy or difficult or impossible to achieve. A grandmaster would easily win this position as white no matter what black does, the average player could potentially struggle against optimal play and a beginner is probably not going to win this as long as black hunkers down and plays passive defense. Let's discuss a bit how white actually wins this position so that we know what we must try to prevent.

At the moment, the position is pretty locked, so white should ultimately aim to open it up somehow. An open file is enough here to work with, so a pawn breakthrough with h3-g4 is going to be enough to open the position eventually. But the fact of the matter is that with a locked central structure there is no real need to play this immediately, and white can instead focus on improving their position by developing the dark-squared bishop on c1; if this bishop were to awaken it could easily become very strong, since black's dark squares are desperately weak as I described earlier. In fact, a pawn break with h3-g4 may not even be necessary to win here if the c1 bishop manages to worm its way into black's position.

In general, white should try to use their extra space to their advantage in order to "optimize" the position of their pieces and threaten as many of black's weak points as possible at once while at the same time take away squares for black's pieces to occupy safely. Therefore, the following would be an excellent sequence of moves for white to be able to play: Nb3 (this opens the potential scope of the bishop on c1 later on, and it blocks black from making any pawn breaks; also, this knight could be very annoying for black if it were to reach c5, as this would practically immobilize the bishop on c8 completely), Be2 (opens up the d-pawn, and it also starts to prepare for a future g4 pawn break), d3 (pushes black's knight away from its active post on c4), Be3 (this bishop may go c5-d6 or f2-h4, depending on what black decides to defend against). If white so pleases, they could begin the entire operation by playing Be2, d3, Be3 first.

**SO WHAT SHOULD BLACK DO HERE?**

This is by far the hardest question to answer. Black is objectively lost here, and to be honest, I'm struggling to see a decent way for black to play this in order to make life hard for white. If I were playing a weaker opponent I would probably just hunker down here and play passively, hoping that white doesn't find a winning plan (which they probably wouldn't find, at least immediately).

However, the problem with this is that white just wins then by playing along the plan I outlined above, and this is something I kind of expect the average player (~1600 Elo) to find eventually. So I guess that ...a5 is really the best move to try here in practical terms. This move is good to try because it eliminates the pawn on b4, which gives black some chances to take back some terrain on the queenside by means of just rolling their pawns forward if white is careless enough. This would solve the space issue nicely, and give black's pieces a fighting chance to activate themselves. Note, however, that black is dead lost with decent play from white here and even if ...a5 is relatively best it's still far from nearly enough to ensure a draw. For instance, the line 1...a5 2.bxa5 Rxa5 (if 2...Nxa5 white just plays Ba3, activating their dark-squared bishop immediately and threatening the knight on e7) 3.Nb3, and white dominates completely. But since the pawn on b4 has been removed this means that the pawns on the queenside are a bit more mobile, which means that white has to be a bit more tactically alert.
> 13 votes

# Answer
Once clear material down against an AI, with no compensation, I would resign immediately without shame. No point limping on. There is nothing to learn by going forwards since the imbalance dominates all positional thinking. Have a look to figure out what was the mistake, and then use the released time to play another game.

After development, if there are no tactical hammer-blows for either side, positional assessment is key. My favourite book for this is Silman’s “The Amateur’s Mind”. It identifies the key things to check and then gives many, many worked examples of the alchemical magic of “improving one’s position” over the course of a few moves.
> 1 votes

---
Tags: analysis, strategy
---


# Question
Title: What is the B+N checkmate position that leads to a longest mate?
Black is trying to avoid a mating net that forces it into the wrong corner. To build the mating net, the White king should cut the black king off the center first, by controlling the center itself. Black can resist that without getting into a form of a mating net. I thought it might be this position where black has no danger of a mating net and has cut the white king off the center.

```
[FEN "6BK/5N2/5k2/8/8/8/8/8 w - - 0 1"]

```

I want to capture the essence of this checkmate without relying on brute force search. Just defining general goals that can be extracted from any position.

I am not asking the technique of mating, just how to express them clearly in a systematic way to a computer.

# Answer
> 3 votes
Using the syzygy tablebases by just putting some B+N position in, and looking for the note that says what the longest one is, we can find that it's

```
8/8/8/6B1/8/8/4k3/1K5N b - - 0 1

```

with a DTM (depth to mate, in plies/half moves) of 65.

This is probably due to the discoordination of all of white's pieces

---
Tags: checkmate, patterns
---


# Question
Title: Why is Ne4 considered as an inaccuracy whereas it is one of very few moves which saves d3 pawn?
```
[FEN "r2q1rk1/1p3ppp/p4n2/2Pp4/1Pn5/P1Bp3P/3N2P1/R2QN2K b - - 4 21"]

```

With Black to move Ne4 is not even in top 5 moves and engine says its an inaccuracy. I know it considers fastest winning moves and positional moves too but Ne4 should be a move not an inaccuracy. Ne4 is also a forcing move with many threats.

# Answer
Calling it an "inaccuracy" is nothing more than the engine saying that it evaluates the position after one move to be a certain amount better than after another move. It doesn't necessarily mean a move is "bad".

Both d-pawns cannot be kept no matter what Black does. After 1...Ne4, if White plays Nxe4, the recapture will leave the c4 knight without a defender, and it doesn't have a lot of places to go. White can win the pawn on e4 and attack that knight. And the dark squares around the Black king are just a bit weak. Black is still winning though.

If instead Black plays ...d4, this forces some trades. Simplifying the position seems like a good idea for Black, since they are winning. Overall Stockfish likes this option better.

Here's a comparison showing what the next few moves might look like for each option:

```
[FEN "r2q1rk1/1p3ppp/p4n2/2Pp4/1Pn5/P1Bp3P/3N2P1/R2QN2K b - - 4 21"]

1...Ne4 (1...d4 2.Nxc4 dxc3 3.Qxd3 Qxd3 4.Nxd3 ) 2.Nxe4 dxe4 3.Qg4 g6 4.Qxe4 *

```
> 7 votes

---
Tags: analysis, positional-play, knights, fork, brute-force
---


title: Why does Stockfish NNUE flatline?

text:
# Question
Title: Why does Stockfish NNUE flatline?
Flatline - to produce a flat evaluation curve.

As I understand engine chess, engines "flatline" in fortress positions. In these positions there are a lot of effectively-equivalent positions that return the same static eval. For example, in a KR vs KB endgame, almost all positions are the same, so it's not surprising that the eval flatlines.

NNUE however is different, because it's a neural network. It's hard for me to imagine that all the computations that's needed in a NN can yield exactly the same number for many different positions. That's why for example Leela Chess Zero never flatlines. How, then, can Stockfish NNUE flatline?

Example of a game where Stockfish NNUE flatlines: first from move 24 to 32 at 0.13, and then from move 33 to 38 at 0.05.

# Answer
> 1 votes
It seems this is happening because for endgame positions, Stockfish uses its handcrafted eval function. This is why Stockfish still has a contempt setting, since it's unclear how to implement contempt with NNUE eval, but contempt is still applicable whenever Stockfish uses its handcrafted eval. The handcrafted eval can flatline, therefore Stockfish can flatline as well.

---
Tags: engines, stockfish
---


# Question
Title: A disagreement between me and my chess engines
In a recent blitz game, I was playing as White and faced the Lasker-Pelikan variation of the Sicilian. Things were not really going according to plan, I was down a Knight and facing obliteration. In the position below, Black has just played Qxe5 :

```
[FEN "2r2rk1/5ppp/1p6/p3q3/1n5R/1P1P2RP/1P1Q2P1/7K w - - 0 25"]

```

In this position, both the Stockfish engine that I have on my phone and the engine from lichess.org give Rxg7+ as the best move for White. Not only that, but they do not even consider the move I played, which is Qh6. The reason why the engine does not think that Qh6 is a good move is that, apparently, Black can respond with Qe1+. However, I cannot see what the problem is for Black in such a case.

To conclude, I think that Black is doomed after Qh6 but the engines do not even recommend it as a correct move. Is there something I am missing here?

# Answer
> 18 votes
> I think that Black is doomed after Qh6 but the engines do not even recommend it as a correct move. Is there something I am missing here?

Yes. The only reason black can't take your queen on h6 is because the g7 pawn is pinned by your rook on g3. If black could take that (even losing the queen to do so) with tempo (i.e. so you don't have time to play Qxh7#) then your queen is lost and with it the game.

Here's how:

```
[FEN "2r2rk1/5ppp/1p6/p3q3/1n5R/1P1P2RP/1P1Q2P1/7K w - - 0 1"]

1. Qh6 Qe1+ 2. Kh2 Qxg3+ 3. Kxg3 gxh6

```

and you are a rook and a knight down and completely lost.

---
Tags: engines, sicilian-defense
---


# Question
Title: Does anybody knows about how the Polgar sisters were trained?
I know they did a lot of hardwork and stuff like that but i just want to know what **exactly** process did they went through(books,how did they practice,etc),is there any biography on them?cause I just did 7months of tactics(~5000),4months of books(strategy),was able to beat the 1800,2000 elo bots on chess.com 6.5/10 times but lost to a 1500 bot(antonio) due to a **blunder**.

# Answer
> 10 votes
The Polgar sisters: Training or Genius? by Cathy Forbes states that the main studying was the flash card method. (Chess: 5334 Problems, Combinations and Games by (the father)Laszlo Polgar \[https://b-ok.cc/book/857033/54e4d4\] provides the puzzles on the flashcards.)

The most important passage (IMO) is the Judith would continue using the flash cards on her free time. When told that she could leave the cards alone, she replied that that cards wouldn't leave her alone. The desire to improve is the most important factor in improvement.

---
Tags: learning, theory, history, famous-players
---


# Question
Title: What is the idea of 'ponder' in the UCI protocol?
I've created my own chess engine and now I'm trying to connect it into the `Chess Arena`. Everything is actually working fine when I play them together (Demo). But I tried to play with it and didn't respond at my second move. So I looked at the console and there's this `go ponder` after my second move. Now I want to know: what's the idea of it?

I tried to go to this link for me to understand, but it's not enough. It says when I receive that command, I need to start searching in pondering mode. What exactly is `start searching in pondering mode`? Is it an infinite search that gets the best move for the opponent and only stops after I moved?

Let's say I move `e2e4`, engine plays `e7e5`. And then receives `go ponder`, after I move, let's say `g1f3`. And then the engine receives `ponderhit` and let's say the search completed depth 5 and result could be `bestmove g1f3 ponder something`. Now what happens if the `bestmove g1f3` matches my move?

# Answer
It's been a long time since I programmed anything, so I may be wrong.

Pondering, like in the comment, allows the computer to think on your time. It basically switches sides and maintains a principle variation (PV search) (although I've seen some engines which maintain 3 PV searches) of what it considers to be the best line. When you make your move, if it's the PV, then it should play the next move immediately.

The problem with ponder is the probability of having a wrong evaluation/incorrect line in the PV. If the opponent's move was made quickly, the computer may have a random move in the PV, not really a possibility with modern computers searching a 3 million NPS, but older computers 20 years ago did have this problem.
> 1 votes

---
Tags: engines, uci
---


# Question
Title: How do you play if both sides get a queen?
Here, I've read through the famous Réti endgame study. However, there is a possibility that both sides can get a queen. For example, take a look at this variation.

```
[FEN "7K/8/k1P5/7p/8/8/8/8 w - - 0 1"]

1.Kg7 h4 2.Kf6 h3 3.Ke7 h2 4.c7 h1=Q 5.c8=Q+ *

```

I've consulted another Wikipedia page, entitled "Pawnless chess endgame", and it says "Queen versus queen: usually a draw, but the side to move first wins in 41.75% of the positions." You can also see the table from the "Tables" section, under the "Common pawnless endgames" subsection. It basically states the same thing. In queen vs. queen, the longest win is in 10 moves and the winning percentage is 42%.

I am really not very good at chess, but is the Wiki article totally correct? If it's correct, then, considering my 41.75 percent winning chance, how do I have to play in order to defeat my opponent if he/she and I both get a queen?

# Answer
> 13 votes
> considering my 41.75 per cent winning chance, how do I have to play in order to defeat my opponent if he/she and I both get a queen?

First of all you need to understand what is meant by "41.75% winning chance". It does NOT mean that your chances of winning are 41.75%. What it means is that in 41.75% of the games considered the game ended in a win and in the other 58.25% it ended in a draw.

Before heading for such an endgame you should first calculate what the result will be because it is pretty hard and fast unless one side blunders.

Basically (provided no blunders) it is always a draw unless one of two conditions apply:

1. The side on move has a forced sequence of moves leading to checkmate
2. The side on move has a forced sequence of moves leading to win of the opponent's queen

The problem is that if the side on move is not in check then they usually have the possibility of an almost endless series of checks on the opponent's king.

Here black is in check and can force an immediate draw by blocking the check with the queen and simultaneously giving check with Qb7+.

However even if black played Kb6 there is no forced checkmate for white and provided black doesn't blunder (by putting the king on the a8-h1 diagonal, the back rank or the h file allowing a skewer check) there is no chance of losing the queen. So it is going to be a draw.

# Answer
> 11 votes
"41.75% win" seems even worsely misleading. The value is technically true for a random position: some stats, but based on the immensely high probability that QxQ or a skewer wins on the spot. (35%, minus K protects his Q, for the capture alone, see below.) In a "neutral" position the chances are far lower - if you can't capture or skewer the Q immediately, the only longer win is the Polerio ending. (Most illuminating here would be a stats of number of won positions vs. win length, this has been done, but I can't find a reference offhand.) Thus, in the position after queening, you can almost make random moves as long as you don't hang your Q.

# Answer
> 2 votes
In this specific position, there is nothing better than to force a queen trade (and the draw) by playing ... Qb7+.

Most good players would have agreed tp a draw no later than the 3rd move as they know that this position will end with in a draw with just reasonable moves. There are examples of both sides queening, but one sides wins due to an immediate checkmate or winning skewer. With lower rated players or maybe if time is really low, there's a chance for a mistake which would explain the absurdly high win percentage.

---
Tags: analysis, endgame
---


title: Why is this position checkmate?

text:
# Question
Title: Why is this position checkmate?
Why is this position checkmate?

```
[FEN "2kr1bnr/1pQ5/p3pp2/2Pp2pp/3P4/3qPN1P/PP1N1PPB/5RK1 w - - 0 19"]

```

# Answer
> 34 votes
The queen is protected by the bishop on h2, so the black king cannot take the queen. Nothing else can take the queen and the queen covers b8 and d7.

# Answer
> 18 votes
Your king is mated when you are in check and no legal move gets you out of check, meaning that all three of the following conditions are met:

1. You cannot capture the attacker.
2. You cannot block the check by interposing a piece between the king and the attacker.
3. There is no safe square to which your king can flee.

The black king is currently in check. He cannot capture the white queen because she is protected by the bishop on h2. (A king may not move to a square in which he would be in check.) No other black piece is in a position to capture the white queen. Therefore, condition 1 is met.

The white queen is adjacent to the black king, so there are no squares available for interposing. Therefore, condition 2 is met.

The only squares the black king could move to that are not already occupied by friendly pieces are b8 and d7, both of which leave him still in check by the white queen. Therefore, condition 3 is met.

Since all three conditions are met, this is checkmate.

EDIT: I've made some minor edits to my answer to address the following two things mentioned in the comments:

1. *You forgot rule 0: "You are in check."* You're correct; these rules don't matter if you're not currently in check. I felt this was implied by rule #1, but I edited the answer slightly to be more explicit.
2. *Wouldn't it be simpler to say that checkmate is when you're in check and no legal move gets you out of check?* Yes, that is simpler. However, it's not as helpful to a beginner, as they might ask, "Okay, but how do I know if no legal move gets me out of check?" My answer helps said newbie out. I've edited the response to be more explicit that the three rules I give are to determine whether any legal move exists to get out of check.

# Answer
> 4 votes
When your king is in check, it has 3 options to escape - either interpose a piece, run away, or capture the attacker. In this position there is no intervening square, so interposing is impossible even if a piece were available to do so. Nor can the king run away since it is blocked by the edge of the board and its own pieces, and the remaining empty escape squares are attacked by the queen. Finally, capture of the queen is impossible since it's protected by its own bishop on h2. Hence the king is in checkmate.

---
Tags: checkmate
---


# Question
Title: Can one improve their chess without playing online?
I have been playing chess for almost a year and I'm addicted to playing chess on Lichess. My stats there are:

* 2100 classical
* 2000 rapid
* 1800 blitz

I feel that playing chess online ruins my life and that my life would be much better without it at the moment.

* I'm studying at University and my grades have dropped.
* I'm not devoting enough time to my work place.
* I'm barely going out with my friends
* I do less sports
* I've dropped some of my other fun hobbies
* I sleep very late
* I barely go on dates

All of these are results of my online chess addiction. However, after all that said, it makes me sad to think that I will give up chess completely. I still want to keep my playing skills and improve.

Can a chess player keep himself in shape by only studying chess (which is not as addictive as playing online) and playing long time control OTB tournaments once in a while? Or should I quit chess completely?

Please help me by finding some things that I could do to stay good at chess while not playing online.

**Edit**:

I'm mainly addicted to blitz, the problem is that I lack self control to restrain myself from playing it. I have tried a few times to stop playing only blitz but failed to accomplish that and went back to my bad habits. I wish there was an option to open an account that would only be allowed to play long time control games, to help people like me. Once I play blitz I usually just crave reaching a specific rating and I play like am possessed.

I started playing in a local chess club a few months ago. I already got to play 3 long time control tournaments, quite successfully, and I want to keep my level there. I fear that without this abusive online playing my abilities OTB will be damaged.

# Answer
> 14 votes
I'd like to start with this comment of yours:

> "I fear that without this abusive online playing my abilities OTB will be damaged."

I know where you are coming from, because I've been there, too. I used to be *ridiculously* addicted to chess - and I wasn't even very good lol. Now it's a hobby, which is much more healthy.

I also know that fear you speak of - I, and people like myself (which presumably includes you) strive for depth, rather than breadth in life. Being very good at one thing seems so much more important than being kind of good at a lot of things; trouble is, I picked the wrong thing.

Personally, *I had to completely stop playing chess for a while.* When I came back to it (in a more recreational fashion), I was indeed worse at chess, and though I have improved, I'm still not completely back to where I was (although I strongly suspect I'll get there).

# It was *completely* worth it.

I had free-time. I had sleep. I had better grades. By golly, I even had more *friends* \- not fair-weather friends, but honest-to-goodness friends that cared about me and my life.

I say all of this to encourage you that even if your playing ability drops off, *please* don't worry about it. **Chess is not your life. Your life is your life. Go out and live it! Study with all of your strength, go on dates, hang out with your friends, work your rear end off and become the absolutely amazing, incredible person that you are** \- one that's always up for a relaxing game of chess with a friend, of course.

---

Now for the practical suggestions:

---

Here are some suggestions for maintaining playing strength while limiting online chess:

* Study master games. Seriously, doing this will get you *way* more chess knowledge than playing oodles of blitz games.
* Read some chess books, playing out the games on the board if you wish. These books are almost always entertaining as well as being extremely helpful.
* Play casually OTB with some friends, analyzing various lines at a relaxed pace - chat with a friend (or maybe even a date) over a nice, no-pressure, slow game (although if it's a date, make sure that she likes chess first XD).
* Visit you local chess club, and play some games there when you're in a good spot with your schoolwork and workplace work.

**TL;DR: it really is possible to enjoy chess *and* have a life.**

# Answer
> 7 votes
I agree with itub's comment. You don't neccessarily have to give up on playing online altogether, but ask yourself whether you just play on at times, game after game, like you're possessed. Does chess become an obsession rather than recreation? Does this happen to you for all time controls?

In general, obsessive playing is more likely when playing blitz (or even faster time controls than that) due to prolonged adrenaline rushes being more likely in faster time controls (in general you get some time to calm yourself down between moves during a longer game).

If you feel like the situation is getting out of hand you shouldn't hesitate to take a break from online chess for a while, and remember that taking a break for now doesn't mean you have to give up playing for the rest of your life. Another thing that you could do that itub also suggested in his comment is to join a local chess club and play chess OTB in general. One of the issues with online chess that makes it addictive is that there's always someone willing to play you online, no matter what time it is, an issue which doesn't really exist with OTB chess in general.

When it comes to keeping oneself in shape chess-wise, I think you don't need to worry that much. If you stop playing completely you will naturally get rusty, but your ability to play will not disappear very easily. When I was inactive for a while during my years as an undergrad I had some issues when I started playing again, but these issues were intimately connected with time management and self-doubt, and after a tournament or two I was already back at full strenght. In general, if you play about 4-5 OTB tournaments a year I have a hard time seeing you even getting rusty in the first place, and if you work on your chess inbetween tournaments by studying chess in general I don't see why you couldn't improve.

# Answer
> 5 votes
In my opinion, online chess often does more to ruin your game than to actually improve it, as most of the time we are just playing Blitz, with not too much thought and with zero analysis of the game

So review your games (I mean, actually do it, not just run them through an engine), find your weakest point and get your hands on a good chess book that treats that topic in depth. A coach is not a bad idea if you can afford it either, but even if you can't, it won't be hard to find some "chess pals" and train with them.

Finally, on the matter of self-control: 1) Try harder! 2) Avoid the temptation by not logging into the site at all! When you play blitz, let it at least be a social activity at the chess club/bar/whatever you're closest to

# Answer
> 3 votes
I would recommend playing in tournaments at your local chess club. Aim for longer games with at least 30 minutes for each side (the longer the better). Based on your online rating, you should be somewhere in the middle of the field depending on the strength of your club.

It may take you some time to adjust to playing over the board if you aren't used to it. However, with practice your online chess skills should transfer to a physical chess board just fine.

# Answer
> 2 votes
If chess is stopping your normal life you should just stop it. It’s not a career for you.

Fischer played better chess than you but never played online. It’s of course possible to improve without playing online. Why not read digital books like Chessable.com? What about study your own game with a computer?

Come out for real tournaments to gain FIDE points whenever you have some time.

# Answer
> 1 votes
Chess is addictive.

Yes you can improve more by not playing online.

But your LIFE would improve even more than your chess if you gave it up or at least made it a very casual hobby instead of trying to improve your game more. You will NOT be a GM. I guarantee it. And if you did, they are a dime a dozen these days. So if you are not in the handful of top world players you will not make any money at chess.

WHY are you playing chess at all? Your list pretty much says chess is messing up your REAL LIFE. If you are logical enough to play chess well you are logical enough to know you should stop playing.

Now, chess is addictive, so find some professional help to break that addiction.

@user19048

# Answer
> 1 votes
Play against Computers instead of humans. I found that playing against the computer is less addictive, as there is no ego involved.

There is a new artificial intelligence called Maia who plays like a human. You can play against it. Keep solving puzzles daily to keep yourself tactically fit.

# Answer
> 1 votes
I'm not a psychologist, but I think you should find out if you are an addiction-prone personality. If yes, then chess would be one of the better choices, since you just might land at another addiction to get the kicks. Willpower is the magic word, and as a chessplayer, your chances are good anyway.

To answer the direct question, I never played online chess in my life and never will do, and still I'm quite strong. It will be an interesting experiment to find out what happened to my ELO after the pandemy, but I guess a few tournaments will put me into shape again. So I don't think it will ruin your ELO giving up online blitz if you read some chess books, solve tactics etc.

---
Tags: learning, study, lichess, otb-chess
---


title: Free tablebase generator software?

text:
# Question
Title: Free tablebase generator software?
I'd like to play a bit with fairy tablebases (Vaclav Kotesovec published quite a few) and am far too lazy to program them anew, especially as I wouldn't wonder if there is free code floating around, and I just would have to find where the PARAMETER N=8 statement hides. (BTW, the results can be quite interesting: as I suspected anyway, Q vs R is drawn on a very large board, and with the right size even a mutual zugzwang exists.)

Still, I never was lucky googling. Do you have any resources? (GitHub, chess programming BBS, maybe even scientific papers)

# Answer
> I never was lucky googling

No need to google. All you needed to do was search on this site and you could have come up with this answer which amongst other things says:

> Ronald de Man (syzygy developer) has published software for generating these tablebases (up to 6 man) on Github
> 2 votes

---
Tags: programming, tablebases
---


# Question
Title: When you are winning, is it ethical to not go for a checkmate right away?
If you are leading a game, is it ethical to capture your opponent's pieces one by one or go straight for checkmate?

# Answer
> 35 votes
There is no rule or law that says that you have to try and checkmate in as few moves as possible and so there is no ethical requirement either.

In fact, if there are just a few pieces left on the board and you are very short of time it makes a lot of sense to take all the opponent's pieces as quickly as possible and only then worry about how you are going to checkmate.

Otherwise if you run out of time while your opponent still has some material left then you are going to lose on time. If your flag falls after you have taken all their pieces then you still get a draw.

# Answer
> 27 votes
It depends.

The USCF Code of Ethics states that the following is unethical:

> Deliberately failing to play at one's best in a game, in any manner inconsistent with the principles of good sportsmanship, honesty, or fair play.

I would take this to mean that if you have a mate in 1 and you see it but purposely don't play it, you're being unethical. However, I would *not* take this to mean that you cannot take your opponent's pieces if this is a legitimate attempt to win (or prevent losing on time.)

# Answer
> 16 votes
If a football game was lopsided at halftime, wouldn't it be ethical to call the game?

Since chess has a resigning option, I don't consider any move as unethical. I consider an opponent who doesn't resign in a hopeless position as someone who deserves to be tortured, and it allows me to practice technique. So promote to all knights and practice the unusual mate.

# Answer
> 9 votes
It depends on level of play and seriousness. If this game is a tournament game but lower rated, I would be happy if my opponent was playing around. This would allow more stalemating chances.

If I seriously didn't want to endure it, I could always resign. If this was a grandmaster game or just a high rated game that was taken seriously, it may be seen as disrespectful and unsportsmanlike to do so.

Just like how there are no real rules against offering a draw, it could be seen as rude to offer a draw when you're clearly losing.

Of course if you're playing a casual game, you can do whatever you want. When I play with my friends I would often give up all my pieces and underpromote some pawns to do fun checkmates like 3 knights and whatnot.

# Answer
> 5 votes
Why would you choose to not choose to checkmate right away? You are wasting both your time and your opponent's time by not doing so. Tournaments take place in short periods of time, so using that time to keep up your ability to play is important. Unless there is a time constraint, and you are trying to ensure that you will not lose by running out of time, you should checkmate in as few moves as possible.

# Answer
> 4 votes
It doesn't hurt to ask your opponent if they'd like to resign or keep playing. I beat a number of better players when they got well ahead and made mistakes, and I lost many games the same way.

Also, weak players don't get to really study desperate endgames if they're always resigning. One of my chess partners used to consistently draw me into a stalemate when I was well ahead, instead of resigning. If he'd just resigned, or if I'd just wiped him out, I would have never grokked that option.

# Answer
> 3 votes
Your opponent has the option to resign.

Personally I feel it depends on the motive. If you deliberately ignoring simple forced mates it seems a bit rude but if you are simply trading pieces to go for a longer/less aggressive and far more certain win that is fine (probably a good idea too).

---
Tags: etiquette
---


# Question
Title: Can someone tell me if this is a checkmate or stalemate?
```
[FEN "5rk/Q1p2p1p/4p1p/2Pq2b/3P2n/4P1Pb/PP1B1P1P/R2R2K w - - 0 1"]

```

Apparently, the system says that it's checkmate, but I don't get it. Can someone please explain it?

# Answer
> 18 votes
This isn't checkmate yet. Neither side is even in check!

However, black is threatening to play Qg2, which would put white in check and there would be nothing to stop that check -- checkmate.

So it's not checkmate *yet*, but it will be soon unless white defends against the threat somehow.

And there is no way to defend against it -- white can block the queen's path by putting a pawn on e4 or f3, but black's queen will just take those pawns and then the threat will be renewed.

# Answer
> 13 votes
I believe you are looking at an engine, and it's telling you is that black, with the correct play, **will** checkmate the opponent. It's not checkmate yet, but as the game progresses, white **cannot** stop checkmate. The engine is showing checkmate not because it's checkmate, but because black will eventually lead to checkmate. White can delay the game by giving up material, but eventually white will run out of defenders, and black will mate. If you look at either side, they both have moves! Stalemate leads to draw, where the side that is going to move does not have any legal moves, but that's not the case here.

tldr: both sides have legal moves so it's not stalemate, and **black, with the correct play (not making any dumb moves like Qxc5), will eventually checkmate white, as there is nothing white can do to stop it.**

# Answer
> 1 votes
While other answers have confirmed that this position will lead to a checkmate by Black, I want to answer the second part of your question (as per the title), the stalemate.

A stalemate occurs when a player is not in a checked position, but has no legal moves to play. An example would be the following position, with Black to play.

```
[FEN "R4n1k/6R1/p7/Pp6/1P6/2B5/5K2/8 b - - 0 1"]
[StartFlipped "0"]

```

Black can't move either pawn, since there's a white pawn in the way.
Black can't move the knight, since that would put the King in check from the white rook on A8.
And Black can't move their King, since they would move into a check (either by the rook or by the bishop).

Yet Black's King isn't in check, so it isn't a checkmate.

Also note that were it White to move, it wouldn't be a stalemate. White could capture the knight with the rook, which would be a checkmate, or White could capture Black's A-pawn with that rook, with would allow Black to move the knight, since this would no longer put Black's King in check.

---

A stalemate is a draw, but keep in mind that not every draw is a stalemate. (Maybe that was why you called it a possible stalemate?)

# Answer
> 1 votes
This is a simple question that deserves a simple answer: **This position is neither checkmate or stalemate.**

Checkmate is where the player to move has no legal moves and is in check. Stalemate is where the player to move has no legal moves and is not in check. In this position, either player would have legal moves if it was their turn, so neither definition applies. (The White king has no legal moves, but other White pieces do have legal moves.)

Now we look specifically at checkmate. The definition is normally stated the other way around: The player to move is in check and has no legal moves. But neither player is in check, again showing that the position is not checkmate.

However, this position *is* a forced mate, either a mate in one (Black to move) or a mate in six for Black (White to move). This means that:

1. If it is Black’s turn, they can reach checkmate on the next move.
2. If it is White’s turn, then Black can reach checkmate in at most six moves, no matter what White does.

This just means that Black *can* reach checkmate in the specified number of moves, if they choose the right moves; if they choose different moves, they may take longer to reach checkmate, or not reach it at all.

---
Tags: analysis, checkmate, stalemate
---


# Question
Title: Who were the first GMs, and how did they become GMs?
In order to qualify for the title of Grandmaster, a player must achieve three Grandmaster norms. This is not the place to go into detail about what those are; the pertinent point is that norms can only be gained in tournaments that fulfill certain criteria, including the requirement that **the entry must include at least three Grandmasters.**

Therefore, it seems to me that it's impossible to become a Grandmaster if there weren't already at least three Grandmasters in existence. How did the first Grandmasters earn the title, and who were they?

# Answer
> 16 votes
> In order to qualify for the title of Grandmaster, a player must achieve three Grandmaster norms.

That is not accurate. The regulations for the award of FIDE titles are given here.

There are two ways to become a grandmaster. Achieving norms and reaching a certain rating is one way but there are also *Direct Titles*. The FIDE handbook defines these like this:

> **Direct title** (automatic title) is a title gained by achieving a certain place or result in a tournament. For example, winning, or achieving a result ≥50 percent in a tournament. On application by the player’s federation and confirmation by the Qualification Commission, such titles are awarded automatically by FIDE.

The tournaments and achievements which qualify the player for the various titles are given in the Table for Direct Titles effective from 1 July 2017.

For the grandmaster title the following results give the player the right to the GM title:

Last 16 of the World Cup
Winner of the Women's World Championship
Outright winner of any of World S65, S50, U20 championships
Outright winner of Continental Individual Championship

But in any case these regulations are made by FIDE and they change with time.

> Who were the first GMs, and how did they become GMs?

The original FIDE grandmasters were awarded the title via a resolution of the FIDE general assembly in 1950. These players were:

1. The top players of the day: world champion Mikhail Botvinnik, and those who had qualified for (or been seeded into) the inaugural Candidates Tournament in 1950: Isaac Boleslavsky, Igor Bondarevsky, David Bronstein, Max Euwe, Reuben Fine, Salo Flohr, Paul Keres, Alexander Kotov, Andor Lilienthal, Miguel Najdorf, Samuel Reshevsky, Vasily Smyslov, Gideon Ståhlberg, and László Szabó.
2. Players still living who, though past their best in 1950, were recognised as having been world class when at their peak: Ossip Bernstein, Oldřich Duras, Ernst Grünfeld, Boris Kostić, Grigory Levenfish, Géza Maróczy, Jacques Mieses, Viacheslav Ragozin, Akiba Rubinstein, Friedrich Sämisch, Savielly Tartakower, and Milan Vidmar.

In 1951 Efim Bogoljubov was added to the list via another vote.

In 1953 something similar to the modern rules was introduced with the world champion and players who qualified for the candidates having the right to the title (if they weren't already) being joined by a variation of the current norm based qualification.

These rules received major revisions in 1957, 1965 and 1970 and may have been tweaked on further occasions.

# Answer
> 0 votes
The original grandmasters were created by the Tsar at the great St Petersburg tournament of 1914. They were Lasker, Capablanca, Alekhine, Marshall and Rubinstein, arguably the five best players of the day, and of whom three held the world championship at one time or another.

---
Tags: history, fide, grandmaster, famous-players, titles
---


# Question
Title: What does an equal odds game look like for a GM vs an engine?
This question began an interesting discussion on handicaps for engines that play against GMs:

Engine-invented variations/hypotheticals

This led me to wonder, are there differences in handicaps in terms of how we measure advantage?

For instance would a material advantage be preferable to space or tempo advantages?

Not sure what the success metric would look like, but i'd like to see the mean permutation on what degree of material advantage places the odds 50/50 for engine vs GM. Then compare that board layout to what tempo advantage would be needed to place the odds at 50/50.

Perhaps if we don't have engines that emulate GMs, we can just use lichess records?

# Answer
As of right now, the "equal odds" between a GM and an engine is about two pawns. I believe Hikaru Nakamura made that comment at some point in this match (I did not watch the entire video). For another perspective, this is what happened when GM David Smerdon played against Komodo with knight odds (GM Smerdon won 5-1).

Note that two pawn odds (White starts without b- and c- pawns) gives a starting eval of about -3.0, while knight odds (White begins without the b1-knight) gives a starting eval of about -5.0. Comparatively 4-tempi odds (White plays e4, d4, Nf3 and Nc3 at start of the game, before Black gets to move) is only about +2.

Do note that giving White five "free" tempi leads to a forced win. For five non-free tempi, you'd have to analyze the specific position.
> 4 votes

---
Tags: engines, advantage, odds
---


# Question
Title: Instead of giving checkmate, I gave stalemate. Why?
I am a beginner, and I have just discovered this annoying stalemate. I got the definition but while playing, I ended up with a stalemate and I don't know why. Could you explain it to me?

```
[FEN "8/8/4K3/8/6R1/2k5/7R/1R1R4 w - - 0 1"]

```

I had 4 rooks that were supposed to block the king so he could not move anymore. Isn't this supposed to be checkmate?

# Answer
> 6 votes
No; for checkmate, the king must be *in check*, i.e. attacked by one of your pieces. This isn't the case in the position you posted, but if you were to move, you'd be able to force mate in two:

```
[FEN "8/8/4K3/8/6R1/2k5/7R/1R1R4 w - - 0 1"]

1. Rh3+ Kc2 2. Rg2#

```

Actually, you don't need that many rooks to checkmate. A lone king and rook will be enough; the procedure is explained in this Wikipedia article.

# Answer
> 1 votes
For checkmate you need to **be able to capture the enemy king in the next move** and your opponent must not have any way to prevent this.

Alternatively this can be defined by two rules that have to be satisfied simultaneously:

1. all escape squares of the king are taken; either blocked by pieces of the king's color or (as in your case) covered by the checkmating side
2. the king is in check (i.e. attacked) and cannot (a) capture the piece which gives check; nor (b) put a piece between the piece which gives check and the king so that the check is interrupted (this would only work for bishop, rook and queen checks)

In your case only "1" is satisfied, so it is not checkmate.

# Answer
> 1 votes
Stalemate and checkmate both involve the player to move having no legal moves. The difference is that, with stalemate, this player is not in check, but with checkmate, this player is in check.

You are correct that the Black king cannot move and, since Black has no other pieces, Black has no legal moves. But Black is not in check. Therefore, this is stalemate and not checkmate.

As Glorfindel has pointed out, if it was White’s turn instead of Black’s turn, it would be possible to force checkmate in two moves. That answer also pointed out that White could force checkmate with just one rook, as described in Wikipedia. This procedure is also described in Wikibooks, along with other useful endgames.

Finally, note that excessive promotion like this (you must have promoted at least two pawns to rooks) is usually discouraged, precisely because it often leads to stalemates like the one you accidentally created.

---
Tags: rules, checkmate, check, stalemate
---


# Question
Title: How did IM Gotham discover cheating before the game?
In a recent scandal, IM Gotham correctly pointed out a cheat even before the game

https://www.youtube.com/watch?v=tAY\_pC3yc0c&ab\_channel=JustForFunHD

The video was in a low digital quality so I couldn't see the screen properly. Not sure where to find the original high definition video. How did Gotham find out the person was a cheater instantly?

# Answer
You can't see it well because it's behind his camera view, but he clicks on the player, bringing up the profile page. And there is his rating chart, which has gone up by a 1000 points in 30 days, very smoothly, as he mentions a few seconds later.

As that would be immediately visible and it's also what he says, my guess is that that is why he immediately suspects cheating.

Then after that, constantly taking more or less the same amount of seconds for every single move, even in the opening, confirms it.
> 9 votes

---
Tags: cheating
---


# Question
Title: Engine-invented variations/hypotheticals
After watching a few alphaZero vs stockfish games, I was very intrigued. Clearly, engines can play at a different kind of level, but for the most part the openings seem pretty meta. Nothing extremely heretical jumped out at me in the first few moves. I dont know how much we humans can read into that; best case scenario the last few hundred years have modeled the opening permutations correctly if engines still use them. Still, engines crush humans on a regular basis.

## Question

What would happen if we forced the engine to use a very absurd opening for the first few moves (like moving both rooks out) then have it resume against a human/GM?

# Answer
I find watching the latest generation of self-taught AIs play is incredibly exciting - and of course they are relatively opaque as is much of AI these days.

Maybe openings turn out to be relatively tractable in that there are not so many fundamentally sensible options, given the transpositions which are possible. A player who begins with a few garbage moves however may still be able to utterly overwhelm a weaker adversary through superior midgame play. So the answer is it depends how much damage the AI inflicted on itself.

The midgame is where the real innovation of alpha zero seems to be. Particularly the received wisdom about pawn play has been turned on its head: pawn sacrifices can be powerful to win tempos and to clear space for line-moving pieces. Surely new concepts like this must already be a factor in top-level human analysis now.
> 3 votes

# Answer
Just my opinion.

Watch the GMs, epically Nakamura, play very unusual openings, odds games, and other stunts against the "mere" 2600s, and you'll find that they still win from a bad position. AlphaZero has shown that it can sacrifice several pawns against the highest rated chess engine. (Game Changer: AlphaZero's Groundbreaking Chess Strategies and the Promise of AI by Matthew Sadler and Natasha Regan is a good book giving many examples of exceptions to human evaluation the common positions.)
> 2 votes

# Answer
Nothing special happens.

Engines play whatever positions you give them. They have no understanding of the word 'absurd'. If you want them to play with a naked king against 3 queens, they'll do it. They'll lose, of course, but they'll do it.

If your question is actually "can a human GM beat an engine if the opening is absurd enough?" the answer is trivially yes. Top human GMs already beat engines at knight odds, so if your opening e.g. gives away a queen for no compensation, humans will win easily. The real question is how unbalanced an opening you need for the match to be balanced, which is addressed in your follow-up question.
> 2 votes

---
Tags: opening, engines, learning
---


# Question
Title: Why does Stockfish lose against this piece sacrifice in the Berlin Defense?
In a recent YouTube video, Jonathan Schrantz presents an absurd (?) piece sacrifice in the Berlin Defense, which Stockfish seems to vastly underestimate.

The engine evaluation shows around -4, until around move 20, when it "realizes" it actually is not even better and starts playing very weird moves. JS plays a live game against Stockfish on the strongest setting available on Lichess and manages to win.

I assume JS did heavy preparation with alternative engines, as the moves played are by no means natural. But what is really happening here? Is the piece sacrifice actually stronger than Stockfish initially judges? Or is it a bad position, that nonetheless manages to break Stockfish and makes it misplay? Is it due to the limited strength of the featured Lichess engine? Throughout the game, it seems to think that almost every move is still winning, but it actually does not predict the responses played by JS, which lead to a shift in the evaluation after being played.

Below is the game until White reaches a winning position, here is link to the video.

```
[FEN ""]

1. e4 e5 2. Nf3 Nc6 3. Bb5 Nf6 4. O-O Nxe4 5. d4 Nd6 6. dxe5 { C67 Ruy Lopez: Open Berlin Defense, l'Hermet Variation } Nxb5 7. Re1 a6 8. c4 Nba7 9. Ng5 Be7 10. Qh5 g6 11. Qh6 Bf8 12. Qh3 Bg7 13. Nc3 h6 14. Qg3 O-O 15. Nd5 Nd4 16. Ne4 d6 17. Bg5 hxg5 18. Nef6+ Bxf6 19. exf6 Re8 20. Qxg5 Be6 21. Nf4 Bf5 22. Re7 Bc2 23. Rae1 Nac6 24. Nd5 Rf8 25. R1e3 Nf5 26. Rh3 Bd1 27. Rh6 Qe8 28. Re3 b6 29. Nf4 Bh5 30. Rxh5 b5 31. g4 Qxe3 32. fxe3 Ne5 33. Rh3 Rfc8 34. gxf5 Nf3+ 35. Rxf3

```

# Answer
> 2 votes
> Is it due to the limited strength of the featured Lichess engine?

Most probably it is the above.

Using the engine at lichess.org/analysis (which is Stockfish 13 NNUE, almost the newest version of Stockfish available), on move 20 its eval was -5.9 for Black and it recommended 20...Rxe1+. The move played, 20...Be6, cost Black a significant amount of its advantage (the eval dropped to -2.8), and 21...Bf5 caused another similar drop. In my analysis run, Stockfish 13 NNUE realized Black had lost its advantage as early as 24...Rf8 (0.00 eval). All the above analysis was at rather low depth of ~25, taking only a few seconds to evaluate for me.

I can't tell if JS used Stockfish 12 with NNUE on. If he didn't, it is over a hundred elo weaker than Stockfish 13 NNUE. I note as well that the analysis engine only ran to depth ~16 at most, which is a very shallow depth in engine chess today (it corresponds to searching only ~8 moves ahead - even human GMs can search further than that in some positions).

---
Tags: engines, analysis, sacrifice, berlin
---


# Question
Title: Why not 5.Bd2 in the French Defense: Exchange Variation?
After the initial moves of the French Defense: Exchange Variation, my opponent played 4.Bb4+. I followed with 5.Bd2, but after analyzing it, I saw that it is not in the master games opening on chess.com and 5.c3 and 5.Nc3 are considered better moves.

```
[fen ""]
1. e4 e6 2. Nf3 d5 3. exd5 exd5 4. d4 Bb4+ 5. Bd2

```

It looks like the most natural move to me, because:

* It forces the bishop away or to take my bishop which I can recapture with my knight, therefore developing it if he decides to take
* c3 looks like a less natural move because although it pushes back the bishop, it prevents my knight from developing on c3 in the future
* Nc3 looks like a less natural move because it pins the knight to the king, and if he takes my knight, he gets my pawns double stacked on the c file, which I always have thought you should try to prevent

So, why the move is weaker?

# Answer
Depending on what database you look at, all three moves (5.c3, 5.Nc3, 5.Bd2) are playing in this position. Nc3 and c3 are the most common, but Bd2 is played sometimes.

A lot of the play in the French Exchange is centered around the central squares and the open e-file. Quite often, White will play c4 and Nc3 and try to deploy their bishops at d3 and f5 or g4.

The problem with playing 5.Bd2 in my opinion is that the bishop is much stronger on a square affecting the center rather than trying to counter Black's bishop. Additionally, if Black plays 5...Bxd2, White can recapture with the Knight, which would put the knight slightly out of position (as it's better on c3 than d2), or the Queen, which would put it slightly out of postion (it's not really affecting anything on d2). If Black does not capture and plays like 5...Bd6 (it's best square), then White needs to reposition the bishop, which is doing nothing on d2.

Playing 5.c3 is fine. It moves Black's bishop, has central solidity, but creates a gameplan where white will need to do more maneuvering to get its pieces (i.e. the b1 Knight) into good positions. Ultimately, the Exchange French tends towards a draw and passive play, and, while 5.c3 seems active, it creates a passive setup for White.

I think @cyclops is right in the value of 5.Nc3. It keeps up the pressure on the center and develops a key piece to its most influential square. Yes, Black can take it and double White's pawns, but a) Black's dark-squared bishop is a really valuable piece in this opening, b) it still allows white to play c4 comfortably to hit the center. It may look messy, but it's better overall.

The French Exchange is usually fairly slow and equal. Bd2 may put White a little out of position, but it does depend on what kind of game White wants to play, i.e. if White wants to be active, passive but solid, or simply counteract anything Black does.
> 1 votes

# Answer
It appears to be 4...Bb4+ that's the unusual move here. The chess.com database only shows one game with it, and that's the game that continued with 5.c3. When you have the position after Bb4+ on the board and it shows 5.Nc3 with a bunch of games, it's actually showing games that *transposed* into that position - the Nc3 was played earlier in the game.

Given that there's only one actual game in the database with Bb4+, there very well may be nothing wrong with Bd2. It hasn't been played simply because the position almost never came up.
> 13 votes

# Answer
I would say that 5.Nc3 is better than 5.Bd2 because 5.Bd2 would allow Black to exchange Bishops very early in the game. It is a general principle that more piece exchanges lead to less complicated middlegames and to more chances of draw, which is naturally something that favors Black. The move 5.c3 does not look optimal to me since, as you said, it blocks the development of the Knight. So, I really don't know why the engine favors it.

By playing 5.Nc3 you develop your Knight to one of its most natural squares, but you allow the pin. This will either force Black to capture your Knight (thus, exchanging a Bishop for a Knight which is generally better for White) or ignore your Knight and further develop. However, White can later respond with a3 followed by c4 and expand his/her grasp on the Queenside. This will probably lead to short castling for both sides, but White should be still slightly better.
> 1 votes

---
Tags: opening, french-defense
---


# Question
Title: Do strong players (2400+) really not double-check their calculations?
(For reference) I'm a candidate master.

However, I've been trying to improve the tactical side of my game, especially calculations and time-management.

One thing I do a lot is double-checking my calculations. While it obviously contributes to my time trouble, this practice has saved me from quite a few blunders.

I've been reading a book by GM Smirnov, Champion Psychology. He strongly insists that it's a very bad habit, as it is a waste of time and proves my lack of self-confidence.

I'm shocked that in my many years of training I've never came across such a blunt opinion (except in Kotov's books, which are, however, strongly criticized e.g. by Nunn in Secrets of Practical Chess).

So what's the deal here? Do strong players (2400+) really not double-check their calculations even in classical time-control?

# Answer
> 6 votes
At shorter time controls, there is little time for conscious double-checking - perhaps there is a kind of parallel awareness of tactical risks and opportunities?

But at longer time controls: there is still a question of what economists call “opportunity cost” - what must I forego if I spend time instead double-checking certain lines?

I am not a serious chess player, but I do compose and solve chess problems, and in both these areas, I reckon that one weakness is I don’t consider enough candidates. I can plunge prematurely into examining detailed lines.

Sometimes that’s productive, but other times I miss better possibilities that I would discover through breadth-first strategic thinking. Effective strategic thinking is hard, but at least I’m aware of the issue and consciously try to work against it. It’s best to do the strategic thinking first, before I go deep and get emotionally invested in particular lines. Once I have an idea of the space of different strategies, then I can triage the most promising ones, then allocating appropriating time to each of them becomes easier, and brief double-checking is a later stage.

By the way, I think this applies to life in general, not just chess. There is no doubt a rack of self-help books about the importance of strategic thinking.

# Answer
> 3 votes
I think the key is to realize that what works for one person may not work for another person. Some people just make more careless mistakes than others 'by default' and have to make up for that by checking more. Just because one chess grandmaster tells you not to double-check does not at all mean that it is correct for you. In fact, not double-checking at all is *definitely* wrong for almost every chess player. What is *definitely* correct is that you have to figure out which subtrees of the search space you want to double-check. Maybe you are double-checking too many of them, and can do better if you skip checking some of the more clear-cut lines, or maybe not. Only you will be able to guess what is the best for you.

You also need to weigh the risks of making an error to guess how many times you want to check a subtree. I definitely check sacrifices a few times just to make sure I did not miss any possible case, because it is too painful to make erroneous sacrifices...

---
Tags: calculation, time-management
---


# Question
Title: How do you write "castles" in algebraic?
Sorry if this question is a duplicate one, but I can't find the algebraic notation for castling. What is it?

# Answer
> 3 votes
In either algebraic or descriptive notation, castling is notated 0-0 or O-O on the Kingside (when the King goes to g1 or g8) and 0-0-0 or O-O-O on the Queenside (when the King goes to c1 to c8). See for example https://en.wikipedia.org/wiki/Algebraic\_notation\_(chess)#Castling

# Answer
> 2 votes
I assume you mean castling? 0-0 denotes kingside castling, i.e. the "short" way, and 0-0-0 is for queenside castling, i.e. the "long" way. The zeros represent the number of squares the rook travels.

---
Tags: castling, notation
---


# Question
Title: Why is it so hard to find a free downloadable chess database with older/historical chess games?
The best free, downloadable chess database I've found is Kingbase (http://www.kingbase-chess.net). It only has games since 1990. I also have the Android Chessbase Online app, which also appears to only have relatively newer games. The only source I know of that has historical chess games is www.chessgames.com (but I don't think you can download the entire database into something like SCID).

Why are these older games so hard to come by?

# Answer
> 6 votes
I invite you do it yourself...

> https://github.com/student-t/ExtractPGN

This is my Python repository for web crawling chess games. I use it to extract PGN chess games from Chessgames. This is an example of the games I extracted:

It's trivial to change the code such that you extract all games from chessgames (**entire database**) into a single PGN file. I believe you're a programmer, so that shouldn't be an issue for you.

# Answer
> 2 votes
This is the link for SmallChess's Python repository for web crawling chess games I found it, just click here : https://github.com/pmerg/ExtractPGN

---
Tags: database
---


# Question
Title: Can we quantify the handicap for playing blindfolded?
Roughly how much ELO does it cost a GM or top player to play blindfolded? For instance, if a 2600-rated GM were blindfolded, against what rating of opponent would they be expected to score roughly 50%? Or, what ELO games roughly correspond to the quality we find when looking at blindfolded games between top GMs (say, 2750-rated) like at Melody Amber?

I'm aware that there will be some variation (e.g. Korchnoi was terrible at blindfold), but there should also be consistency - most top GMs have no trouble playing blindfold and the fact that many top players enjoyed success at Melody Amber suggests none of that group are massively less affected by the blindfold than the rest.

Some estimates I've found online already:

* A Chess.com thread where a user considers Larry Christiansen's performances and gauges the rating handicap of playing blindfolded to be about 500 points
* A SE post concerning blind players. Here the number 600 points is thrown out there.

These strike me as overestimations (and are called out in the threads themselves for being arbitrary). For example, even the lower bound suggested in the blind players thread (450 points) would make the three top blind players all individually on par with Carlsen or better were they not blind.

As for Christiansen, that's the kind of thing I want to know more about. I presume there are no examples of 2800-rated players testing themselves in blindfold against 2200-rated players. (Examples from say Morphy's time would seem to strengthen my point - Morphy was much stronger than his competition, but his non-blindfold results make very obvious that he was NOT 600+ points stronger, or even close to that, while he had no trouble beating most opponents blindfold.) So maybe we can use examples of 2600+ rated GMs playing against opponents around 2000-2300 to make a judgement?

# Answer
It really depends on the player, because some top players are used to think about their position without looking at the board (Nakamura, for instance is very often looking somewhere else during his games). For these players, it woud feel quite easy to play blindfold. But there are lots of players, who never think without looing at the position on the board. For those, it would be more difficult.
> 2 votes

# Answer
It depends. Some can play multiple games at once. Others would struggle to play just one at a much lower level. There is no way to apply a correction factor that would work for all players. I played blindfold as an A player and beat an expert easily.
> -1 votes

---
Tags: rating, blindfold-chess, handicap
---


# Question
Title: Are there any examples of high-level games in which the game was resigned or drawn without any captures?
Are there examples of high-level games which were resigned or drawn before any captures were made? Along similar lines, what game had the most moves before a capture was made?

Edit: I'm especially interested in longer games without captures (I'd like to see the strategies, etc); I'm not necessarily looking for the shortest game without captures.

# Answer
> 11 votes
Per Wikipedia:

**Shortest Game with no captures**

> The shortest decisive game ever played in master play that was decided because of the position on the board (i.e. not because of a forfeit or protest) is Z. Đorđević – M. Kovačević, Bela Crkva 1984. It lasted only three moves (1.d4 Nf6 2.Bg5 c6 3.e3?? Qa5+ winning the bishop), and White resigned.

```
[Fen ""]
1.d4 Nf6 2.Bg5 c6 3.e3?? Qa5+

```

> There have been many forfeited games (which could technically be regarded as losses in zero moves), the most notable examples being Game 2 of the 1972 world championship match between Boris Spassky and Bobby Fischer, which Fischer defaulted, and Game 5 of the 2006 world championship match between Vladimir Kramnik and Veselin Topalov, which Kramnik defaulted. A game between Fischer and Oscar Panno, played at the Palma de Mallorca Interzonal 1970, went 1. c4 resigns. Panno refused to play to protest the organizers' rescheduling of the game to accommodate Fischer's desire not to play on his religion's Sabbath. Panno was not present when the game was to begin. Fischer waited ten minutes before making his move and went to get Panno to convince him to play. Fifty-two minutes had elapsed on Panno's clock before he came to the board and resigned.

**Most moves without a capture**

> In Rogoff-Williams, World Junior Championship, Stockholm 1969, the first capture (94.bxc5) occurred on White's 94th move.

# Answer
> 19 votes
Wikipedia says that the longest decisive game without a capture is:

> Nuber-Keckeisen, Mengen 1994 lasted 31 moves without a single capture. In the end Keckeisen, facing imminent checkmate, resigned:

```
[Fen ""]

1.e4 b6 2.d4 e6 3.Bd3 Bb7 4.Nf3 g6 5.O-O Bg7 6.Nbd2 Ne7 7.Re1 O-O 8.Nf1 d6 9.Qe2 Nd7 10.Bg5 Qe8 11.Rad1 a5 12.c3 Rc8 13.Ng3 Kh8 14.Qd2 Ng8 15.h3 e5 16.Bc2 h6 17.Be3 Rd8 18.Nh2 Kh7 19.f4 f6 20.Qf2 Ne7 21.Rd2 Rh8 22.f5 g5 23.Bd1 Rb8 24.Bh5 Qf8 25.Ng4 Ba6 26.Red1 b5 27.b4 a4 28.a3 Bb7 29.Rd3 Nc6 30.Bg6+ Kg8 31.Qa2+ 1-0

```

For a drawn game:

> Filipowicz-Smederevac, Polanica Zdroj 1966 was drawn in 70 moves under the fifty-move rule, without any piece or pawn having been captured (Whyld 1986, p. 124).

```
[fen ""]
[Event "Rubinstein Memorial 4th"]
[Site "Polanica Zdroj (Poland)"]
[Date "1966.08.25"]
[Round "14"]
[White "Filipowicz Andrzej (POL)"]
[Black "Smederevac Petar (YUG)"]
[Result "1/2-1/2"]
[ECO "C00"]
[WhiteElo "2330"]
[BlackElo "2450"]
[Annotator ""]
[Source ""]
[Remark ""]

1.e4 e6 2.d3 Ne7 3.g3 c5 4.Bg2 Nbc6 5.Be3 b6 6.Ne2 d5 7.O-O d4
8.Bc1 g6 9.Nd2 Bg7 10.f4 f5 11.a3 O-O 12.e5 a5 13.a4 Ba6 14.b3
Rb8 15.Nc4 Qc7 16.Kh1 Nd5 17.Bd2 Rfd8 18.Ng1 Bf8 19.Nf3 Be7 20.h4
h5 21.Qe2 Ncb4 22.Rfc1 Bb7 23.Kh2 Bc6 24.Na3 Ra8 25.Qe1 Rdb8
26.Qg1 Qb7 27.Qf1 Kg7 28.Qh1 Qd7 29.Ne1 Ra7 30.Nf3 Rba8 31.Ne1
Bd8 32.Nf3 Rb8 33.Ne1 Bc7 34.Nf3 Rh8 35.Ng5 Bd8 36.Nf3 Be7 37.Qg1
Bb7 38.Nb5 Raa8 39.Na3 Ba6 40.Qf1 Rab8 41.Nc4 Bd8 42.Qd1 Ne7
43.Nd6 Bc7 44.Qe2 Ng8 45.Ng5 Nh6 46.Bf3 Bd8 47.Nh3 Ng4+ 48.Kg1
Be7 49.Nc4 Nd5 50.Nf2 Bb7 51.Nh3 Bc6 52.Qg2 Rhc8 53.Re1 Rc7 54.Re2
Ra7 55.Ree1 Ra6 56.Re2 Rba8 57.Ree1 R8a7 58.Na3 Ra8 59.Nc4 Nh6
60.Na3 Nf7 61.Nf2 Rd8 62.Nc4 Rb8 63.Nh3 Bd8 64.Na3 Ra7 65.Qh1
Bc7 66.Qg2 Rd8 67.Qh1 Nh6 68.Ng5 Qe8 69.Kh2 Rd7 1/2-1/2

```

# Answer
> 7 votes
There is a drawing line in the Zaitsev variation of the Ruy Lopez that shows up from time to time I would think.

```
[FEN ""]
1.e4 e5 2.Nf3 Nc6 3.Bb5 a6 4.Ba4 Nf6 5.O-O Be7 6.Re1 b5 7.Bb3 d6 8.c3 O-O 9.h3 Bb7 10.d4 Re8 11.Ng5 Rf8 12.Nf3

```

# Answer
> 3 votes
If allow the longest game without a capture based on losing on time, you can bump it up to 71 moves. The source is the page '"Chess Records." on Tim Krabbe's site.

```
[Title "Meijfroidt B.-Lenoir A., Veurne, 2000"]
[FEN ""]

1. c4 Nf6 2. Nc3 e5 3. g3 d6 4. Bg2 Nbd7 5. e3 c6 6. Nge2 Qc7 7. O-O Be7 8. d3 O-O 9. b3 h6 10. Bb2 Nh7 11. d4 f5 12. e4 f4 13. f3 g5 14. Kh1 Ndf6 15. d5 c5 16. Qd3 Bd7 17. Nd1 Qc8 18. Nf2 Nh5 19. g4 Ng7 20. h3 Nf6 21. Kh2 Kf7 22. Rh1 Rh8 23. Kg1 h5 24. Bc3 Rh6 25. Kf1 Qe8 26. Ke1 b5 27. Kd2 a5 28. Kc2 Rh8 29. Qd2 Qb8 30. Kd3 Rc8 31. Nc1 Bd8 32. Ke2 Qa7 33. Qc2 Qa6 34. Bd2 Bb6 35. Ncd3 Qa7 36. Nb2 Rf8 37. Qd3 Rac8 38. Rac1 b4 39. Ra1 Kg6 40. Qc2 Rf7 41. Nbd3 Rcf8 42. Ne1 Qa8 43. Bc1 Qc8 44. Bb2 Qa6 45. Qd3 Ra8 46. Qc2 Nge8 47. Ned3 Qc8 48. Ne1 Ra6 49. Qd3 Qa8 50. Nc2 Rh7 51. Qd1 Ng7 52. Bc1 Qh8 53. Bb2 Ra7 54. Rb1 Bc8 55. Ra1 Rf7 56. Qd3 Nge8 57. Rag1 Nc7 58. Rd1 Kg7 59. Ra1 Qe8 60. Kd2 Kg8 61. Rae1 Re7 62. Ba1 Qg6 63. Bb2 Rh6 64. Ba1 Reh7 65. Bb2 Qg7 66. Na1 Bd7 67. Qe2 Qf7 68. Qd3 Qe8 69. Nc2 a4 70. Ke2 Qa8 71. Rd1 Qa6

```

# Answer
> 0 votes
Just have a look at this game : https://en.wikipedia.org/wiki/List\_of\_world\_records\_in\_chess#Latest\_first\_capture

---
Tags: statistics, captures, master-games
---


# Question
Title: Is there a website that supports blind chess?
I am a blind chess player and desperately need a platform that I can play online. I've searched the web and the only thing that I could find is software that you have to download in order for this feature to be supported. I don't like to go for trouble if I don't have to. I would like to know if there is an online website that supports these kinds of features.

# Answer
Lichess has an option to play blindfolded if you have an account registered.

You have to activate the Speech Sound effect, in the upper right corner → Sound → Speech.

To enable writing coordinates(e.g. Nxe4) instead of moving pieces you can activate blindfold mode in your game display preferences.

Enjoy your games!

Source
> 35 votes

---
Tags: online-chess, websites, blindfold-chess
---


# Question
Title: Why does my ability/rating against bots vary?
I've recently started playing chess again and am training against the chess.com bots.

I've been able to blaze through the lower rated bots and started to get stuck around the 1100s with having to take time with my games to get past them and recently beat a 1500 bot.

However, I've found an old page open with a 550 bot (Oliver) and, although rushing the openings, I haven't been able to consistently beat him.

Is this variance in being able to beat 1500, but still have challenge with much lower ratings normal?

# Answer
> 2 votes
The bots do have a lot of variance, especially the weaker ones. I just tried playing Oliver and he hung his queen on move 3. If that happens you're obviously going to have an easy game.

> and started to get stuck around the 1100s with having to take time with my games to get past them

> although rushing the openings, I haven't been able to consistently beat him.

So when you play the stronger bots, you take your time, and when you play the weaker ones, you don't? That explains it. It's pretty easy to get into a losing position fast if you aren't taking the game seriously enough, even against a weak opponent. This can happen both against computers and against real players.

---
Tags: engines, rating, training
---


# Question
Title: What is the name of this unconventional opening?
You start by moving the knight's pawn on either side to b3 or g3. Then you do the same on the other side. Ideally, you fianchetto the bishops into both triangle pawn formations.

```
 [FEN ""]

1. b3 null 2. g3 null 3. Bb2 null 4. Bg2

```

I tried to use it as Black, but I am still struggling to make it into a strong defense, as it appears to be rather a powerful offensive opening. This opening seems to be gaining popularity at least for White, but I struggle to find information about it on the Internet.

# Answer
> 12 votes
This set up is often called "The Hippo", a possible reason is that bishops look like the eyes of a hippopotamus.

For example: Eric Rosen: Don't Mess With The Hippo

# Answer
> 7 votes
The setup after b3+Bb2 or g3+Bg2 (or on Black's side b6+Bb7, g6+Bg7) is called a fianchetto https://en.wikipedia.org/wiki/Fianchetto. Doing this on both Kingside and Queenside is thus called a "double fianchetto"; I don't think there's a more specific name than that.

# Answer
> 2 votes
1.b3 is Nimzo-Larsen attack. You can check with Lichess database.

# Answer
> 1 votes
1.b3 is called Larsen's opening, while 1.g3 is Benko's opening. They are examples of openings that are collectively called modern or hypermodern.

If you have doubts about opening names, I think the easiest thing to do is play them on a chess engine. Usually the engine will then tell you what is the corresponding name of the opening.

---
Tags: opening, pawns, terminology, bishops
---


# Question
Title: Quickly converting board to bitboard representation using python-chess library
I would like to convert a given chess board into its bitboard representation, but my implementation is rather slow. Here is what I'm doing (using the python-chess package):

```
board = chess.Board('rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1)

w_pawn = (np.asarray(board.pieces(chess.PAWN, chess.WHITE).tolist())).astype(int)
w_rook = (np.asarray(board.pieces(chess.ROOK, chess.WHITE).tolist())).astype(int)
w_knight = (np.asarray(board.pieces(chess.KNIGHT, chess.WHITE).tolist())).astype(int)
w_bishop = (np.asarray(board.pieces(chess.BISHOP, chess.WHITE).tolist())).astype(int)
w_queen = (np.asarray(board.pieces(chess.QUEEN, chess.WHITE).tolist())).astype(int)
w_king = (np.asarray(board.pieces(chess.KING, chess.WHITE).tolist())).astype(int)

b_pawn = (np.asarray(board.pieces(chess.PAWN, chess.BLACK).tolist())).astype(int)
b_rook = (np.asarray(board.pieces(chess.ROOK, chess.BLACK).tolist())).astype(int)
b_knight = (np.asarray(board.pieces(chess.KNIGHT, chess.BLACK).tolist())).astype(int)
b_bishop = (np.asarray(board.pieces(chess.BISHOP, chess.BLACK).tolist())).astype(int)
b_queen = (np.asarray(board.pieces(chess.QUEEN, chess.BLACK).tolist())).astype(int)
b_king = (np.asarray(board.pieces(chess.KING, chess.BLACK).tolist())).astype(int)

return np.concatenate((w_pawn, w_rook, w_knight, w_bishop, w_queen, w_king,
                       b_pawn, b_rook, b_knight, b_bishop, b_queen, b_king))

```

For the starting position this function returns:

```
[0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0]

```

Which is what I want. The only issue is the speed of this function.

# Answer
> 6 votes
python-chess already has the built in utilities to handle conversions. Here is an example:

```
import chess

board = chess.Board('rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1')

WP = board.pieces(chess.PAWN, chess.WHITE)
BP = board.pieces(chess.PAWN, chess.BLACK)

print (int(WP), int (BP))

print (list(WP), list(BP))

print ("\nWHITE PAWNS:\n" + str(WP))

print ("\nBLACK PAWNS:\n" + str(BP))

```

Output:

```
65280 71776119061217280

[8, 9, 10, 11, 12, 13, 14, 15] [48, 49, 50, 51, 52, 53, 54, 55]

WHITE PAWNS:
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
1 1 1 1 1 1 1 1
. . . . . . . .

BLACK PAWNS:
. . . . . . . .
1 1 1 1 1 1 1 1
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .
. . . . . . . .

```

From a list, or from an integer, you can easily construct a Bitboard however you choose to define it.

# Answer
> 6 votes
To convert a single bitboard to a numpy array:

```
def bitboard_to_array(bb: int) -> np.ndarray:
    s = 8 * np.arange(7, -1, -1, dtype=np.uint64)
    b = (bb >> s).astype(np.uint8)
    b = np.unpackbits(b, bitorder="little")
    return b.reshape(8, 8)

```

To convert multiple bitboards to a numpy array:

```
def bitboards_to_array(bb: np.ndarray) -> np.ndarray:
    bb = np.asarray(bb, dtype=np.uint64)[:, np.newaxis]
    s = 8 * np.arange(7, -1, -1, dtype=np.uint64)
    b = (bb >> s).astype(np.uint8)
    b = np.unpackbits(b, bitorder="little")
    return b.reshape(-1, 8, 8)

```

Example usage:

```
import chess
import numpy as np

board = chess.Board()

black, white = board.occupied_co

bitboards = np.array([
    black & board.pawns,
    black & board.knights,
    black & board.bishops,
    black & board.rooks,
    black & board.queens,
    black & board.kings,
    white & board.pawns,
    white & board.knights,
    white & board.bishops,
    white & board.rooks,
    white & board.queens,
    white & board.kings,
], dtype=np.uint64)

board_array = bitboards_to_array(bitboards)

```

Which gives:

```
>>> board_array.shape
(12, 8, 8)

>>> black_pawns = board_array[0]
... print(black_pawns)
...
[[0 0 0 0 0 0 0 0]
 [1 1 1 1 1 1 1 1]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]]

>>> black_kings = board_array[5]
... print(black_kings)
...
[[0 0 0 0 1 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]
 [0 0 0 0 0 0 0 0]]

```

---
Tags: engines, programming, python, performance, bitboard
---


title: Retrograde problem websites

text:
# Question
Title: Retrograde problem websites
I am looking for a good chess website about retrograde analysis problems, but after a few searches, I haven't found anything. Are there any websites that you can recommend?

# Answer
> 5 votes
I would recommmend The Retrograde Analysis Corner It is a top notch and well known site that explains castling and en passant conventions, what exactly it is all about, and how to solve such problems among it's many, many helpful things.

# Answer
> 5 votes
Do not miss Rund um die Retroanalyse, a blog by Thomas brand, in German language. It features each week a retro problem, with explanations and the problem solution.

# Answer
> 1 votes
There are literally thousands of retro problems at https://pdb.dieschwalbe.de, accessible through the easy-to-use query interface.

There are already discussions for many of the most interesting ones, and if you have any questions or comments, you can just add your own.

---
Tags: problems, retrograde-analysis, websites, recommendations
---


title: German chess composition glossary

text:
# Question
Title: German chess composition glossary
I'm trying to look through some puzzles at http://www.wenigsteiner.de/, but there are some abbreviations I'm not familiar with that I'm having a hard time finding through Google; I guess they are abbreviations for German words, but I don't know German. Is there a glossary with such words?

In particular:

* I think VRZ just means defensive retractor, short for "Verteidigungsrückzüger", but what is VV VRZ? (Seen in Andreas Thoma's problems from 2018 preselection)
* What is kBP 22.0 (I'm guessing "shortest proof game", but I'm not sure how)? (Seen in the First Prize problem from 2018)

# Answer
> 10 votes
VV is Vorwärtsverteidigung - if a position is retracted into where Black might interfere (by mating White himself ?!), he may. kbP is indeed SPG. A translation source for many problem chess terms

# Answer
> 5 votes
The glossary at https://pdb.dieschwalbe.de/keywords.jsp?s=all translates many terms from German, English & French. However it is far from complete.

For fairy terms there is also https://www.dieschwalbe.de/lexikon.htm

Any particular questions which remain, please raise here and I will try to answer.

---
Tags: terminology
---


# Question
Title: Where can I find these mentioned chess problems?
In his article “The Horse Concoction", Tim Krabbe mentions retrograde analysis problems that involve placing 10 rooks, knights, or bishops on the board for a mate in 1. The 10 rooks problem shown (it also on site). However, the other two by Henrik Juel and Guus Rol are only mentioned. Who made which is unclear, although suspect that it goes respectively.

Here is the relevant portion of the article.

> "In the last few years this old idea, where all the pawns of one or even both sides promote to one kind of piece, had been taken up again by the Dane Henrik Juel and the Dutchman Guus Rol - first with Bishops, then with Knights. And when Goldsteen saw Rol's latest version of an earlier composition by Juel, something unusual happened to him: he was jealous. He was just pissed off that he hadn't thought of Juel's and Rol's ten-knight problem (add ten black Knights to a given position so that White can mate in 1)."

Can these problems be found online? I would love to see them out of curiosity and to learn more about retrograde analysis.

# Answer
Thank to Bojan Basic, who responded to my thread on the Matplus.net forum, I now know what the knight problem is. But the bishop problem still remains unseen, it seems.

This is Henrik's Juel predecessor problem. It can be found in the Die Schwable Chess Problem Database Server.

```
[Title "Henrik Juel, Probleemblad 1/1999, Add a king and 9 Black knights for a mate in one"]
[FEN "n7/7P/P7/8/8/1PKPP1P1/2P2P2/1N1N4 w - - 0 1"]

```

Here is the improved problem that Guus Rol created. It is also in the Die Schwable Chess Problem Database Server.

```
[Title "Henrik Juel & Guus Rol, Probleemblad 05/1999, 4th Honorable Mention, Add a king and 10 Black knights for a mate in one"]
[FEN "8/7P/8/P7/6K1/1P1PP1P1/2P2P2/2NN4 w - - 0 1"]

```

Lastly, although it is not the 10 bishops problem, this problem is a nice one that captures the essence of it what it may be. Once more, it is in the Die Schwable Chess Problem Database Server.

```
[Title "Henrik Juel. Probleemblad, 5/1997, Add a mating bishop"]
[FEN "b3B3/1k1B3B/7b/1B3b1B/B6b/3b1K1b/7B/1BbBbbB1 w - - 0 1"]

```
> 0 votes

# Answer
Henrik Juel's three "add pieces" problems listed above (together with a fourth one) are all to be found, together with detailed solutions in PDB, using the query: a='juel' and K='add pieces'.

Here is the superb fourth one, with its surprising solution...

```
[Title "Henrik Juel. Probleemblad, 5/1997. Add a unit. What was the last move?"]
[FEN "4k3/ppp1pp2/4pp2/8/3P4/3P2P1/1PpP1PP1/2K5 w - - 0 1"]

```
> 1 votes

---
Tags: problems, retrograde-analysis, identify-this
---


title: What is the next best move for white?

text:
# Question
Title: What is the next best move for white?
Is there a possibility that white can win this game as long as both players are playing the best of their game?

What should be the next move for white to play if white wants to win the game?

* avoid checks to white king/play defensive.
* try to capture black queen even if white queen needs to be sacrificed?
* protect the white pawn on C file

```
[FEN "r2Q4/5q1k/2P3pp/p7/4n1P1/2b4P/P7/2KR4 w - - 0 1"]

```

# Answer
At this point, I believe white is completely lost, and it seems that the engine agrees. I think the basic idea is that the material deficit is too much and the black king isn't in any real danger as the bishop on c4 can come into g7 and block any checks/mating ideas. While the white king is in the open with active black pieces around it.

Firstly if you take the rook (Qxa8), then Qc4. You can block any checks with the bishop and create a discovery check, which will lead to a checkmate.

You can't really protect the c-pawn well and if you do, it will be too slow as black has very quick ways to infiltrate with the queen. And for similar reasons, it is also not feasible to play defence, as you have too many weaknesses to cover .

Trading queens also doesn't get you anywhere, although it is recommended by the engine since black's queen is more dangerous than white's. In that case, if you take back with the rook (Rxd7) then Bg7 again and black's rook is always going to keep an eye on the pawn. If pawn takes, then Bf6 and the square is always covered enough times. Not to mention that black can always sack a piece for the pawn and will still be up a minor piece.

Having said all that, although the game is lost for white in all situations, I think your best practical bet would be to take the rook on a8 and sort of hope that black is not able to find the checkmate. As counterplay, you can try to push your past pawn or get your rook on offence with a check.

Hope this helps!
> 5 votes

# Answer
White should resign. There is no way to avoid losing.

(Also, if I understand the board diagram correctly and Black's last move was to move the queen from f2 to f7, then Black missed the move Qb2 which is immediate checkmate.)

(Edit: We actually don't know the second part for sure, as black could have been in check with a rook on f7 for example, but of course we won't know for sure, unless we had the moves)
> 2 votes

# Answer
I think white can play Rd7, and if the queens are both taken by the rooks, then after blacks king moves, you can play Rb7, followed by c7, then Rb8, pinning the rook. If I'm mistaken, and black can play something which doesn't involve Queen trade, or in the Rb7,c7, Rb8 moves black can counter, please inform me.
> 0 votes

---
Tags: learning, strategy
---


title: CQL - Isolated Queen Pawn postions

text:
# Question
Title: CQL - Isolated Queen Pawn postions
I'm looking for a CQL query that will return all positions with the below pawn structure for both White and Black

```
 [FEN "8/pp3ppp/4p3/8/3P4/8/PP3PPP/8 w - - 0 1"]

```

# Answer
All right, so I found the following query for the pawn structure in the diagram above:

```
(match  ;query for IQP white
      (position
         :and (
            (position Pa2 Pb2 Pd4 Pf2 Pg2 Ph2 pa7 pb7 pe6 pf7 pg7 ph7)
            (position
            :piececount P[c2-7,e2-7] 0
            :piececount p[c2-7,d2-7] 0 )
         )
      )
)

```

For black though, I wanted to search for any IQP position, so I used this query:

```
    (match ;query for IQP black
      (position
        :and (
          (position pd5)
          (position
            :piececount P[a2-7] 1
            :piececount P[b2-7] 1
            :piececount P[c2-7] 0
            :piececount P[d2-7] 0
            :piececount P[e2-7] 1
            :piececount P[f2-7] 1
            :piececount P[g2-7] 1
            :piececount P[h2-7] 1

            :piececount p[a2-7] 1
            :piececount p[b2-7] 1
            :piececount p[c2-7] 0
            :piececount p[d2-7] 1
            :piececount p[e2-7] 0
            :piececount p[f2-7] 1
            :piececount p[g2-7] 1
            :piececount p[h2-7] 1
      )
     )
  )
)

```

Lame, but at least it works :)
> 1 votes

---
Tags: isolated-pawn, cql
---


# Question
Title: How good is 1. e3 2. c4 as an opening for White?
How good is 1. e3 2. c4 as an opening for White? Afterward, developing the knight on b1 to c3, and developing the bishops too, it seems good. Castling is preferably done on opposite sides as well.

# Answer
Overall, I wouldn't suggest it, especially for a beginner. There are better ways to fight for an advantage.

By playing e3 first, you are allowing your opponent to do almost whatever they like on their first move. Are you OK with them playing 1...d5? Is that going to prevent you from playing c4? If that's going to be a problem, you may want to play 1.c4 first instead (which is the much more reputable English opening.)

With a pawn on e3, your c1 bishop has limited scope. Perhaps you want to fianchetto it to b2? Otherwise, it's either stuck on d2 where it doesn't do much, or you need to play e4 to free it, which perhaps means that e3 was a waste of a tempo.

Castling on opposite sides seems like it's something you need to decide later - don't do it if you aren't in the right position. If your opponent castles kingside (which they usually do), then castling queenside means that you're putting your king on the c-file, behind a pawn you've moved two squares (and if you've fianchettoed the c1 bishop, the b-pawn has also moved.) Depending on what your opponent has been doing and how open the game has become, this may be a bad idea.
> 7 votes

# Answer
It’s difficult to assess how good a relatively unplayed opening like this when considered in isolation. However I feel it’s dominated by the English. I want to play 1.c4 first, as it's directly aggressive, and leaves the door open as to how I will develop the bishops. I am unlikely to play e4 for a while, as d4 can become weak, but I don’t need to play e3 yet.

The question then is: are there any risks in the English which mean I should play 1.e3 first? What countermove would mean I don’t want to play 2.c4, and play something else? Actually, no Black response to 1.c4 particularly alarms me: I feel ok to play in any of the 20 positions which Black returns to me after his first move.

Domination of one strategy by another is a simplifying concept in game theory, in the absence of complete analysis. So a sufficient answer to the question: “how good is 1.e3?” Is “not as good as 1.c4!” The Nakamuras of this world will continue to play with it occasionally, but not, I suspect, against the Karlsens of this world.
> 4 votes

# Answer
Compared to what?

I played e3 myself way back then - if you manage to lure your opponent into a reverse Sicilian, especially any sharp variation where the tempo makes the difference, it's fine.§ Otherwise, hard to say. You could take a look at the Lichess opening book on the analysis board: e4 has 33/42/25%, e3 33/27/39%. But note those stats might be extremely skewed (only 687 games for e3, maybe all by the same oddball who will never learn...)

§After 1.e3 e5 2.c4 Nf6 3.Nc3 d5 4.cxd5 the stats are already 50/31/18. Even a GM game is listed, you have one guess who played White, hint: begins with N and ends with akamura. ;-)
> 1 votes

---
Tags: opening, theory, beginner, development
---