Big fish

Advanced methods and approaches for solving Sudoku puzzles

Big fish

Postby vidarino » Mon Mar 13, 2006 1:23 am

I finally got around to adding support for finned fish to my solver, and couldn't resist experimenting with large sizes. As far as I know, these finned beasts don't have an unfinned counterpart.

N=6
Code: Select all
  1368    37  1368 |     38     4  1356 |   3567-    2     9
    89     4     2 |     89  3567* 3567*|      1    56#   35
  1369*  379     5 |   2369*  236* 1236*|    367*    4     8
-------------------+--------------------+--------------------
    36*    5     7 |     36*    1     4 |      9     8     2
     2     1    36 |      7     9     8 |      4    56   356
     4     8     9 |      5   236*  236*|     36*    7     1
-------------------+--------------------+--------------------
     7    39    13 |    246*    8   256*|     56*   19   456*
     5     2     4 |      1    67*    9 |      8     3    67*
   189     6    18 |     34   357   357 |      2    19   457
 
Finned Whale with 6 in R234678C145679 + fin R2C8
   -> R1C7 <> 6


N=7
Code: Select all
   257     9     3 |     14    14    25 |   2578*   28*    6
     4    28    57 |     28#    9     6 |    357    35     1
     6     1   258*|      7    38* 2358-|    259     4    59
-------------------+--------------------+--------------------
    28*    7     1 |      9     5     4 |     28*    6     3
    59    48     6 |      3     2    78 |      1    59    47
 23589* 2348   259 |      6    78*    1 |     59    28*   47 
-------------------+--------------------+--------------------
     1     6   249 |   2458*  348*  238 |    359     7   589*
   378*   38    78*|     15     6     9 |      4    15     2
    29     5   249 |   1248*13478*   37 |      6   139    89*
   
Finned Leviathan with 8 in R1346789C1345789 + fin R2C4
   -> R3C6 <> 8


I had to invent new names for them. (I was a bit reluctant to call the first one a Whale, since, well, it's not a fish, and calling it food might also be politically incorrect. But then again, Jellyfish and Squirmbags(!?) aren't fish or food either. Not where I come from, at least.):)

These are obviously absolutely impossible to spot for a human solver.

It was a bit intriguing to actually find beasts of these sizes. I did a quick scan for N=8, but I didn't find any - which is good, since I've used up all the good names. And I'm pretty sure there aren't any of size 9, since they would cover the whole grid. ;-)

Vidar
vidarino
 
Posts: 295
Joined: 02 January 2006

Postby tarek » Mon Mar 13, 2006 1:55 am

They are valid Vidar, but are they needed?
First example
Code: Select all
*--------------------------------------------------------*
| 1368  37   *1368 | 38    4     1356 |-3567 *2     9    |
| 89    4     2    | 89    3567  3567 | 1    #56    35   |
| 1369  379   5    | 2369  236   1236 | 367   4     8    |
|------------------+------------------+------------------|
| 36    5     7    | 36    1     4    | 9     8     2    |
| 2     1    *36   | 7     9     8    | 4    *56    356  |
| 4     8     9    | 5     236   236  | 36    7     1    |
|------------------+------------------+------------------|
| 7     39    13   | 246   8     256  | 56    19    456  |
| 5     2     4    | 1     67    9    | 8     3     67   |
| 189   6     18   | 34    357   357  | 2     19    457  |
*--------------------------------------------------------*
Eliminating 6 From r1c7 (Finned XWing in Columns 38)

Second example:
Code: Select all
*-----------------------------------------------------------------*
| 257    9      3     | 14     14     25    | 2578   28     6     |
| 4     *28     57    |#28     9     *6     | 357    35     1     |
| 6      1      258   | 7      38    -2358  | 259    4      59    |
|---------------------+---------------------+---------------------|
| 28     7      1     | 9      5      4     | 28     6      3     |
| 59    *48     6     | 3      2     *78    | 1      59     47    |
| 23589  2348   259   | 6      78     1     | 59     28     47    |
|---------------------+---------------------+---------------------|
| 1      6      249   | 2458   348    238   | 359    7      589   |
| 378    38     78    | 15     6      9     | 4      15     2     |
| 29     5      249   | 1248   13478  37    | 6      139    89    |
*-----------------------------------------------------------------*
Eliminating 8 From r3c6 (Finned XWing in rows 25)

