An exemple of 8 pieces endgame

Discussion about development of draughts in the time of computer and Internet.
TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

An exemple of 8 pieces endgame

Post by TAILLE » Thu Oct 02, 2008 18:21

Hi,

By analysing a Ghestem position I reached the following position. Though Damy has the 7 pieces database it is unable to explore the tree and reach this database in order to give the result of that position. In addittion, as a human playing against Damy, I win with black and I manage to draw with white !!!!

Image
Black to play

What is your view ?

Can Ed. give the result by using its 8 pieces database ?

My feeling is that black cannot win but I am not 100% sure.

Gérard

Ed Gilbert
Posts: 859
Joined: Sat Apr 28, 2007 14:53
Real name: Ed Gilbert
Location: Morristown, NJ USA
Contact:

Post by Ed Gilbert » Fri Oct 03, 2008 13:44

Hi Gerard,

You must be a strong player to be able to win this ending against Damy! I would be interested to see the game. Can you post it?

Kingsrow does not see a database result because its partial 8-piece database is the set of positions with a maximum of 1 king at each color, and here black has 2 kings. I agree with you that it looks like it should be a draw.

Have you made any progress on computing the 8-piece database? I have been experimenting with different compression algorithms. I'm about to benchmark a third approach which I think should have lookups as fast as my original db but compresses to about 20% smaller. When I finish this I thought I might set my quad core up to build a full 8-piece db. I did some rough estimates and with 4 cores running in parallel I think it should take between 12 and 16 months.

-- Ed

TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

Post by TAILLE » Fri Oct 03, 2008 14:48

Ed Gilbert wrote:Hi Gerard,

You must be a strong player to be able to win this ending against Damy! I would be interested to see the game. Can you post it?

Kingsrow does not see a database result because its partial 8-piece database is the set of positions with a maximum of 1 king at each color, and here black has 2 kings. I agree with you that it looks like it should be a draw.

Have you made any progress on computing the 8-piece database? I have been experimenting with different compression algorithms. I'm about to benchmark a third approach which I think should have lookups as fast as my original db but compresses to about 20% smaller. When I finish this I thought I might set my quad core up to build a full 8-piece db. I did some rough estimates and with 4 cores running in parallel I think it should take between 12 and 16 months.

-- Ed

Concerning the proposed endgame I was also surprised to win this endgame against Damy, though I am convinced that the position is a draw!
Before giving you the way I won against Damy, I would be very interested to see if I can also win against Kingsrow. I begin with 1...03-21

Image
White to play

What would be Kingsrow answer ?

For the time being I do not work on the 8 pieces endgame database. After having generated the 7 pieces database I decided to work on my evaluation function which is also a lot of work. I planned to come back to the generation of the endgame database by mid 2009, with a more powerfull PC.
At least I calculted the number of positions for a full 8 pieces database and I found about 18.000.000.000.000 positions. Do you agree with such figure ?

Gérard

Ed Gilbert
Posts: 859
Joined: Sat Apr 28, 2007 14:53
Real name: Ed Gilbert
Location: Morristown, NJ USA
Contact:

Post by Ed Gilbert » Fri Oct 03, 2008 23:36

TAILLE wrote:Before giving you the way I won against Damy, I would be very interested to see if I can also win against Kingsrow. I begin with 1...03-21
Ok. Kingsrow plays 39-33.
TAILLE wrote:For the time being I do not work on the 8 pieces endgame database. After having generated the 7 pieces database I decided to work on my evaluation function which is also a lot of work. I planned to come back to the generation of the endgame database by mid 2009, with a more powerfull PC.
Of course the evaluation function is always a work in progress. It will never be finished! I find that I can use my pc for both endgame db building and for normal email and web browsing at the same time. If I have to run kingsrow for something then I can kill one or 2 of the db build instances and restart them when I'm finished. I will only lose a maximum of a few hours of db building when I do that. 90% of the time I am not sitting at my PC so it's ok to normally have it building databases.
At least I calculted the number of positions for a full 8 pieces database and I found about 18.000.000.000.000 positions. Do you agree with such figure ?
I am only interested in 4x4 and 5x3 positions. For these the exact number I get is 16,502,336,047,605 positions, and adding all the 2 - 7 piece positions with a maximum of 5 pieces on a side I get 17,545,773,699,810 positions.

-- Ed

TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

Post by TAILLE » Fri Oct 03, 2008 23:46

Ed Gilbert wrote:Ok. Kingsrow plays 39-33.
Damy chose also 39-33!

03-21 39-33 36-41

Image
White (Kingsrow) to play

Did you take into account symetry considerations in your calculation of the number of positions ?

Gérard

Ed Gilbert
Posts: 859
Joined: Sat Apr 28, 2007 14:53
Real name: Ed Gilbert
Location: Morristown, NJ USA
Contact:

Post by Ed Gilbert » Sat Oct 04, 2008 00:19

Gerard,

Kingsrow plays 25-20.

Yes, my counts are only the positions that have to be resolved and do not include colors-reversed mirror images.

-- Ed

TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

