Wording of a solution

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

Wording of a solution

Postby Lummox JR » Sun Oct 08, 2006 10:31 pm

The book I'm developing is going to not only show the solved grids of puzzles, but show step by step how to solve them. However to save space, the detailed solution will not show any grids during the process.

I've found that for some advanced techniques, I'm running into a problem of excess verbosity. Advanced coloring seems to be particularly bad about this, since it involves long conjugate chains. This is what my solver is spitting out, which I think is too wordy:

Advanced coloring finds a set of two conjugate chains r3c9=7 - r3c6=7 - r5c6=7 - r5c6=3; r4c5=3 - r4c5=8 - r4c9=8 - r3c9=8. Either r3c9=7 or r3c9=8, so r3c9≠5. There is another set of two conjugate chains r4c5=3 - r4c5=8 - r4c9=8 - r3c9=8; r3c9=7 - r3c6=7 - r5c6=7 - r5c6=3. Either r4c5=3 or r5c6=3, so r6c5≠3. There is another set of three conjugate chains r5c2=7 - r5c6=7 - r3c6=7 - r3c9=7; r3c9=8 - r4c9=8; r4c9=1 - r5c8=1. Either r5c2=7 or r5c8=1, or both, so r5c2≠1. There is another set of four conjugate chains r5c6=3 - r5c6=7 - r3c6=7 - r3c9=7; r3c9=8 - r4c9=8; r4c9=1 - r5c8=1; r5c8=9 - r5c7=9. Either r5c6=3 or r5c7=9, or both, so r5c7≠3. There is another set of three conjugate chains r5c6=3 - r5c6=7 - r3c6=7 - r3c9=7; r3c9=8 - r4c9=8; r4c9=1 - r5c8=1. Either r5c6=3 or r5c8=1, or both, so r5c8≠3. There is another set of three conjugate chains r8c1=7 - r8c7=7; r8c7=4 - r8c6=4 - r7c6=4 - r7c6=6; r3c6=6 - r3c4=6 - r8c4=6 - r8c4=5. Either r8c1=7 or r8c4=5, or both, so r8c1≠5. There is another conjugate chain r1c5=5 - r1c5=7 - r6c5=7 - r5c6=7 - r5c6=3 - r5c3=3 - r3c3=3 - r3c3=5. Either r1c5=5 or r3c3=5, so r1c2≠5 and r3c4≠5. There is another conjugate chain r3c1=3 - r3c1=4. Either r3c1=3 or r3c1=4, so r3c1≠5 and r3c1≠9. There is another conjugate chain r3c3=5 - r3c3=3 - r5c3=3 - r5c6=3 - r5c6=7 - r3c6=7 - r3c6=6 - r3c4=6 - r8c4=6 - r8c4=5. Either r3c3=5 or r8c4=5, so r8c3≠5. There is another set of two conjugate chains r5c8=1 - r4c9=1; r4c2=1 - r9c2=1. Either r5c8=1 or r9c2=1, or both, so r9c8≠1. There is another set of three conjugate chains r7c5=9 - r7c1=9; r1c1=9 - r1c1=2 - r4c1=2 - r4c2=2; r4c2=1 - r9c2=1 - r8c3=1 - r8c5=1. Either r7c5=9 or r8c5=1, or both, so r7c5≠1. There is another conjugate chain r1c5=5 - r8c5=5 which touches r7c5=5 at both ends. Either r1c5=5 or r8c5=5, so r7c5≠5, so r7c5=9. There is another conjugate chain r1c1=9 - r1c2=9 which touches r1c7=9 at both ends. Either r1c1=9 or r1c2=9, so r1c7≠9, so r5c7=9. There is another conjugate chain r1c1=9 - r1c2=9. Either r1c1=9 or r1c2=9, so r3c2≠9. There is another conjugate chain r1c5=5 - r8c5=5. Either r1c5=5 or r8c5=5, so r9c5≠5. There is another conjugate chain r3c2=5 - r3c3=5. Either r3c2=5 or r3c3=5, so r3c8≠5. There is another set of two conjugate chains r3c2=5 - r5c2=5 - r5c2=7 - r5c6=7 - r3c6=7 - r3c6=6 - r3c4=6 - r8c4=6; r8c3=6 - r8c3=1 - r9c2=1 - r4c2=1. Either r3c2=5 or r4c2=1, or both, so r4c2≠5. There is another conjugate chain r3c2=5 - r5c2=5. Either r3c2=5 or r5c2=5, so r9c2≠5. There is another conjugate chain r4c9=1 - r7c9=1. Either r4c9=1 or r7c9=1, so r9c9≠1. There is another set of two conjugate chains r4c1=2 - r1c1=2 - r1c1=9 - r9c1=9; r9c1=5 - r7c1=5. Either r4c1=2 or r7c1=5, or both, so r4c1≠5. There is another set of three conjugate chains r7c1=5 - r9c1=5; r9c1=9 - r9c2=9 - r9c2=1 - r4c2=1; r4c9=1 - r7c9=1. Either r7c1=5 or r7c9=1, or both, so r7c9≠5.