I haven't seen a pure squirmbag to date, I've seen the pure Jellyfish (one by mike barker recently was awesome), I don't think we'll need bigger fish in a 9*9 grid

Tarek
User avatar
tarek
 
Posts: 2644
Joined: 05 January 2006

Postby vidarino » Mon Mar 13, 2006 9:08 am

Hmm, both of your Finned X-Wings appear to be Sashimi X-Wings, as far as I can see... You had me worried that my fin detection function was messed up there for a moment.:) (I guess this proves it's time to add Sashimi to the mix...)

Anyway, no, they most certainly are not needed. It would probably be easier to mentally build a bivalue/bilocation plot than to hunt for these beasts manually. My post was primarily done for entertainment purposes. ;-)

I haven't seen a pure squirmbag to date, I've seen the pure Jellyfish (one by mike barker recently was awesome), I don't think we'll need bigger fish in a 9*9 grid


Most likely true, but while a genuine Squirmbag never will be found (since it would have a smaller order counterpart), the fin (or "skewed" cell for Sashimis) makes me wonder if such a counterpart readily exists.

Vidar
vidarino
 
Posts: 295
Joined: 02 January 2006

Postby vidarino » Mon Mar 13, 2006 10:26 am

Allrighty then, how about this?

Code: Select all
 2    *7    *9     |  6    *58   *58    | *4     3    *1   
 3    *6    *45    |  2    *47   *1     | *9     58   *578 
 45    8     1     |  47    9     3     |  67    56    2   
-------------------+--------------------+--------------------
 6    *2    *3     |  458  *45   *7     | *15    19   *589 
 9    *15   *78    |  1358 *13   *6     | *2     4    *57   
 15    4     78    |  158   2     9     |  67    568   3   
-------------------+--------------------+--------------------
 8    #59    6     |  57    17    2     |  3     19    4   
-145  *1359 *2     |  135  *6    *45    | *8     7    *59   
 7    *13   *45    |  9    *138  *458   | *15    2    *6   

Finned Whale with 5 in R124589C235679 + fin R7C2
   -> R8C1 <> 5


And I repeat, I know it's not a needed technique at all. Now I'm just attempting
to show that there can exist finned or sashimi variations of high order fish.:)

Vidar

Edit: Since the above can be solved with a simple XY-Wing, here is a real Finned Squirmbag without (as far as I can tell) a simpler counterpart;
Code: Select all
 2       159    *1579    | *8      *1367    4       | #167    *379    *13679 
 4       3      *17      | *167    *9       2       |  5      *8      *167   
 78      189     6       |  157     137     357     |  4       2      -1379   
-------------------------+--------------------------+--------------------------
 568     45689   2589    |  124679  12367   367     |  167     34579   13569 
 56      7       259     |  12469   1236    36      |  16      3459    8     
 1       469    *3       | *4679   *5       8       |  2      *479    *679   
-------------------------+--------------------------+--------------------------
 5678    568     578     |  3       4       567     |  9       1       2     
 9       2      *4       | *57     *8       1       |  3      *6      *57     
 3       156    *157     | *2567   *267     9       |  8      *57     *4     

Finned Squirmbag with 7 in R12689C34589 + fin R1C7
   -> R3C9 <> 7


Edit 2: And I'll be darned, a Whale too.:)

Code: Select all
*4    *2    *58    | *7     6    *58    |  9     3    *1   
 7     89    389   |  458   358   1     |  56    2    -456 
*1    *35   *6     | *2345  9    *24    |  7    #58   *48   
-------------------+--------------------+--------------------
 3568  3468  7     |  2345  358   24    |  1     58    9   
