Pawn backwardness

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

xmas79
Posts: 286
Joined: Mon Jun 03, 2013 7:05 pm
Location: Italy

Pawn backwardness

Post by xmas79 »

I'm playing with pawn patterns. I enjoyed very much writing all the stuff, and I found it very straightforward also.... However there's the definition of "backward pawn" that is a bit "too" vague. Isolated pawns are... well... isolated.... But backward? Reading over and over the chessprogramming wiki the very same perplexity seems to emerge...

Right to the questions:

Position 1: is b7 backward?
[d]K6k/1p6/8/8/2p5/2Pp4/3P4/8 w - -


Position 2: is d2 backward? is e4 backward?
[d]K6k/2p1p1pp/3p4/3P4/4P3/8/3P4/8 w - -


Position 3: is g6 backward? are h3 and h2 backward?
[d]K6k/3p4/6p1/p1p3Pp/P1P5/7P/1P5P/8 w - -
D Sceviour
Posts: 570
Joined: Mon Jul 20, 2015 5:06 pm

Re: Pawn backwardness

Post by D Sceviour »

xmas79 wrote:I'm playing with pawn patterns. I enjoyed very much writing all the stuff, and I found it very straightforward also.... However there's the definition of "backward pawn" that is a bit "too" vague. Isolated pawns are... well... isolated.... But backward? Reading over and over the chessprogramming wiki the very same perplexity seems to emerge...

Right to the questions:

Position 1: is b7 backward?
[d]K6k/1p6/8/8/2p5/2Pp4/3P4/8 w - -


Position 2: is d2 backward? is e4 backward?
[d]K6k/2p1p1pp/3p4/3P4/4P3/8/3P4/8 w - -


Position 3: is g6 backward? are h3 and h2 backward?
[d]K6k/3p4/6p1/p1p3Pp/P1P5/7P/1P5P/8 w - -
A backward pawn is an unprotected pawn that cannot advance safely, and it is on a half-open file (thus it can be threatened). Also, this often requires the presence of rooks on the board, since they are the best pieces to exploit backward pawns. This definition differs from other formal definitions. In Position 3, some would call g6 backward. I would define g6 as blocked and unprotected for the purposes of creating a useable pawn structure formula.

Therefore, in Position 1 there is no backward pawn. In Position 2, only c7 is backward. Position 3 has no backward pawn.
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: Pawn backwardness

Post by bob »

xmas79 wrote:I'm playing with pawn patterns. I enjoyed very much writing all the stuff, and I found it very straightforward also.... However there's the definition of "backward pawn" that is a bit "too" vague. Isolated pawns are... well... isolated.... But backward? Reading over and over the chessprogramming wiki the very same perplexity seems to emerge...

Right to the questions:

Position 1: is b7 backward?
[d]K6k/1p6/8/8/2p5/2Pp4/3P4/8 w - -
yes
[/quote]



Position 2: is d2 backward? is e4 backward?
[d]K6k/2p1p1pp/3p4/3P4/4P3/8/3P4/8 w - -

/quote]
no and no. e4 can be supported by d2-d3, d2 is iffy. It can't be supported, but it can be used to advance e pawn and it is a bit hard to attack it.

Position 3: is g6 backward? are h3 and h2 backward?
[d]K6k/3p4/6p1/p1p3Pp/P1P5/7P/1P5P/8 w - -
yes, yes, yes and also the b pawn as well.
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: Pawn backwardness

Post by bob »

D Sceviour wrote:
xmas79 wrote:I'm playing with pawn patterns. I enjoyed very much writing all the stuff, and I found it very straightforward also.... However there's the definition of "backward pawn" that is a bit "too" vague. Isolated pawns are... well... isolated.... But backward? Reading over and over the chessprogramming wiki the very same perplexity seems to emerge...

Right to the questions:

Position 1: is b7 backward?
[d]K6k/1p6/8/8/2p5/2Pp4/3P4/8 w - -


Position 2: is d2 backward? is e4 backward?
[d]K6k/2p1p1pp/3p4/3P4/4P3/8/3P4/8 w - -


