Null move test

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Rebel, chrisw

jdart
Posts: 4366
Joined: Fri Mar 10, 2006 5:23 am
Location: http://www.arasanchess.org

Null move test

Post by jdart »

This position occurred recently in an online game:

[d]8/5K2/p2kp2b/p1p1p3/2P1P3/1P3P2/5N2/8 w - -

White played Nh1! and won. Finding this for my engine appears to be closely tied to how much null move reduction is applied in a position like this, where there is only a minor for each side on board, plus pawns. Arasan did not solve it even at high depths but if I do less reduction in this situation, then it does solve it.

--Jon
jstanback
Posts: 130
Joined: Fri Jun 17, 2016 4:14 pm
Location: Colorado, USA
Full name: John Stanback

Re: Null move test

Post by jstanback »

Hi Jon,

Good position! Coincidentally, I was experimenting will null-move reduction yesterday on a similar endgame with only one minor per side. Here is the position

[d]8/p2b2p1/3P1p2/4k3/1B5P/3K4/8/8 b - -

In Wasp I allow NMP if the side to move has one or more pieces. If the null-move search fails high and depth >= 5 I do a verification search with depth-4. The null-move reduction formula I have been using is simple: R = 3 + depth/8. With this formula, Wasp takes 35 ply and over 2 minutes to find Kf4 with a score > 1.5 pawns. For your position it takes 36 ply and 42s to find Nh1.

Yesterday I changed the formula to R = 3 + (depth >= 8 && TD->null_move_cnt <= 1) and it solves the position above in 33 ply, 90s and solves your position in 35 ply, 35s. So a little faster, but not much. After about 25000 games at G/15s+0.18s it gave an Elo improvement of +2, so it didn't seem to hurt to restrict the null-move reduction, at least for fast games.

For Wasp there are lots of positions where it is blind due to over-reducing critical lines, especially in endgames. LMR is particularly finicky. I've tried limiting the total ply of reductions so that the depth searched is always at least some fraction of the root depth, but that hasn't worked very well. I don't know how engines like SF can get away with such huge reduction!

John
User avatar
MikeB
Posts: 4889
Joined: Thu Mar 09, 2006 6:34 am
Location: Pen Argyl, Pennsylvania

Re: Null move test

Post by MikeB »

jstanback wrote: Mon Dec 16, 2019 5:34 pm Hi Jon,

Good position! Coincidentally, I was experimenting will null-move reduction yesterday on a similar endgame with only one minor per side. Here is the position

[d]8/p2b2p1/3P1p2/4k3/1B5P/3K4/8/8 b - -

In Wasp I allow NMP if the side to move has one or more pieces. If the null-move search fails high and depth >= 5 I do a verification search with depth-4. The null-move reduction formula I have been using is simple: R = 3 + depth/8. With this formula, Wasp takes 35 ply and over 2 minutes to find Kf4 with a score > 1.5 pawns. For your position it takes 36 ply and 42s to find Nh1.

Yesterday I changed the formula to R = 3 + (depth >= 8 && TD->null_move_cnt <= 1) and it solves the position above in 33 ply, 90s and solves your position in 35 ply, 35s. So a little faster, but not much. After about 25000 games at G/15s+0.18s it gave an Elo improvement of +2, so it didn't seem to hurt to restrict the null-move reduction, at least for fast games.

For Wasp there are lots of positions where it is blind due to over-reducing critical lines, especially in endgames. LMR is particularly finicky. I've tried limiting the total ply of reductions so that the depth searched is always at least some fraction of the root depth, but that hasn't worked very well. I don't know how engines like SF can get away with such huge reduction!

John
The exception to the reductions are very refined and specific. search.cpp adds about 1200 Elo alone ( meaning if you disable all the search smarts, SF Elo is about 2300 to 2400 with its current evaluate.cpp).
Image
Joost Buijs
Posts: 1563
Joined: Thu Jul 16, 2009 10:47 am
Location: Almere, The Netherlands

Re: Null move test

Post by Joost Buijs »

In Nightmare the rule to allow nullmove is: at least one king-move plus a move with another piece (not a pawn) to a square that is not attacked by the opponent.

Nightmare does not solve Jons position either and goes for a repetition draw, it solves the position of John (Kf4) after 54 seconds at 33 ply with a score of > 3 pawns.

During the endgame moves with a knight to a corner get a very negative bonus of about -0.5 pawn (at least in Nightmare this is the case), it is very likely that variations starting with moves like these are pruned away a few plies later.