SudokuSolver icon indicating copy to clipboard operation
SudokuSolver copied to clipboard

Avoidable rectangle is applied even if there is no double solution

Open Kermalis opened this issue 4 years ago • 1 comments

The following puzzle (currently named Unsolved - Incorrect 1.txt in the repo):

1549-----
-----41--
-6-75---9
-1---8---
69---7-4-
--5----37
-8-----1-
----3--68
------5--

Avoidable rectangle is applied (because other techniques are not implemented yet) For now, it points out a flaw with my implementation of avoidable rectangle.

image

G4 should not be changed because G7 cannot be 6 and D7 cannot be 3. This means a double solution involving G4 is not possible, so the avoidable rectangle should not try to avoid it.

The technique needs to check if it would be a double solution if the three cells were swapped.

Kermalis avatar Oct 30 '20 12:10 Kermalis

This puzzle is now solved by XY-Chain, but the bug still applies if XY-Chain is disabled. It was renamed to XY-Chain (2).txt

Kermalis avatar Oct 30 '20 13:10 Kermalis