Position 3: is g6 backward? are h3 and h2 backward?
[d]K6k/3p4/6p1/p1p3Pp/P1P5/7P/1P5P/8 w - -
A backward pawn is an unprotected pawn that cannot advance safely, and it is on a half-open file (thus it can be threatened). Also, this often requires the presence of rooks on the board, since they are the best pieces to exploit backward pawns. This definition differs from other formal definitions. In Position 3, some would call g6 backward. I would define g6 as blocked and unprotected for the purposes of creating a useable pawn structure formula.

Therefore, in Position 1 there is no backward pawn. In Position 2, only c7 is backward. Position 3 has no backward pawn.
The being on a half-open file is generally not required. There are three pieces that attack down files. Two rooks and the queen. There are 8 pieces that attack from other directions. two rooks and queen down a rank, plus bishops knights and king. Some give an extra penalty for being on a half-open file. I only give that extra penalty if there are pieces (rooks or queen) that can use that half-open file to attack from the front.
D Sceviour
Posts: 570
Joined: Mon Jul 20, 2015 5:06 pm

Re: Pawn backwardness

Post by D Sceviour »

bob wrote:The being on a half-open file is generally not required. There are three pieces that attack down files. Two rooks and the queen. There are 8 pieces that attack from other directions. two rooks and queen down a rank, plus bishops knights and king. Some give an extra penalty for being on a half-open file. I only give that extra penalty if there are pieces (rooks or queen) that can use that half-open file to attack from the front.
I agree "being on a half-open file is generally not required" is part of the classical interpretation for a backward pawn. However, the classical description was not particularly useful when designing a pawn structure formula. Rather than "give an extra penalty for being on a half-open file", it was simpler to define the half-open file as necessary for being backward. This saved a lot of time later on when trying to figure out if a rook (or Queen) could attack the pawn.

In addition, by my definition a backward pawn can be repaired where a blocked pawn cannot. In position 1 if black to move, then b5 wins instantly even though it cannot advance safely on the next move.
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: Pawn backwardness

Post by bob »

D Sceviour wrote:
bob wrote:The being on a half-open file is generally not required. There are three pieces that attack down files. Two rooks and the queen. There are 8 pieces that attack from other directions. two rooks and queen down a rank, plus bishops knights and king. Some give an extra penalty for being on a half-open file. I only give that extra penalty if there are pieces (rooks or queen) that can use that half-open file to attack from the front.
I agree "being on a half-open file is generally not required" is part of the classical interpretation for a backward pawn. However, the classical description was not particularly useful when designing a pawn structure formula. Rather than "give an extra penalty for being on a half-open file", it was simpler to define the half-open file as necessary for being backward. This saved a lot of time later on when trying to figure out if a rook (or Queen) could attack the pawn.

In addition, by my definition a backward pawn can be repaired where a blocked pawn cannot. In position 1 if black to move, then b5 wins instantly even though it cannot advance safely on the next move.
This doesn't have anything to do with backward pawns hover. b5 wins because of a tactical issue with the advanced white pawn becoming passed and promoting where white's king ends up out of play.

You have to be very careful in that backward pawns are backward pawns. And the eval has to handle the most common cases best. This position is dominated by advanced passed pawns where the scores ought to be far larger than the backward pawn penalty...

This ought to be easy for any chess engine to evaluate, given a few plies of search to work out the pawn pushes. The eval is supposed to recognize "static" features. This is a highly dynamic position. Dynamics depend on search rather than evaluation.
D Sceviour
Posts: 570
Joined: Mon Jul 20, 2015 5:06 pm

Re: Pawn backwardness

Post by D Sceviour »

bob wrote: You have to be very careful in that backward pawns are backward pawns. And the eval has to handle the most common cases best. This position is dominated by advanced passed pawns where the scores ought to be far larger than the backward pawn penalty...

Dynamics depend on search rather than evaluation.
If you are saying is that a backward (meaning blocked and unprotected) pawn is a liability then I agree. However, a backward (meaning repairable) pawn is neither a liability nor an asset itself. As you mentioned before, "I only give that extra penalty if there are pieces (rooks or queen) that can use that half-open file to attack from the front." There is no disagreement here.

