Difficulty question

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

Difficulty question

Postby Pupp » Tue Sep 15, 2020 4:11 am

Does anybody know exactly what the mechanics are that apps use to rate a sudoku puzzle?

I whipped through a puzzle that SE rated 5.5 and said had a WXYZ wing. I solved it with a couple of back to back skyscrapers and didn't use a WXYZ-Wing. I thought the puzzle wouldn't rate over 4.2, but it was rated 5.5,and I was curious why it was rated so high. I also solved the puzzle in 11:38. That's a new best at the Fiendish 1 level, although the app I use, Sudoku 10000 Plus, has wildly varying difficulties at the Fiendish Range, anywhere from 4.2 to over 6.5.

Over all, other than pair of skyscrapers, I didn't see a single technique that was even 4.0 level. Puzzles with a single skyscraper were showing up before 4.0 range, if i recall.
I'm deliberately not posting the puzzle, because it's not really the point of the thread.
I'm not asking specifically how Sudoku Explorer rates puzzles, but just in a general sense what's the difference between a 4.5 and a 5.5 puzzle, when they both seem to have very little difference in actual difficulty.

Analysis results
Difficulty rating: 5.5 (WXYZ-Wing 126)
This Sudoku can be solved using the following logical methods:
48 x Hidden Single
1 x Pointing
2 x Claiming
1 x WXYZ-Wing 126
The most difficult technique (ER): WXYZ-Wing 126
Pupp
 
Posts: 128
Joined: 18 October 2019

Re: Difficulty question

Postby mith » Tue Sep 15, 2020 5:12 pm

