One idea to solve chess?

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

chrisw
Posts: 4313
Joined: Tue Apr 03, 2012 4:28 pm

Re: One idea to solve chess?

Post by chrisw »

Ovyron wrote: Mon May 27, 2019 1:41 am
chrisw wrote: Fri May 17, 2019 10:05 pm
Uri Blass wrote: Fri May 17, 2019 7:37 pmI think that if you want to solve chess then you should try to solve.
chess engines of today do not try to solve the game and when they say 0.00 people have no idea if they found a forced draw or simply found a line that they evaluate as equal.
That’s easily dealt with. Use bit zero to distinguish between score by real draw and evaluation equality.
What is a "real draw"? If the engine thinks there's a certain line that is forced draw, and all deviations from either side lose them the game, but it's wrong, no such thing exists. All draws come from "evaluation equality" except those that are inside a Tablebase, which are irrelevant as they're already solved.
it beats me why someone should take a paragraph of text consisting of two sentences. Snip away the second sentence. And then disagree with the first sentence when the second sentence had already done that itself. Why do you snip posts like that?

Your assertion “all draws come from evaluation equality” is of course nonsense. Evaluation equality can come about just because the evaluation terms happen to add to 0.0, not necessarily a draw at all.
Actual, real draws, are as a result of perpetual, stalemate, insufficient material, agreement and so on, It is in all Chess for Beginners, Chapter one.

But I've seen Stockfish give 0.00 score to a position up to depth 59, only to realize white is winning at depth 60, there's no way to know if a position is drawn unless you examine all possible possibilities.
syzygy
Posts: 5557
Joined: Tue Feb 28, 2012 11:56 pm

Re: One idea to solve chess?

Post by syzygy »

chrisw wrote: Mon May 27, 2019 10:39 am
Ovyron wrote: Mon May 27, 2019 1:41 am
chrisw wrote: Fri May 17, 2019 10:05 pm
Uri Blass wrote: Fri May 17, 2019 7:37 pmI think that if you want to solve chess then you should try to solve.
chess engines of today do not try to solve the game and when they say 0.00 people have no idea if they found a forced draw or simply found a line that they evaluate as equal.
That’s easily dealt with. Use bit zero to distinguish between score by real draw and evaluation equality.
What is a "real draw"? If the engine thinks there's a certain line that is forced draw, and all deviations from either side lose them the game, but it's wrong, no such thing exists. All draws come from "evaluation equality" except those that are inside a Tablebase, which are irrelevant as they're already solved.
it beats me why someone should take a paragraph of text consisting of two sentences. Snip away the second sentence. And then disagree with the first sentence when the second sentence had already done that itself. Why do you snip posts like that?
The full paragraph was this:
That’s easily dealt with. Use bit zero to distinguish between score by real draw and evaluation equality. But, while the leaf end of PV evaluation is given by the search as the root position evaluation, it isn’t. So not really very useful anyway.
So you were talking about figuring out whether the PV itself ends in an "actual draw" or not. That is indeed not particularly useful information. Also, you don't need to reserve a bit in evaluation values for that. Just walk down the PV and check.

I suppose Uri wasn't thinking only of the position at the end of the PV when he said "forced draw".
chrisw
Posts: 4313
Joined: Tue Apr 03, 2012 4:28 pm

Re: One idea to solve chess?

Post by chrisw »

syzygy wrote: Thu May 30, 2019 6:04 pm
chrisw wrote: Mon May 27, 2019 10:39 am
Ovyron wrote: Mon May 27, 2019 1:41 am
chrisw wrote: Fri May 17, 2019 10:05 pm
Uri Blass wrote: Fri May 17, 2019 7:37 pmI think that if you want to solve chess then you should try to solve.
chess engines of today do not try to solve the game and when they say 0.00 people have no idea if they found a forced draw or simply found a line that they evaluate as equal.
That’s easily dealt with. Use bit zero to distinguish between score by real draw and evaluation equality.
What is a "real draw"? If the engine thinks there's a certain line that is forced draw, and all deviations from either side lose them the game, but it's wrong, no such thing exists. All draws come from "evaluation equality" except those that are inside a Tablebase, which are irrelevant as they're already solved.
it beats me why someone should take a paragraph of text consisting of two sentences. Snip away the second sentence. And then disagree with the first sentence when the second sentence had already done that itself. Why do you snip posts like that?
The full paragraph was this:
That’s easily dealt with. Use bit zero to distinguish between score by real draw and evaluation equality. But, while the leaf end of PV evaluation is given by the search as the root position evaluation, it isn’t. So not really very useful anyway.
So you were talking about figuring out whether the PV itself ends in an "actual draw" or not. That is indeed not particularly useful information. Also, you don't need to reserve a bit in evaluation values for that. Just walk down the PV and check.

I suppose Uri wasn't thinking only of the position at the end of the PV when he said "forced draw".
It can be useful if different evaluations are applied to different types of draws.
User avatar
Ovyron
Posts: 4556
Joined: Tue Jul 03, 2007 4:30 am

Re: One idea to solve chess?

Post by Ovyron »

chrisw wrote: Thu May 30, 2019 10:48 pmIt can be useful if different evaluations are applied to different types of draws.
The point is the score of a "true" draw can't be backtracked, as you don't know the "true" score of the rest of the moves, which would either all end in backtracked "true draws", or a mate in something, which is the most difficult to solve.