*358  *1    *89    | *3589  7    *358   |  26    4    *26   
*58   *49   *2     | *49    1    *6     |  3     7    *58   
-------------------+--------------------+--------------------
*368  *3568 *1     | *358   2    *358   |  4     9    *7   
*2    *7    *35    | *6     4    *9     |  8     1    *35   
 9     358   4     |  1     358   7     |  25    6     235 

Finned Whale with 5 in R135678C123469 + fin R3C8
   -> R2C9 <> 5
vidarino
 
Posts: 295
Joined: 02 January 2006

Postby tarek » Mon Mar 13, 2006 12:55 pm

Hi Vidar,

At first glance I thought that they were valid, but because my solver should have caught the Squirmbag (which it didn't:( ) I studied the matter more closely)......

Vertices are fine.......

Eliminated cell can see both Fin & vertix & all in same box...

The fin's row has the vertices......

The fin's column........hmmmm [oops I need to edit this phrase, as the fin's column is actually candidate free]...........

The finned squirmbag now look vey valid to me (pending 1 further check), & I need to go back & check my solver:D

The whale though has a lesser fish with it.

Good catch Vidar


Tarek
Last edited by tarek on Mon Mar 13, 2006 9:36 am, edited 2 times in total.
User avatar
tarek
 
Posts: 2644
Joined: 05 January 2006

Postby tarek » Mon Mar 13, 2006 1:18 pm

As for the naming, I suggest:

n=5, Starfish instead of Squirmbag
n=6, Seksfish:D (You can't object on this one Vidar)
n=7 Dogfish (7 letters)
n=8 Octupus
n=9 Enniafish
n=10 Hammerhead (10 letters) or Whaleshark

Tarek
User avatar
tarek
 
Posts: 2644
Joined: 05 January 2006

Postby aeb » Mon Mar 13, 2006 1:26 pm

vidarino wrote:And I repeat, I know it's not a needed technique at all.

Edit 2: And I'll be darned, a Whale too.:)

Code: Select all
*4    *2    *58    | *7     6    *58    |  9     3    *1   
 7     89    389   |  458   358   1     |  56    2    -456 
*1    *35   *6     | *2345  9    *24    |  7    #58   *48   
-------------------+--------------------+--------------------
 3568  3468  7     |  2345  358   24    |  1     58    9   
*358  *1    *89    | *3589  7    *358   |  26    4    *26   
*58   *49   *2     | *49    1    *6     |  3     7    *58   
-------------------+--------------------+--------------------
*368  *3568 *1     | *358   2    *358   |  4     9    *7   
*2    *7    *35    | *6     4    *9     |  8     1    *35   
 9     358   4     |  1     358   7     |  25    6     235 

Finned Whale with 5 in R135678C123469 + fin R3C8
   -> R2C9 <> 5

Hmm. What is the argument with al these fish? One assumes one digit value d and then observes that all occurrences of d in a set of N rows do occur in a set of N-1 columns (or vice versa), which is impossible.
For example, in this Whale, assuming (2,9)5 one sees that all occurrences of 5 in rows 1,3,5,6,7,8 are in columns 1,2,3,4,6. But entirely equivalent is the statement that all occurrences of 5 in columns 5,7,8 are in rows 4,9 (always assuming (2,9)5).
So a finned Whale is the same thing as a finned Swordfish.
aeb
 
Posts: 83
Joined: 29 January 2006

Postby vidarino » Mon Mar 13, 2006 1:31 pm

tarek wrote:The fin's column........hmmmm [oops I need to edit this phrase, as the fin's column is actually candidate free]...........


No, I don't think it needs to be.

Look at it this way; if the fin did not have the candidate, we would have a plain old N-fish, which would zap the target cell. If the fin cell is the right spot for the candidate, it would still zap the target since they're in the same box.
vidarino
 
Posts: 295
Joined: 02 January 2006

Postby tarek » Mon Mar 13, 2006 1:33 pm

You are right aeb,

