A "nice" challenge

Everything about Sudoku that doesn't fit in one of the other sections

A "nice" challenge

Postby Mike Barker » Sun Apr 02, 2006 1:47 am

Here’s a puzzle challenge which may already have been proposed. I recently coded up grouped nice loops in my solver. To check it out I made nice loops the highest priority after naked and hidden singles. I then ran 10000 randomly generated puzzles. The solver was able to find solutions to around 9950. What surprised me was that in addition to singles and nice loops only 1 hidden triple and 4 unique rectangles were used for all 9950 solutions. It turns out that most puzzles can be solved with nothing but singles and nice loops! So here’s the challenge: solve your favorite puzzle with nothing but singles and nice loops. I’m still a wanna-be nice guy so haven’t even tried yet, but here’s a computer solution for Carcul’s Nice loop Exercise #4. I’ve looked at some loops generated with this approach. After you do you may not think of me as such a nice guy. Again apologies to Carcul for notation, I use “~” to identify discontinuous nice loops and don’t show the complete loop or all of the exclusions. (It’s on my to-do list)
Code: Select all
 2 3 . | 5 4 . | 9 . 8
9 4 . | . . . | . . 3
1 8 . | 9 . . | . 4 .
-------+-------+-------
. 5 4 | . 1 . | 8 9 .
. 9 3 | 8 . 4 | 5 . 1
8 2 1 | 7 9 5 | 3 6 4
-------+-------+-------
3 1 . | 4 . . | . 8 .
4 6 . | . . . | . . 9
5 7 . | 2 . . | 4 . 6


Nice Loop: r1c6=1=r1c8-1-r2c7=1=r8c7~1~ => r8c6<>1
Nice Loop: r1c6=1=r1c8-1-r9c8=1=r9c6-1-r1c6 => r2c8<>1
Nice Loop: r9c6=1=r9c8=3=r8c8-3-r8c4-1-r9c6 => r8c5<>3
Nice Loop: r3c5=3=r3c6-3-r4c6=3=r4c4=6=r2c4~6~r3c5 => r3c5<>6
Nice Loop: r3c6=3=r3c5-3-r9c5-8-r8c6~7~r3c6 => r3c6<>7
Nice Loop: r8c8=3=r8c4-3-r9c5-8-r8c6~7~r8c8 => r8c8<>7
Nice Loop: r8c5=5=r8c8=3=r8c4-3-r9c5~8~r8c5 => r8c5<>8
Nice Loop: r1c6=1=r1c8-1-r9c8-3-r9c5-8-r8c6~7~r1c6 => r1c6<>7
Nice Loop: r2c4-6-r1c6-1-r2c4 => r2c5<>6
Nice Loop: r2c5=8=r9c5=3=r3c5-3-r3c6~2~r2c5 => r2c5<>2
Nice Loop: r4c9=2=r4c6-2-r5c5=2=r3c5~2~ => r3c9<>2
Nice Loop: r2c3=5=r3c3-5-r3c9-7-r1c8=7=r1c3~7~r2c3 => r2c3<>7
Nice Loop: r8c5-5-r7c5=5=r7c9-5-r3c9~7~ => r3c5<>7
Nice Loop: r3c5-3-r3c6-2-r3c5 => r3c7<>2
Nice Loop: r2c5-8-r2c6-7-r2c5 => r2c7<>7
Nice Loop: r2c6-8-r8c6-7-r2c6 => r9c6<>8
Nice Loop: r1c8=1=r2c7=2=r2c8-2-r5c8~7~r1c8 => r1c8<>7
The Solution is completed with just singles.
Mike Barker
 
Posts: 458
Joined: 22 January 2006

Postby Carcul » Thu Apr 06, 2006 2:23 pm

Hi Mike Barker.

Mike Barker wrote:It turns out that most puzzles can be solved with nothing but singles and nice loops!


I am shure you are aware that there are many puzzles that cannot be solved with only singles and nice loops (unfortunately:D ).

Mike Barker wrote:...but here’s a computer solution for Carcul’s Nice loop Exercise #4.


Very good. Only two comments: 1) try to solve that puzzle (and the others) just by hand; 2) exercise 4 can be solved with half the loops your program has used.

Mike Barker wrote:Again apologies to Carcul for notation,...


You don't need to apologize: if you feel more confortable with that notation then please use it, as long as you explain its meaning.

Regards, Carcul
Carcul
 
Posts: 724
Joined: 04 November 2005

Postby ravel » Fri Apr 07, 2006 10:20 am

Carcul wrote:I am shure you are aware that there are many puzzles that cannot be solved with only singles and nice loops (unfortunately:D ).
Carcul

It would be a pity, if you could solve all puzzles with nice loops (i am sure you can with SINs).
Just the fact you cant, gives sudokus this big complexity and also much of the appeal for manual solutions.
ravel
 
Posts: 998
Joined: 21 February 2006

Re: A "nice" challenge

Postby ronk » Fri Apr 07, 2006 11:39 am

Mike Barker wrote:I use “~” to identify discontinuous nice loops and don’t show the complete loop or all of the exclusions. (It’s on my to-do list)

Good show, Mike. Just a thought: You should be able to cut down on the number of solution steps by "focusing" on exclusions at bivalues and at bilocations. For the latter, the longer the bilocation chain the better, I think.

P.S. Of your to-do items, I'd recommend giving priority to showing all the exclusions.
ronk
2012 Supporter
 
Posts: 4764
Joined: 02 November 2005
Location: Southeastern USA


Return to General