king pawn endgames

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

adams161
Posts: 626
Joined: Sun May 13, 2007 9:55 pm
Location: Bay Area, CA USA
Full name: Mike Adams

king pawn endgames

Post by adams161 »

While there are soem good ideas in the endgame thread i want to look into, particularly scoring bonsues and penalties for reaching certain piece configurations, I want to start with the basics and the first that comes to mind is king and pawn endgames and passers.

It seems when a pawn is evaluated as passed you should measure its distance to promotion and assign a bonus based on being close to being promoted. You have of course a pawn square table that gives the pawn more points if it is on a higher rank and closer to promotion but when the postion is kings and pawns or maybe kings and pawns and one minor piece you want to accelerate this bonus with the distance to promotion bonus.

How smart does this bonus need to be? if its king and pawns should you check if the king can stop the pawn or just rely on search to do that. If stopping the pawn is outside the horizon, how would you make the engine force the king to chase the pawn if it can stop it?

In king pawn endings perhaps a race function can be used to see if the king can stop the pawn?

Two or more linked passed pawns are stronger in allmost all endgames than 2 isolated passed pawns. I have an isolated penalty but it is not enough to make pulsar see the dangerous of giving up 2 linked passed pawns. This seems like it can be fixed more easily with a strong penalty or bonus for 2 linked pawns in king pawn or king other piece pawn endings.

these ideas seem sound? any suggestions?

Mike
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: king pawn endgames

Post by bob »

adams161 wrote:While there are soem good ideas in the endgame thread i want to look into, particularly scoring bonsues and penalties for reaching certain piece configurations, I want to start with the basics and the first that comes to mind is king and pawn endgames and passers.

It seems when a pawn is evaluated as passed you should measure its distance to promotion and assign a bonus based on being close to being promoted. You have of course a pawn square table that gives the pawn more points if it is on a higher rank and closer to promotion but when the postion is kings and pawns or maybe kings and pawns and one minor piece you want to accelerate this bonus with the distance to promotion bonus.

How smart does this bonus need to be? if its king and pawns should you check if the king can stop the pawn or just rely on search to do that. If stopping the pawn is outside the horizon, how would you make the engine force the king to chase the pawn if it can stop it?

In king pawn endings perhaps a race function can be used to see if the king can stop the pawn?

Two or more linked passed pawns are stronger in allmost all endgames than 2 isolated passed pawns. I have an isolated penalty but it is not enough to make pulsar see the dangerous of giving up 2 linked passed pawns. This seems like it can be fixed more easily with a strong penalty or bonus for 2 linked pawns in king pawn or king other piece pawn endings.

these ideas seem sound? any suggestions?

Mike
There are several ideas here. In king and pawn endgames, the most critical concept is "square of the king" which determines whether a pawn can run to promote and the king can't catch it.

Next is the concept of "distant passed pawn". If you have a passer that is far away from the remaining pawns, then you can use that pawn to drag the opposing king away from the rest of his pawns since it has to stop your passer. meanwhile you eat his pawns and win. There are some subtle exceptions, in that a distant passer is no good if your opponent has a protected passer.

You need to extend this to recognize a distant candidate passer as well, which lets you recognize won endings even earlier in the search, before you have actually created a real outside passer.

You need to do as you mentioned with passed pawn advances. The farther they advance the more dangerous they become. connected passers are even better since the supporting pawn can not be captured else the other pawn (the protected passer) out-runs the king and promotes.

You need to have code to attract your king to the right position. Centralization won't cut it, your king needs to support its own passer or blockade the opponent's passer, etc...

It is a significant amount of work to get it right...