The constant repetition of "there is another..." is a little annoying, but then you can only get automated output to look natural to a point. I can probably simply not print a chain that's only two cells long, like the r3c2=5-r3c3=5 chain mentioned above.

The quesiton before the group is: Am I on the right track? How might I set up the program to print this differently, without illustrating on a grid? Should I simply ditch printing the conjugate chains with this method? (It seems okay for simple coloring though.)

For those who want to see which puzzle this printout came from, it's this one:
Code: Select all
. . .|3 . 1|. 4 .
. 6 7|. 4 .|. . .
. . .|. 2 .|1 . .
-----------------
. . .|. . 9|. 7 .
8 . .|. 6 .|. . .
. . 9|1 . 5|. . 2
-----------------
. 3 2|. . .|. . .
. . .|. . .|. 2 9
. . 4|7 . .|8 . .
Lummox JR
 
Posts: 125
Joined: 22 September 2005

Postby tarek » Sun Oct 08, 2006 10:39 pm

I think that the word colouring is related to VISION......

in that instance showing a grid with colours (or shadings if B&W) would save all of that & give a clearer PICTURE

tarek
User avatar
tarek
 
Posts: 3762
Joined: 05 January 2006

Postby Lummox JR » Mon Oct 09, 2006 4:29 am

Shadings of black and white aren't possible because coloring usually involves more than a single conjugate chain at a time, and advanced coloring almost always involves several.

And like I said, I really don't want to show a grid. I could, but it would be too big and the candidates too tiny, and this would so bloat the full solution section as to warrant removing it entirely.
Lummox JR
 
Posts: 125
Joined: 22 September 2005

Postby tarek » Mon Oct 09, 2006 8:25 am

Shading is one way of filling a white space (you can have patterns too)...you can have distinct, easily identifiable conjugates (Many if needed) using that.......however production of B&W drawings on paper needs probably 600-1200dpi I think for it to look nice (That is why words are better than drawings for some)

Lummox JR wrote:it would be too big and the candidates too tiny, and this would so bloat the full solution section as to warrant removing it entirely
This can also describe the chains that your solver brought out....

I'm sure there is a way to shorten your wording of the solution or at least make it easier to look at (use numbered lines & tabs) but IMO a chunky ugly grid would still be superior, it is a personal opinion which understandably may not sound reasonable to some.......

tarek
User avatar
tarek
 
Posts: 3762
Joined: 05 January 2006

Re: Wording of a solution

Postby ronk » Mon Oct 09, 2006 12:16 pm

Lummox JR wrote:The book I'm developing ...

Advanced coloring finds a set of two conjugate chains r3c9=7 - r3c6=7 - r5c6=7 - r5c6=3; r4c5=3 - r4c5=8 - r4c9=8 - r3c9=8. Either r3c9=7 or r3c9=8, so r3c9≠5. There is another set of two conjugate chains r4c5=3 - r4c5=8 - r4c9=8 - r3c9=8; r3c9=7 - r3c6=7 - r5c6=7 - r5c6=3. Either r4c5=3 or r5c6=3, so r6c5≠3. There is another set of three conjugate chains r5c2=7 - r5c6=7 - r3c6=7 - r3c9=7; r3c9=8 - r4c9=8; r4c9=1 - r5c8=1. Either r5c2=7 or r5c8=1, or both, so r5c2≠1. There is another set of four conjugate chains r5c6=3 - r5c6=7 - r3c6=7 - r3c9=7; r3c9=8 - r4c9=8; r4c9=1 - r5c8=1; r5c8=9 - r5c7=9. Either r5c6=3 or r5c7=9, or both, so r5c7≠3.

Three recommendations:
1) Replace all the "There is another set of three ..." with "Three ...", or whatever the number might be.
2) Number the steps for easy reference in possible discussions.
3) Format by indenting

Then the initial steps might look like ..
Code: Select all
1.  Advanced coloring finds a set of two conjugate chains r3c9=7 - r3c6=7 - r5c6=7 -
    r5c6=3; r4c5=3 - r4c5=8 - r4c9=8 - r3c9=8. Either r3c9=7 or r3c9=8, so r3c9<>5.
