Forums

The most beautiful puzzle that my engine can never solve

Sort:
Lent_Barsen
Well of course if you feed Stockfish the moves it will eventually see that white is winning, 

That's not what I did. I put Stockfish into analysis mode and then played its moves as white against your solution moves as black, and it found Qxc7+. It still evaluated 0.00 until some moves down the road when it decided white was winning, and then when I backed it up to the beginning it maintained that white was winning all along.

I was not able to replicate it when I tried it again today, so I'm not sure what happened there.

One thing I'd say on a more meta level though is that of course Stockfish can solve this. Any engine can solve this. It's just a matter of the horizon effect, not a fundamental incapability.

drdos7
Lent_Barsen wrote:
Well of course if you feed Stockfish the moves it will eventually see that white is winning, 

That's not what I did. I put Stockfish into analysis mode and then played its moves as white against your solution moves as black, and it found Qxc7+. It still evaluated 0.00 until some moves down the road when it decided white was winning, and then when I backed it up to the beginning it maintained that white was winning all along.

I was not able to replicate it when I tried it again today, so I'm not sure what happened there.

One thing I'd say on a more meta level though is that of course Stockfish can solve this. Any engine can solve this. It's just a matter of the horizon effect, not a fundamental incapability.

Well, you'll have to forgive me if I'm a bit skeptical about Stockfish finding 2.Qxc7+! because it has NEVER found it on my 20 core system, also when you "back it up" the correct moves and evaluation are stored in the hash table so of course it's going to see that white is winning, and I maintain that Stockfish cannot solve this no matter what the horizon.

Here's another one it can't solve:

removedusername8329742834

No I know why the cheaters in puzzles don't get 100%^^

chinoi321
Lent_Barsen wrote:
Well of course if you feed Stockfish the moves it will eventually see that white is winning, 

That's not what I did. I put Stockfish into analysis mode and then played its moves as white against your solution moves as black, and it found Qxc7+. It still evaluated 0.00 until some moves down the road when it decided white was winning, and then when I backed it up to the beginning it maintained that white was winning all along.

I was not able to replicate it when I tried it again today, so I'm not sure what happened there.

One thing I'd say on a more meta level though is that of course Stockfish can solve this. Any engine can solve this. It's just a matter of the horizon effect, not a fundamental incapability.

These engines could not solve the puzzle , to explain it professionally , just because there are not updated the programs which have ability to trapp queen and use zugwang to win material . To update this program , need lots of money and energy , that is why the vast majority of engines currently do not have this program installed . Of course , these engines can't solve the puzzle .

chinoi321
Grab_her_by_the_pawn wrote:

No I know why the cheaters in puzzles don't get 100%^^

Make sure that most of cheaters can't get his first move correctly in these types of puzzle .

Lent_Barsen
These engines could not solve the puzzle , to explain it professionally , just because there are not updated the programs which have ability to trapp queen and use zugwang to win material . To update this program , need lots of money and energy , that is why the vast majority of engines currently do not have this program installed . Of course , these engines can't solve the puzzle .

If there are puzzles that engines just fundamentally cannot solve, and the limitation is not due to the Horizon Effect, then it seems likely there should be some unsolvable puzzles where the solution doesn't run 40 or 60 ply deep. Any 10 ply examples?

Arisktotle
Lent_Barsen wrote:

If there are puzzles that engines just fundamentally cannot solve, and the limitation is not due to the Horizon Effect, then it seems likely there should be some unsolvable puzzles where the solution doesn't run 40 or 60 ply deep. Any 10 ply examples?

The limitation is always due to the Horizon effect. Having accepted that fact, the designers of engine software have added heuristic and neural network strategies which are inherently imperfect. But even the simplest engine software could solve every chess puzzle by backward induction if not restricted by the speed of its CPU cores - what we know as Horizon.

drdos7
Lent_Barsen wrote:
These engines could not solve the puzzle , to explain it professionally , just because there are not updated the programs which have ability to trapp queen and use zugwang to win material . To update this program , need lots of money and energy , that is why the vast majority of engines currently do not have this program installed . Of course , these engines can't solve the puzzle .

If there are puzzles that engines just fundamentally cannot solve, and the limitation is not due to the Horizon Effect, then it seems likely there should be some unsolvable puzzles where the solution doesn't run 40 or 60 ply deep. Any 10 ply examples?

Try this Mate in 5 that Stockfish struggles with, and remember this isn't white to play and win, it is a mate in 5 (not a mate in 22 or 15 or 7):

Elroch

I believe the Stockfish algorithms would, in principle, play perfect chess given unlimited computing and memory. This is because if it continued to grow the analysis tree, eventually it would be complete, and its choice would be game theoretic optimal. This is impossible in practice because of the vast time and memory needed.