Perhaps we should start from there, then, solve all the positions that are a mate in something, then true draws could be backtracked bacause the rest of moves are known mates. You could start with the Patzer's Blunder:

1. e4 e5 2. Qh5 Nc6 3. Qxf7+
[d]r1bqkbnr/pppp1Qpp/2n5/4p3/4P3/8/PPPP1PPP/RNB1KBNR b KQkq -

That's presumably a position where black mates in X, if you solved it to a mate score, and the rest of alternative moves were a "true" draw, it could be backtracked.

Something more interesting is this:

1. e4 e5 2. Bc4 Nf6 3. Bxf7+
[d]rnbqkb1r/pppp1Bpp/5n2/4p3/4P3/8/PPPP1PPP/RNBQK1NR b KQkq -

Is this a "black to move and mate in X" position? Perhaps chess could be solved in the weakest way, if nobody could find a mate score for this position. As if white giving up a Bishop for a pawn like this in the opening doesn't lose, how can we expect black to lose the game from the opening position with full material? It'd prove that chess is draw with perfect play, in the weakest way.
Your beliefs create your reality, so be careful what you wish for.
Uri Blass
Posts: 10268
Joined: Thu Mar 09, 2006 12:37 am
Location: Tel-Aviv Israel

Re: One idea to solve chess?

Post by Uri Blass »

syzygy wrote: Thu May 30, 2019 6:04 pm
chrisw wrote: Mon May 27, 2019 10:39 am
Ovyron wrote: Mon May 27, 2019 1:41 am
chrisw wrote: Fri May 17, 2019 10:05 pm
Uri Blass wrote: Fri May 17, 2019 7:37 pmI think that if you want to solve chess then you should try to solve.
chess engines of today do not try to solve the game and when they say 0.00 people have no idea if they found a forced draw or simply found a line that they evaluate as equal.
That’s easily dealt with. Use bit zero to distinguish between score by real draw and evaluation equality.
What is a "real draw"? If the engine thinks there's a certain line that is forced draw, and all deviations from either side lose them the game, but it's wrong, no such thing exists. All draws come from "evaluation equality" except those that are inside a Tablebase, which are irrelevant as they're already solved.
it beats me why someone should take a paragraph of text consisting of two sentences. Snip away the second sentence. And then disagree with the first sentence when the second sentence had already done that itself. Why do you snip posts like that?
The full paragraph was this:
That’s easily dealt with. Use bit zero to distinguish between score by real draw and evaluation equality. But, while the leaf end of PV evaluation is given by the search as the root position evaluation, it isn’t. So not really very useful anyway.
So you were talking about figuring out whether the PV itself ends in an "actual draw" or not. That is indeed not particularly useful information. Also, you don't need to reserve a bit in evaluation values for that. Just walk down the PV and check.

I suppose Uri wasn't thinking only of the position at the end of the PV when he said "forced draw".

correct.

I would like engines after they see 0.00 to do 2 searches(one when a draw is a win for white and one when a draw is a win for black and show me the scores in both cases)

Note that draw is only repetition of previous position in the search or stalemate or insufficient material or a draw by fifty move rule for the discussion.

If the 2 searches have a mate score then it means that the position is a forced draw and the engine may play immediately the "winning" move in the search when draw is a win for the side to move.
Uri Blass
Posts: 10268
Joined: Thu Mar 09, 2006 12:37 am
Location: Tel-Aviv Israel

Re: One idea to solve chess?

Post by Uri Blass »

Ovyron wrote: Mon Jun 03, 2019 2:17 pm
chrisw wrote: Thu May 30, 2019 10:48 pmIt can be useful if different evaluations are applied to different types of draws.
The point is the score of a "true" draw can't be backtracked, as you don't know the "true" score of the rest of the moves, which would either all end in backtracked "true draws", or a mate in something, which is the most difficult to solve.

Perhaps we should start from there, then, solve all the positions that are a mate in something, then true draws could be backtracked bacause the rest of moves are known mates. You could start with the Patzer's Blunder:

1. e4 e5 2. Qh5 Nc6 3. Qxf7+
[d]r1bqkbnr/pppp1Qpp/2n5/4p3/4P3/8/PPPP1PPP/RNB1KBNR b KQkq -

That's presumably a position where black mates in X, if you solved it to a mate score, and the rest of alternative moves were a "true" draw, it could be backtracked.

Something more interesting is this:

1. e4 e5 2. Bc4 Nf6 3. Bxf7+
[d]rnbqkb1r/pppp1Bpp/5n2/4p3/4P3/8/PPPP1PPP/RNBQK1NR b KQkq -

Is this a "black to move and mate in X" position? Perhaps chess could be solved in the weakest way, if nobody could find a mate score for this position. As if white giving up a Bishop for a pawn like this in the opening doesn't lose, how can we expect black to lose the game from the opening position with full material? It'd prove that chess is draw with perfect play, in the weakest way.
No chance to prove today even the first position is a mate for black.
It may be more interesting if computers can prove that black can force a draw when they consider draw as a win for black(this is an easier problem but chess engines are not designed to try to solve it).