- Games, Toys, and Hobbies»
- Puzzles, Logic Problems & Brain Teasers
Sudoku Sherlock-Style: Getting To N-1
At a bare-bones level, all Sudoku solving is about eliminating the impossible until
- Games, Toys, and Hobbies»
- Puzzles, Logic Problems & Brain Teasers
Sudoku Sherlock-Style: Getting To N-1
At a bare-bones level, all Sudoku solving is about eliminating the impossible until just one alternative remains—as Holmes observed, the remaining possibility must represent the answer we seek. I like to call this “getting to N-1,” perhaps because it makes me feel more mathematically adept that I actually am.
The first tack most of us take to get to N-1 is what I’ve called “cross-referencing.” In this strategy, we look at a particular digit—say, all the 1s—in a grid, observing where their “lines of influence” intersect, as illustrated in the grid below:
For each “subgrid”—that’s just my terminology, by the way—there are nine boxes, so our “N” for the subgrid starts out as 9. If the subgrid is the intersection of two columns and two rows containing ones as shown, then 8 boxes will be ruled out, since you can never have two 1s in the same row or column. That means N–1 possibilities have been ruled out! That leaves just one box that can contain a 1, so we can write a 1 in it with full confidence that it is correct.
By the way, when we do write that number in, it is a good idea to check immediately whether this new digit gets us to N-1 in some other subgrid—that is, it’s a good idea if we want to solve our puzzles faster! Here’s an idealized (unrealistic but clarified) example, based on the previous grid:
The new “1” we write in eliminates one of two possible boxes for the digit “2”—blocking it out, as it were. This brings up the fact that, unlike our first example, most subgrids in most puzzles already have some boxes with numbers entered when we begin. Naturally, these numbers reduce “N” accordingly. For example, the highlighted subgrid in the example below has 5 boxes already filled, so “N” for that box starts out as 4—and luckily for the solver, a single well-placed 1 eliminates 3 of them at a stroke—and voila! we have “N-1!”
Sometimes we don’t quite make it to N-1, naturally; the information we need isn’t yet available. But that doesn’t mean we should give up on the angle we’ve been considering—at least, not just yet. Sometimes “N-2,” or even “N-3,” implies “N-1” somewhere else in the layout.
At first blush, it might seem that there is nothing that can be done with this layout. None of the digits we need in our right-hand ‘target’ subgrid are helpfully placed in the left-hand subgrid. However, we can place one of them—“1”—to N-3. Specifically, we know it’s found somewhere within the three boxes of the top row. And since those boxes are contained within a single row, they are just as useful as an actual written “1” for getting to N-1 in the target subgrid.
Here’s how it looks:
It’s as if the unseen digit casts a shadow across the rest of the row, so I call this strategy “shadow theory.” It’s a surprisingly versatile solving tool, and the second pillar of my Sudoku strategy “CSI”—“Cross-reference, Shadow, Inventory.”
So far we’ve been looking at possibilities only in terms of physical position with a sub-grid. But it’s often necessary to consider possibilities from the angle of numerical complements as well. What does that mean?
Well, since every row, column or subgrid must contain all the digits from 1-9 with no duplications, it’s easy to make a list of the missing digits. For example, if a particular row contains the digits 1-6, we can conclude that the missing digits in that row must be 7-9. Of course, that means that each of the three empty boxes in that row can only be 7, 8 or 9. I call this “inventorying possibilities”—and yes, that is the “Inventory” in “CSI.”
Now, here’s the good part. If any two of these three digits affect one of the empty boxes, then we’ve reached N-1 for that box, and have found our answer!Here’s an idealized example of this highly effective technique:
One of the cool things about this is that it very often leads to the other missing digits, too, if you follow up properly. For example, if you have either a “1” or “2” showing anywhere in the bottom 6 boxes of the top middle subgrid, you’ll be able to fill in both digits of the right hand row. Here’s how that might look:
Examples 8a and 8bClick thumbnail to view full-size
Once you get the “2”, the “1” follows by simple elimination. (This isn't the purest example, because you could do the same thing without this technique by starting instead with the 2s. But doing it the way we did illustrates the technique--and sometimes there really is no alternative.)
The same principle applies, naturally, with filling subgrids in