YZF_Sudoku

Programs which generate, solve, and analyze Sudoku puzzles

Re: YZF_Sudoku

Postby mith » Fri Aug 14, 2020 11:47 pm

Thanks, I actually am a programmer. :) On my (linux) system, it was failing to extract with the files separated, but actually concatenating the files first did the trick.
mith
 
Posts: 996
Joined: 14 July 2020

Re: YZF_Sudoku

Postby ghfick » Sat Aug 15, 2020 1:38 pm

I am unsure of your initial trouble. The downloaded files are separate. Why did you need concatenation?
ghfick
 
Posts: 233
Joined: 06 April 2016
Location: Calgary, Alberta, Canada youtube.com/@gordonfick

Re: YZF_Sudoku

Postby mith » Sat Aug 15, 2020 3:46 pm

What I'm saying is 7-zip was failing (for me) to run with the two part files. Concatenating them into a single 7z file worked for me.
mith
 
Posts: 996
Joined: 14 July 2020

Re: YZF_Sudoku

Postby ghfick » Mon Aug 17, 2020 5:48 pm

Tarek has taken me back to SE. Sometimes, SE gives explanations that help a lot. Take the recent puzzle with the Unique Loop.
SE says:
"The cells r3c4, r3c6, r9c6, r9c5, r4c5, r4c1, r5c1, r5c4 form a Unique Loop with the values 2 and 9. There are exactly two ways of placing the values 2 and 9 in the cells of the Unique Loop, forming two possible configurations. In both configurations, each row, column or block touched by the Unique Loop contains each of the two values 2 and 9 exactly once. As a result, if one of these two configurations were part of the solution, it could be replaced by the other one to get a second valid solution.
Because a valid sudoku cannot have more than one solution, none of the two configurations of the Unique Loop can be valid. This implies that either r4c5 or r4c1 contains one of the values 3 or 7. It follows that either r4c5 or r4c1 forms a Naked Triplet with r4c4 and r4c7 on the values 3,5 and 7 in the row.
Other potential positions of the values 3,5 and 7 can therefore be removed from the row."
The crucial part appears to be the sentence with 'touched by the Unique Loop'. For a Unique Rectangle, this requirement is clearly true. This would appear to be a necessary condition for any UL. I am still struggling as to whether it is indeed necessary.
I suppose a human solver might, in principle, be able to handle such a step but WOW. Not likely me any time soon.
Nicolas Juillerat seems to have left the Sudoku scene many years ago. He deserves our thanks for so many reasons.
ghfick
 
Posts: 233
Joined: 06 April 2016
Location: Calgary, Alberta, Canada youtube.com/@gordonfick

Re: YZF_Sudoku

Postby yzfwsf » Thu Sep 24, 2020 8:14 am

Grouped W-Wing was added.
Add middle level chains. I'm tentatively named contradiction fork AIC, the hint view can be cycled by press F4, or click in bottom text box to select Specified view.
Fix known bugs.