SE applies the easiest technique available at each step (in batch mode, I think it applies all techniques of the same type together, perhaps, but that doesn't matter here). If SE didn't find a skyscraper, that suggests one of two things:

1. You are rating in 1.2.1 mode (in which case it won't find skyscrapers - they'll be included as Turbot Fish with a rating around 6.6, I believe, so it will find the WXYZ first).
2. There isn't actually a skyscraper, and the technique you used was something more complicated or in error.

https://github.com/SudokuMonster/Sukaku ... ner-v1.2.1
https://github.com/SudokuMonster/Sukaku ... er-v1.17.8

One thing worth noting is that if you are in 1.2.1 mode and switch back to 1.17.8 mode, it will not enable any new techniques; you'll have to either enable them manually or close SE and restart it after switch modes.
mith
 
Posts: 225
Joined: 14 July 2020

Re: Difficulty question

Postby Pupp » Tue Sep 15, 2020 8:02 pm

It's irrelevant if SE found a skyscraper or not. It's algorithm is designed to work a certain way. Some other app is just as likely to find the skyscraper and not the WXYZ-Wing, or find some other solution.

The question is just a general inquirer into how any app (SE or some other), decides the difference between levels. It could level 3.0 to 3.9 -vs- a puzzle in the 4.0 to 4.9 range, or is could be 2.0 to 2.9 -vs- 3.0 to 3.9, or some other other even high number combination like 5.0 to 5.9 -vs- 6.0 to 6.0.

The main stipulation is that the puzzles are about one apart. (That is you be comparing a puzzle say 4.2 vs a puzzle rated 5.2 with similar techniques.) So there is the fact that you have to compare puzzles with similar solving techniques in order to get a decent comparison. But like I said, this is a general question so specific examples aren't really needed for the thread.
Pupp
 
Posts: 128
Joined: 18 October 2019

Re: Difficulty question

Postby mith » Tue Sep 15, 2020 8:25 pm

The rating level for each technique is coded into whatever rating tool you're using. The links I gave in my previous post show specifically what ranges correspond to what techniques for SE (1.2.1 or the current 1.17.8).

It should be obvious just from playing around with any two different solvers, but different solvers rate techniques differently, and apply techniques in different orders. (And apart from SE, most solvers give a total rating that takes into account all techniques used, not just the "hardest".) The exact scores used are somewhat arbitrary. In the case of the Skyscraper, it was not included as a separate technique in 1.2.1 so it shows up with a rating of 6.6, but in the current SE it has a rating of 4.0 (4.3 for grouped?). So you'll find puzzles rated 6.6 (or even higher) by SE 1.2.1 that would currently be rated 4.0, and some rated 6.6 that are still rated the same.

See revision-of-se-ratings-and-resolution-rules-t36376.html for example for discussion of revising the SE ratings - you may be able to get more of the information you're looking for there. The ratings aren't totally arbitrary of course, but IMO are more useful comparing techniques of the same "type" (for example, X-Wing is 3.2, Swordfish is 3.8, Jellyfish is 5.2; or 2-strong-links techniques like Skyscrapers are 4.0-4.3, 3-strong-links are 5.4-5.7, 4-strong-links are 5.8-6.1, etc.), rather than between types (whether a Swordfish is "harder" than a Skyscraper is a matter of opinion and depends on the solver).
mith
 
Posts: 225
Joined: 14 July 2020

Re: Difficulty question

Postby Pupp » Tue Sep 15, 2020 9:42 pm

Ahh, ok, thanks. That's interesting
Pupp
 
Posts: 128
Joined: 18 October 2019

Re: Difficulty question

Postby Pupp » Tue Sep 15, 2020 11:38 pm

mith wrote:SE applies the easiest technique available at each step (in batch mode, I think it applies all techniques of the same type together, perhaps, but that doesn't matter here). If SE didn't find a skyscraper, that suggests one of two things:

1. You are rating in 1.2.1 mode (in which case it won't find skyscrapers - they'll be included as Turbot Fish with a rating around 6.6, I believe, so it will find the WXYZ first).
2. There isn't actually a skyscraper, and the technique you used was something more complicated or in error.

https://github.com/SudokuMonster/Sukaku ... ner-v1.2.1
https://github.com/SudokuMonster/Sukaku ... er-v1.17.8

One thing worth noting is that if you are in 1.2.1 mode and switch back to 1.17.8 mode, it will not enable any new techniques; you'll have to either enable them manually or close SE and restart it after switch modes.


I use a great variety of techniques. I'm scanning the board and finding stuff and implementing them. I used several techniques that SE didn't use, and I almost always use techniques that SE doesn't use. I can't comment on other solvers, since I primarily use SE, but Sudoku Explorer's algorithm is designed to find the maximum possible easy or trivial steps, then use the minimum number of harder steps. What happens is you end up getting an analysis with mostly trivial steps (or at least trivial to the level your solving), then one or two really advanced steps.

It's a shame nobody's figured out a way to easily save a game and all the moves it took to finish the puzzle. I think someone said some app could do it, but I think you had to tweak the programming, or use Window's command-line-interface with the app to do it. I don't know, it sounded a bit technical to me.

I would be nice to have both a standard format and the ability to save all the moves of a game. It would be enlightening to compare how a creative person solves sudoku puzzles, compared to someone that is very bookish and tries to emulate how an app would solve the same puzzle.

I've solved about 8 to 10 "Fiendish 1" puzzled in Sudoku 10000 Plus, all rated between 4.5 and about 6.0 or so, flawlessly, yet I've never solved a single one with the same path that SE took.

I used to play chess, and there is great creativity in chess, in spite of the fact on a move to move basis, your distilling the board position to a few considerations and some logic. But over the course of the game, you often have to get creative in order to see something your opponent didn't.

I hit a ceiling in chess and eventually got bored of it. I didn't feel like I could get past the ceiling without a chess coach, and I wasn't into chess anywhere near that level of commitment.
Pupp
 
Posts: 128
Joined: 18 October 2019

Re: Difficulty question

Postby mith » Tue Sep 15, 2020 11:57 pm

I only bring up the second possibility because of our discussion in the other thread.

Personally, I don't care how you solve a puzzle. Do what works for you. But if you want to understand why SE gives something a certain rating when you feel you only used easier techniques to solve it, we're not going to be able to do much to help you figure that out without an example. If it matters to you, go back to that puzzle and resolve it from the beginning, making a note of the steps you took.

It's never going to be the case that you can solve a puzzle exclusively using steps that SE considers easier than the step determining its rating. It may well be the case that you are solving a puzzle using steps you consider easier than whatever SE comes up with (and especially if you are in 1.2.1 mode, as discussed previously). Different people are going to prefer different steps for any given puzzle.
mith
 
Posts: 225
Joined: 14 July 2020

Re: Difficulty question

Postby Pupp » Wed Sep 16, 2020 1:20 am

mith wrote:I only bring up the second possibility because of our discussion in the other thread.

Personally, I don't care how you solve a puzzle. Do what works for you. But if you want to understand why SE gives something a certain rating when you feel you only used easier techniques to solve it, we're not going to be able to do much to help you figure that out without an example. If it matters to you, go back to that puzzle and resolve it from the beginning, making a note of the steps you took.

It's never going to be the case that you can solve a puzzle exclusively using steps that SE considers easier than the step determining its rating. It may well be the case that you are solving a puzzle using steps you consider easier than whatever SE comes up with (and especially if you are in 1.2.1 mode, as discussed previously). Different people are going to prefer different steps for any given puzzle.


I know. :(

I do think there needs to be some sort of standardized way for programs to save moves. Sudoku 1000 remembers every move, but then locks a puzzle after you finish it. The only possibility on that app is to leave a single cell unfinished. But without some sort of standard way to save the puzzle with moves, so you can publish it online, is frustrating.

I should say I'm not solving with easier moves per se, but I do often use a variety of techniques to solve puzzle. Sometimes, that means I use techniques that are not exactly trivial, and will use multiple not-so-trivial techniques that bypass the hardest technique that SE might find. So in essence, none of my techniques (sometime), in puzzles are as difficult as the hardest one that SE suggested. The very last puzzle I did would be interesting to post, but it would be an all afternoon marathon to break the puzzle down into every technique I used.

In chess, you train your brain to constantly process an ever changing board, where your opponent chooses half the moves, so my brain isn't trained to find the best or most efficient path, but rather to take advantage of the first possible path I can find that I know will work.

I think I'll start a new thread, asking people to post about how they solve puzzle, as in do they feel it's a creative process or more rigorous process.
Pupp
 
Posts: 128
Joined: 18 October 2019

Re: Difficulty question

Postby Hajime » Wed Sep 16, 2020 8:26 am

Pupp wrote:.... I used several techniques that SE didn't use, and I almost always use techniques that SE doesn't use. 
....
I think I'll start a new thread, asking people to post about how they solve puzzle, as in do they feel it's a creative process or more rigorous process.

Also you made me curious what (new?) methods you use.
User avatar
Hajime
 
Posts: 193
Joined: 20 April 2018
Location: Netherlands

Re: Difficulty question

Postby Pupp » Tue Sep 22, 2020 2:09 am

Hajime wrote:
Pupp wrote:.... I used several techniques that SE didn't use, and I almost always use techniques that SE doesn't use. 
....
I think I'll start a new thread, asking people to post about how they solve puzzle, as in do they feel it's a creative process or more rigorous process.

Also you made me curious what (new?) methods you use.


Not new methods. I thought I might have had something newish a couple times in the last couple months, but it turned out to be not using correct logic earlier in the game and sorta making an educated guess on how to continue. Right now I'm on a pretty steep level, that doesn't leave much room for innovation. The easier a puzzle, the more likely you could just make an educated guess when stuck and actually solve the puzzle.

When your just learning Sudoku, it can be hard to figure out if your using an actual technique, or just made an educated guess when looking at some pattern. Usually in that case, if it works at all, you can figure out that only 2 cells might solve the puzzle or at least get you past your current position your stuck on, so your basically 50/50 on making the correct choice, but you can add a touch of intuition to make a better guess of that. BUT IT'S NOT CORRECT LOGIC to use in solving the puzzle.
-I'm a stickler about trying to solve puzzles with the correct logic, even if it's not the exact same logic as SE, but it could be the solution another app might use.

In any event, when the puzzles are above 5.0, educated guessing, if well intended, isn't a good thing, and usually only make the puzzle unsolvable. I did get lucky one day and solve a puzzle over 6.0 with some educated guessing at a couple a spots in the puzzle, but it's not good form to use.

In any event, even different apps will use different paths to solve a puzzle. A lot depends on the algorithm. SE, which I should probably stop using, has an algorithm that finds maximum number of easiest steps, followed by as few as possible harder steps. I should try and find an app that is more likely to choose steps that I'd use.

I'm still working on Sudoku 10000 Plus [Fiendish 1 level]. Some puzzles I work out flawlessly, and some puzzles take a few tries. Once I know a puzzle is borked, I just roll the puzzle back to it's starting position. I generally wait till the next day to tackle a problem again, in order to clear my head. I made a decision a couple weeks ago not to use educated guessing anymore.
Considering I just took up Sudoku earlier this year, I think I've actually come a long way.
Pupp
 
Posts: 128
Joined: 18 October 2019

Re: Difficulty question

Postby SpAce » Tue Sep 22, 2020 4:10 am

Hi Pupp,

Pupp wrote:When your just learning Sudoku, it can be hard to figure out if your using an actual technique, or just made an educated guess when looking at some pattern. Usually in that case, if it works at all, you can figure out that only 2 cells might solve the puzzle or at least get you past your current position your stuck on, so your basically 50/50 on making the correct choice, but you can add a touch of intuition to make a better guess of that. BUT IT'S NOT CORRECT LOGIC to use in solving the puzzle.

Indeed. However, there are perfectly logical ways to take advantage of 50/50 situations. In fact, most valid solving techniques depend on them. Whenever you have only two possibilities left and at least one must be true in the solution, you have what we call a strong link. What can you do with them, except take a guess and hope it's the correct one and leads to a solution?

The most primitive option is to use Trial and Error (T&E). It sounds like guessing but isn't because its goal is the exact opposite. With T&E you're actually trying to hit the invalid possibility and find a contradiction for it. If you do find one, you know with a 100% certainty that the assumed option was wrong and can be eliminated. That's perfectly valid logic, even if not very elegant. It can be used with more than two possibilities, of course, but it's the most effective in a 50/50 situation because eliminating one option means that the other must be correct.

What makes T&E different from guessing is that if the assumption leads to a solution instead of a contradiction it's an unwanted result. Solutions found that way are simply discarded, just like assumptions that lead to a dead-end (neither a solution nor a contradiction). Only contradictions are good results. If a found solution is kept without proving the other option(s) false it's just guessing. Of course you can keep it and consider the puzzle solved if that's your only goal, but you can be sure that no one else is impressed. (Also, you can't know if that was the only possible solution.)

A more elegant way to use 50/50 situations is to consider both possibilities simultaneously and try to find something they both agree on (usually an elimination). Anything they can agree on must be valid, because at least one option must be true and truths can't lie. Such agreements are called verities (truths) as opposed to contradictions (falsehoods). In that solving style you're not even trying to figure out which one of the two original options is true -- you're using them to prove something else entirely.

What makes verities more elegant (and more efficient) than contradictions is that they let you find valid conclusions directly without assuming anything. Most solving techniques work like that, including patterns like Skyscrapers and wings and so on, by proving that at least one of the end points must be true (thus anything they both see can be eliminated). Most of such named patterns are special cases of AICs.

All verity findings can be double-checked by assuming the opposite result and seeing it produce a contradiction. Thus they're just two sides of the same coin.

I should try and find an app that is more likely to choose steps that I'd use.

Have you tried Hodoku?
-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: 2505
Joined: 22 May 2017

Re: Difficulty question

Postby Pupp » Tue Sep 22, 2020 12:55 pm

I have Hodoku installed, I just haven't gotten around to really looking at it much. LOL.

But right now, it looks like the average difficulty for Fiendish 1 puzzles is about 5.5 on SE. At that level, I should be able to solve the puzzles with logic and little guessing. Right now, my big focus is learning to use various Y, XY, WXY, and WXYZ patterns. I think that's my main obstacle right now. Once I nail those down, I should be rolling along again at a nice pace.
Pupp
 
Posts: 128
Joined: 18 October 2019

Re: Difficulty question

Postby coloin » Tue Sep 22, 2020 8:12 pm

SpAce wrote:Indeed. However, there are perfectly logical ways to take advantage of 50/50 situations. In fact, most valid solving techniques depend on them. Whenever you have only two possibilities left and at least one must be true in the solution, you have what we call a strong link. What can you do with them, except take a guess and hope it's the correct one and leads to a solution?

The most primitive option is to use Trial and Error (T&E). It sounds like guessing but isn't because its goal is the exact opposite. With T&E you're actually trying to hit the invalid possibility and find a contradiction for it. If you do find one, you know with a 100% certainty that the assumed option was wrong and can be eliminated. That's perfectly valid logic, even if not very elegant. It can be used with more than two possibilities, of course, but it's the most effective in a 50/50 situation because eliminating one option means that the other must be correct.

What makes T&E different from guessing is that if the assumption leads to a solution instead of a contradiction it's an unwanted result. Solutions found that way are simply discarded, just like assumptions that lead to a dead-end (neither a solution nor a contradiction). Only contradictions are good results. If a found solution is kept without proving the other option(s) false it's just guessing. Of course you can keep it and consider the puzzle solved if that's your only goal, but you can be sure that no one else is impressed. (Also, you can't know if that was the only possible solution.)

A more elegant way to use 50/50 situations is to consider both possibilities simultaneously and try to find something they both agree on (usually an elimination). Anything they can agree on must be valid, because at least one option must be true and truths can't lie. Such agreements are called verities (truths) as opposed to contradictions (falsehoods). In that solving style you're not even trying to figure out which one of the two original options is true -- you're using them to prove something else entirely.

What makes verities more elegant (and more efficient) than contradictions is that they let you find valid conclusions directly without assuming anything. Most solving techniques work like that, including patterns like Skyscrapers and wings and so on, by proving that at least one of the end points must be true (thus anything they both see can be eliminated). Most of such named patterns are special cases of AICs.

All verity findings can be double-checked by assuming the opposite result and seeing it produce a contradiction. Thus they're just two sides of the same coin.


Excellent reply and very informative ....
coloin
 
Posts: 1915
Joined: 05 May 2005

Re: Difficulty question

Postby SpAce » Wed Sep 23, 2020 12:04 am

coloin wrote:Excellent reply and very informative ....

Thanks! Glad to hear :)
User avatar
SpAce
 
Posts: 2505
Joined: 22 May 2017


Return to General