Elroch
DesperateKingWalk wrote:
Elroch wrote:

I believe the Stockfish algorithms would, in principle, play perfect chess given unlimited computing and memory. This is because if it continued to grow the analysis tree, eventually it would be complete, and its choice would be game theoretic optimal. This is impossible in practice because of the vast time and memory needed.

You believe wrong.

Again Stockfish is a TYPE B Shannon chess engine. And is always pruning almost all moves in a chess position. No matter how much time and memory.

This is wrong. You are claiming that it stops analysing when it only sees relatively unappealing moves that have not been exhaustively analysed. It does not, given adequate resources. 

  1. It continues to analyse more nodes, taking a finite time for each
  2. There are a finite number of nodes
  3. Thus, in principle, it would complete the task in finite time with unlimited memory

Again, a type B chess engine, and Stockfish is a type B chess engine. Is not designed to solve every chess positions. And it not able to solve them. Because it was not designed to solve them.

See above to learn something simple but new.

Note this is about the algorithms, not a 64-bit implementation that is limited to 16 million terabytes of RAM. But only implementation details would need to change, not algorithmic ones.

drdos7
DesperateKingWalk wrote:
A chess engine that is designed to look at every move. Easily solves this mate in 5 posted earlier. In less then 1 second. 
 

WinCHEST Ver.3.19i+, 08-Mar-2011
Options = -M2044 -Z5 -11 -el -U -C16 -K1 -P4 -X20 -0 -5 -rS
Input file: STDIN
Reading job:
% created by ChestUCI Ver.5.2
W: Kb1 Re3 Bb2 Nc7 Ng2 Pa3 Pb4 Pc3 Pd2 Pf4 Ph4 (11)
B: Kg4 Re5 Bd7 Pa6 Pb6 Pb3 Pc4 Pd3 Pe4 Pf5 Ph5 (11)
FEN: 8/2Nb4/pp6/4rp1p/1Pp1pPkP/PpPpR3/1B1P2N1/1K6 w - -
analysing (first special-mate in 5 moves):
Solution (in 5 moves):
b1c1
Time (virt) = 0.040 sec

PV= b1c1 b6b5 c1d1 a6a5 d1e1 a5a4 e1f2 d7e8 e3g3
 b1c1 a6a5 c1d1 ...+3
b6b5 c1d1 ...+3
d7a4 c1d1 ...+3
d7b5 c1d1 ...+3
d7c6 c1d1 ...+3
d7c8 c1d1 ...+3
d7e8 c1d1 ...+3
e5a5 c1d1 ...+3
e5b5 c1d1 ...+3
e5c5 c1d1 ...+3
e5e6 c1d1 ...+3
e5e7 c1d1 ...+3
e5e8 c1d1 ...+3
d7e6 c7e8 ...+1
e5d5 c7d5 ...+1

end of solution tree (no duals except at top)
Total Time (virt) = 0.041 sec

Correct Mark, but Stockfish 16 doesn't see it (most people don't get the developement versions) and I doubt that Dragon does either even though I don't own it, and the guy I was giving this position to asked for a 10 ply that engines like Stockfish won't solve rather than a mate finder that can't play a game of chess like WinCHEST (unless of course some day it finds a forced mate from the starting position grin, which if the game is a draw from the starting position then that would be impossible).

drdos7
DesperateKingWalk wrote:
drdos7 wrote:
DesperateKingWalk wrote:
A chess engine that is designed to look at every move. Easily solves this mate in 5 posted earlier. In less then 1 second. 
 

WinCHEST Ver.3.19i+, 08-Mar-2011
Options = -M2044 -Z5 -11 -el -U -C16 -K1 -P4 -X20 -0 -5 -rS
Input file: STDIN
Reading job:
% created by ChestUCI Ver.5.2
W: Kb1 Re3 Bb2 Nc7 Ng2 Pa3 Pb4 Pc3 Pd2 Pf4 Ph4 (11)
B: Kg4 Re5 Bd7 Pa6 Pb6 Pb3 Pc4 Pd3 Pe4 Pf5 Ph5 (11)
FEN: 8/2Nb4/pp6/4rp1p/1Pp1pPkP/PpPpR3/1B1P2N1/1K6 w - -
analysing (first special-mate in 5 moves):
Solution (in 5 moves):
b1c1
Time (virt) = 0.040 sec

PV= b1c1 b6b5 c1d1 a6a5 d1e1 a5a4 e1f2 d7e8 e3g3
 b1c1 a6a5 c1d1 ...+3