Version 612 release(A bug was found in @ mith's "potential hardenest" 4 test, so fix it and upload it again.)

Please download the two files at the same time and put them in the same directory, remove ". 7z" at the end of each file name, and then decompress them.
YZF_Sudoku612.7z.001.7z
(256 KiB) Downloaded 171 times
YZF_Sudoku612.7z.002.7z
(251.93 KiB) Downloaded 167 times
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: YZF_Sudoku

Postby Cenoman » Mon Sep 28, 2020 9:08 pm

Hi yzfwsf,
Tough puzzle on sudoku.com.au site, September 28, 2020
..83..41.7.............7.8..72..3...5...9...1...4..62..6.8.............6.23..95..
My solution:
Code: Select all
 +--------------------------+-------------------------+------------------------+
 |  269     59      8       |  3       256     26     |  4       1      7      |
 |  7       1345    145     |  1259    12458   1248   |  239     6      2359   |
 |  12346   1345    1456    |  12569   12456   7      |  239     8      2359   |
 +--------------------------+-------------------------+------------------------+
 |  4689    7       2       |  16      168     3      |  89      5      489    |
 |  5       348     46      |  26      9       268    |  378     347    1      |
 |  1389    1389    19      |  4       7       5      |  6       2      389    |
 +--------------------------+-------------------------+------------------------+
 |  149     6       14579   |  8       12345   124    |  1237    3479   234    |
 |  1489    14589   14579   |  1257    12345   124    |  12378   3479   6      |
 |  148     2       3       |  167     146     9      |  5       47     48     |
 +--------------------------+-------------------------+------------------------+

1. (9=186)r4c457 - a6 = (62-3)r13c1 = r6c1 - (3=489)r469c9 loop =>-9a1, -14a7, -3b4, -4i3, -8r4c19; singles to 81

Your solver proposes:
tough28092020.png
tough28092020.png (31.02 KiB) Viewed 1086 times

Almost Locked Set XY-Wing ,Triple Links: A=r4c457{1689}, B=r469c9{3489}, C=r46789c1{134689}, X,Y=6, 3, Z=9 => r6c2<>3 r7c9<>4 r3c1<>1 r3c1<>4 r1c1<>9

that could be written as the loop
(9=186)r4c457 - (6=14893)r46789c1 - (3=489)r469c9 loop => -3r6c2, -4 r7c9, -14r3c1, -9r1c1 (equivalent to mine, with ALS r46789c1 vs AHS r13c1)

This loop eliminates -8r4c19 also (from application of the process to the weak links internal to each ALS, here the WL 8r4c5 - 8r4c7) Does your solver misses it, or do you discard the cannibalistic eliminations for any reason ?

Hereafter, the pigeonhole matrix (PM) of the move. It is a symmetrical matrix, therefore any candidate in sight of one column is eliminated.
Hidden Text: Show
Code: Select all
 1r9c1 4r9c1 8r9c1
 1r8c1 4r8c1 8r8c1 9r8c1
 1r7c1 4r7c1       9r7c1
 1r6c1       8r6c1 9r6c1 3r6c1
       4r4c1 8r4c1 9r4c1       6r4c1
                               6r4c4 1r4c4
                               6r4c5 1r4c5 8r4c5
                                           8r4c6 9r4c6
                                                 9r4c9 4r4c9 8r4c9
                         3r6c9                   9r6c9       8r6c9
                                                       4r9c9 8r9c9
-----------------------------------------------------------------
-1r3c1 -4r3c1     -9r1c1 -3r6c2           -8r4c19     -4r7c9
Cenoman
Cenoman
 
Posts: 2993
Joined: 21 November 2016
Location: France

Re: YZF_Sudoku

Postby yzfwsf » Wed Sep 30, 2020 7:10 am

Fix the bug that Cenoman pointed out that ALS-XY-Wing did not handle Cannibalism correctly.
Rename the contradiction fork AIC to Cell Forcing Chain/Region ForcingChain to avoid confusion in naming and communication troubles.
Added UR Forcing Chain (Kraken UR).
You can configure whether to enable RC FC and UR FC, but RC FC is the precondition of UR FC.

Version 613 release.

Please download the two files at the same time and put them in the same directory, remove ". 7z" at the end of each file name, and then decompress them.
YZF_Sudoku613.7z.001.7z
(256 KiB) Downloaded 163 times
YZF_Sudoku613.7z.002.7z
(254.67 KiB) Downloaded 162 times
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: YZF_Sudoku

Postby yzfwsf » Wed Sep 30, 2020 7:15 am

@Cenoman FIx the bug,Tks.
ALS-XY-Wing-Fix.png
ALS-XY-Wing-Fix.png (37.06 KiB) Viewed 1066 times


UR Forcing Chain Example:
JE+RC FC+UR FC.png
JE+RC FC+UR FC.png (75.98 KiB) Viewed 1066 times


JE+RC FC+UR FC2.png
JE+RC FC+UR FC2.png (84.73 KiB) Viewed 1066 times
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: YZF_Sudoku

Postby SpAce » Fri Oct 02, 2020 12:32 am

Hi yzf,

yzfwsf wrote:Rename the contradiction fork AIC to Cell Forcing Chain/Region ForcingChain to avoid confusion in naming and communication troubles.

I don't like this naming. What you're describing is a contradiction chain, and I think it would be clearest to call it such (or Nishio). I don't think it makes any sense to call contradiction chains "forcing chains", even though some do.

Contradiction chains were not included in the original definition of forcing chains. It's unfortunate that some (including Hodoku and SudokuWiki) have confused the two concepts. The original forcing chain was what we now call Kraken and what Hodoku calls "Forcing Chain Verity". I have explained my reasoning in more detail here.

Added UR Forcing Chain (Kraken UR).

I think this is confusing concepts even more. The example you posted is clearly a contradiction chain -- not a Kraken! Krakens are always verity chains, never contradiction chains. I would prefer Krakens and Forcing Chains to be synonyms, which means that contradiction chains shouldn't be called forcing chains either. Definitely not krakens.

For me these are or should be synonyms:

Code: Select all
Kraken == Forcing Chain (Verity only)
Nishio == Contradiction Chain

I don't see any reason to confuse those terms with each other. It's bad for accurate communication. "Contradiction Chain" is an unambiguous term. Why not use that for chains that start with an assumption and end up with a contradiction? It's the simplest and the least confusing approach.
-SpAce-: Show
Code: Select all
   *             |    |               |    |    *
        *        |=()=|    /  _  \    |=()=|               *
            *    |    |   |-=( )=-|   |    |      *
     *                     \  ¯  /                   *   

"If one is to understand the great mystery, one must study all its aspects, not just the dogmatic narrow view of the Jedi."
User avatar
SpAce
 
Posts: 2671
Joined: 22 May 2017

Re: YZF_Sudoku

Postby yzfwsf » Fri Oct 02, 2020 1:20 am

SpAce wrote:Hi yzf,

yzfwsf wrote:Rename the contradiction fork AIC to Cell Forcing Chain/Region ForcingChain to avoid confusion in naming and communication troubles.

I don't like this naming. What you're describing is a contradiction chain, and I think it would be clearest to call it such (or Nishio). I don't think it makes any sense to call contradiction chains "forcing chains", even though some do.

Contradiction chains were not included in the original definition of forcing chains. It's unfortunate that some (including Hodoku and SudokuWiki) have confused the two concepts. The original forcing chain was what we now call Kraken and what Hodoku calls "Forcing Chain Verity". I have explained my reasoning in more detail here.

Added UR Forcing Chain (Kraken UR).

I think this is confusing concepts even more. The example you posted is clearly a contradiction chain -- not a Kraken! Krakens are always verity chains, never contradiction chains. I would prefer Krakens and Forcing Chains to be synonyms, which means that contradiction chains shouldn't be called forcing chains either. Definitely not krakens.

For me these are or should be synonyms:

Code: Select all
Kraken == Forcing Chain (Verity only)
Nishio == Contradiction Chain

I don't see any reason to confuse those terms with each other. It's bad for accurate communication. "Contradiction Chain" is an unambiguous term. Why not use that for chains that start with an assumption and end up with a contradiction? It's the simplest and the least confusing approach.

Since each branch chain is reversible, if you reverse each branch chain it will be a verity chain.
I didn't reverse the branches in order to save trouble. That's all. Do you agree with this explanation?
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: YZF_Sudoku

Postby SpAce » Fri Oct 02, 2020 1:43 am

yzfwsf wrote:Since each branch chain is reversible, if you reverse each branch chain it will be a verity chain.
I didn't reverse the branches in order to save trouble. That's all. Do you agree with this explanation?

Yes and no. I agree that they're reversible (Denis doesn't) but they're still very different beasts, both in theory and in practice. If you present something as a contradiction chain, it shouldn't be called a kraken, and vice versa. It's confusing and wrong. The reversal isn't always straight-forward either, which is why Hodoku doesn't present a verity option for all of its contradiction chains (if they'd require multi-krakens when reversed).

