lichess.org
Donate

King and Pawn versus King

This thread will discuss the King and Pawn versus King endgame.

The main focus will be on how a human learns to play this endgame correctly.
What models or theories or patterns or whatever that a human uses to play this endgame correctly.
Of course you can consider this also from the point of view of programming a computer to play these
endgames in the same way as a human plays.

This endgame is denoted KPk. White pieces being capital letters; Black pieces being lowercase letters.

All KPk endgames are totally solved by the endgame tablebases.
The tablebase does not tell you *how* to play. They only tell you the result, the best moves, and how long until a
win/loss/draw.

Today (2020), I believe computers are fast enough that they can correctly play these endgames by brute force look-ahead. That was not always the case.
The minimum requirements for a human to play KPk correctly:

- They know the rules of chess.
- They are rational in the game theory sense. For example, if they have a winning move and know it, then they play it. Same for a drawing move - they do not lose on purpose.

0. Human novice chess players playing OTB (over the board) are known to play moves that are illegal, and often their opponent does not see that illegal move either. Early computer programs also were known to play illegal moves. The "bugs" have to be worked out by extensive testing, whether it is humans or computers.

1. The first thing you have to teach people is that the endgame Kk is, by FIDE definition, a draw. Kids have been known to have just two bare Kings on the board, moving them around in a vain attempt to checkmate!

2. The second thing is the concept of stalemate. They may know the rule and still fail to appreciate it.

3. The third thing to teach is how to mate in the endgame KQk in positions where we assume Black cannot capture the Queen on the move, and is not stalemated in the position.

4. The fourth thing to teach is how the A/D network applies in this simply setting. This is so simple that it would be easy to overlook that it can be taught. The point is that given a KPk position, one can know without calculation (by calculation I always mean look-ahead calculation) that certain moves are drawing with Black on the move, and losing with White on the move, based on the A/D network. People may object that since it only takes a calculation of one half-move to see these things, using the A/D network is overkill. True, but it gives us a very simple example of using the A/D network. The A/D network must work here as a limit case.

With these 4 things learned, we can move on to the next steps in learning these endgames.
The next steps is the realization of the following things:

1. To win, White must not lose the pawn, must promote the pawn to a Queen without it being captured, and then use the procedure learned for KQk. White must avoid stalemating if possible.

2. To draw, Black must either capture the pawn, or capture a promoted Queen, both giving the draw Kk, , or obtain a stalemate.

This is a great example, in a trivial setting, of what is meant by a "plan". There are no details for the plans yet.

There are two normal definitions for "plan" outside chess:

Def 1. A detailed proposal for doing or achieving something.
Def 2. An intention or decision about what one is going to do.

Above, we have given the "what" for White and Black; not the how.

These plans are a huge leap. No program that I'm aware of uses these plans in this endgame. You certainly cannot ask these programs what their plan is. The can only give you a variation.

How does having a plan help? In only the simplest positions will you be able to calculate to a win/loss/draw because the tree will be too large. Having a plan can help cut down the width of the tree by giving candidate moves at each node.

What else can be done to guide you?

Both sides could use the idea of "Force" to know that a pawn loss or promoted Queen loss would mean a draw. This also follows from the A/D network.

You could use some rules-of-thumb (ROT). ROT would help you calculate farther because they could limit the width of the tree you search. But the exceptions to the ROT would mean you might miss an opportunity.

You could learn a procedure or set of procedures known to produce the best result, or good results most of the time.

You could memorize certain positions and how to handle those.
It would be quite interesting to have a program that could take the data from the tablebase for KPk or neural net from a program like lc0 or data it used or created and be able to create the plans in #4. I know of no such program. I don't know how to write such a program.

It would be easy to create a chess playing program that was hard coded to play by the plans in #4; even if it used no calculation, but had the A/D network to take care of the Force. Such a program would play like a beginner who was unaware of any of the ideas at the end of #4, and who could not calculate at all.
Because of the plans from #4, both players are interested in the cases where the pawn can become a Queen with no aid from White's King. Hence, the first thing I teach in this endgame is how to easily get the answer to this question.