b6b5 c1d1 ...+3
d7a4 c1d1 ...+3
d7b5 c1d1 ...+3
d7c6 c1d1 ...+3
d7c8 c1d1 ...+3
d7e8 c1d1 ...+3
e5a5 c1d1 ...+3
e5b5 c1d1 ...+3
e5c5 c1d1 ...+3
e5e6 c1d1 ...+3
e5e7 c1d1 ...+3
e5e8 c1d1 ...+3
d7e6 c7e8 ...+1
e5d5 c7d5 ...+1

end of solution tree (no duals except at top)
Total Time (virt) = 0.041 sec

Correct Mark, but Stockfish doesn't see it and I doubt that Dragon does either even though I don't own it, and the guy I was giving this position to asked for a 10 ply that engines like Stockfish won't solve rather than a mate finder that can't play a game of chess like WinCHEST (unless of course some day it finds a forced mate from the starting position , which if the game is a draw from the starting position then that would be impossible).

Read the post. I already showed that Stockfish finds the mate in 5.

The latest Stockfish does not struggle with this mate in 5.

Line 0.0
8/2Nb4/pp6/4rp1p/1Pp1pPkP/PpPpR3/1B1P2N1/1K6 w - - 0 1

Analysis by Stockfish dev-20230824-4c4cb185:

1.Kc1 a5 2.Kd1 axb4 3.Ke1 bxa3 4.Kf2 axb2 5.Rg3#
 Depth: 245/10 00:02:42 3686MN, tb=19348
 White mates.

(, 02.09.2023)

I edited mine to read Stockfish 16 doesn't solve it.

drdos7
DesperateKingWalk wrote:
drdos7 wrote:

Here is another study where Stockfish is absolutely helpless (along with other engines), and has no clue as to the solution:

White to play and WIN:

We have more then one type of search that computer chess engines can use in finding a solution. Here the MCTS search gives Lc0 the answer on winning this chess position.

Line 0.0
7q/b1p5/1p1Npkb1/pPP2ppP/P1P5/3B2P1/5P1R/K3R3 w - - 0 1

Analysis by Lc0 v0.30.0:

1.hxg6 Qxh2 2.Rxe6+ Kxe6 3.g7 Qh1+ 4.Kb2 Qa8 5.Bxf5+ Kf6 6.Nc8 Kxg7 7.c6 Kf6 8.Bd7 Ke5 9.f3 Kf6 10.Kc3 Ke5 11.Kd3 Kf6 12.Ke4 Bb8 13.f4 gxf4 14.gxf4 Ba7 15.Kf3 Bb8 16.Kg4 Kg6 17.f5+ Kf6 18.Kh5 Ba7 19.Kh6 Qb8 20.Kh7 Kf7 21.Be6+ Kf6 22.Kg8 Qa8 23.Kf8 Qb8 24.Ke8 Qa8 25.Kd7 Qb8 26.Kd8 Qa8 27.Ke8 Bb8 28.Ne7 Ba7+ 29.Bc8 Kg7 30.Kd7 Kf7 31.Nd5
 Depth: 30/67 00:00:22 80637kN, tb=5
 White is better.

(, 02.09.2023)

Ok, so try the other ones with Lc0 MCTS (Monte Carlo Tree Search)

Lent_Barsen

I muddied the waters unintentionally by saying "Stockfish" when I really meant "engines" generally or "computers" (although some of this discussion about Stockfish specifically has been interesting).

The question I intended to ask is whether there are positions computers can't solve, and I think the answer is no. Engines would include programs that search the entire width of the game tree, and such engines should be able to solve any problem within their horizon which admits to a definite outcome (1-0, 0-1, 1/2). Such engines should even be able to solve chess itself, albeit on impractical timescales.

Arisktotle
Lent_Barsen wrote:

I muddied the waters unintentionally by saying "Stockfish" when I really meant "engines" generally or "computers" (although some of this discussion about Stockfish specifically has been interesting).

The question I intended to ask is whether there are positions computers can't solve, and I think the answer is no. Engines would include programs that search the entire width of the game tree, and such engines should be able to solve any problem within their horizon which admits to a definite outcome (1-0, 0-1, 1/2). Such engines should even be able to solve chess itself, albeit on impractical timescales.

Precisely! As a deterministic, 2-player, alternate move game, the solving algorithm can be written on a single sheet of paper (skipping the chess rules).

This is however not true for chess compositions which have a number of fundamental unknowns. Fundamental because the WFCC has specifically blocked the solvers access to that information. It concerns castling right, e.p. right, all the past repeatable positions, the state of the 50-move counter and who is on move. That's the reason why FENs cannot represent compositions - they pretend to know things which are untrue or undefined. To satisfy the unknowns one needs a mathematical model - or, as it is, a number of mathematical models! That's why the engines cannot solve a number of my compositions. Btw, the models do not only apply to retrograde problems, they are in the orthodox zone as well. For instance, If you could prove for any of the preceding diagrams that no proof game exists for it with "white on move" you are to assume that "black is on move" (irrespective of the FEN or anything the puzzle interface would force on you).