2.  Two conjugate chains r4c5=3 - r4c5=8 - r4c9=8 - r3c9=8;
    r3c9=7 - r3c6=7 - r5c6=7 - r5c6=3. Either r4c5=3 or r5c6=3, so r6c5<>3.
3.  Three conjugate chains r5c2=7 - r5c6=7 - r3c6=7 - r3c9=7; r3c9=8 - r4c9=8;
    r4c9=1 - r5c8=1. Either r5c2=7 or r5c8=1, or both, so r5c2<>1.
4.  Four conjugate chains r5c6=3 - r5c6=7 - r3c6=7 - r3c9=7; r3c9=8 - r4c9=8;
    r4c9=1 - r5c8=1; r5c8=9 - r5c7=9. Either r5c6=3 or r5c7=9, or both, so r5c7<>3.


But most importantly, the step description must be clear and correct. I was never able to figure out the first step. Maybe it's because some of the '=' are supposed to be "<>". For example, r3c9=7 and r3c6 can't both be true.
ronk
2012 Supporter
 
Posts: 4764
Joined: 02 November 2005
Location: Southeastern USA

Postby MCC » Mon Oct 09, 2006 1:04 pm

Lummox JR, as a general thought, have you approached a publisher about this book? Is it a commission by a publisher?

If you have a publisher then they would help you with the book layout.

You could end up with a book that no one wants to publish, other than vanity press.

You could also think about splitting the subject into two or three books, such as: Simple, Intermediate and Advance or; Basic and Advance.

Like I say, it's just a thought, you don't want to do all that work for nothing.
MCC
MCC
 
Posts: 1275
Joined: 08 June 2005

Postby Lummox JR » Mon Oct 09, 2006 5:25 pm

I'm publishing this on lulu.com. I have several reasons for this, one of them being that I'm preparing another book through them and want to get a good look at the quality of their press and any potential pitfalls. (I've heard good things, but preparedness never hurts!) One advantage of this is that they can ring-bind a book so it will lie flat when open, which for a sudoku book is a huge plus. Even if this book doesn't end up interesting too many people, it will be a good jumping-off point.

There is no need to split this into different levels, because this book is meant to cover advanced techniques only. Out of 150 puzzles, only the first 40 will require techniques less intensive than coloring: Remote pairs, X-fish, XY-wings, XYZ-wings, and uniqueness tests. I found that way too many officially published sudoku books cater to beginners, or people who think they're doing hard puzzles but aren't. The whole premise of the book is to start where mainstream sudoku usually stops, and descend even further into the realm of obscene difficulty.

ronk wrote:Three recommendations:
1) Replace all the "There is another set of three ..." with "Three ...", or whatever the number might be.
2) Number the steps for easy reference in possible discussions.
3) Format by indenting

I like that idea. It might need some tweaking but you've definitely given me an idea how to proceed. Thanks for the suggestion!
Lummox JR
 
Posts: 125
Joined: 22 September 2005

Postby Lummox JR » Wed Oct 11, 2006 6:16 am

I think I've decided on a final format, and it's one that saves space while still being somewhat presentable. I used the idea of numbering each step, but instead of indenting I decided to simply put the step numbers in bold. This seems to do a world of good. As a space-saver I also avoid showing most hidden singles. This is an example solution:
(1) Eight singles are exposed. By elimination, r2c4=1. (2) Any 9’s in r2 are in b2. (3) Any 2’s in c2 are in b4. (4) In b1, 7 and 8 only occur in r2c1 or r2c2 (hidden pair). This proves r3c1=2. (5) Any 5’s in r3 are in b1. (6) Any 5’s in b7 are in c1. (7) Any 5’s in b9 are in r9. (8) In r7, c1 and c4 can only be 5 or 7 (naked pair). By elimination, r7c2=1 and r7c3=3. Seven singles are exposed. (9) Any 1’s in r6 are in b6. (10) In c7, 2 and 5 only occur in r6 or r9 (hidden pair). (11) A rectangle with r7c1=57 and r7c4=57, and r8c1=578 and r8c4=578 proves 8 must exist in one of those cells, otherwise the solution would not be unique; therefore 8 can be eliminated from r8c5. (12) In r8, 5 and 8 only occur in c1 or c4 (hidden pair). (13a) Coloring for 7 shows that the ends of the conjugate chain r5c4-r7c4-r7c1-r2c1-r2c2 touch another chain r4c5-r4c2. r5c4 and r2c2 must both be 7 or both not, but either one invalidates the other, so both can be eliminated. 7 must be at r2c1, r7c4, and r9c3. (13b) This immediately places 7 at r8c8. The puzzle is cracked.

