title: Java Library for PGN parser

text:
# Question
Title: Java Library for PGN parser
I would like to find a Java library that will allow me to read a PGN file that could contain several chess games, probably with comments inserted also. But, it won't be used to generate moves or play the moves in a board. I just want to read the PGN and get the header section and move section, and dump everything into a database.

Any light that will direct me to the right path is really appreciated. I just need the parser and segment the information from the PGN and then I will do the dumping into the database.

# Answer
After reading a bunch of open source code, I just found out that most of them are relying on *Chesspresso* which is a solid Java Chess library that can handle move validation, PGN parser (what I was looking for), chessboard renderering, etc.

The code is well-documented and easy to understand. It took me around 30 minutes to read the code and start testing. Pretty happy with this library.

You can download the source code from sourceforge: Chesspresso Source Code

**Sample code:** (This is a fragment from Game class, I just need to add more detail for the header section and I will be ready to dump each pgn game into my database).

```
    public String getHeaderString(int line)
{
    if (line == 0) {
        StringBuffer sb = new StringBuffer();
        sb.append(getWhite());
        if (getWhiteElo() != 0) sb.append(" [").append(getWhiteElo()).append("]");
        sb.append(" - ").append(getBlack());
        if (getBlackElo() != 0) sb.append(" [").append(getBlackElo()).append("]");
        sb.append("  ").append(getResultStr()).append("  (").append(getNumOfMoves()).append(")");
        return sb.toString();
    } else if (line == 1) {
        StringBuffer sb = new StringBuffer();
        sb.append(getEvent()).append(", ").append(getSite()).append(", ").append(getDate());
        sb.append("  [").append(getRound()).append("]");
        return sb.toString();
    } else if (line == 2) {
        return getECO();
    } else {
        throw new RuntimeException("Only 3 header lines supported");
    }
}

```
> 10 votes

# Answer
You could use chesslib.

In the README file there is an example of how to load and walk through all the moves from all the games in the PGN file:

```
    PgnHolder pgn = new PgnHolder("/opt/games/linares_2002.pgn");
    pgn.loadPgn();
    for (Game game: pgn.getGame()) {
        game.loadMoveText();
        MoveList moves = game.getHalfMoves();
        Board board = new Board();
        //Replay all the moves from the game and print the final position in FEN format
        for (Move move: moves) {
            board.doMove(move);
        }
        System.out.println("FEN: " + board.getFen());
    }

```
> 4 votes

# Answer
As a general hint: Look at Open Source Android chess games. Like DroidFish (https://github.com/peterosterlund2/droidfish) Maybe you can find there what you are looking for or at least use it as a starting point.
> 2 votes

# Answer
I know I am late to the party but if anyone is still looking for answer then here's complete source code of my png parser
> 2 votes

---
Tags: database, pgn, master-games, annotation
---


# Question
Title: Does this bishop sac when your knight is pinned to your queen have a name?
This is a common tactic in various openings. It goes like this:

* A bishop pins your knight to your queen
* You sacrifice your bishop with check to attract the king forward
* You give a check with your "pinned" knight to win the bishop that pinned you

Here is an example:

```
[FEN "rn1qkb1r/pp3ppp/2p2n2/4p3/2BPP1b1/5N2/PPP3PP/RNBQK2R w KQkq - 4 7"]

7. Bxf7+! Kxf7 8. Nxe5+ Kg8 9. Nxg4

```

Does this tactic have a name?

# Answer
> 4 votes
Yes; this is called attraction. In this position, the White bishop attracts the Black king to f7 in order for the f3 knight to give check on e5, forking the king and bishop. This combination wins White two pawns.

---
Tags: tactics, terminology, sacrifice, pins
---


title: How is "fianchetto" really pronounced?

text:
# Question
Title: How is "fianchetto" really pronounced?
I have heard "fianchetto" for four decades now, and I have always pronounced it "fēənˈCHetō", but I have heard many people also pronounce it "fēənˈketō".

It is of Italian origin, so I am wondering if there are any Italians out there, especially natives, or anyone really, who can tell me what is the true, and proper, pronunciation.

# Answer
> 37 votes
While I'm not sure exactly how "fēənˈketō" would be pronounced (I'm not a native English speaker), that's more correct as to the pronunciation of the "ch" (following the Italian pronunciation).

The pronunciation written in English would be something like `fee-ahn-keh-toh`, with the accent on the third syllable (`keh`).

I just found this website in which there are actual recordings of italian (I hope) people pronouncing it. It sounds pretty good to me.

# Answer
> 29 votes
According to Wikipedia:

> In chess, the fianchetto (/ˌ**fiænˈtʃɛtoʊ**/; **Italian: \[fjaŋˈketto\]** "little flank") is a pattern of development ...

Hence English speakers pronounce the "ch" as in "chess" and Italian speakers as in "kettle".

Which suggests that there is no "true, and proper, pronunciation".

# Answer
> 6 votes
In Italian, c is pronounced like English "ch" or "tsh" before "i" and "e" and like "k" (unaspired) before "a", "o", and "u". If you want it as "k" before "i" and "e", you add an "h" in between, if you want it as "tsh" before "a" (and probably the other dark vowels as well), you add an "i" in between that is not (or hardly) being pronounced.

Similar with "g".

So ciabatta is "tshah-baht-tah", giotto is "jot-to", Giuseppe is "ju-sep-pe", fianchetto is "fee-ahn-ket-to".

# Answer
> 5 votes
*Fianchetto* is commonly pronounced in English as /fiænˈɛtoʊ/ (soft *ch* as in "cherry") but the original Italian word is pronounced /fjaŋˈ**k**etto/ (hard *ch* as in "chaos"). Note the word is cognate to English *flan**k***.

It is common for terms borrowed from other languages to take on 'erroneous' pronunciations if the inherited orthography is ambiguous e.g.

* *cherub* (Latin: /k/; English /tʃ/)
* *pistachio* (Italian: /k/; English /tʃ/)
* *bruschetta* (Italian: /sk/; English: /ʃ/)

# Answer
> 3 votes
When in Rome speak Roman.

They may say fi an Ket oh in Italy, but the rest of the world says fi an CHet oh.

Words change meanings and pronounciations over time and the majority usage eventually wins out.

I always have heard fi an Chet oh and that is how I say it.

# Answer
> 0 votes
When in Rome speak Roman? Yes, "Let's REN-dezz-voose at the high sih-CHOO-ell (as in choo choo train)" I think if you're an American player below 2000, it really doesn't matter how you pronounce fianchetto. But, once you become a really good player, then do as the international chess community does. At the master level, the only proper way to ponounce fianchetto is to respect the Italian origin of the word and to say "fee-uhn-KET-toh". But, you're still free to follow MAGA rules and say "fee-uhn-CHET-toh" if it suits your fancy.

---
Tags: terminology, fianchetto, pronunciation
---


# Question
Title: Can a stalemate be forced even if it is the opponent's turn to move first?
Here are examples in which the side that desires a stalemate can force a stalemate, provided it is their turn to move.

Are there positions where the side which desires a stalemate does not presently have the current move, but can still force a stalemate?

Let the side desiring a stalemate be white. So it is black's turn to move first. I'd expect that to be very difficult because black has one tempo to avoid a stalemate. So whatever black does, it would have to still result in a stalemate.

# Answer
```
[FEN "5k1K/7P/8/8/8/8/8/8 w - - 0 1"]

```

https://lichess.org/analysis/5k1K/7P/8/8/8/8/8/8\_w\_-\_-\_0\_1

**Remark**: Actually, I remember reading about this typical pawn endgame position that is drawn since rook pawn as an explanation as to why stalemate should not be a win for the stalemating player. So if these kinds of stalemates didn't exist, then **I think we wouldn't be talking about stalemates (as a draw) in the 1st place**. So really the root of this question is about why we have stalemates as draws in the 1st place...or something.

IMNSHO, in light of this remark, I think my answer should be the accepted one so that we know this question isn't some fun fact joke question about chess but really about the very foundation of stalemates as draws.

Exhibit A for why stalemate should NOT be a loss for the person stalemated. Black held the draw here by stalemating white -- should black really have won the game here? by Musicrafter
> 11 votes

# Answer
Hauke, it stole at least 20 minutes of my time. But here is here a position, without promoted pieces, in which not infinite tempi can help Black win. This is not a dead position as both sides have theoretical wins. Black can even let White promote and it will be a draw still. Furthermore, if White was low on time for example, they could easily enforce a stalemate with a knight promotion.

```
[FEN "8/6pp/6pk/6p1/6P1/q5PK/P5PP/8 b - - 0 1"]
[startflipped ""]

1... Qb4 2. a4 Qc5 3. a5 Qd6 4. a6 Qe7 5. a7 Qf8 6. a8=N Qe7 7. Nb6 Qd6 8. Nc8 Qc5 9. Nd6 Qd5 10. Nf7+ Qxf7

```
> 12 votes

# Answer
In fact, there are positions where even an infinite amount of free tempi won't help Black at all! Here's a quick sketch:

```
[FEN "7q/8/8/8/8/Pp6/prpp1p1p/Kbkrbrbr w KQkq - 0 1"]

```

Observe White still has five free moves with the P. Even if you add that White may pass whenever he may like - still, the only way to a Black win is White committing suicide, e.g. by promoting and later taking on b2.
> 9 votes

# Answer
I searched PDB for selfstalemate problems, and the only one I found where Black has more material is:

```
[Title "Ivan Bryukhanov. Problemkiste Apr 2002, 5630. P1016527. b) s=3"]
[fen "1k6/R1R5/nKp5/8/q7/8/8/8 w - - 0 1"]
[StartFlipped "0"]

1.Ra8+ Kxa8 2. Ra7+ Kb8 3. Ra8+ Kxa8=

```

The OP asks for the materially superior side to have the move, so take the situation *after* White's played the key move. Now bPc6 is needless. (Bryukhanov needed bPc6 because, without it, 1 Rb7+ win.)

```
[Title "Ivan Bryukhanov (version)"]
[fen "Rk6/2R5/nK6/8/q7/8/8/8 b - - 0 1"]
[StartFlipped "0"]

1... Kxa8 2. Ra7+ Kb8 3. Ra8+ Kxa8=

```

Black's pieces trap wK. White's rooks give sacrificial checks: Black has no option but to capture White's rooks and leave White with a bare, stalemated king.
> 6 votes

# Answer
Black has made a third queen but White has just checked and can get a draw.

```
[Title "Holding the draw against three queens"]
[fen "2K5/4q3/3q4/kR6/8/8/8/1q6 b - - 0 1"]
[StartFlipped "0"]

1... Ka4 {Capturing White's rook stalemates immediately} 2. Rb4+! {Black threatens Qc7# (either), so White must keep checking. 2 Ra5+? Kb3 3 Ra3+ Qxa3 wins in 3 more moves} Ka3 3. Rb3+! {3 Ra4+? Kb2/Kb3 4 Rb4+ Kc2 5 Rb2+ Kd3 then e.g. 6 Rb3+ (wR isn't afraid to be en prise) Ke4 7 Rb4+ Qd4 8 Rxd4+ Ke3 9 Rd7 (9 Rd3+/Re4+? QxR) Qf5/Qe6/Qe8+ wins in 3 more moves} Ka2 4. Rb2+! {4 Ra3+ Kb2! 5 Rb3+ Kc1 6 Rc3+ Qc2 7 Rxc2+ Kd1 8 Rc1+ then e.g. Ke2 9 Re1+ Kf3 10 Rf1+ Ke4 11 Re1+ Kd5 12 Rd1+ Kc6 13 Rc1+ Qc5 14 Rxc5+ KxR/QxR and wins in 3 more moves} Ka1 {Ka3 and continuing refusing to capture makes White's rook a rambling rook} 5. Ra2+! {Both captures stalemate immediately.}

```
> 6 votes

# Answer
Building (or rather tearing down) from Hauke's example:

```
[FEN "8/8/8/p7/8/Ppk56/brpp4/Kbb5 b KQkq - 0 1"]
[startflipped ""]

```

Neither black nor white can avoid the stalemate.
> 3 votes

# Answer
Given that no one else has mentioned this other than bof in a comment, it's likely I'm missing something, but I don't know what: if White is to move and can force stalemate in N moves, then by definition White has a move that creates a position where Black is to move and White can force stalemate in N-1 moves. So any White to force stalemate in more than 2 moves (an example of which you link to) trivially gives an example of what you're looking for.
> 1 votes

---
Tags: problems, stalemate
---


# Question
Title: Puzzles that highlight the finiteness of the chessboard
I'm curious as to whether there are compositions of chess puzzles/problems where the solution really emphasizes the boundedness of the board. Put differently, cases where the solution would be impossible on an infinitely large board.

# Answer
> 6 votes
Now that's a refreshingly different kind of question :)

It's probably easier to compose such a problem than to search for one, but that said, there's one that comes to mind:

```
 [Title "White to play and win"]
 [fen "8/5N1k/8/7b/1b5N/1K6/1B6/8 w - - 0 2"]

```

(Study by Henri Rinck)

**Hint:**

> You want to keep all 3 pieces as white in order to win. Try to set up a trap on the `b4` bishop by setting up a discovery on the black king.

**Solution:**

> 1.Ng5+ Kh6 {only possible attempt to keep material} 2.Bc1 {Double threat: discovery on the king and threatening to take on b4, the trap is set} Ba5 {Any other move drops the bishop to a discovery check} 3.Ka4 Bb6 {only move again} 4.Kb5 Ba7 5.Ka6 Bb8 6.Kb7 {bishop falls.} From move `3.Ka4` it had become clear where this is going: the white king keeps shouldering the bishop until it hits a wall and cannot escape anymore. Now on an infinite board, this trap would have been impossible as the king and bishop dance would have continued endlessly.

# Answer
> 3 votes
Is this the sort of problem you're looking for?

```
[Title "Erich Bartel. Augsburger Allgemeine, 10 Feb 2001, no.628. #6"]
[StartFlipped "0"]
[fen "8/7Q/3b2B1/1K6/3k4/4p3/8/8 w KQkq - 0 1"]

1. Bb1! Ke5 (1... e2? 2. Qe4+) 2. Qf5+ Kd4 3. Qe4+ Kc3 4. Qd3+ Kb2 5. Qc2+ Ka1 6. Qa2#

```

It is P1126265 in the PDB.

# Answer
> 1 votes
A problem must surely demonstrate the finiteness of the board if it has two twins, the solutions are essentially different, and the twinning is by shifting every unit 1 file to the right. Or, regarding the units as fixed, by cutting the empty h-file off the right-hand side and pasting it to the left-hand side.

```
[Title "Heinz Däubler. Augsburger Allgemeine, 23 Sep 2006, no. 919a. P1197652"]
[fen "1B6/1B6/8/1k6/8/1K6/8/1N6 w - - 0 1"]
[StartFlipped "0"]

1. Ba7 Ka5 2. Kc4 {Na3? stalemates} Ka4 3. Bb8 Ka5 4. Bc7+ Ka4 5. Bc6#

```

and

```
[Title "ditto, all 1 file to the right"]
[fen "2B5/2B5/8/2k5/8/2K5/8/2N5 w - - 0 1"]
[StartFlipped "0"]

1. Bb7 Kb5 2. Nb3 {Kd4? Kb4 3 and bK escapes to the a-file and White can't mate in time} Ka4 3. Bd6 Kb5 4. Bc5 Ka4 5. Bc6#

```

---
Tags: problems, mathematics
---


title: I can't understand this puzzle

text:
# Question
Title: I can't understand this puzzle
I came across this puzzle and even after I learned the answer I couldn't quite understand what's going on. I understand that we amaterial advantage by capturing the knight with a pawn, but I can't understand why the queen has to go to d8. Can someone please explain the answer?

```
[FEN "r1b2rk1/1pqpbppp/p3pn2/6B1/3NP3/2N2Q2/PPP2PPP/R3R1K1 w - - 0 1"]

1. e5! Qd8 2. exf6

```

# Answer
> 4 votes
The knight is pinned to the bishop so when white plays e5 the knight can't move without losing the bishop. It looks like maybe the knight *could* move to d5 protecting the bishop. The problem is that white can take the knight with the knight on c3 and black doesn't have time to play BxB because the white knight on d5 is threatening the queen on c7 and so black must first take that d5 knight.

```
[fen "r1b2rk1/1pqpbppp/p3pn2/6B1/3NP3/2N2Q2/PPP2PPP/R3R1K1 w - - 0 1"]

1. e5 Nd5 2. Nxd5 exd5 3. Bxe7 Re8 4. Bd6

```

---
Tags: analysis, puzzles
---


title: Rules: Is this position a draw?

text:
# Question
Title: Rules: Is this position a draw?
Is this position a draw?

```
[FEN ""]
1. Nf3 Nf6 2. Ng1 Ng8 3. Nf3 Nf6 4. Ng1 Ng8

```

I don't mean to ask the age-old question "Is chess a draw?"; four moves have been played here, returning to the starting position. Since the start position has appeared three times, it seems that white can claim a draw by threefold repetition. However, lichess does not permit this claim, which got me thinking that perhaps there is a subtlety to the rules.

FIDE says:

> 9.2
> The game is drawn, upon a correct claim by a player having the move, when the same position for at least the third time (not necessarily by a repetition of moves):
>
> a. is about to appear, if he first writes his move, which cannot be changed, on his scoresheet and declares to the arbiter his intention to make this move, or
>
> b. has just appeared, and the player claiming the draw has the move.
>
> Positions are considered the same if and only if the same player has the move, pieces of the same kind and colour occupy the same squares and the possible moves of all the pieces of both players are the same. Thus positions are not the same if:
>
> 1. at the start of the sequence a pawn could have been captured en passant.
> 2. a king or rook had castling rights, but forfeited these after moving. The castling rights are lost only after the king or rook is moved.

It seems that white clearly has the ability to claim a draw by 9.2.a, since 5. Nf3 would definitely repeat the position after 1. Nf3. But my question is really whether 9.2.b applies for white (or perhaps equivalently whether black can claim the draw on move 4 via 9.2.a): Did the starting position "occur" before 1. Ng3? Or does it somehow not count? Are the rules ambiguous?

Obviously this is a silly game, but this kind of "Fool's Draw" might occur in practice when both players want a draw but are not allowed a normal offer (e.g. FIDE world championship 3.8.3b "The players cannot draw a game by agreement before black’s 30th move.").

# Answer
> 16 votes
This is a better question than it seems at first glance.

Intuitively it seems possible to claim a draw, since the position appears to have occurred three times.

**However,** according to a strict reading of the rules, the position after 4...Ng8 has appeared only for the second time. The relevant clauses are 9.2:

> \[...\] Positions are considered the same if and only if the same player **has the move**, \[...\]

and 1.1 about the start of the game:

> The player with the white pieces commences the game. A player is said to ‘**have the move**’, when his opponent’s move has been ‘made’.

In the starting position, white does not "have the move" since black did not make a prior move, white merely commences the game. Therefore, the positions before 1. Nf3 and after 4...Ng8 are **not** the same, and a draw cannot be claimed yet.

# Answer
> 5 votes
It's a repetition draw, claimable by either side (black on the previous move).

If you believe that "commencing the game" is something different from "having and playing the move" then please explain from the FIDE laws what you do when you "commence the game". How about standing up and proclaiming loudly "the game has commenced" and sitting dow again? Obviously not. "Commencing the game" is only different from "having and playing the move" in that it also indicates it's the first time that white has the move in the game - which is purely informational without legal implications.

The initial game position is as much a position as any other one and after 4. ... Ng8 it appears for the third time with the same player on move. So it is subject to a (pre-)claimed draw. White need not announce 5.Nf3 as the required double repetition was already completed.

# Answer
> 3 votes
This is a funny situation - in a FIDE tournament, it depends on whether you're talking about White or Black. To claim a draw in FIDE tournaments the procedure is as follows:

1) Write down the move you are planning to make that will result in a three-fold repetition. Do NOT make the move.

2) Call over the arbiter and explain what move you're about to make, and how this results in a three-fold. The arbiter checks it over and declares the game drawn.

So after 4.Ng1, if Black wanted to claim a draw he'd write 4...Ng8 down and call the arbiter over. The game would then be declared drawn. If he actually made the move 4...Ng8 and tried calling the aribter over, he could not claim a draw since it's not his turn. It's extremely weird, but this is how it works. So assuming the diagram position has been reached in a real game, Black could not claim a draw there (it's not his turn).

Meanwhile, White could claim a draw in the position you posted. Not because of the fact that the position has been repeated three times, but because if he moves 5.Nf3, the resulting position has been seen three times. So he'd write down 5.Nf3, call the aribter over, etc.

I've known people who have missed out on a draw and ending up losing their game because they weren't aware of this technicality in FIDE tournaments. It's borderline ridiculous but those are the rules.

# Answer
> 1 votes
The position is a draw if and ONLY IF White plays 5. Nf3 again, with the same position repeated 3 times with all the same conditions. However, if any other move is played, the game continues.

---
Tags: rules, draw, threefold-repetition, claim-draw
---


# Question
Title: Why does Black play b6 in these lines of the King's Indian?
In this position, White is threatening to play some combo of Bxc5 / Nxe5:

```
[FEN ""]
1.d4 Nf6 2.c4 g6 3.Nc3 Bg7 4.e4 d6 5.Nf3 O-O 6.Be2 Nbd7 7.O-O e5 8.d5 Nc5 9.Qc2 a5 10. Bg5 h6 11.Be3

```

Here `11...b6` is the most popular response. My question is, why not `Ne8` / `Nfd7` / `Nh5`, since those moves simultaneously deal with White's threat while making way for the f-pawn to be pushed? Initially, I thought the reason was because it'd be somehow bad for Black if White decided to capture on `c5` and Black had to capture back with the d-pawn. But consider this very similar line:

```
[FEN ""]
1.d4 Nf6 2.c4 g6 3.Nc3 Bg7 4.e4 d6 5.Nf3 O-O 6.Be2 Nbd7 7.O-O e5 8.d5 Nc5 9.Qc2 a5 10. Be3 Ng4!

```

This has an ~80% winrate for Black according to the lichess Masters database, and here he's basically saying to White "please, go ahead and capture my knight! I'll capture back with the d-pawn and I'll be super happy with my position!"

So why is `11...b6` preferred to a knight move in the original position?

# Answer
This is the old, old main line that is usually considered dead equal.

I can't believe the 80% winning percentage for black has to do with the objective merits of the position.

Note that Lichess' opening explorer does not show the ratings involved in those games, nor the dates. Looking at percentages only can be extremely misleading.

I think the following is happening: theory probably says that Bg5 10.Bg5 h6 11.Be3 is slightly more precise than 10.Be3, because it has provoked the weakening move ...h6, and that can sometimes be exploited.

So in the games where 10.Be3 is played, *white is probably weaker on average*, or he would have played 10.Bg5. That can explain the 80% score for black.

In similar fashion, the difference in frequency between ...Ng4 and ...b6 may have something to do with the time period, one was probably in fashion for a while, then the other.

I only checked Gallagher's *Play the King's Indian*, which contains the position after Bg5 h6 Be3 by transposition.

His assessment of ...Ng4 there is that it's obviously critical because it was played by Fischer (!) but unnecessarily risky, and he analyzes ...Nh5 and ...b6 to comfortable positions for black.

As that was a very influential book, maybe ...Ng4 became less popular then (around 2004) and ...b6 more popular?

Anyway my feeling is that it's all a matter of taste.
> 4 votes

