user13744: It is going from #26 through +60 to +9. Thats all engines best moves with deep analysis. Schould it not be a forced checkmate if I will follow the engine evaluation?



user12873: Engines do not calculate every single variation up until their depth.  It would take far too long to do this at a depth of, say, 20 moves.  After only the first four moves in chess, there over a billion positions.
Engines choose what variations to calculate based off their evaluation algorithms (how they evaluate positions).  For example, assume it gets to a position in its calculations where the opponent has 5 possible moves.  If it evaluates that 3 of these moves are +10 for the computer, it could entirely skip these variations and only calculate the remaining 2.  This saves large amounts of time and processing power.
Thus, if an engine calls "mate in X", that is really just its best guess.  It's possible the engine incorrectly thought some variation was bad for the opponent, and thus chose not to calculate it.  However, maybe it turns out this variation actually prolonged the game a few more moves.
An engine's evaluation algorithm is based on a number of factors regarding the current position in its calculations.  Black could have had a move that "looked" worse to the engine (based off its evaluation algorithm), causing it not to calculate the resulting variation.  Concretely though, this move could have been objectively the best, as it prolonged mate.
The reason an engine often changes its evaluation from "mate in X" to something like +60 is that, after "going down the rabbit hole" as far as it can, it then checks over and refines its previous calculations.  It wouldn't make sense to refine/perfect its calculations first, as this is like the cherry on the cake.  Analyzing to a high depth is of highest priority - refining its previous calculations is almost always secondary.

user13544: Stockfish (at a search depth of 99 moves) evaluates the initial position as actually a mate-in-19.
[FEN "2n5/1p6/1P3k2/R1K1p1p1/2p1PpPp/5P1P/8/8 w - - 4 1"]

1.Ra8 Ne7 Kxc4 Nc6 Kc5 Ke7 Rc8 Nd8 Kd5 Ne6 Kxe5 Kd7 Kd5 Ke7 Re8+ Kxe8 Kxe6 Kf8 e5 Kg7 Kd6 Kg8 e6 Kf8 Kd7 Kg8 e7 Kf7 e8=Q+ Kf6 Kd6 Kg7 Ke7 Kh6 Kf8 Kh7 Qh5#

The next position is a mate in 18 moves.
[FEN "R7/1p2n3/1P3k2/2K1p1p1/2p1PpPp/5P1P/8/8 w - - 6 2"]

1.Kxc4 Nc6 Kc5 Ke7 Rc8 Nd8 Kd5 Ne6 Kxe5 Kd7 Kd5 Ke7 Re8+ Kxe8 Kxe6 Kf8 e5 Kg7 Kd6 Kg8 e6 Kf8 Kd7 Kg8 e7 Kf7 e8=Q+ Kf6 Kd6 Kg7 Ke7 Kh6 Kf8 Kh7 Qh5#

The final position is mate in 17 moves.
[FEN "R7/1p6/1Pn2k2/4p1p1/2K1PpPp/5P1P/8/8 w - - 1 3"]

1.Kc5 Ke7 Rc8 Nd8 Kd5 Ne6 Kxe5 Kd7 Kd5 Ke7 Re8+ Kxe8 Kxe6 Kf8 e5 Kg7 Kd6 Kg8 e6 Kf8 Kd7 Kg8 e7 Kf7 e8=Q+ Kf6 Kd6 Kg7 Ke7 Kh6 Kf8 Kh7 Qh5#

You probably didn't give the engine sufficient time to find the mate.
Another important fact to note is that the Lichess app uses the javascript version of Stockfish. The problem with this version is that it cannot make use of hash tables. So when the engine evaluates a position and then left to evaluate another position resulting from a move in the initial position, it evaluates the position as if it was restarted before evaluation. I am pretty sure if you give the engine some time to evaluate the second and last positions it will come up with the mate.

13744: <p>It is going from #26 through +60 to +9. Thats all engines best moves with deep analysis. Schould it not be a forced checkmate if I will follow the engine evaluation?</p>