Advanced coloring can still be pretty lengthy because of the huge color chains, but it works much better than before. You may notice that singles are combined with other steps (except in step 1, since they're almost always the first step). I would like to know if there's a better way to express the coloring deduction made in this example, though.

This is all in 9-point Arial, which shouldn't be too horrible since this section is mostly a reference for anyone who gets seriously stuck. Most logic puzzle books I've seen don't go to too much trouble to pretty up this section.

As of right now my book layout looks like this:

Introduction and solving techniques: About 20 pages
Puzzles (150): 75 pages
Detailed solutions: About 75 pages
Solved grids: 25 pages

Since the book is 6"x9", putting two puzzles on a page is a pretty big space saver. I'm staggering them so there's one at the top left, one at the bottom right, so it's easier not to lose yourself in the wrong grid.
Lummox JR
 
Posts: 125
Joined: 22 September 2005

Postby ravel » Wed Oct 11, 2006 8:05 am

Lummox JR wrote:(13a) Coloring for 7 shows that the ends of the conjugate chain r5c4-r7c4-r7c1-r2c1-r2c2 touch another chain r4c5-r4c2. r5c4 and r2c2 must both be 7 or both not, but either one invalidates the other, so both can be eliminated. 7 must be at r2c1, r7c4, and r9c3.
Cant be a good description, because i dont understand it:)
Can you post the situation please ? Is it this
Code: Select all
 *-----------*
 |...|...|...|
 |77.|...|...|
 |...|...|...|
 |---+---+---|
 |.7.|.7.|...|
 |...|7..|...|
 |...|...|...|
 |---+---+---|
 |7..|7..|...|
 |...|...|...|
 |...|...|...|
 *-----------*
with strong links r5c4-r7c4-r7c1-r2c1-r2c2 and r4c5-r4c2 ?

Then the x-chain r4c2=r4c5-r5c4=r7c4-r7c1=r2c1 would eliminate 7 from r2c2, but why must r5c4 and r2c2 both be 7 or both not (no strong link r2c2-r4c2 or r5c4-r4c5) ?
ravel
 
Posts: 998
Joined: 21 February 2006

Postby ronk » Wed Oct 11, 2006 11:37 am

ravel wrote:... but why must r5c4 and r2c2 both be 7 or both not ...

Because they bear the same color
Code: Select all
 *-----------*
 |...|...|...|
 |bB.|...|...|
 |...|...|...|
 |---+---+---|
 |.G.|.g.|...|
 |...|B..|...|
 |...|...|...|
 |---+---+---|
 |B..|b..|...|
 |...|...|...|
 |...|...|...|
 *-----------*
ronk
2012 Supporter
 
Posts: 4764
Joined: 02 November 2005
Location: Southeastern USA

Postby ravel » Wed Oct 11, 2006 12:03 pm

ronk wrote:
ravel wrote:... but why must r5c4 and r2c2 both be 7 or both not ...