A big conceptual and practical difference is that the elimination is not part of a verity pattern -- it's a (potential) consequence of it. The pattern can exist and be recognized even if it doesn't have anything to eliminate. On the other hand, a contradiction pattern can't exist without the elimination being part of it, because it always starts with that assumption. Verity patterns can be found without assuming anything, which is one reason why they're considered more elegant.
User avatar
SpAce
 
Posts: 2671
Joined: 22 May 2017

Re: YZF_Sudoku

Postby yzfwsf » Fri Oct 02, 2020 5:55 am

For the sake of elegance (mentioned by SpAce), I decided to reissue version 613.
Please download the two files at the same time and put them in the same directory, remove ". 7z" at the end of each file name, and then decompress them.
YZF_Sudoku613.7z.001.7z
(256 KiB) Downloaded 161 times
YZF_Sudoku613.7z.002.7z
(255.79 KiB) Downloaded 167 times


Hidden Text: Show
UR FC.png
UR FC.png (35.73 KiB) Viewed 1027 times


UR Forcing Chain: Each true guardian of UR 68{r6c13,r7c13} will all lead r7c1<>6
(1-8)r6c1=(8-6)r7c1
(4-8)r6c1=(8-6)r7c1
(7-8)r6c1=(8-6)r7c1
2r6c3-r6c4=r3c4-(2=6)r3c1-6r7c1
4r6c3-(4=8)r4c3-r7c3=(8-6)r7c1
(3-8)r7c3=(8-6)r7c1
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: YZF_Sudoku