Elroch
DesperateKingWalk wrote:
Elroch wrote:
DesperateKingWalk wrote:
Elroch wrote:

I believe the Stockfish algorithms would, in principle, play perfect chess given unlimited computing and memory. This is because if it continued to grow the analysis tree, eventually it would be complete, and its choice would be game theoretic optimal. This is impossible in practice because of the vast time and memory needed.

You believe wrong.

Again Stockfish is a TYPE B Shannon chess engine. And is always pruning almost all moves in a chess position. No matter how much time and memory.

This is wrong. You are claiming that it stops analysing when it only sees relatively unappealing moves that have not been exhaustively analysed. It does not, given adequate resources. 

  1. It continues to analyse more nodes, taking a finite time for each
  2. There are a finite number of nodes
  3. Thus, in principle, it would complete the task in finite time with unlimited memory

Again, a type B chess engine, and Stockfish is a type B chess engine. Is not designed to solve every chess positions. And it not able to solve them. Because it was not designed to solve them.

See above to learn something simple but new.

Note this is about the algorithms, not a 64-bit implementation that is limited to 16 million terabytes of RAM. But only implementation details would need to change, not algorithmic ones.

So when does a type B chess engine not prune moves.....

If you prune moves in a 100% tactical game like chess. You can not solve that game.

If you had a "ultimate computer". You would use a type A algorithm.

Only moves that are proven dominated can be truly pruned. Other moves can merely be given low priority.

Do you REALLY think that the Stockfish algorithms (infinite depth) stop analyzing a problem before they have found the solution (because, according to you, it has been pruned)?

If so it should be possible to find a mate in 2 or 3 it can't solve - just design it so the solution move is pruned. Moreover, it must stop analysing without finding the solution.

I assert neither is so.

Elroch

Now engage your brain. If the analysis tree keeps growing at a finite rate it has to eventually solve the initial position (given unlimited room).

Your claim implies that the Stockfish analysis tree stops growing when there are moves that could logically change the evaluation and which only have a bare evaluation. Why??

No, it gives them low priority and gets round to them eventually. The key fact is that a bare evaluation does not imply a branch is inferior and can be ignored - it merely gives an indication of how likely it is to be irrelevant.

[There are some variations that can be permanently pruned - those that can be proven to not be superior to those that have been analysed. This requires at least exhaustive analysis of all legal moves by one side. For example, this is absolute minimum to prove a mate in N - every position reached by a legal move for black needs to be dealt with. That means both:

(1) analysing at least one move for white in such positions

and

(2) analysing all positions reachable by a legal move for black from a position white reaches by such moves.

Stockfish' relatively poor efficiency for solving puzzles is a matter of prioritisation. It can be busy deeply analysing more plausible looking moves when an implausible one is key. But if it finishes the plausible looking ones, Sherlock Holmes maxim comes into play.

Elroch

Answer the following question if you want to have any claim to honesty.

Does the Stockfish algorithm stop analysing when it hasn't found a solution and still has a completely unanalysed candidate move?

Do you understand the point that an algorithm will either solve a problem or stop analysing and leave some node WITH JUST A BARE EVALUATION? Perhaps you have some confused belief that such a node can be pruned? Definitely false unless the problem is already solved.

If you do, why do you believe that Stockfish would fail to solve a mate in 2 by only analysing a subset of the legal first moves? Exactly the same can apply at any depth in an analysis tree, with the same conclusion.

Do you think a move can be pruned without doing any analysis of it? Why would you believe such a thing?

Why do you think the fact that when Stockfish has only analysed a few billion nodes it has not analysed enough of a tree that is much larger is relevant to the question about the algorithm with a quadrillion times more time and computational resources?

Elroch

You confuse "an impractically long time" and "never".

I accept that this is beyond your capabilities to understand. You need to answer the much more enlightening question.

"When does Stockfish (in "unlimited" mode) stop analysing when there remains a candidate move that could change its opinion of the result?"

That is the one which has the answer: NEVER.

Elroch

Actually I did answer it. Unlike you for my question.

More explicitly, in infinite analysis mode, if Stockfish manages say a million nodes per second and the number of nodes in the complete tree is N, the answer is:

In less than N / 1000000 seconds

This time can easily be aeons or more. That is irrelevant to the truth about the algorithm.

Now answer my question:

When does Stockfish (in infinite analysis mode) stop analysing when there is a completely unanalysed candidate move that can affect the result?