<p><img src="https://i.stack.imgur.com/HJWgk.jpg" alt="enter image description here">
<a href="https://i.stack.imgur.com/cjbUk.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cjbUk.jpg" alt="enter image description here"></a></p>
 12873: <p>Engines do not calculate <em>every single variation</em> up until their depth.  It would take far too long to do this at a depth of, say, 20 moves.  After only the first four moves in chess, there over a billion positions.</p>

<p>Engines choose what variations to calculate based off their evaluation algorithms (how they evaluate positions).  For example, assume it gets to a position in its calculations where the opponent has 5 possible moves.  If it evaluates that 3 of these moves are +10 for the computer, it could entirely skip these variations and only calculate the remaining 2.  This saves large amounts of time and processing power.</p>

<p>Thus, if an engine calls "mate in X", that is really just its best guess.  It's possible the engine incorrectly thought some variation was bad for the opponent, and thus chose not to calculate it.  However, maybe it turns out this variation actually prolonged the game a few more moves.</p>

<p>An engine's evaluation algorithm is based on a number of factors regarding <em>the current position in its calculations</em>.  Black could have had a move that "looked" worse to the engine (based off its evaluation algorithm), causing it not to calculate the resulting variation.  Concretely though, this move could have been <em>objectively</em> the best, as it prolonged mate.</p>

<p>The reason an engine often changes its evaluation from "mate in X" to something like +60 is that, after "going down the rabbit hole" as far as it can, it then checks over and refines its previous calculations.  It wouldn't make sense to refine/perfect its calculations first, as this is like the cherry on the cake.  Analyzing to a high depth is of highest priority - refining its previous calculations is almost always secondary.</p>
 13544: <p>Stockfish (at a search depth of 99 moves) evaluates the initial position as actually a mate-in-19.</p>

<pre><code>[FEN "2n5/1p6/1P3k2/R1K1p1p1/2p1PpPp/5P1P/8/8 w - - 4 1"]

1.Ra8 Ne7 Kxc4 Nc6 Kc5 Ke7 Rc8 Nd8 Kd5 Ne6 Kxe5 Kd7 Kd5 Ke7 Re8+ Kxe8 Kxe6 Kf8 e5 Kg7 Kd6 Kg8 e6 Kf8 Kd7 Kg8 e7 Kf7 e8=Q+ Kf6 Kd6 Kg7 Ke7 Kh6 Kf8 Kh7 Qh5#
</code></pre>

<p>The next position is a mate in 18 moves.</p>

<pre><code>[FEN "R7/1p2n3/1P3k2/2K1p1p1/2p1PpPp/5P1P/8/8 w - - 6 2"]

1.Kxc4 Nc6 Kc5 Ke7 Rc8 Nd8 Kd5 Ne6 Kxe5 Kd7 Kd5 Ke7 Re8+ Kxe8 Kxe6 Kf8 e5 Kg7 Kd6 Kg8 e6 Kf8 Kd7 Kg8 e7 Kf7 e8=Q+ Kf6 Kd6 Kg7 Ke7 Kh6 Kf8 Kh7 Qh5#
</code></pre>

<p>The final position is mate in 17 moves.</p>

<pre><code>[FEN "R7/1p6/1Pn2k2/4p1p1/2K1PpPp/5P1P/8/8 w - - 1 3"]

1.Kc5 Ke7 Rc8 Nd8 Kd5 Ne6 Kxe5 Kd7 Kd5 Ke7 Re8+ Kxe8 Kxe6 Kf8 e5 Kg7 Kd6 Kg8 e6 Kf8 Kd7 Kg8 e7 Kf7 e8=Q+ Kf6 Kd6 Kg7 Ke7 Kh6 Kf8 Kh7 Qh5#
</code></pre>

<p>You probably didn't give the engine sufficient time to find the mate.</p>

<p>Another important fact to note is that the Lichess app uses the javascript version of Stockfish. The problem with this version is that it cannot make use of hash tables. So when the engine evaluates a position and then left to evaluate another position resulting from a move in the initial position, it evaluates the position as if it was restarted before evaluation. I am pretty sure if you give the engine some time to evaluate the second and last positions it will come up with the mate.</p>
