Main Page - Back
 
From SudokuWiki.org, the puzzle solver's site
breakline

Rectangle Elimination

Released 14th Oct 2023

This is the first novel 'tough' strategy in a long time and replaces Empty Rectangles which I feel is an overly complicated pattern. Ken Reek from Denver, USA, sent me his explanation and it is included in his solver SudoKoach. I think it sufficiently distinct to warrant its own test and go near the start. The pattern can also be expressed with AICs usually with at least one grouped cell. For those curious I've kept the Empty Rectangle test on the solver so you can go back a step, untick Rectangle Elimination and compare.

Comments welcome.

I will use the original puzzle Ken sent to me to illustrate his pattern.

The pattern works on a single number - in this case 9.

Rectangle Elimination 1
Rectangle Elimination 1 : Load Example

The base of the pattern consists of a Hinge cell G2 connected to the one remaining 9 in the row (or column), in this case G6. This part has to be a strong either/or link. First 'wing' cell in orange.

From the hinge G2 we look for another 9 in the opposite orientation (the column) and in a different box that is weakly linked - more than two 9s in the unit. The second 'wing' cell.

Consider the weakly-linked A2. If it's ON, then the other wing cell G6 must also be ON. However, this would eliminate ALL the 9s in the 'fourth corner box' (box 2, which is the fourth corner of the rectangle). So A2 cannot be ON, i.e. we can eliminate 9 as a possibility from A2. Simple as.
Rectangle Elimination 2
Rectangle Elimination 2


So it turns out there is a second Rectangle Elimination at this stage of the puzzle and my solver finds it before Ken's one - just because of the way I search for the hinge first and go from top-left to bottom-right.

If the 9 in F2 was ON it would remove the 9 in G2 - AND - it would turn OFF the 9 in F4 and turn ON the 9 in J4 - eliminating the 9 in J1.

Since we can't remove all the 9s in box 7 we have a contradiction assuming 9 in F2 can be a solution.

Double Rectangle Elimination

Double Rectangle Elimination
Double Rectangle Elimination : Load Example or : From the Start
The solver can identify more than one candidate in the same pattern as shown here. The results will be
If +1[B8] then -1[D8] forcing +1[D1] which removes all 1s from box 1, so B8 cannot be 1
If +2[B8] then -2[D8] forcing +2[D1] which removes all 2s from box 1, so B8 cannot be 2

To show how this is also an Empty Rectangle I've displayed the pattern here.

Grouped X-Cycle
1 taken off B8. ERI=B1 + strong link on 1 between D1 and D8.
2 taken off B8. ERI=B1 + strong link on 2 between D1 and D8.


And to show how these are often expressible as Nice Loops I show that pattern here

Grouped X-Cycle
X-CYCLE on 1 - Discontinuous Alternating Nice Loop, length 6):

+1[B8]-1[D8]+1[D1]-1[A1]+1[B2|B3]-1[B8]
- Contradiction: When B8 is set to 1 the chain implies it cannot be 1 - it can be removed

Two Strong Links

Two strong links example
Two strong links example : Load Example or : From the Start

Another kind of double Rectangle Elimination is when both links are strong.
In this case the solver will return

If either +5[B7] or +5[E2] are ON then both are on because they are strongly linked through the hinge cell B2. If both are ON then this removes all 5s from box 6, so neither can be 5

This kind I find to be much, much rarer.

Note: The solver will always alternative strong/weak in a chain and draw the lines that way since it represents ON/OFF/ON etc. See here.

To give it's Nice Loop definition we have to use quite a complicated chain. It also works but discovering that B2 must be the solution rather than finding the wings are not. Two sides of the same coin but proves Rectangle Elimination is an easier pattern to find for a human.

X-CYCLE on 5 - Discontinuous Alternating Nice Loop, length 6):
-5[B2]+5[E2]-5[E7|E9]+5[F7]-5[B7]+5[B2]
- Contradiction: When 5 is removed from B2 the chain implies it must be 5 - other candidates 6 can be removed

This strategy is patched into the online solver - I have run tests to check my code and see how widespread it is. I intent to place it between Y-Wings and Swordfish. On testing Ruuds top 50k test set I find 35,826 instances across 23,885 puzzles, so very high - but that is partly due to being at the front of the queue. I also found a small bug in the Empty Rectangles getting more instances, but that is moot now.

Exemplars

These puzzles have the most Rectangle Eliminations while still being less than or equal to diabolicals.
They make good practice puzzles.

Go back to Y-Wing StrategyContinue to SwordFish Strategy


Article created on 7-October-2023. Views: 26441
This page was last modified on 23-October-2023.
All text is copyright and for personal use only but may be reproduced with the permission of the author.
Copyright Andrew Stuart @ Syndicated Puzzles, Privacy, 2007-2024