The problem is one of definition. It is easier and simpler to distinguish between a backward (meaning blocked and unprotected) pawn and a backward (meaning repairable) pawn by dropping the definition for the former. They are completely different cases that require a different assessment. The backward (meaning blocked and unprotected) pawn case belongs to a study of attacks on pawn chain bases. Currently, I do not evaluate attacks on pawn chains because of the complexities. Perhaps pawns chains are best left for the search rather than any attempt to try a static evaluation. It would be interesting to hear if there are any simple suggestions for the static evaluation of pawn chains.
xmas79
Posts: 286
Joined: Mon Jun 03, 2013 7:05 pm
Location: Italy

Re: Pawn backwardness

Post by xmas79 »

D Sceviour wrote: A backward pawn is an unprotected pawn that cannot advance safely, and it is on a half-open file (thus it can be threatened). Also, this often requires the presence of rooks on the board, since they are the best pieces to exploit backward pawns. This definition differs from other formal definitions. In Position 3, some would call g6 backward. I would define g6 as blocked and unprotected for the purposes of creating a useable pawn structure formula.

Therefore, in Position 1 there is no backward pawn. In Position 2, only c7 is backward. Position 3 has no backward pawn.
You are giving an exact definition of what a backward pawn is. However it seems to me a bit arbitrary:

1- As Bob says the open-file stuff is bogus. There is not such a requirement for a pawn to be backward. It simply increases the weakness of the pawn, but only if there are rooks o the board.
2- The base of the pawn chain could be (should be?) easily seen as a backward pawn, therefore in position 1 d2 could also backward
3- in position 1 b7 is clearly a backward pawn.
4- in position 2 e7 is clearly a backward pawn.
5- in position 3 b2, d7 are clearly backward pawns.
6- in position 3 g6, h3 h2 are weak, and we go back to point 2.

I think everyone understand that they are weak, but what I'm trying to establish is how much.
xmas79
Posts: 286
Joined: Mon Jun 03, 2013 7:05 pm
Location: Italy

Re: Pawn backwardness

Post by xmas79 »

bob wrote:
Position 2: is d2 backward? is e4 backward?
[d]K6k/2p1p1pp/3p4/3P4/4P3/8/3P4/8 w - -
no and no. e4 can be supported by d2-d3, d2 is iffy. It can't be supported, but it can be used to advance e pawn and it is a bit hard to attack it.
It could be useful to mark e4 as backward to some degree. From a statically point of view, e4 pawn cannot be advanced without being captured, so it is weak. Clearly, with some dynamics pawn has a support and the weakness disappear. However, this is what search is for, and I fear that these bonus/penalties can have downsides.
xmas79
Posts: 286
Joined: Mon Jun 03, 2013 7:05 pm
Location: Italy

Re: Pawn backwardness

Post by xmas79 »

D Sceviour wrote:The problem is one of definition. It is easier and simpler to distinguish between a backward (meaning blocked and unprotected) pawn and a backward (meaning repairable) pawn by dropping the definition for the former.
What do you mean for "repairable"? That can be pushed in (say) 3 plies because of support from another pawn? And how do you evaluate a pawn that can't be pushed immediately and never will because the "supporting" pawn is blocked by piece?
They are completely different cases that require a different assessment. The backward (meaning blocked and unprotected) pawn case belongs to a study of attacks on pawn chain bases.
I'm here to exactly discuss this. However you have yours definition of what a backward pawn is (repairable? blocked and unprotected?).
Currently, I do not evaluate attacks on pawn chains because of the complexities. Perhaps pawns chains are best left for the search rather than any attempt to try a static evaluation. It would be interesting to hear if there are any simple suggestions for the static evaluation of pawn chains.
Pawn structure is probably the very only thing that must be corrrectly evauated. Getting the structure right in eval will save the engine from a lot of nonsense searches. This is particularly true during midgame, where search can't get it right even if you let the engine analyze for years....

IMHO.