Obviously one could just count how many moves it takes White to have the pawn reach b8 (5) and what Black's King can do in that number of moves so as to either capture the pawn or capture the promoted Queen. The large number of paths the Black King can take bewilders the beginner. It is intuitive that Black needs to decrease the file number he is on for each of his moves. That leaves him on the d-file at the end of his 4-th move. White then Queens on move 5.

Instead of this counting plus logic, or using calculation, the square of the pawn method is a *static* analysis method for getting the correct answer.

The square of the pawn method would be easy to program.
The next concept is the White King escorting the pawn to be a Queen.

We already saw in the square of the pawn the procedure for the win if Black cannot catch the pawn running to be a Queen. If Black would be able to catch the pawn, then White needs to use his King. Since we are assuming Black's King is near the pawn as it approaches the queening square, White must control the queening square with his King and if White's King also controls the 6th and 7th rank squares on that file, then unless Black can capture the pawn before the pawn reaches the 6th rank, White will win.



It would be easy to program that if the White King is on the 7th rank on a file next to the file of the pawn, and the pawn is on the 6th rank, then move the pawn up until it is a Queen. It doesn't matter where the Black King is.
Then use the KQk procedure to mate.

I used the term "control" above. It is not necessary to understand what this word means to know the procedure. Here the word reduces to the White King attacking those 6th, 7th, and 8th rank squares, which keeps the Black King from being able to move to any of them because of the rules of chess.
Rook pawns are an exception in many KPk endgames.

Consider this position.



This would be easy to program. White would not push the pawn because that is stalemate. On any other White King move, Black would, following the plan in #4, move the King toward the pawn - ...Kh7. White would protect the pawn, if still possible. Black would then play ...Kh8 to attempt getting the stalemate or capture the pawn if possible.
So far we have been following the last sentence in #4
"You could memorize certain positions and how to handle those."
We have been calling back to the plans to explain how the handling of those positions relates to the plans.

We will be continuing to learn new positions and how to handle those. There are only a few more to memorize in this way.

However, at this point teachers introduce chess theory ideas to help the student with the coming positions because the students can then see those ideas in a simple setting. The teachers then expect those ideas to guide the student in positions that have not been memorized.

These ideas are examples of two of the other things mentioned in #4:

"You could use some rules-of-thumb (ROT). ROT would help you calculate farther because they could limit the width of the tree you search. But the exceptions to the ROT would mean you might miss an opportunity."

"You could learn a procedure or set of procedures known to produce the best result, or good results most of the time."

The chess theory ideas referred to in #9 are:

1. The idea of King opposition.
en.wikipedia.org/wiki/Opposition_(chess)

2. Nimzowitsch ideas to replace opposition as he expounded in his book "My System".

3. The ideas of key squares and corresponding squares.
en.wikipedia.org/wiki/Key_square
en.wikipedia.org/wiki/Corresponding_squares

Both 1 and 2 are ROT combined with procedures. They both require calculation in some cases to get the correct answer. Number 3 is a static analysis method that does not require calculation and always gives the correct answer!

Historically the above ideas came in the order above. Nimzowitsch was adamant that the idea of opposition had to go! Not only were there exceptions, but he claimed it was not the right way to understand what was going on. However, not all Nimzowitsch's terminology survived; for example "tripartite maneuver" and "reserved blockading point" did not survive. Number 3 is taught by some, and is the focus of my courses, but it is not the ideas taught by most. That is because number 3 is more complex and requires visualization that people find difficult. I still teach all three of the above.

Teachers that do not teach #3 teach a combination of #1 and #2 together with exceptions and calculation.

Recall that the main focus of this thread is *how* a human learns to play this endgame correctly. I've also been talking parenthetically about how to program a computer to play using the methods used to teach a human.

But once a human learns how to do something to the point where they have mastered it, they have internalized it and may no longer use the same methods. An analogy is reading text aloud. You might have learned to pronounce words by sounding them out, but even if you did, you don't use that method once you know how a word is pronounced.

Magnus Carlson has said that he does not know key squares and corresponding squares theory. He says he just knows the answer from experience. However, listening to him talk about KPk endgames, he explains them using 1 and 2. But that does not mean he solves them using 1 and 2!

A computer could be programmed to play by using #3 of post #10. There is no visualization issue. It would use the complete numbering system method per the Wikipedia link in #10. It could explain its solution by producing the numbered board.

This topic has been archived and can no longer be replied to.