Because they bear the same color
Ah, thanks, i mixed r5c4 and r4c5:(

So what about writing it as x-chain, Lummox (either end must be true - eliminate the number from the cells that see both) ?

What Ron showed above for me is "multiple coloring" (B and g share a unit, therefore b or G must be true and since r2c2 sees both, B must be false), while "advanced coloring" only works with alternating strong and weak links in one chain.
I prefer first to use the latter and only try multiple coloring, if it does not help, but this is a matter of taste.
ravel
 
Posts: 998
Joined: 21 February 2006

Postby Lummox JR » Wed Oct 11, 2006 3:47 pm

ravel wrote:What Ron showed above for me is "multiple coloring" (B and g share a unit, therefore b or G must be true and since r2c2 sees both, B must be false), while "advanced coloring" only works with alternating strong and weak links in one chain.
I prefer first to use the latter and only try multiple coloring, if it does not help, but this is a matter of taste.

There are two major schools of thought on coloring terminology. One of them says that simple coloring is just when there's only one conjugate chain involved, and multi-coloring is when there are several. (Most agree that advanced coloring is when conjugates can spread within a cell, so the chain covers more than one digit.)

I don't hold with this school of thought, because it uses confusing terminology, and it also pretends that simple coloring is way too simple to be of much use most of the time. Instead I follow the school that says simple coloring is any form of coloring that involves a single digit, and therefore more than one conjugate chain is allowed. For clarity, I typically refer to anything using multiple chains as complete simple coloring, because the blue-green-only format is a fairly weak technique. Complete simple coloring completely encompasses several other techniques, including fishy cycles.

Indeed, there's just about zero sense in only finding a single conjugate chain, because if you're looking for one you may as well find the others and save yourself some work later. The odds of finding a self-excluding chain all on its own, or eliminations based on just one chain, are quite low, but the odds of finding something with multiple chains are much better.

As far as x-chain, well, I'm not a fan of forcing chains and I don't use most forms of them in the book. Forcing chains smack way too much of trial-and-error, which if you're going that way you may as well use actual T&E (which also is covered in the book, as back propagation a.k.a. bifurcating implication chains). Most forms of forcing chains can be nailed by complete simple coloring, or advanced coloring, since most chains involve the use of conjugates. Either coloring method is preferable because they can show you a pattern, and if you're finding conjugates in the first place, again you may as well find the rest. What you described (either end must be true - eliminate the number from the cells that see both) is something that even the simplest form of coloring will tell you.

However I like the idea of rephrasing this: "Either r4c5 or r4c2 is 7. Because r5c4 and r2c2 are linked, and one is not 7, the other isn't either." In advanced coloring terms that would say "Either r1c2=6 or r2c3=9. Because r4c2=6 and r4c3=9 are linked, and one is false, the other is also false."
Lummox JR
 
Posts: 125
Joined: 22 September 2005

Postby ravel » Sat Oct 14, 2006 12:36 pm

Lummox JR wrote:There are two major schools of thought on coloring terminology. One of them says that simple coloring is just when there's only one conjugate chain involved, and multi-coloring is when there are several.
I agree here.
(Most agree that advanced coloring is when conjugates can spread within a cell, so the chain covers more than one digit.)
From all i read "coloring" of any forms only uses one digit. Do you have a link (or do you mean 3D Medusa)?
Instead I follow the school that says simple coloring is any form of coloring that involves a single digit, and therefore more than one conjugate chain is allowed. For clarity, I typically refer to anything using multiple chains as complete simple coloring, because the blue-green-only format is a fairly weak technique. Complete simple coloring completely encompasses several other techniques, including fishy cycles.
[Edit: reformulated]It is left to you to introduce another new name, though each technique already has 2 or 3 names. As i said, for me that is "multiple coloring", but i noticed that "multicoloring" in Angus' Simple Sudoku is restricted to 2 groups.
Of course the eliminations from fishy cycles (x-rings, closed SL chains) can be done with multiple coloring also, but how would you describe this ('=' means conjugated for n. '-' same unit):
x-ring for number n in cells A=B-C=D-E=F-A (n can be elimnated in cells that see both A and B or both C and D or both E and F)
The odds of finding a self-excluding chain all on its own, or eliminations based on just one chain, are quite low, but the odds of finding something with multiple chains are much better.
Not for "strong link" chains (connected with "weak links", i.e. it is sufficient, that the candidates share a unit). From my experience the eliminations that can be made with multiple coloring, but not with strong links, are very rare and seldom solve a puzzle. The advantage of "strong links " is that they can be denoted very short and clear without the need of showing the grid (and with some practice they also can be spot rather easily).
What you described (either end must be true - eliminate the number from the cells that see both) is something that even the simplest form of coloring will tell you.
Thats the point: it is a simple form of coloring and easy to denote, but an explanation based on multiple coloring is hard to understand without a graphic. Lets look at another sample, one of Ruuds nightmares:
Code: Select all
----------------------------------------------------------
|2459  17    245   |357   8     1257  |1247  23479 6     |
|259   3     6     |57    125   4     |127   8     12579 |
|245   17    8     |9     12356 12567 |1247  2347  12457 |
----------------------------------------------------------
|23568 268   235   |1     4     2567  |9     267   278   |
|1     246   7     |8     269   269   |3     5     24    |
|2458  2468  9     |567   256   3     |12478 2467  12478 |
----------------------------------------------------------
|468   5     1     |2     69    689   |478   479   3     |
|7     24689 234   |346   1369  1689  |5     249   2489  |
|2348  2489  234   |345   7     589   |6     1     2489  |
----------------------------------------------------------
The 6 in r4c1 can be eliminated with coloring and a short and clear notation can be:
3 SL (strong links) in 6: r7c1=r8c2-r8c4=r6c4-r6c8=r4c8 (r7c1 or r4c8 must be 6) => r4c1<>6.
How would you formulate this ?
ravel
 
Posts: 998
Joined: 21 February 2006


Return to General