Post by TAILLE » Sat Oct 04, 2008 00:24

Ed Gilbert wrote:Gerard,

Kingsrow plays 25-20.

-- Ed
21-12

Image
White to play

Gérard

Ed Gilbert
Posts: 859
Joined: Sat Apr 28, 2007 14:53
Real name: Ed Gilbert
Location: Morristown, NJ USA
Contact:

Post by Ed Gilbert » Sat Oct 04, 2008 00:30

Kingsrow plays 15-4.

TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

Post by TAILLE » Sat Oct 04, 2008 00:34

Ed Gilbert wrote:Kingsrow plays 15-4.
11-17

Ed Gilbert
Posts: 859
Joined: Sat Apr 28, 2007 14:53
Real name: Ed Gilbert
Location: Morristown, NJ USA
Contact:

Post by Ed Gilbert » Sat Oct 04, 2008 00:39

[FEN "B:WK15,25,35,39:BK3,11,16,K36."]
3-21 2. 39-33 36-41 3. 25-20 21-12 4. 15-4 11-17 5. 35-30 *

Ed Gilbert
Posts: 859
Joined: Sat Apr 28, 2007 14:53
Real name: Ed Gilbert
Location: Morristown, NJ USA
Contact:

Post by Ed Gilbert » Sat Oct 04, 2008 00:40

I should add that kingsrow now sees a draw with the 7-piece database.

-- Ed

TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

Post by TAILLE » Sat Oct 04, 2008 00:46

Ed Gilbert wrote:[FEN "B:WK15,25,35,39:BK3,11,16,K36."]
3-21 2. 39-33 36-41 3. 25-20 21-12 4. 15-4 11-17 5. 35-30 *
Very good Ed., I am now convinced Kingrow have found the draw.

For your information the mistake made by Damy was
3-21 2. 39-33 36-41 3.15-4?

The figure I got for 4x4 + 5x3 positions is
17.276.119.230.855
So, there is something wrong somewhere.

My figure for 5x3 positions is :
5.076.472.816.490 * 2

Gérard

Ed Gilbert
Posts: 859
Joined: Sat Apr 28, 2007 14:53
Real name: Ed Gilbert
Location: Morristown, NJ USA
Contact:

Post by Ed Gilbert » Sat Oct 04, 2008 00:56

Gerard,

Kingsrow does not see clear loss for 3. 15-4, only that it is not as good as 25-20.

Here are my counts for individual slices. Where do we disagree? (use the "no gaps" column).

Code: Select all

          ..........no gaps...........      .......with gaps...........
slice         positions         mbytes          positions        mbytes
-----     -----------------     ------      ----------------     ------
 0404        37,581,505,500      8,960        37,581,505,500      8,960
 0413       270,586,839,600     64,512       270,586,839,600     64,512
 0422       364,463,906,400     86,894       364,463,906,400     86,894
 0431       217,665,944,100     51,895       217,665,944,100     51,895
 0440        48,627,498,150     11,593        48,627,498,150     11,593
 0503        60,130,408,800     14,336        60,130,408,800     14,336
 0512       162,352,103,760     38,707       162,352,103,760     38,707
 0521       145,785,562,560     34,757       145,785,562,560     34,757
 0530        43,533,188,820     10,379        43,533,188,820     10,379
 1313       487,179,026,400    116,152       496,996,236,000    118,493
 1322     1,312,744,996,200    312,982     1,366,739,649,000    325,856
 1331       784,214,890,800    186,971       833,614,254,000    198,749
 1340       175,246,925,700     41,782       190,281,514,500     45,366
 1403       270,586,839,600     64,512       270,586,839,600     64,512
 1412       730,768,539,600    174,228       745,494,354,000    177,739
 1421       656,372,498,100    156,491       683,369,824,500    162,928
 1430       196,053,722,700     46,742       208,403,563,500     49,687
 2222       884,567,138,400    210,897       959,625,711,000    228,792
 2231     1,057,156,135,200    252,045     1,196,055,234,000    285,161
 2240       236,310,705,400     56,340       279,079,554,600     66,537
 2303       485,951,875,200    115,859       485,951,875,200    115,859
 2312     1,312,744,996,200    312,982     1,366,739,649,000    325,856
 2321     1,179,422,851,200    281,196     1,279,500,948,000    305,056
 2330       352,385,378,400     84,015       398,685,078,000     95,053
 3131       315,948,485,600     75,327       380,965,741,200     90,829
 3140       141,294,366,500     33,687       181,824,558,300     43,350
 3203       435,331,888,200    103,791       435,331,888,200    103,791
 3212     1,176,322,336,200    280,457     1,250,421,381,000    298,123
 3221     1,057,156,135,200    252,045     1,196,055,234,000    285,161
 3230       315,948,485,600     75,327       380,965,741,200     90,829
 4040        15,802,050,675      3,767        22,199,510,025      5,292
 4103       194,509,992,600     46,374       194,509,992,600     46,374
 4112       525,740,777,100    125,346       570,844,543,500    136,099
 4121       472,621,410,800    112,681       558,159,109,200    133,075
 4130       141,294,366,500     33,687       181,824,558,300     43,350
 5003        34,673,520,420      8,266        34,673,520,420      8,266
 5012        93,746,925,580     22,351       104,020,561,260     24,800
 5021        84,301,124,180     20,098       104,020,561,260     24,800
 5030        25,210,705,660      6,010        34,673,520,420      8,266
 8 piece totals
         16,502,336,047,605  3,934,463    17,742,341,663,475  4,230,103

TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

Post by TAILLE » Sat Oct 04, 2008 01:23

Ed Gilbert wrote:Gerard,

Kingsrow does not see clear loss for 3. 15-4, only that it is not as good as 25-20.

Here are my counts for individual slices. Where do we disagree? (use the "no gaps" column).

Code: Select all

          ..........no gaps...........      .......with gaps...........
slice         positions         mbytes          positions        mbytes
-----     -----------------     ------      ----------------     ------
 0404        37,581,505,500      8,960        37,581,505,500      8,960
 0413       270,586,839,600     64,512       270,586,839,600     64,512
 0422       364,463,906,400     86,894       364,463,906,400     86,894
 0431       217,665,944,100     51,895       217,665,944,100     51,895
 0440        48,627,498,150     11,593        48,627,498,150     11,593
 0503        60,130,408,800     14,336        60,130,408,800     14,336
 0512       162,352,103,760     38,707       162,352,103,760     38,707
 0521       145,785,562,560     34,757       145,785,562,560     34,757
 0530        43,533,188,820     10,379        43,533,188,820     10,379
 1313       487,179,026,400    116,152       496,996,236,000    118,493
 1322     1,312,744,996,200    312,982     1,366,739,649,000    325,856
 1331       784,214,890,800    186,971       833,614,254,000    198,749
 1340       175,246,925,700     41,782       190,281,514,500     45,366
 1403       270,586,839,600     64,512       270,586,839,600     64,512
 1412       730,768,539,600    174,228       745,494,354,000    177,739
 1421       656,372,498,100    156,491       683,369,824,500    162,928
 1430       196,053,722,700     46,742       208,403,563,500     49,687
 2222       884,567,138,400    210,897       959,625,711,000    228,792
 2231     1,057,156,135,200    252,045     1,196,055,234,000    285,161
 2240       236,310,705,400     56,340       279,079,554,600     66,537
 2303       485,951,875,200    115,859       485,951,875,200    115,859
 2312     1,312,744,996,200    312,982     1,366,739,649,000    325,856
 2321     1,179,422,851,200    281,196     1,279,500,948,000    305,056
 2330       352,385,378,400     84,015       398,685,078,000     95,053
 3131       315,948,485,600     75,327       380,965,741,200     90,829
 3140       141,294,366,500     33,687       181,824,558,300     43,350
 3203       435,331,888,200    103,791       435,331,888,200    103,791
 3212     1,176,322,336,200    280,457     1,250,421,381,000    298,123
 3221     1,057,156,135,200    252,045     1,196,055,234,000    285,161
 3230       315,948,485,600     75,327       380,965,741,200     90,829
 4040        15,802,050,675      3,767        22,199,510,025      5,292
 4103       194,509,992,600     46,374       194,509,992,600     46,374
 4112       525,740,777,100    125,346       570,844,543,500    136,099
 4121       472,621,410,800    112,681       558,159,109,200    133,075
 4130       141,294,366,500     33,687       181,824,558,300     43,350
 5003        34,673,520,420      8,266        34,673,520,420      8,266
 5012        93,746,925,580     22,351       104,020,561,260     24,800
 5021        84,301,124,180     20,098       104,020,561,260     24,800
 5030        25,210,705,660      6,010        34,673,520,420      8,266
 8 piece totals
         16,502,336,047,605  3,934,463    17,742,341,663,475  4,230,103
I have exactly the same numbers!
Finally I made a mistake when adding all the numbers (error in the formula in order to take into account symetries).

Now I have to go to bed !

Gérard

TAILLE
Posts: 968
Joined: Thu Apr 26, 2007 18:51
Location: FRANCE

Post by TAILLE » Sat Oct 04, 2008 15:30

Hi Ed,

Image

I have just made a small change of my evaluation function in order to improve Damy for handling the above position.

The result is the following : Damy avoids now the 15-04 move and Damy hesitates between 25-20 and 29-24.
Do you agree that these 2 moves allow white to obtain the draw ?

Concerning the 8 pieces database I do not intend to build the complete database. In any case I need to try and build a partial database and gain experience for building 9 or 10 pieces partial databases.
I can see some advantage of building a complete 5x3 database because a lot of winning positions exist with 2 kings in the weak side.
The 4x4 database is quite different because a very high pourcentage of positions with 2 kings in each side are draw positions. As a consequence it is a very good opportunity to build only a partial database, igoring all positions with at least 2 kings in each side.
Instead of handling the 6,349,390,414,625 positions of the complete 4x4 database I have only to handle 2,992,267,002,125 for a rather very powerful partial data base (at least it is my view today)

Gérard

Post Reply