# Answer
**After 10. Ng4 then simply 11. Bxc5.** You lost a centralized knight but more importantly, after dxc5, white can double on the d file and try to open the centre after rd1

*(Back to the original position)* **11....Nh5** then white can play 12. a3 (b4 in mind) taking initiative, 12. Bxc6 (rd1 in mind) threatening to open the d file, 12. Qd2 with the same idea or probably g3 denying f4 for the knight.

**11.... Ne8 is passive**. White probably won't play Bxc6 because otherwise the knight goes to d6. I dont think it is time to play it and f4 but since we are humans, practical chances exist. \**

**11... Nfd7** would take care of Bxc5 but i dont feel like it is the time to play it.

**11... b6** would take care of Bxc6 and lock the position.

B6\> Nfd7\>Nh5\>Ne8

White has a space advantage and has a slight lead in development. Opening the position would work in white's favor. That is why i think the key move in this line is 8. D5. White shouldn't have closed the position while black should try to do it. That is why b6 is preferred.

.

White suddenly scored lower than black after 8. D5 A computer might be able to handle blacks kingside attack but a human make mistakes. Be3 is much better. If you don't open the position, attack would come from the flank. If that flank is where your king is in, it suddenly becomes more effective than an attack on the other flank due to checks and mate threats. I would think that is why black scored high