Code: Select all
*--------------------------------------------------------*
| 4     2     58   | 7     6     58   | 9     3     1    |
| 7     89    389  | 458  *358   1    |*56   *2    -456  |
| 1     35    6    | 2345  9     24   | 7    #58    48   |
|------------------+------------------+------------------|
| 3568  3468  7    | 2345 *358   24   | 1    *58    9    |
| 358   1     89   | 3589  7     358  | 26    4     26   |
| 58    49    2    | 49    1     6    | 3     7     58   |
|------------------+------------------+------------------|
| 368   3568  1    | 358   2     358  | 4     9     7    |
| 2     7     35   | 6     4     9    | 8     1     35   |
| 9     358   4    | 1    *358   7    |*25    6     235  |
*-------------------------------------------------------*
Eliminating 5 From r2c9 (Finned Swordfish in Columns 578)


Tarek
User avatar
tarek
 
Posts: 2644
Joined: 05 January 2006

Postby vidarino » Mon Mar 13, 2006 1:41 pm

aeb wrote:But entirely equivalent is the statement that all occurrences of 5 in columns 5,7,8 are in rows 4,9 (always assuming (2,9)5).
So a finned Whale is the same thing as a finned Swordfish.


Hrm, darn it to heck, you're right... I wonder why my solver didn't see that swordfish. I'll fix it and get back to you.:)
vidarino
 
Posts: 295
Joined: 02 January 2006

Postby Havard » Mon Mar 13, 2006 1:52 pm

vidarino wrote:Edit: Since the above can be solved with a simple XY-Wing, here is a real Finned Squirmbag without (as far as I can tell) a simpler counterpart;
Code: Select all
 2       159    *1579    | *8      *1367    4       | #167    *379    *13679 
 4       3      *17      | *167    *9       2       |  5      *8      *167   
 78      189     6       |  157     137     357     |  4       2      -1379   
-------------------------+--------------------------+--------------------------
 568     45689   2589    |  124679  12367   367     |  167     34579   13569 
 56      7       259     |  12469   1236    36      |  16      3459    8     
 1       469    *3       | *4679   *5       8       |  2      *479    *679   
-------------------------+--------------------------+--------------------------
 5678    568     578     |  3       4       567     |  9       1       2     
 9       2      *4       | *57     *8       1       |  3      *6      *57     
 3       156    *157     | *2567   *267     9       |  8      *57     *4     

Finned Squirmbag with 7 in R12689C34589 + fin R1C7
   -> R3C9 <> 7


Here is the simpler counterpart:
Code: Select all
. . . | . . . | 7 . .
. . . | . . . | | . .
7 . . | . . 7 | | . *
|-----+-----|-+-|----
| . . | . . 7 | 7 . .
| . . | . . | | . . .
| . . | . . | | . . .
|-----+-----|-+------
7 . . | . . 7 | . . .
. . . | . . . | . . .
. . . | . . . | . . .


and your whale:
Code: Select all
*4    *2    *58    | *7     6    *58    |  9     3    *1   
 7     89    389   |  458   358   1     |  56    2    -456 
*1    *35   *6     | *2345  9    *24    |  7    #58   *48   
-------------------+--------------------+--------------------
 3568  3468  7     |  2345  358   24    |  1     58    9   
*358  *1    *89    | *3589  7    *358   |  26    4    *26   
*58   *49   *2     | *49    1    *6     |  3     7    *58   
-------------------+--------------------+--------------------
*368  *3568 *1     | *358   2    *358   |  4     9    *7   
*2    *7    *35    | *6     4    *9     |  8     1    *35   
 9     358   4     |  1     358   7     |  25    6     235 

Finned Whale with 5 in R135678C123469 + fin R3C8
   -> R2C9 <> 5


has this much easier pattern:
Code: Select all
. . 5-------5 | . . .
. . . | * * . | 5 . .
. . . | . . . | | . .
------+-------+-|----
. . . | . . . | | . .
. . . | . . . | | . .
. . . | . . . | | . .
------+-------+-|----
. . . | . . . | | . .
. . 5-----------+---5
. . . | . . . | 5 . .

