UR Type 1

Advanced methods and approaches for solving Sudoku puzzles

UR Type 1

Postby Nidomy » Wed Jun 30, 2021 12:10 pm

http://hodoku.sourceforge.net/en/tech_ur.php

I tried this technique with the first example, and it worked, but the reason it should work doesn't make sense to me.

The reasonning says that if you remove the 3 from the cell with the red 89, you will get two solutions, but it's not the case.
If you actually do it, you will get zero solutions, because every solution will lead to a contradiction.
I know that this technique is controversial, and maybe, it's because we have nothing to back it up theoretically.

And to me on the intuitive level it's a bit strange to think that if you add numbers to a starting grid you might get a new grid with more solutions.
To me the number of solutions can only decrease (stay the same or decrease, not strictly dicrease) in this case. Like, you might get from a grid
with one solution to a grid with zero solutions.
Nidomy
 
Posts: 1
Joined: 30 June 2021

Re: UR Type 1

Postby JasonLion-Admin » Wed Jun 30, 2021 5:13 pm

Nidomy wrote:The reasonning says that if you remove the 3 from the cell with the red 89, you will get two solutions, but it's not the case.
If you actually do it, you will get zero solutions, because every solution will lead to a contradiction.
I know that this technique is controversial, and maybe, it's because we have nothing to back it up theoretically.

All of the uniqueness techniques depend on the assumption that there is exactly one solution. The situation you describe can come up, but it violates this assumption, so the reasoning does not apply. The technique is valid and can be proven, but only if you make this assumption (not safe to do in the real world as many published puzzles have more than one solution).
User avatar
JasonLion-Admin
Site Admin
Site Admin
 
Posts: 89
Joined: 17 April 2010
Location: Silver Spring, MD, USA

Re: UR Type 1

Postby Mathimagics » Wed Jun 30, 2021 5:55 pm

Nidomy wrote:The reasoning says that if you remove the 3 from the cell with the red 89, you will get two solutions, but it's not the case.
If you actually do it, you will get zero solutions, because every solution will lead to a contradiction.

The reasoning really says that, with r2c2 = 89 (that is, 3 is removed), then either the puzzle has no solutions, or it has multiple solutions.

The fact that setting r2c2 = 8 or 9 actually leads to a contradiction in both cases, is simply evidence that this UR example is not a particularly good one.
User avatar
Mathimagics
2017 Supporter
 
Posts: 1926
Joined: 27 May 2015
Location: Canberra

Re: UR Type 1

Postby jco » Wed Jun 30, 2021 11:18 pm

Hello,
Mathimagics wrote:(...)
The fact that setting r2c2 = 8 or 9 actually leads to a contradiction in both cases, is simply evidence that this UR example is not a particularly good one.


A good example in this sense must come from a puzzle with more than one solution.
For a proper puzzle (having only one solution), if we ignore the pattern and perform only logically justified eliminations that pattern will be destroyed naturally in the resolution process (since the puzzle only admits one solution, that pattern can't be in the final configuration ... that would be a contradiction). If we force the pattern to stay at any stage of a proper puzzle, that would be possible only by performing a step along the way such that the only solution is no longer available (an incorrect step was performed). Again, if every step is logically correct, getting such pattern in the final configuration would contradict the fact that the puzzle was designed with one and only one solution. For a proper puzzle, we use the UR argument to get eliminations (i.e., knowing that the pattern is false, allows one to identify certain false candidates) that many times help solving quickly a proper puzzle. Of course the UR move isn't performed to avoid multiple solutions (that is impossible in a proper puzzle anyway).
The Sudoku book of Professor Jerry Janusz (mentioned in the books section) has a collection of puzzles (#193 up to #200) with multiple solutions, in the final chapter. One such example is discussed in the book for a puzzle with 5 solutions (at pp. 110-113 the author obtains 4 of them). The discussion on BUG in that book is also very good. I never tried to solve a puzzle with multiple solutions.

Edit: small improvements in the text.
JCO
jco
 
Posts: 764
Joined: 09 June 2020

Re: UR Type 1

Postby Pupp » Thu Jul 01, 2021 4:00 am

Nidomy wrote:http://hodoku.sourceforge.net/en/tech_ur.php

I tried this technique with the first example, and it worked, but the reason it should work doesn't make sense to me.

The reasonning says that if you remove the 3 from the cell with the red 89, you will get two solutions, but it's not the case.
If you actually do it, you will get zero solutions, because every solution will lead to a contradiction.
I know that this technique is controversial, and maybe, it's because we have nothing to back it up theoretically.

And to me on the intuitive level it's a bit strange to think that if you add numbers to a starting grid you might get a new grid with more solutions.
To me the number of solutions can only decrease (stay the same or decrease, not strictly dicrease) in this case. Like, you might get from a grid
with one solution to a grid with zero solutions.


Of course you would get zero solutions for the example puzzle if you removed the 3.
It was trying to say in a hypothetical puzzle that a improperly made puzzle, a rectangle with a pair of numbers, repeated four
times would mean it was not a good puzzle.

In a proper sudoku puzzle, it means you messed up earlier in the puzzle, paving the way for a symetrical rectangle, and the sudoku would be unsolvable without backtracking moves.
Pupp
 
Posts: 246
Joined: 18 October 2019

Re: UR Type 1

Postby marek stefanik » Tue Jul 06, 2021 3:54 pm

Hi Nidomy,

If we delete the 3, we will be left with two options: 8r2c2, 9r2c3, 9r6c2, 8r6c3 and 9r2c2, 8r2c3, 8r6c2, 9r6c3.
Since these two options don't affect anything else, any solution with one of them will lead to a solution with the other.

We are assuming that the sudoku is valid and therefore has exactly one solution.
If the solution contained the UR, we could simply swap the two options and get another one.
Therefore the solution does not contain the UR and we have to use the 3 to prevent it.

You can construct a puzzle with multiple solutions with the UR (without any guardians) and check how many solutions it has (for example using the 'Solution Count' button in Andrew's solver).
Half of them will use one option for the UR, half of them the other one.
Consequently, every puzzle with a UR has even number of solutions, whether it's 0, 2 or for example 42.
What we can say for sure, is that no valid puzzle can contain a UR.

Marek
marek stefanik
 
Posts: 360
Joined: 05 May 2021


Return to Advanced solving techniques