(Note that if the resulting position is the same after either Nh5, Nfd7, if Ne8 then it shouldn't matter result wise. But some are better to sidestep some ideas from white)

Edit: i would think statistics can describe practical chances well but there are stuffs happening too. It could be that even tho the moves are inaccurate, the opponent doesn't respond properly, the number of games are small and so on
> 2 votes

# Answer
Rizal provides a good move analysis. Positionally, the black knight at c5 is well placed and moving it would decrease its influence. Supporting the knight with b6 keeps the knight on a good square. If white takes the knight, then capturing the bishop with bxc5 keeps the center closed and opens the b file for black. This makes white's typical plan of queen side expansion difficult. Black can proceed with the usual f7-f5 plan unhindered by white's queenside pressure.
> 0 votes

---
Tags: opening, kings-indian
---


# Question
Title: Which chess pro's are in esports organizations?
All I got so far:

1. Alex & Andrea Botez - Envy
2. Hikaru Nakamura - TSM (team solomid)
3. Andrew Tang (Penguingm1) - C9 (cloud9)
4. Nemo Zhou Qiyu (akanemsko) - CLG (Counter Logic Gaming)

Is there some kind of list for this please? (Besides perhaps doing category intersection on wiki, if it will even give me a complete list, at least with the ones who have wiki pages)

# Answer
Anna Cramling. From Wiki:

> After about a year of streaming on Twitch, she signed with Panda, becoming their first chess streamer as well as the first Swedish chess player to sign with an eSports organisation.
> 2 votes

---
Tags: online-chess, streaming, botez
---


title: Record Swiss top tie

text:
# Question
Title: Record Swiss top tie
In a current German championship, a whopping 11 players currently have 5/6. The fact that 197 players are listed makes this a bit less remarkable, of course. Obviously, the probability p of such an event would be the most convincing record measure, but that's a tough one. I thus suggest the following approximation: Largest tie at the end of a 9 round swiss, measured by t=(tied people at the top)/(all people). (Or is there a statistical argument that I should apply some logarithms?) So we have about t~0.05 here, which should be easy to beat.

Anyway, what is the largest mass tie you recall? (Round robins would be also remarkable, but have the few players advantage in comparison here.)

# Answer
There are a couple of records of this sort in the relevant Wikipedia page. To quote:

> Thirteen players tied for first with 5–1 scores at the National Open held on March 17–19, 2000 in Las Vegas: grandmasters Jaan Ehlvest, Alexander Goldin, Alexander Baburin, Pavel Blatny, Eduard Gufeld, Yuri Shulman, Alex Yermolinsky, Gregory Kaidanov, Dmitry Gurevich, Alexander Stripunsky, and Gregory Serper, and International Masters Rade Milovanovic and Levon Altounian.\[93\]

There's also a double round robin record:

> At the Linares 2001 tournament, five of the six players (83.3%) finished with a minus score. Garry Kasparov won with 7½/10, while Judit Polgár, Alexander Grischuk, Peter Leko, Alexei Shirov, and Anatoly Karpov tied for second to sixth places, each with 4½/10.
> 4 votes

---
Tags: history, swiss-pairing
---


# Question
Title: How do you retrieve your c4 pawn in the Catalan?
In regular queen's gambit, you are happy to give away the c4 pawn because your light squared bishop is staring at the square all game and you will probably be able to eventually retrieve it. In the Catalan opening, your bishop has moved to g2, where it cannot exert pressure on c4. What do you do if your opponent then accepts the c4 pawn?

# Answer
> 4 votes
The primary idea in the Catalan (specifically the open Catalan), is to use the time that black has wasted capturing a pawn to develop quicker and squeeze a small advantage out of the middle game through more active, and optimally placed pieces. The pawn is difficult for black to hold onto if white chooses to pursue material equality, but that style of play is not always compatible with the themes in the Catalan.

To answer your question about regaining the pawn, Qc2 is usually sufficient. Black can defend the pawn but white can take queen side space while undermining the defense of the pawn and generally wind up with a better position. In my experience in the Catalan system, black tends give the pawn back and accept that white had to waste tempi to do so.

# Answer
> 4 votes
Im not a Catalan player myself, but in general, after giving up a pawn, it is not always the right question to ask whether you can recover it. The Queens Gambit is ofter referred to as a pseudo-gambit because recovery of the pawn is often very simple. In those cases (say the Muzio Gambit) where recovery of the material is by no means assured, the right question is how to make use of the compensation. The Catalan seems to me to be an in-between case. White can play to recover the Pawn but doesn't have to. Black can play to hold the Pawn but doesn't have to. For more detail, you need advice from an actual Catalan player.

---
Tags: queens-gambit, catalan
---


# Question
Title: Why don't masters play 7...e5 against the Fianchetto Variation of the King's Indian?
In the Lichess database, this is the most popular way to play against the Fianchetto Variation of the KID:

```
[FEN ""]
1.d4 Nf6 2.c4 g6 3.g3 Bg7 4.Bg2 O-O 5.Nc3 d6 6.Nf3 Nc6 7.O-O e5

```

But at master level, `7...a6` (the Panno Variation) is by far the most popular move, and playing in traditional KID fashion with `7...e5` scores horrendously for Black. What's the reason for this?

# Answer
> 4 votes
I think I found the "refutation" to this setup:

```
[FEN ""]
1. d4 Nf6 2. c4 g6 3. g3 Bg7 4. Bg2 O-O 5. Nc3 d6 6. Nf3 Nc6 7. O-O e5 8. d5 Ne7 9. e4 Nd7 10. Ne1 f5 11. Nd3 Nf6 12. Bg5 h6 13. Bxf6 Bxf6 14. f4

```

I'm no master, but it seems to me like Black's attack has been completely stopped on the kingside because White has managed to blockade e4/f4, while White still has potential for launching a queenside attack. Nearly all of the master games from this position are either White wins or draws.

On the flipside, I did notice that `8...Nb8` scores much better for Black after `8.d5`, but if White plays `9.c5` after that then the winning chances again seem to favor White.

**edit:** Indeed, the `8...Nb8` line is featured on FM Kamil Plichta's Chessable course: https://www.chessable.com/course/31739/

---
Tags: opening, analysis, kings-indian
---


# Question
Title: How does the Grand Prix Attack compare to the Rossolimo/Canal Attack?
How does the Grand Prix Attack compare to the Rossolimo/Canal Variations for someone who wants to develop an anti-Sicilian repertoire? What are the pros and cons of each opening? Thanks.

# Answer
> 5 votes
First and foremost it should be noted that while you can employ the Grand Prix Attack against basically any Sicilian, the Rossolimo/Canal Variations can only be played against 2...Nc6 and 2...d6 Sicilians.

If you look at GM games, the Rossolimo will appear more than the Grand Prix Attack due to being more solid (not moving the f pawn so early and following classical opening principles) and retaining white's opening advantage. Opening theory has found that black can equalize in some lines against the Grand Prix Attack. However, for people way below GM level, the Grand Prix Attack is a great weapon which can often lead to devastating attacks against the black king and interesting dynamic positions. Although the Rossolimo can also result in attacks against the black king, it is more commonly associated to positional games in which white will play against black's doubled c pawns while conceding the bishop pair.

If I had to summarize the advantages/disadvantages of both openings in some bullet points, it would go as follows:

Rossolimo/Canal Variations:

* Often lead to slower and more positional games
* Harder to play for white and black (some positional ideas are hard to understand for both sides)
* More lines to learn for you and your opponent, and so, the better prepared player will often hold some advantage (some lines white plays d4 straight away, some lines you prepare with c3, some lines you play d3...)
* As you climb the elo ladder, this opening can still consistently be used as your main weapon against d6/classical Sicilians
* Great if you play the Ruy Lopez and to a lesser extent the Nimzo-Indian, since you can borrow ideas from them in some lines

Grand Prix Attack:

* Often lead to more aggressive double-edged positions
* Opening moves stay more or less the same regardless of what your opponent plays (easier to play)
* Very thematic ideas and pawn breaks (easier to play)
* Loses a little of its effectiveness as you climb the elo ladder
* Can be played against pretty much any Sicilian

---
Tags: opening, sicilian-defense
---


# Question
Title: What's the accurate move order for this line?
```
[FEN ""]
1.e4 g6 2.d4 Bg7 3.Nc3 c6 4.f4 d5 (4...Qb6 5.Nf3 d5 6.e5 Bg4 7.Be2) 5.e5 Qb6

```

According to the Lichess Masters database, both `4...Qb6` and `4...d5 5.e5 Qb6` are sidelines for Black that score quite well. Which is the more accurate move order here?

To me, it seems like `4...Qb6` is better / more forcing since it comes with a double attack on the d-pawn, forcing White to play `5.Nf3` and giving our light-squared bishop a clear path to develop on `g4`. (`5.e5` seems premature to me-- we haven't committed our d-pawn, so we can start undermining the center with `5...d6`.) On the other hand, I don't really see the point of `4...d5 5.e5 Qb6`-- White can play pretty much anything he wants for his 6th move, ie. he can question your queen immediately with `6.Na4` and then consolidate his pawn chain with `c3`, or make it harder for our bishop to develop with `6.h3`. Is my intuition that `4...Qb6` is better correct?

# Answer
> 1 votes
I found an explanation of this move in Jon Speelman's *Modern Defence* book (published 2000):

So my intuition was correct; `4...Qb6` does seem to be the more accurate move.

# Answer
> 3 votes
Most likely 4...d5 is a little bit better. Why do you want your queen to b6 at all? Usually developing the queen early in the opening is not recommended (for various different reasons) and I think this is no exception. Queen is offsides on b6. It's premature developing, you don't yet know where the queen belongs. After 4...d5 5.e5, the most common moves for Black are 5...h5 and 5...Nh6. It seems 5...h5 has been more popular lately (at least in my database) and I have to say that I personally like it more as well. Pawn to h3 would be a positional mistake by White. White most likely will (and should) develop his knight to f3 during the next few moves after which Black can play Bg4.

Anyway, both moves (4...Qb6 and 4...d5) are definitely playable. I think you should vary your openings and use both, even though I believe 4...d5 to be theoretically slightly better (and more in accordance with the chess principles).

---
Tags: opening, modern-defense
---


# Question
Title: Openings where Black castles queenside and White castles kingside
I really enjoy opposite-side castling positions where I'm able to launch pawn storms and put my opponent under pressure. For this reason, I actually enjoy the Exchange French as Black / I want to take up the Scandinavian Defense, since in both of those openings Black commonly castles queenside while White castles kingside. In what other openings does this usually happen?

(This question was edited; before I was asking about openings that lead to opposite-side castling in general, but in e.g. the Sicilian Dragon when Black castles kingside, White can keep it boring and castle kingside as well. By contrast, this doesn't happen as often when you castle queenside.)

# Answer
> 2 votes
There are some openings where you can castle to the queenside with Black and your opponent typically castles kingside. For example, Botvinnik variation in the Semi-Slav defence. For white, the choice is wider. Zemish variation in King's Indian, main lines in most variations of the Sicilian defence, especially the ones where White play Bg5 or Be3 right away (Keres attack in Scheveningen, main lines in Najdorf, Dragon. In Pirc and Caro Kann White and Black typically castle to different sides as well.

# Answer
> 1 votes
Finding out the entire list of common openings is practically impossible. Many players often play by their own strengths, and one opening someone plays might have queenside castling, while others might not, vice versa. That being said, the most common openings and deviations from these are Sicilian, and queens pawn d4 openings. There is no way to accurately predict what a player chooses in a position.

If you enjoy opposite castling, you should wait till your opponent castles, or if you are sure they will not castle in a certain direction then you can also do so.

# Answer
> 1 votes
Here's a mini-list of openings (both amateur/professional) I compiled that fit this criteria. Feel free to comment or add your own post if you have suggestions:

* Advance Caro-Kann
* Albin Countergambit
* Black Lion
* Botvinnik Semi-Slav
* Exchange French
* Winawer French
* Exchange Ruy Lopez
* Scandinavian Defense, Anderssen Counterattack (Qa5/early e5)
* Scandinavian Defense, Bronstein Variation (Qd6/a6)
* 3.Nf3 Scandinavian

Some more suggestions are listed here.

---
Tags: opening, castling
---


title: Pattern Recognition - Chess Tactics

text:
# Question
Title: Pattern Recognition - Chess Tactics
I have a collection of ten thousand games of a player. Is there a way to look which kind of tactics does the player miss on most often?

Which tactics does he need to focus on?

# Answer
Create a new lichess account. Import the games into the new account. Run AimChess on it. You will then statistics about the player.
> 2 votes

---
Tags: analysis, tactics, training
---


# Question
Title: List of chess players by their peak FIDE blitz rating
I've come across a list of the highest FIDE ratings ever achieved by all 2700+ players in the 2700chess.com:

This shows all the players above 2700 in classical ordered by their FIDE peak rating. It also shows when and where the respective peak rating was acquired. (This can also be found on wiki.)

I tried to find a similar list for the FIDE blitz ratings but to no success.

**Is there a place that has a list of the highest official FIDE blitz ratings by player ? If not, then may you please provide a list similar to here? (Please include their countries.)**

It can be either for the top 100, or all players above 2700. Any of those lists would be good.

Curiously when i hover in the current live top 100 blitz ratings in 2700chess.com i can see the player's peak:

But it doesn't seem have a list with the best blitz's only.

# Answer
> 6 votes
> Is there a place that has a list of the highest official FIDE blitz ratings by player ?

Not as far as I know.

> If not, then may you please provide a list similar to here? (Please include their countries.)

Here are the results from the relevant queries on my database constructed from the downloads available from the FIDE rating download website for players with blitz ratings of 2700 and over. Since you also ask for countries I've included distinct player/country combinations. So, So appears twice, once for the Philippines and once for the US. Similarly Caruana for both Italy and the US and winner in the appearances category, Firouza appears 3 times for Iran, FIDE and France.

The "Period" is the first FIDE rating list in which the player achieved the rating. If the player didn't play rated blitz for a year after that then they obviously retain the rating for the next year so the "Period" is the year and month in which FIDE first recorded that rating for them.

**PlayerName FedName MaxRating Period**

1. Carlsen, Magnus Norway 2986 2017/12
2. Vachier-Lagrave, Maxime France 2948 2019/07
3. Nakamura, Hikaru United States 2934 2019/03
4. Grischuk, Alexander Russia 2923 2012/08
5. Karjakin, Sergey Russia 2906 2013/01
6. Nepomniachtchi, Ian Russia 2880 2014/07
7. Andreikin, Dmitry Russia 2877 2012/08
8. Ding, Liren China 2875 2016/04
9. Aronian, Levon Armenia 2871 2018/07
10. Mamedyarov, Shakhriyar Azerbaijan 2866 2014/12
11. So, Wesley United States 2861 2021/07
12. Artemiev, Vladislav Russia 2849 2018/05
13. Le, Quang Liem Vietnam 2843 2013/08
14. Kramnik, Vladimir Russia 2841 2016/06
15. Anand, Viswanathan India 2832 2018/12
16. Shkuro, Iuri Ukraine 2828 2017/03
17. Giri, Anish Netherlands 2822 2016/05
18. Caruana, Fabiano United States 2818 2018/06
19. Duda, Jan-Krzysztof Poland 2818 2019/01
20. Bogdanovich, Stanislav Ukraine 2815 2015/05
21. Ivanchuk, Vassily Ukraine 2815 2017/12
22. Yu, Yangyi China 2812 2019/09
23. Morozevich, Alexander Russia 2811 2014/10
24. Firoozja, Alireza France 2810 2021/07
25. Mamedov, Rauf Azerbaijan 2810 2016/01
26. Radjabov, Teimour Azerbaijan 2808 2015/01
27. Navara, David Czech Republic 2806 2015/06
28. Svidler, Peter Russia 2805 2019/01
29. Dubov, Daniil Russia 2804 2017/01
30. Kasparov, Garry Russia 2801 2017/09
31. Fedoseev, Vladimir Russia 2798 2015/05
32. Korobov, Anton Ukraine 2797 2014/01
33. Ponomariov, Ruslan Ukraine 2797 2013/07
34. Adams, Michael England 2796 2019/01
35. Dominguez Perez, Leinier Cuba 2796 2017/01
36. Tomashevsky, Evgeny Russia 2793 2016/04
37. Gelfand, Boris Israel 2792 2016/04
38. Nguyen, Ngoc Truong Son Vietnam 2791 2013/07
39. Leko, Peter Hungary 2790 2017/04
40. Bortnik, Alexandr Ukraine 2784 2016/07
41. Wang, Hao China 2784 2016/04
42. Lu, Shanglei China 2781 2015/05
43. Rapport, Richard Hungary 2776 2021/07
44. Caruana, Fabiano Italy 2775 2012/07
45. Harikrishna, P. India 2774 2016/04
46. Kovalenko, Igor Latvia 2774 2015/03
47. Firoozja, Alireza FIDE 2770 2020/07
48. Bu, Xiangzhi China 2767 2019/06
49. Salem, A.R. Saleh United Arab Emirates 2767 2017/07
50. Andriasian, Zaven Armenia 2766 2018/04
51. Amonatov, Farrukh Tajikistan 2764 2016/07
52. Petrosian, Tigran L. Armenia 2762 2018/01
53. Matlakov, Maxim Russia 2760 2020/01
54. Bruzon Batista, Lazaro Cuba 2758 2012/07
55. Jobava, Baadur Georgia 2758 2017/01
56. Kamsky, Gata United States 2756 2012/09
57. Vidit, Santosh Gujrathi India 2756 2019/12
58. Zubov, Alexander Ukraine 2754 2019/08
59. Topalov, Veselin Bulgaria 2752 2012/07
60. Ghaem Maghami, Ehsan Iran 2751 2020/03
61. Kasimdzhanov, Rustam Uzbekistan 2750 2017/06
62. Dreev, Aleksey Russia 2749 2014/07
63. Sargissian, Gabriel Armenia 2749 2014/07
64. Sjugirov, Sanan Russia 2748 2018/11
65. Malakhov, Vladimir Russia 2747 2015/04
66. Bacrot, Etienne France 2744 2013/03
67. Riazantsev, Alexander Russia 2744 2013/10
68. So, Wesley Philippines 2744 2014/07
69. Dominguez Perez, Leinier United States 2743 2015/12
70. Onischuk, Vladimir Ukraine 2743 2015/08
71. Smirin, Ilia Israel 2743 2014/11
72. Wojtaszek, Radoslaw Poland 2743 2014/07
73. Wei, Yi China 2740 2017/06
74. Gretarsson, Hjorvar Steinn Iceland 2737 2017/11
75. Polgar, Judit Hungary 2736 2014/07
76. Maghsoodloo, Parham Iran 2735 2019/09
77. Jakovenko, Dmitry Russia 2734 2012/08
78. Jones, Gawain C B England 2734 2016/05
79. Savchenko, Boris Russia 2734 2015/05
80. Adly, Ahmed Egypt 2733 2016/10
81. Chadaev, Nikolai Russia 2733 2013/03
82. Iturrizaga, Eduardo Venezuela 2733 2016/10
83. Bologan, Viktor Moldova 2732 2012/07
84. Dlugy, Maxim United States 2731 2012/08
85. Shimanov, Aleksandr Russia 2731 2012/08
86. Movsesian, Sergei Armenia 2730 2013/07
87. Tkachiev, Vladislav France 2730 2014/01
88. Alekseev, Evgeny Russia 2729 2015/06
89. Bauer, Christian France 2728 2019/07
90. Inarkiev, Ernesto Russia 2728 2013/03
91. Fressinet, Laurent France 2727 2013/03
92. Melkumyan, Hrant Armenia 2727 2016/01
93. Vitiugov, Nikita Russia 2727 2015/11
94. Meier, Georg Germany 2726 2014/07
95. Georgiev, Kiril Bulgaria 2725 2013/03
96. Firoozja, Alireza Iran 2724 2019/01
97. Xiong, Jeffrey United States 2724 2019/11
98. Efimenko, Zahar Ukraine 2719 2012/10
99. Socko, Bartosz Poland 2718 2017/06
100. Bocharov, Ivan Russia 2715 2018/11
101. Shirov, Alexei Latvia 2715 2013/03
102. McShane, Luke J England 2713 2012/07
103. Kuzubov, Yuriy Ukraine 2712 2015/05
104. Laznicka, Viktor Czech Republic 2711 2015/11
105. Safarli, Eltaj Azerbaijan 2711 2017/05
106. Amin, Bassem Egypt 2709 2018/01
107. Bachmann, Axel Paraguay 2709 2016/04
108. Bruzon Batista, Lazaro United States 2709 2018/01
109. Kravtsiv, Martyn Ukraine 2709 2019/07
110. Guseinov, Gadir Azerbaijan 2708 2018/10
111. Moiseenko, Alexander Ukraine 2708 2012/07
112. Topalov, Veselin FIDE 2708 2017/12
113. Tsydypov, Zhamsaran Russia 2708 2019/03
114. Najer, Evgeniy Russia 2707 2013/10
115. Sasikiran, Krishnan India 2707 2012/07
116. Kononenko, Dmitry Ukraine 2706 2015/08
117. Ponkratov, Pavel Russia 2705 2016/08
118. Swiercz, Dariusz Poland 2705 2016/04
119. Hou, Yifan China 2704 2015/01
120. Rakhmanov, Aleksandr Russia 2704 2014/12
121. Shankland, Samuel L United States 2704 2019/08
122. Pantsulaia, Levan Georgia 2703 2017/08
123. Vovk, Yuri Ukraine 2702 2015/11
124. Berkes, Ferenc Hungary 2701 2015/09
125. Zhigalko, Sergei Belarus 2701 2016/01
126. Fridman, Daniel Germany 2700 2013/01
127. Jumabayev, Rinat Kazakhstan 2700 2016/04

---
Tags: rating, fide, statistics, blitz
---


# Question
Title: Python-chess : How to make infinite analysis in multiPV mode?
I need to run infinite analysis in multiPV mode. How to do it right? My code doesn't work.

```
original_fen = "7k/1b1r1pp1/3Bp1np/1p2P1q1/8/1PQB2P1/2R2P1P/6K1 b - - 3 23"
original_board = chess.Board(original_fen)
full_path = PATH + ENGINE_NAME_FIRST
engine = chess.engine.SimpleEngine.popen_uci(full_path)
with engine.analysis(original_board, multipv=MULTI_PV) as analysis:

```

# Answer
> 1 votes
You will need to open a UCI connection, and then issue the following command:

```
go infinite

```

And then issue 'stop' to the engine when you would like to stop the search.

The documentation is simple and has everything.

---
Tags: engines, analysis
---


title: Why is this position drawn?

text:
# Question
Title: Why is this position drawn?
This position was reached in semi-final game 1 of FIDE world cup 2021. With black to play the players agreed to a draw. The white is up a pawn and looks to be winning? I am not able to figure out a drawing continuation for black.

```
[FEN "8/8/4k3/6K1/8/7P/8/8 w - - 0 1"]

```

# Answer
In these rook-pawn endgames the key rule is that if the defending king reaches the queening square (h8 in this case) then the game is a draw. If the attacking king manages to control it (but not occupy it), however, then it can be a win. You can see this by looking at the key positions

```
[FEN "7k/8/6KP/8/8/8/8/8 w - - 0 1"]

```

White cannot stop Black from playing ...Kg8-h8 *ad infinitum*, and h7 leads to an immediate draw by stalemate. Similarly if

```
[FEN "7K/5k2/7P/8/8/8/8/8 w - - 0 1"]

```

This position is also drawn because White cannot extract the king from in front of the pawn.

In the game, Black to play goes ...Kf7, and White cannot stop Black from playing ...Kh8 eventually, reaching the first position. Hence the position is drawn.

If it were White to play in this position, then 1. Kg6 wins. 1...Ke7 2. Kg7! (any other move allows 2...Kf8 and again Black reaches the first position) followed by h4-h5-h6 leads to a promotion that Black cannot stop.
> 22 votes

# Answer
Ke6-f7-g8-h8 and then the black king shuffles between h8 and g8. If white pushes the pawn to h7, it will lead to stalemate. The pawn can't be promoted. This is basic endgame theory and very useful to know!
> 6 votes

---
Tags: endgame, fide, pawn-endgame
---


# Question
Title: List of chess players by their peak FIDE rapid rating
Similar to these:

1. List of female chess players by peak FIDE rating
2. List of female chess players by peak FIDE rating with countries?
3. List of chess players by their peak FIDE blitz rating
4. List of female chess players by their peak FIDE blitz rating

There is a Wiki list is for all of the top-rated FIDE chess players. But where is the list of top chess players by peak FIDE rapid rating? Please include countries.

---

Update: Wow. See answer: Carlsen, Magnus Norway 2919, 1st and only player so far to achieve 2900+ in rapid. Unlike blitz where, as we can expect, Hikaru Nakamura has achieved 2900+

# Answer
> 2 votes
Here are the results from the relevant queries on my database constructed from the downloads available from the FIDE rating download website for players with rapid ratings of 2700 and over. Since you also ask for countries I've included distinct player/country combinations. So, for instance, Caruana appears for both Italy and the US.

The "Period" is the first FIDE rating list in which the player achieved the rating. If the player didn't play rated rapid for a year after that then they obviously retain the rating for the next year so the "Period" is the year and month in which FIDE first recorded that rating for them.

It is interesting how old some of these peak rapid ratings are. It looks like maybe the top players don't play that much rapid, compared to blitz and standard?

**PlayerName FedName MaxRating Period**

1. Carlsen, Magnus Norway 2919 2017/07
2. Vachier-Lagrave, Maxime France 2873 2019/11
3. Caruana, Fabiano Italy 2858 2014/07
4. Nakamura, Hikaru United States 2853 2019/06
5. So, Wesley United States 2852 2018/07
6. Grischuk, Alexander Russia 2851 2017/07
7. Ivanchuk, Vassily Ukraine 2844 2016/01
8. Ding, Liren China 2836 2020/01
9. Mamedyarov, Shakhriyar Azerbaijan 2833 2017/07
10. Aronian, Levon Armenia 2830 2015/03
11. Karjakin, Sergey Russia 2830 2012/08
12. Caruana, Fabiano United States 2829 2015/03
13. Dominguez Perez, Leinier Cuba 2826 2017/12
14. Anand, Viswanathan India 2822 2018/04
15. Nepomniachtchi, Ian Russia 2821 2015/11
16. Korobov, Anton Ukraine 2818 2019/12
17. Dominguez Perez, Leinier United States 2816 2018/09
18. Artemiev, Vladislav Russia 2812 2018/11
19. Fedoseev, Vladimir Russia 2810 2018/01
20. Kramnik, Vladimir Russia 2799 2016/03
21. Svidler, Peter Russia 2799 2014/08
22. Wang, Hao China 2795 2019/04
23. Yu, Yangyi China 2795 2017/05
24. Morozevich, Alexander Russia 2791 2014/10
25. Topalov, Veselin Bulgaria 2790 2013/07
26. Radjabov, Teimour Azerbaijan 2788 2012/07
27. Kobyliansky, Igor Ukraine 2787 2020/01
28. Dreev, Aleksey Russia 2785 2013/01
29. Kasparov, Garry Russia 2783 2017/09
30. Dubov, Daniil Russia 2779 2019/01
31. Giri, Anish Netherlands 2779 2017/10
32. Malakhov, Vladimir Russia 2777 2014/01
33. Onischuk, Vladimir Ukraine 2775 2019/02
34. Duda, Jan-Krzysztof Poland 2774 2020/01
35. Andreikin, Dmitry Russia 2773 2013/10
36. Leko, Peter Hungary 2773 2014/01
37. Le, Quang Liem Vietnam 2771 2014/10
38. Inarkiev, Ernesto Russia 2767 2017/11
39. Sjugirov, Sanan Russia 2765 2016/01
40. Wang, Yue China 2765 2014/01
41. Adams, Michael England 2764 2014/01
42. Kamsky, Gata United States 2762 2013/03
43. Jakovenko, Dmitry Russia 2759 2019/11
44. Harikrishna, P. India 2758 2018/12
45. Rublevsky, Sergei Russia 2757 2015/10
46. Gelfand, Boris Israel 2755 2017/01
47. Tomashevsky, Evgeny Russia 2752 2014/07
48. Vitiugov, Nikita Russia 2752 2012/11
49. Wei, Yi China 2752 2020/01
50. Zhigalko, Sergei Belarus 2752 2015/11
51. Bu, Xiangzhi China 2751 2018/05
52. Navara, David Czech Republic 2751 2017/10
53. Fressinet, Laurent France 2750 2013/01
54. Kovalenko, Igor Latvia 2750 2016/02
55. Ponomariov, Ruslan Ukraine 2748 2013/11
56. Rapport, Richard Hungary 2748 2017/10
57. Short, Nigel D England 2744 2017/01
58. Nguyen, Ngoc Truong Son Vietnam 2743 2015/09
59. Wojtaszek, Radoslaw Poland 2743 2013/03
60. Shirov, Alexei Latvia 2742 2014/02
61. Kryvoruchko, Yuriy Ukraine 2740 2015/11
62. Guseinov, Gadir Azerbaijan 2739 2015/11
63. Mamedov, Rauf Azerbaijan 2739 2018/10
64. Ponkratov, Pavel Russia 2737 2018/01
65. Moussard, Jules France 2736 2019/10
66. Oparin, Grigoriy Russia 2736 2021/01
67. Naiditsch, Arkadij Germany 2735 2013/01
68. Riazantsev, Alexander Russia 2735 2017/01
69. Bacrot, Etienne France 2733 2015/05
70. Anton Guijarro, David Spain 2732 2017/09
71. Bologan, Viktor Moldova 2732 2012/07
72. Zubov, Alexander Ukraine 2731 2019/04
73. Xiong, Jeffrey United States 2730 2019/11
74. Cheparinov, Ivan Bulgaria 2727 2014/03
75. Chigaev, Maksim Russia 2727 2018/07
76. Jobava, Baadur Georgia 2727 2014/07
77. Savchenko, Boris Russia 2727 2018/01
78. Matlakov, Maxim Russia 2726 2019/11
79. Movsesian, Sergei Armenia 2725 2016/01
80. Eljanov, Pavel Ukraine 2724 2013/10
81. Brunello, Sabino Italy 2722 2019/11
82. Pantsulaia, Levan Georgia 2722 2018/01
83. Petrosian, Tigran L. Armenia 2721 2019/01
84. Rakhmanov, Aleksandr Russia 2721 2018/05
85. Salem, A.R. Saleh United Arab Emirates 2720 2019/01
86. Bogdanovich, Stanislav Ukraine 2719 2016/07
87. Safarli, Eltaj Azerbaijan 2718 2019/09
88. Vallejo Pons, Francisco Spain 2718 2013/07
89. Vidit, Santosh Gujrathi India 2718 2017/01
90. Amonatov, Farrukh Tajikistan 2716 2017/01
91. Sargissian, Gabriel Armenia 2715 2019/06
92. Alekseenko, Kirill Russia 2714 2019/01
93. Moiseenko, Alexander Ukraine 2714 2012/08
94. Motylev, Alexander Russia 2711 2020/01
95. Ragger, Markus Austria 2711 2015/07
96. Grachev, Boris Russia 2710 2012/11
97. Meier, Georg Germany 2710 2019/06
98. Istratescu, Andrei France 2709 2013/08
99. Khairullin, Ildar Russia 2709 2013/07
100. Khismatullin, Denis Russia 2709 2016/01
101. cShane, Luke J England 2709 2016/08
102. Efimenko, Zahar Ukraine 2708 2012/10
103. Kokarev, Dmitry Russia 2708 2018/10
104. Akopian, Vladimir Armenia 2707 2017/07
105. Shirov, Alexei Spain 2707 2019/07
106. Popov, Ivan Russia 2706 2016/01
107. Bruzon Batista, Lazaro Cuba 2704 2013/10
108. Fedorchuk, Sergey A. Ukraine 2704 2017/10
109. Socko, Bartosz Poland 2704 2015/11
110. Firouzja, Alireza FIDE 2703 2020/01
111. Tsydypov, Zhamsaran Russia 2703 2020/04
112. Li, Chao b China 2702 2017/01
113. Areshchenko, Alexander Ukraine 2701 2013/07
114. Najer, Evgeniy Russia 2701 2015/06
115. Fridman, Daniel Germany 2700 2017/09
116. Iturrizaga, Eduardo Venezuela 2700 2014/07

---
Tags: history, rating, fide, statistics, records
---


# Question
Title: List of female chess players by their peak FIDE blitz rating
Similar to these:

1. List of female chess players by peak FIDE rating
2. List of female chess players by peak FIDE rating with countries?
3. List of chess players by their peak FIDE blitz rating
4. List of chess players by their peak FIDE rapid rating
5. List of female chess players by their peak FIDE rapid rating

There is a Wiki list is for all of the top-rated FIDE chess players. We now have a list for the top female chess players by peak FIDE rating. As in link above, we have a list of top chess players peak FIDE blitz rating. But where is the list of top female chess players by peak FIDE blitz rating? Please include countries.

I'll start

1. Polgar, Judit Hungary 2736 2014/07
2. Hou, Yifan China 2704 2015/01 (Good for Hou Yifan in being rated 2700+ in blitz though not standard.)

Update: See answer: There are indeed no other females in the list above.

# Answer
> 1 votes
Here are the results from the relevant queries on my database constructed from the downloads available from the FIDE rating download website for female players with blitz ratings of 2400 and over (chosen as the nearest round number to give close to 100 players). Since you also ask for countries I've included distinct player/country combinations.

The "Period" is the first FIDE rating list in which the player achieved the rating. If the player didn't play rated blitz for a year after that then they obviously retain the rating for the next year so the "Period" is the year and month in which FIDE first recorded that rating for them.

**PlayerName FedName MaxRating Period**

1. Polgar, Judit Hungary 2736 2014/07
2. Hou, Yifan China 2704 2015/01
3. Muzychuk, Anna Ukraine 2665 2014/05
4. Gunina, Valentina Russia 2652 2015/04
5. Lahno, Kateryna Russia 2643 2017/01
6. Muzychuk, Anna Slovenia 2639 2013/01
7. Kosteniuk, Alexandra Russia 2612 2013/03
8. Dzagnidze, Nana Georgia 2591 2014/05
9. Stefanova, Antoaneta Bulgaria 2590 2016/04
10. Kosintseva, Tatiana Russia 2578 2014/05
11. Zhao, Xue China 2576 2014/05
12. Paehtz, Elisabeth Germany 2574 2013/09
13. Harika, Dronavalli India 2573 2015/01
14. Ushenina, Anna Ukraine 2573 2014/01
15. Ju, Wenjun China 2571 2016/05
16. Tan, Zhongyi China 2565 2015/08
17. Koneru, Humpy India 2558 2013/01
18. Zhukova, Natalia Ukraine 2553 2012/07
19. Lahno, Kateryna Ukraine 2549 2014/01
20. Lei, Tingjie China 2543 2019/06
21. Stefanova, Antoaneta FIDE 2540 2017/01
22. Cmilyte, Viktorija Lithuania 2532 2013/01
23. Bodnaruk, Anastasia Russia 2530 2016/11
24. Kosintseva, Nadezhda Russia 2519 2012/07
25. Wang, Jue China 2512 2013/06
26. Sebag, Marie France 2504 2014/01
27. Chiburdanidze, Maia Georgia 2497 2012/07
28. Krush, Irina United States 2494 2016/12
29. Khotenashvili, Bela Georgia 2485 2014/01
30. Charochkina, Daria Russia 2481 2013/10
31. Ding, Yixin China 2476 2012/08
32. Kulon, Klaudia Poland 2473 2018/09
33. Huang, Qian China 2472 2014/07
34. Cori T., Deysi Peru 2470 2012/07
35. Socko, Monika Poland 2465 2017/02
36. Matnadze, Ana Spain 2464 2012/07
37. Khademalsharieh, Sarasadat Iran 2463 2019/06
38. Staniak, Maria Poland 2458 2018/07
39. Abdumalik, Zhansaya Kazakhstan 2457 2018/01
40. Munguntuul, Batkhuyag Mongolia 2455 2012/08
41. Batsiashvili, Nino Georgia 2454 2012/07
42. Romanko, Marina Russia 2454 2014/11
43. Melia, Salome Georgia 2453 2012/07
44. Zhu, Chen Qatar 2451 2013/01
45. Goryachkina, Aleksandra Russia 2449 2018/01
46. Arabidze, Meri Georgia 2445 2016/11
47. Pham, Le Thao Nguyen Vietnam 2444 2015/11
48. Muzychuk, Mariya Ukraine 2443 2012/07
49. Pogonina, Natalija Russia 2443 2015/06
50. Zatonskih, Anna United States 2442 2013/01
51. Javakhishvili, Lela Georgia 2439 2017/08
52. Rogule, Laura Latvia 2438 2016/07
53. Moser, Eva Austria 2436 2013/10
54. Cramling, Pia Sweden 2435 2018/01
55. Gvetadze, Sofio Georgia 2435 2013/05
56. Michna, Marta Germany 2433 2018/01
57. Danielian, Elina Armenia 2432 2012/07
58. Lomineishvili, Maia Georgia 2431 2012/07
59. Zhai, Mo China 2429 2012/08
60. Khurtsidze, Nino Georgia 2428 2012/07
61. Kovalevskaya, Ekaterina Russia 2427 2012/08
62. Kashlinskaya, Alina Russia 2426 2017/11
63. Mkrtchian, Lilit Armenia 2426 2012/07
64. Girya, Olga Russia 2425 2013/10
65. Guo, Qi China 2425 2013/06
66. Alexandrova, Olga Spain 2424 2014/08
67. Pustovoitova, Daria Russia 2423 2016/01
68. Hoang, Thanh Trang Hungary 2422 2016/11
69. Gaponenko, Inna Ukraine 2421 2017/11
70. Kalinina, Olga Ukraine 2421 2014/07
71. Galliamova, Alisa Russia 2417 2016/11
72. Peptan, Corina-Isabela Romania 2417 2013/01
73. Turova, Irina Russia 2416 2015/08
74. Khukhashvili, Sopiko Georgia 2415 2012/09
75. Skripchenko, Almira France 2412 2018/01
76. Houska, Jovanka England 2411 2014/05
77. Maltsevskaya, Aleksandra Russia 2411 2020/10
78. L'Ami, Alina Romania 2409 2014/01
79. Li, Ruofan Singapore 2406 2015/05
80. Sukandar, Irine Kharisma Indonesia 2406 2016/01
81. Vaishali R India 2405 2017/11
82. Szczepkowska-Horowska, Karina Poland 2404 2013/01
83. Tania, Sachdev India 2404 2012/07
84. Arakhamia-Grant, Ketevan Scotland 2403 2013/07
85. Padmini, Rout India 2403 2018/09
86. Paikidze, Nazi Georgia 2402 2012/07
87. Buksa, Nataliya Ukraine 2401 2018/04
88. Vasilevich, Tatjana Ukraine 2400 2014/08

---
Tags: history, rating, fide, statistics, records
---


title: What constitutes a draw?

text:
# Question
Title: What constitutes a draw?
I know what makes a game a stalemate, and I know that stalemate is 1/2 point to everyone, and I assume draw is the same, but can there be a draw without a stalemate?

# Answer
> 6 votes
As Ian Bush points out in his comment the gory details are spelled out in the latest version of FIDE Laws of Chess. Article 9 covers most of the points but others are hidden in articles 6.9, 7.5.5 and A.4.3

Summarising:

1. Players agree a draw
2. Stalemate
3. Neither player can mate the other even with the other player trying to get checkmated
4. Correct claim by the player on move that the position has or is about to be repeated for the 3rd time
5. Correct claim by the player on move that 50 moves (100 half moves) have been completed or are about to be completed with no captures or pawn moves
6. Variation of 4. If the position is repeated 5 times then regardless of any claim the game is drawn. An observant arbiter is supposed to spot this and step in.
7. Same variation of 5. If 75 moves (150 half moves) have been completed with no pawn moves or captures then the game is drawn.
8. If one player "loses" for a "normal" chess reason (doesn't include resigns) but the opponent can't mate with any series of helpful moves from both sides (i.e. helpmate is impossible) then the game is drawn. These "loses" include losing on time, two illegal moves.

---
Tags: rules, endgame, fide, draw, stalemate
---


# Question
Title: How do you make NNUE neural network for the newest Stockfish chess engine?
How can I make, for example, Stockfish 13 or 14 with a NNUE neural network? What is the precise procedure for making a NNUE neural network for some chess engine? I noticed that lichess.org uses Stockfish with NNUE and I want the same in with my Stockfish engine. How does one go about doing this?

# Answer
For Stockfish there are two options - you can either use an exe with an embedded network, or download the network separately and place it in the same folder as the exe.

In either case, you will have to enable the NNUE option. If you are using the command line UCI protocol, the command will be:
`setoption name Use NNUE value true`

If you are using a GUI like chessbase, there will be a checkbox somewhere that you can set:

*Note that I have downloaded an explicit NNUE file, and the relative path is set in the EvalFile option*

The Stockfish GitHub page has a few more details as well:
https://github.com/official-stockfish/Stockfish#a-note-on-classical-evaluation-versus-nnue-evaluation
> 1 votes

---
Tags: engines, stockfish
---


# Question
Title: Is there a way to classify a chess position using algorithms and data science?
Given a position, is there a way we can classify a it, such as if whether there is a pin, fork, or trap, or a mate a mate in 2 or 3? If it is possible, what would be a better approach, an algorithmic way or a machine learning/reinforcement learning? Or are there any other alternatives ways?

# Answer
Yes. Let's break it down.

`Pin, fork`

This is easily done by bitboard operations. I'm not aware of an independent package that can do that, but it's not hard to do it yourself. You just need to work out all the attackers (White and Black), where your pieces are, do some bitwise AND XOR operations. Please take a look at Stockfish's `evaluate.cpp`.

`mate a mate in 2 or 3`

Easy! Just run Stockfish or even better a mate tactics solver such as `Crystal`!

`trap`

This is going to be very challenging if possible with our current technology. Chess engine doesn't really understand the moves, they assume best play. Computers doesn't understand human-imperfect-level dirty plays. You can work out some simple traps by passing the move to the other colour (e.g. lichess, chess.com etc), but you're not going to get perfect results.
> 4 votes

---
Tags: engines, computer-chess
---


# Question
Title: When can a player with just a bishop/knight vs overwhelming material claim a win on time?
Is there any program or algorithm that determines conclusively whether or not a person at severe material disadvantage can claim a win on time?

This question got me thinking about precise parameters needed for flagging. I noticed that bishop vs queen can't flag for a win, and neither can bishop vs rook, or bishop vs. rook and queen. The friendly piece blocking the king can always interpose. Then I saw bishop vs two pawns and rook and queen had a case where it happened:

```
8/8/8/5R2/3k1KQ1/5PP1/3b4/8 w - - 0 1

```

However, this doesn't seem to work so well when the pawns aren't connected. Put one on the b-file and one on the g-file, and it's a draw. My rough proof was this:

* Black King guards a maximum of 3 squares
* Black bishop checks and guards a maximum of 2 squares--but if the King guards 3 squares, that overlaps with the bishop. The King guards two adjacent corners in the other King's possible moves, but the bishop guards two opposite ones.
* White thus needs to have 4 pieces to block the way out

However, in this case, white can underpromote to a bishop then cooperate. So clearly it's not immediately trivial to tell off-hand if there is a win.

Plus if White has just one less pawn but it's a rook pawn, this disaster can always happen, if the queen and rook wander off.

```
5k1K/7P/5b2/8/8/8/Q7/1R6 w - - 0 1

```

Time forfeits could thus cause some arguments over whether a position with overwhelming material disadvantage is possible to win.

So is there an established and relatively quick set of rules to determine this? Or is there an actual program that calculates everything? I imagine it's doable with brute force and, so said brute force doesn't take forever, guesswork. Just wondering about the level of complexity.

# Answer
> 8 votes
> When can a player with just a bishop/knight vs overwhelming material claim a win on time?

A win on time can be claimed when it is possible to "checkmate the opponent's king by a series of legal moves". In other words when helpmate is possible. So basically we have to determine when helpmate is possibel and when it isn't.

In both cases King + minor piece is not enough to deliver helpmate against a bare king because the king plus minor piece cannot cover all the squares around the lone king and also give check. The lone king needs at least one extra piece to block the square the the king + minor piece can't cover and at the same time not be able to take the minor piece or block the check in the case of the bishop.

First let's look at all the possible combinations of king + minor piece vs king + one piece where the one piece can block the square next to the king not covered by the opposing king or minor piece. This will tell us which combinations work.

**King + Bishop vs King + Rook or Queen**

If the opponent has a rook or a queen they can always block the check from the bishop. Hence checkmate not possible.

```
[fen "KR6/8/k1b5/8/8/8/8/8 w - - 1 1"]

```

**King + Bishop vs King + Knight**

The following helpmate position is checkmate.

```
[fen "KN6/1b6/1k6/8/8/8/8/8 w - - 1 1"]

```

**King + Bishop vs King + Opposite Coloured Bishop**

The following helpmate position is checkmate.

```
[fen "KB6/1b6/1k6/8/8/8/8/8 w - - 1 1"]

```

**King + Knight vs King + Queen**

This doesn't work because the queen can always either take the knight or the position is illegal because both kings are in check. Hence checkmate not possible.

```
[fen "KQ6/2n5/k7/8/8/8/8/8 w - - 1 1"]

```

**King + Knight vs King + Rook**

The rook isn't quite as mobile as the queen so this does work.

```
[fen "KR6/2n5/k7/8/8/8/8/8 w - - 1 1"]

```

**King + Knight vs King + Knight**

This works.

```
[fen "KN6/2n5/1k6/8/8/8/8/8 w - - 1 1"]

```

**King + Knight vs King + Bishop**

This works.

```
[fen "KB6/8/kn6/8/8/8/8/8 w - - 1 1"]

```

So we have K+B wins against:

K+N
K+opposite coloured bishop

K+N wins against:

K+R
K+B
K+N

These are the minimum requirements for the superior side so if the superior side has at least this much material then helpmate is possible.

This also means that if the superior side has at least one pawn then helpmate is possible because the pawn can promote to a knight and in both cases helpmate is possible.

---
Tags: rules, endgame, claim-draw
---


# Question
Title: Longest chess game possible (maximum moves)
What is the longest chess game possible in terms of chess moves? I read somewhere that there is a theoretical maximum of 5949 moves. But I don't see any proof and I don't think it is correct.

Can it be infinite?

Source

# Answer
> 11 votes
Some cleaning up is required, I think:

The number on the website you link to differs from the results published in Bonsdorff et al., *Schach und Zahl.* Unterhaltsame Schachmathematik. pp. 11–13. There they say that if the 50-move-rule is *mandatory* the longest possible game (i.e. where both players cooperate to achieve the weird goal of a game of maximal duration) lasts 5899 moves. Possibly, the web site used a simpler upper estimate for the "gaps" between pawn moves and captures that cannot be achieved in all occasions.

However, the 50-move-rule (and also the position-repeated-three-times-rule) is *not* mandatory, i.e. whether or not a player demands remis by that rule is up to him! The players may decide to ignore the rule and play on, thus allowing for an eventually periodic sequence of moves, i.e. an infinite game.

# Answer
> 6 votes
1. 49 as black and white move knights.
2. 32 * 50 = 1600; to lock the pawns up. In this case, White pushes each pawn 1 time until it is stopped by a black pawn.
3. 6 * 50 * 8 = 2400; the white pawns are devoured one at a time, and as a black pawn is unblocked, it runs down the board, one square at a time. They promote to Knights.
4. 7 * 50 = 350; each of the new knights are devoured.
5. 30 * 50 = 1500; the rest of the pieces are devoured. Kings have to be left standing, so 30 here, not 31.

The sum of these moves is 5899. Although in order to practically make this happen, both sides will have to lose one tempo capturing the last remaining piece of their opponents, leaving us with 5898 total moves. For an example demonstration of how this works out, check out this youtube video.

# Answer
> 5 votes
The answer depends on preference:

* If you apply a 50-move limit, the longest possible chess game is 5898.5 moves long.
* If you apply a 75-move limit, it is 8848.5 moves long.

See https://wismuth.com/chess/longest-game.html for a detailed demonstration.

If you don't apply either of these, the next hurdle is draw by repetition (at 3 or 5 occurrences). I don't know if anyone has explored this systematically: perhaps a project for someone?

If you reject draw by repetition too, then you can carry on forever. Have a look at https://wismuth.com/chess/statistics-games.html#perft-ratios which argues that the maximum eigenvalue of chess (which will dominate the growth rate in the long run) is about 84.3.

Which approach is right?

* If you are a player, then I guess you might say that the 50-move rule involves player choice, while the 75-move rule is mandatory, so go for the latter.
* If you are a problemist, you might say that the 50-move rule only applies by default to retro problems. However you would probably be interested to waive that convention for this interesting problem. I don't know any problemists who are adopting the 75-move rule yet, and it's excluded from scope of conventions.

# Answer
> 4 votes
Ian Stewart discusses in an October 1995 Scientific American column how chess can be played with an infinite number of moves (and thus have a game that never ends).

> Anyone who plays chess knows that some games just peter out : neither player seems able to win, nothing constructive can be done and there is no obvious way to end the game. If neither player agrees to a draw, the game might go on indefinitely. Foreseeing such situations, the bodies that frame the laws of chess have proposed many different rules to force games to end. The classic law states that the game shall be drawn if a player proves that 50 moves have been made on each side, checkmate has not been given, no men have been captured and no pawn has been moved.
>
> But recent computer analyses have shown that the rule is not sufficient. There are some endgames in which one player can force a win after 50 moves, when no pieces have been captured and no pawns moved. So the laws of chess must specify certain exceptional situations. Any law that limits the number of moves permitted under particular conditions runs the same risk as the original, and so it would be nice to come up with a different approach altogether. One proposal, made some time ago, was that the game should end if the same sequence of moves, in exactly the same positions, is repeated three times in a row. (Do not confuse this with the standard law that if the same position occurs three times, the player facing it can claim a draw. But note that this law does not oblige them to do so.)

Stewart then proceeds to create a sequence of two symbols that never repeats a pattern thrice. He then shows that this sequence can be used by the two players to play a valid endless game even if the proposal becomes official. (This sequence is called Stewart's choral sequence.)

# Answer
> 4 votes
From Wikipedia (see http://en.wikipedia.org/wiki/Draw\_%28chess%29):

> "The rules allow for several types of draws: stalemate, the threefold repetition of a position (with the same player to move), if there has been no capture or a pawn being moved in the last fifty moves, if checkmate is impossible, or if the players agree to a draw. In games played under time control, a draw may result under additional conditions. A stalemate is an automatic draw, as is a draw because of insufficient material to checkmate. A draw by threefold repetition or the fifty-move rule may be claimed by one of the players with the arbiter (normally using his score sheet), and claiming it is optional."

So, if none of the players claims a draw, the game can go on forever. If at least one of the players intends to claim a draw when he has the possibility, then the threefold repetition rule and the fifty-move rule garantee that the game will end after a finite time. Maybe this can give the number of 5949 moves though? Considering the vast number of possible positions, the game could go on for much longer than 5949 moves before the threefold repetition rule applies. The fifty-move rule means that every 50 moves one of the players has to either move a pawn or make a capture. Pawn can make 2x8x6=96 moves. There are 32 pieces, so we can never exceed 50x(96+32)=6400 moves. So what is the minimal number of pieces that have to remain on the board to avoid a stalemate?

# Answer
> 3 votes
There is a cap on the length of a game of chess in terms of the number of moves. That's because of the Fifty-Move Rule. Any attempt to draw out a game indefinitely would trigger the fifty-move rule and result in a draw. The reason for this is simple. To carry on the game indefinitely, you have to:

1. Move pawns an infinite number of times: impossible. The number of possible pawn moves is obviously finite as pawns cannot move backward.
2. At some point, cease capturing your opponent's figures (otherwise you will capture their king, i.e. checkmate them, ending the game): this will trigger the 50-move rule.

Also, I suggest moving this to Chess.SE.

# Answer
> 3 votes
The other answers have relied on the 50 move rule, and have pointed out the possibility of the game not ending if neither player invokes it.

As it is highly unlikely somebody would want to play a game of chess for thousands of moves in a regular game, it follows that such a game would be contrived solely for the purpose of playing out the longest chess game possible. Furthermore, as nobody would want to spend their entire life playing a game of chess just to hold the record for longest game of chess, this all would be a purely mental exercise.

However, given these constraints and the fact that an unending game of chess is possible if neither player claims a draw from the 50 move rule, it is still unsatisfying to say that a game of chess can go on forever. Since we cannot substitute chess players, eventually one or the other of the players will die of old age or some other cause and will be unable to continue thereby forfeiting the game or at least bringing it to an end. We can therefore calculate an upper limit on the number of moves that can be played before this occurs.

Assuming both players learn to play chess earlier than any person yet, say at 3 years old, and live to be older than the oldest person alive, say 120 years old, and that they play every waking moment, say 16 hours per day on average, and play speed chess averaging one move per second, and take only leap days off to rest, this yields an upper bound of 1 move/second * 86400 seconds/day * 365 days/year * 117 years or 3,689,712,000 moves as the longest chess game possible between two people when neither invokes the 50 move rule to claim a draw.

# Answer
> 0 votes
According to the "new" FIDE rules, game cannot go to infinity, due to 75 moves rule or automatic draw when a position gets repeated 5 times in a row. Since the amount of positions is finite, the games need to be finite as well.

---
Tags: records, mathematics
---


# Question
Title: Are there any gambits where I HAVE to decline?
I know popular openings like the Queen's Gambit can be accepted with an initiative for white. Is there any gambit where accepting it would lead to **a forced mate** for the player that accepted it?

# Answer
> 52 votes
While it's not generally given as part of the explicit definition, the term "gambit" usually refers to an offer of material that can be accepted. If it can't be accepted, then it's a trap.

You can look through chess traps and see that many of them involve apparently giving up material.

# Answer
> 11 votes
Yes. In this line in the Dutch Defence black cannot take the offered bishop

```
[fen ""]

1. d4 f5 2. Bg5 h6 3. Bh4 g5 4. e3 gxh4?? 5. Qh5#

```

# Answer
> 3 votes
I would add that there are situations where one side "offers" the material that cannot be taken, but it is not really intended as a trap, it happens in the course of a logical development of the opening. The most "mainstream" example is perhaps the Berlin defense:

```
[fen ""]

1.e4 e5 2.Nf3 Nc6 3. Bb5 Nf6 4.O-O Ne4 5.d4 Nd6 (5... exd4 6. Re1 d5 Nxd4) 6.Bxc6 dxc6 7. dxe5 Nf5 8. Qxd8 Kxd8

```

White's 4. O-O and 5.d4 seems to offer black a pawn, however if black accepts, the pin is a problem. White threatens both f3. and Nc6. It is not quite a forced mate but Black will have to give up material without complete compensation. "Everyone knows" that it's better not to take the pawn.

# Answer
> 2 votes
I would say that in lower levels, the Blackburne-Shilling Gambit is a gambit that you should never accept as the capturing the pawn on e5 can lead to a lot of traps.

```
[FEN ""]

1. e4 e5 2. Nf3 Nc6 3. Bc4 Nd4

```

---
Tags: opening, gambits
---


# Question
Title: What are the biggest free chess game databases? Is it legal to download games from them?
Are there some free chess game databases where it is possible and allowed to download games? Is it possible to use this information for my own purposes? For example, would be allowed to make a machine learning app that learned from the downloaded games?

# Answer
> 17 votes
Absolutely! Nobody has the copyright. Enjoy your machine learning adventure!

# Answer
> 4 votes
I would like to add a caveat against the blithe assumptions that chess games/score are not possible to copyright.

Individually, probably not. But as a collection, 'catalogue copyright' just might apply.

In some places, catalogue copyright is used for works that normally could not be protected by copyright, but which still merit some form of protection. Lists, catalogues and directories are typical examples: the protection time is usually less than 10 years.

If it does apply or not depends on the situation: is it national law (say, US Copyright law) that applies? is it the Berne Convention? The World Copyright Convention? Or even individual trade agreements between two countries?

It would almost certainly not be applied for fairly small, random downloads: it might however be applied for full download/dump of a chess database. An organization that plans to use it may add identifiable material that makes it possible to say where the information was taken from.

# Answer
> 3 votes
Caïssabase is one of the biggest and best.

From the website:

> **What is Caïssabase?**
>
> When I got back into Chess a year or two back I couldn't find a decent free regularly updated database of Chess games.
>
> There are some good ones out there like Kingbase and Millionbase (not updated anymore).
> ...
> **What is in Caïssabase?**
> **CURRENTLY 4.02 MILLION GAMES**
>
> I started from the following databases/sources.
>
> Millionbase
> Kingbase
> I then merged in all of the TWIC back issues up to the date on the archive as well as all the master games from pgnmentor.
> ...
> **What about curation?** Glad you asked. Roughly I followed these rules.
>
> * Removed all duplicates
> * Removed all games with less than 5 moves
> * Aimed for all games to have one (or both) players at least master strength
> * Fixed names and event spellings where possible
> * Inserted ELO's where known
> * Inserted extended ECO opening codes

> ...
> **Legal/Copyright**
> Where I live facts are not copyrightable, Chess moves played in a game are facts.
>
> You'll notice there are no comments on any of the games as comments are copyrightable.

The latest download is from September 2019, so perhaps the intention of a monthly download is proving a bit too much. Meanwhile I've downloaded it for use with Scid vs PC and will be a grateful user.

Edit: There is a new download available as of 14th November 2020 with a new goal of updating once a quarter.

# Answer
> 2 votes
I would add the Lichess Elite Database to the list :-) It is the best of lichess games: only higher-rated players in "decent" time controls (aka no bullet).

# Answer
> 1 votes
Mere aggregation is not protected by copyright in the US. Copyright only protects creative production, not a collection of facts as stated above. Annotations and comments might be copyrighted but it wouldn't add any copyright collection to the moves in the game.

---
Tags: database
---


# Question
Title: Why hasn't the rating of full-time chess streamers improved?
Analyzing the five titled players from this question:

* Anna Cramling's rating appears not to have budged in the last year, presumably because of COVID.
* Andrew Tang's rating appears not to have changed much since he signed with Cloud9 in 2019.
* Qiyu Zhou's rating appears not to have changed much either.
* Alexandra Botez's rating appears to have decreased slightly.
* Hikaru Nakamura's classical rating declined, but his blitz rating increased.

If we neglect Anna Cramling (lack of data) and Hikaru Nakamura (since he was already a professional player), why is it that none of the other three players seem to have gotten an elo boost from playing chess full-time? Playing chess full-time ought to imply a lot of practice, and practice should lead to improvement.

Only thing I can think of is that online streaming focuses primarily on blitz, and therefore might not have an impact on classical chess. So one might expect classical rating to remain the same and blitz rating to increase. However, Nakamura's rating is the only one that follows this trend.

# Answer
The answer is very simple. Full-time chess streaming does nothing to improve your chess.

For players under 2200 the single best thing to do is work on tactics. Full-time chess streaming does nothing to improve your tactics. Following the Woodpecker Method as described by Axel Smith and Hans Tikkanen is what you need to do.

For players over 2200 the best thing to do is what this answer to a similar question says:

> The principle teaching of the Soviet School of chess as described by Dvoretsky and others is that the key to improvement lies in annotating your own games.
>
> Only by critically examining the (bad) moves you make can you identify the kind of mistakes you typically make and only then can you take positive steps to correct them.
>
> This is a very active thing to do. It involves putting your brain into gear. Just putting your game into an engine and seeing where the evaluation changes by a big margin and noting the engine suggestion doesn't count. That is just passive.

If you are "full-time chess streaming" you are not spending much time doing deep analysis of your own games and mistakes. You are not doing what is necessary for improvement. Instead you are presenting shallow chess for entertainment and money.
> 5 votes

# Answer
I don't believe signing to an e-sport will magically improve chess rating. Highly doubt those e-spot clubs have the resources to train a GM player. They don't have access to deep opening preparations, Kasparov's level training, deep Stockfish analysis, do they?

The clubs are excellent at marketing but not chess improvements. They are not coaching the players, but trying to make money from them.
> 2 votes

---
Tags: learning, streaming
---


# Question
Title: Should King's Indian players know know how to play Benoni-type positions?
I'm very fond of the King's Indian, but I dislike playing the Benoni because I feel like it's much harder to find a clear-cut plan. However, against some anti-KID systems such as the Samisch, the Averbakh, and the Four Pawns Attack, I've read that it's considered best for Black to go for the c5 instead of the e5 break. So should I suck it up and learn how to play Benoni structures in order to deal with these systems, or bury my head in the and study the theory for 6...Nc6 against the Samisch, 6...Na6 against the Averbakh, 6...Na6 against the Four Pawns Attack, etc. in order to avoid the Benoni?

# Answer
Learning how to play Benoni (and even Benko) structures gives you a lot of flexibility down the line when playing the KID. The family of openings that is classified as "King's Indian" is vast, and when you play it as black you have to be mentally prepared that white may try anything against your setup. While it's possible to avoid Benoni structures as a KID player, I hardly see the point in consistently doing so besides dogma.

You need a flexible mindset and a keen sense for dynamics when playing the KID, and this is true for the Benoni as well. So even if the openings look somewhat different at first glance they are fundamentally similar, and if you're comfortable with one of them you're probably also comfortable playing the other. One major point in not being afraid of playing ...c5 is that it is way more compatible with the goal of activating the bishop on g7 when compared to the ...e5 break, and you will be a lot more dangerous to your opponents as a KID player if you know how to properly handle the beast that is your dark-squared bishop.
> 2 votes

# Answer
One of the points of the KID is its flexibility. You can optimize your setup according to what White does.

One of the points of Openings is to get a position you understand and are comfortable playing.

e5 is usually playable. I suggest playing it and see how you like it. Worse case is you may learn something.

I personally like playing all of the modern/kid/benoni/benko systems. The fluidity keeps things interesting.
> 1 votes

# Answer
I am following this course on Chessable. It tries to avoid Benoni-type structures whereever possible and I like its suggestions, I highly recommend the course.
> 1 votes

---
Tags: kings-indian, modern-benoni, benoni
---


# Question
Title: Why did the USCF stop using a "grandmaster" title in 1961?
I was somewhat surprised to learn recently that the USCF used to use a ratings-based "Grandmaster" title, which was a title above "Senior Master". It seems that this was not a lifetime title, and a player would lose it if their rating fell below the rating threshold for that title. In the first USCF rating list which was published in the November 20th, 1950 issue of *Chess Life*. It lists the different "Classifications" of players by rating, with "Grandmaster" corresponding to a rating of over 2700. This list names two "Grandmasters" - Reuben Fine, and Sammy Reshevsky (though Reshevsky was listed as "Inactive"). In looking at a 1955 USCF rating list, I see that the only name listed on the rating list as a "Grandmaster" was Sammy Reshevsky. If I look at a 1958 rating list, the threshold for Grandmaster was dropped to 2600, and there were now once again two USCF Grandmasters - Sammy Reshevsky, and Bobby Fischer. The situation was the same in 1960, with the same thresholds and the same two names as the only "Grandmasters". Then, in the June 1961 issue of *Chess Life*, there was an article by Arpad Elo describing the mathematics of the USCF rating system (I'm presuming this was about the time of the transition between the old Harkness rating system, and Elo's new system), and the highest title it listed was the "Senior Master" title, for players with USCF ratings of 2400 and above, and it mentioned that "Grandmaster" was now a sub-category of "Senior Master" used to differentiate players rated over 2500. (The article also mentioned that, as originally designed, the rating system was meant to be calibrated such that a rating of 2000 corresponded to a level of ability to achieve a 50% score in the US Open, which I thought was very interesting...) In the 1961 rating list, Reshevsky and Fischer were both now listed as "Senior Masters". And that was apparently the end of the USCF "Grandmaster" title.

What was the reasoning for this change? Were there any other players besides Fine, Reshevsky, and Fischer who ever had the USCF "Grandmaster" title? They were the only ones I found.

# Answer
Those were the only USCF grandmasters. I don’t know the reason for dropping the title, but it did coincide with the adoption of ELO in 1960
> 3 votes

---
Tags: history, rating, uscf, titles
---


# Question
Title: List of female chess players by their peak FIDE rapid rating
Similar to these questions:

1. List of female chess players by peak FIDE rating
2. List of female chess players by peak FIDE rating with countries?
3. List of chess players by their peak FIDE blitz rating
4. List of female chess players by their peak FIDE blitz rating
5. List of chess players by their peak FIDE rapid rating

There is a Wiki list is for all of the top-rated FIDE chess players. We now have a list for the top female chess players by peak FIDE rating. As in link above, we have a list of top chess players peak FIDE rapid rating. But where is the list of top female chess players by peak FIDE rapid rating? Please include countries.

Note: Usually I'd start with Judit Polgar (and then afterwards Hou Yifan) but in this case there's no Judit Polgar in the above rapid list for 2700+, so I wouldn't know how to start with them.

# Answer
> 1 votes
Here are the results from the relevant queries on my database constructed from the downloads available from the FIDE rating download website for the top female players by rapid rating rated over 2450 (round number to give about 50 players - actually 53 players).

The "Period" is the first FIDE rating list in which the player achieved the rating. If the player didn't play rated standard for a year after that then they obviously retain the rating for the next year so the "Period" is the year and month in which FIDE first recorded that rating for them.

PlayerName FedName MaxRating Period

1. Polgar, Judit Hungary 2669 2013/08
2. Hou, Yifan China 2645 2016/09
3. Koneru, Humpy India 2626 2013/01
4. Ju, Wenjun China 2618 2019/01
5. Lahno, Kateryna Ukraine 2616 2013/01
6. Kosteniuk, Alexandra Russia 2612 2017/10
7. Muzychuk, Anna Ukraine 2611 2017/01
8. Lahno, Kateryna Russia 2599 2014/05
9. Gunina, Valentina Russia 2597 2014/01
10. Stefanova, Antoaneta Bulgaria 2582 2013/01
11. Dzagnidze, Nana Georgia 2580 2014/01
12. Muzychuk, Anna Slovenia 2577 2012/07
13. Cramling, Pia Sweden 2546 2012/07
14. Lei, Tingjie China 2545 2018/12
15. Zhao, Xue China 2545 2012/07
16. Stefanova, Antoaneta FIDE 2536 2017/04
17. Kosintseva, Tatiana Russia 2530 2014/05
18. Harika, Dronavalli India 2529 2012/07
19. Paehtz, Elisabeth Germany 2524 2014/01
20. Muzychuk, Mariya Ukraine 2521 2018/01
21. Kosintseva, Nadezhda Russia 2516 2013/01
22. Ushenina, Anna Ukraine 2513 2015/01
23. Tan, Zhongyi China 2509 2016/04
24. Goryachkina, Aleksandra Russia 2504 2019/01
25. Sebag, Marie France 2504 2013/01
26. Zatonskih, Anna United States 2504 2012/07
27. Pogonina, Natalija Russia 2501 2019/07
28. Javakhishvili, Lela Georgia 2499 2014/07
29. Arabidze, Meri Georgia 2497 2015/05
30. Girya, Olga Russia 2497 2020/01
31. Khotenashvili, Bela Georgia 2494 2018/05
32. Khurtsidze, Nino Georgia 2494 2012/11
33. Abdumalik, Zhansaya Kazakhstan 2490 2019/01
34. Krush, Irina United States 2490 2014/09
35. Socko, Monika Poland 2490 2015/04
36. Zhu, Chen Qatar 2489 2012/07
37. Danielian, Elina Armenia 2488 2018/01
38. Bodnaruk, Anastasia Russia 2487 2016/09
39. Galliamova, Alisa Russia 2485 2013/01
40. Chiburdanidze, Maia Georgia 2475 2012/07
41. Moser, Eva Austria 2469 2014/12
42. Batsiashvili, Nino Georgia 2467 2012/07
43. Huang, Qian China 2464 2018/07
44. Mkrtchian, Lilit Armenia 2464 2015/01
45. Cmilyte, Viktorija Lithuania 2462 2012/07
46. Pustovoitova, Daria Russia 2462 2017/01
47. Khademalsharieh, Sarasadat Iran 2460 2019/01
48. Matnadze, Ana Spain 2459 2014/09
49. Pham, Le Thao Nguyen Vietnam 2456 2018/01
50. Turova, Irina Russia 2456 2017/09
51. Munguntuul, Batkhuyag Mongolia 2455 2016/05
52. Skripchenko, Almira France 2452 2017/11
53. Guo, Qi China 2451 2017/10

---
Tags: history, rating, fide, statistics, records
---