Postby ghfick » Fri Oct 09, 2020 12:17 am

I have been using the default .ini file for 613. I have noticed that 613 will give an AIC and miss an identical XY Chain [sometimes?].
Just recently, I came across a puzzle with a Dual Empty Rectangle. Of course 613, gives the two regular ERs. I think Duals are rare [but interesting!] Worth adding?
The contradiction chains are fascinating but I think that adding the various Krakens would be a good add. Maybe the code for them would slow things down?
ghfick
 
Posts: 233
Joined: 06 April 2016
Location: Calgary, Alberta, Canada youtube.com/@gordonfick

Re: YZF_Sudoku

Postby yzfwsf » Fri Oct 09, 2020 7:01 am

Fix the problem of program crash caused by search dynamic chain. The puzzles given in the link below will cause the program to crash if you use the Find All Possible Steps function at the beginning.
http://forum.enjoysudoku.com/a-great-disturbance-in-the-force-t38315.html
Fixed the problem that the address of starting cell in text prompt for kraken cell is wrong.

ghfick wrote:Just recently, I came across a puzzle with a Dual Empty Rectangle. Of course 613, gives the two regular ERs. I think Duals are rare [but interesting!] Worth adding?

Please tell me in detail, what is dual ER.

ghfick wrote:I have been using the default .ini file for 613. I have noticed that 613 will give an AIC and miss an identical XY Chain [sometimes?].

Please provide the puzzle that caused the problem, thank you.

ghfick wrote:The contradiction chains are fascinating but I think that adding the various Krakens would be a good add. Maybe the code for them would slow things down?

There are already kraken cell/kraken region/kraken UR in the program, let’s talk about which extra kraken you want to add.

613 release again
https://drive.google.com/file/d/12Fa7zUA9YNQ8rDT5oa11CFuPmZ2FFYcj/view?usp=sharing
yzfwsf
 
Posts: 921
Joined: 16 April 2019

Re: YZF_Sudoku

Postby ghfick » Fri Oct 09, 2020 7:17 pm

I give a screenshot of a Dual ER in the puzzles section of the forum.
I will get back to you on the other queries.
ghfick
 
Posts: 233
Joined: 06 April 2016
Location: Calgary, Alberta, Canada youtube.com/@gordonfick

PreviousNext

Return to Software