And that solves the puzzle. (your whale don't)

havard
Havard
 
Posts: 377
Joined: 25 December 2005

Postby vidarino » Mon Mar 13, 2006 2:08 pm

Drat. I stand corrected. And before anyone asks, I will repeat again that I didn't believe for a second that these patterns helped solving in any way. I just merely looking for high-order N-fish that didn't have a smaller counterpart. My stance on the subject is wavering badly right now, though. ;-)

Anyway, my solver has now been fixed, and the search for big fish continues.

Here's one more for you all to scrutinize;

Code: Select all
 7      456    346    |  45     2      8      |  36     9      1     
 8      9      23     |  67     67     1      |  23     5      4     
*56     1     *2456   |  9     *45    *3      |  268    7     *28   
----------------------+-----------------------+-----------------------
 2      3456   8      |  356    1      9      |  45     46     7     
*56     34567 *9      |  367   *8     *47     |  1245   146   *25   
*1      467   *4567   |  2     *567   *457    |  9      8     *3     
----------------------+-----------------------+-----------------------
*3      578   *57     | -1457  *457   *6      |  14578  2     *9     
 4      2      1      |  8      9     #57     |  57     3      6     
*9      5678  *567    | -1457  *3     *2      |  14578  14    *58   

Finned Squirmbag with 5 in R35679C13569 + fin R8C6
   -> R7C4 <> 5
   -> R9C4 <> 5


(And yes, I know multi-coloring / an X-cycle can zap the one in R9C4. Possibly the other one, too, but I haven't studied it. (Actually, the whole thing can be solved just by cracking the 5s.:) ) )

Vidar
vidarino
 
Posts: 295
Joined: 02 January 2006

Postby vidarino » Mon Mar 13, 2006 2:16 pm

tarek wrote:I think I discovered where the bug is in my solver.........it can't identify the pattern where the fin is next to 2 Vertices.


Good to hear. I found mine, too. In my paranoia, I had some code that verified that the fish was really a valid fish if the fin cells were disregarded. Obviously, this test was messed up, since it threw away a lot of perfectly valid bits of fish.

So, if nothing else, this thread has been a great way to give my solver a run for its money.:)

Vidar
vidarino
 
Posts: 295
Joined: 02 January 2006

Postby tarek » Mon Mar 13, 2006 2:24 pm

I think it needs some more Vidar,

Code: Select all
*-----------------------------------------------------------------*
| 7     *456    346   |*45     2      8     | 36     9      1     |
| 8      9      23    | 67     67     1     | 23     5      4     |
| 56     1      2456  | 9      45     3     | 268    7      28    |
|---------------------+---------------------+---------------------|
| 2     *3456   8     |*356    1      9     |*45     46     7     |
| 56     34567  9     | 367    8      47    | 1245   146    25    |
| 1      467    4567  | 2      567    457   | 9      8      3     |
|---------------------+---------------------+---------------------|
| 3      578    57    |-1457   457    6     | 14578  2      9     |
| 4      2      1     |*8      9     #57    |*57     3      6     |
| 9      5678   567   |-1457   3      2     | 14578  14     58    |
*-----------------------------------------------------------------*
Eliminating 5 From r7c4 (Finned Swordfish in rows 148)
Eliminating 5 From r9c4 (Finned Swordfish in rows 148)


This one had one vertix in the box, so my solver caught it

Tarek
User avatar
tarek
 
Posts: 2644
Joined: 05 January 2006

Postby vidarino » Mon Mar 13, 2006 2:28 pm

tarek wrote:This one had one vertix in the box, so my solver caught itTarek


Oh bugger. I commented out the bits that calculate the new bitmasks, but not the line that actually tested it. So now it was testing against an unset variable. Geh.

Fixed, and the hunt continues... ;-)

Vidar
vidarino
 
Posts: 295
Joined: 02 January 2006

Next

Return to Advanced solving techniques