Saturday, September 29, 2007

Sudoku Lesson VI - Solving Squares

O.k., is the suspense concerning coupling pairs from Lesson IV killing you yet? Here's why coupling pairs are so important. Let's add a new tool to your box -- solving a square. In this operation, we cycle through the numbers inside of a square, i.e., without projection. As we check possibilities, we can skip over boxes having the coupling pairs, and we can eliminate the coupled pair numbers from our test to see what numbers are left that fit.

Take, for example, the puzzle below. I've cycled through twice, and marked all the boxes:




















Note in the middle top square that we have the numbers 2 and 9 marked for boxes (5,1) and (5,2). Despite the marking of a 5 in box (5,2), the 2 and the 9 are a coupling pair. That means that the 5 cannot go in (5,2), and therefore must go in (5,3):




















In the top middle square, we can put a 4 only in (6,3), and thus 8 goes in (4,3), because 2 and 9 are already slated to go in the other two boxes (5,1) and (5,2) in the top middle square:



















Thus, using the coupling pair, we've largely completed the top middle square!

Monday, September 24, 2007

Are You Hungry? I Had Surgery.

Didn't write the next Sudoku lesson yet. I had surgery on my right great toe to remove an ingrown nail. You may remember this saga, if not, click the title of this post for a little history. The nail basically wrapped itself around the inside of my toe by growing sideways, ever since I had the suitcase dropped on it (more history). The doctor cut it out and burned the root with carbolic acid to ensure that nothing ever grows there again. When the doctor showed me what he pulled out, I had to take a picture of it, superimposed on my good left toe in the position it was in, just so you can get some perspective how deep this thing was growing inside of the other side of my right toe. When Mac saw it, he gagged down his food:


Saturday, September 15, 2007

Sudoku Lesson V - Solving Hard Boxes

Ok, so you've cycled through all the numbers twice, and have done all the projections possible. Cycle through all the numbers twice means that you should try to project the number 1 into all nine squares, then try 2 through 9. As you find solutions, you fill them in. This will change the available spots in each square, so you might be able to solve other numbers that you couldn't the first time through. That's why you start over and do the projections again a second time. I find that when you cycle a third time, you may only solve a paltry few extra numbers, and you time is better spent using other techniques to solve numbers in each square. Thus, you can cycle through a third time, but in my experience, that's going to be a waste of time. Instead, you should proceed with the next few lessons, which will provide you with some powerful Sudoku tools to solve the puzzle.

Sometimes it looks like you're going to get stuck early, with no way to get even a few boxes solved. When this happens, step back and take a look at the forest. Let's take our early puzzle example, which I've marked only using projection, and by cycling through all of the numbers only twice. Here's where we stand:



















Pick any three squares in a row or a column that you haven't solved a particular number in yet. See if you have pairs (not necessarily coupling pairs) marked in all three squares. If so, then if there are two pairs in the same two rows or same two columns, then another different number, marked in a third pair in the last square in that same row or column as the other two pairs is a solution. Remember, a square is a set of nine boxes, illustrated with the bold lines surrounding it. There are nine squares in a sudoku puzzle.

Confused? Let's look at an example. Take the number 8 for example. Look at the middle row of squares. Can you see what I'm talking about? I can mark an 8 in the two middle boxes of the center square at (5,5) and (6,5), because 8 is marked in the top and bottom rows in the left and right middle squares, at (3,4), (3,6), (7,4) and (7,6). This is because, if the left middle square has an 8 in the top row of the middle squares, i.e., row 4, then the right middle square must have an eight in the bottom row 6, and vice-versa. Therefore, the only place that an 8 can go in the center square is in the middle row 5, so this is how I mark the center square:



















Continue to look for potential solutions using this tool. Sometimes there will only be two boxes that you will mark, and sometimes you will find only one box, which you will solve.

Monday, September 03, 2007

Laboring Day

As the summer wanes, my family abandoned me for the last vacation. They booked a cruise, poised to return just before school begins. I would have traveled with them, but my work was too heavy to provide me with the amount of time that they wanted to expend. Two weeks. Far too long for an attorney to be away from his practice.
Left alone to my own devices, and unable to find anyone willing to travel back down to Atlantic City for yet another poker rampage, I decided to take my old Bic board out from the shed where it had been stored since moving to West Islip. At 9 a.m., I gathered my parts and secured them to the roof of the Windstar to make the 60 second journey to the end of the block where I can launch from the community beach.
There's a fresh breeze and quite a bit of chop, but the tide's coming in and I'm optimistic. Having taken a few lessons on beach starting and harness in Aruba this winter past, I'm eager to ply my new found knowledge on my rig. I chose the bigger 6.2 square meter sail for today, but I question whether I should have opted for the 5.6. Nevertheless, after a quick beach start, I hook in and head across the Great South Bay. But I let the board point too far into the wind, and inevitably it shift, launching me into the soup. My watch unfastened, but remained on my wrist. It's 9:30 a.m.
After securing my watch, I begin to uphaul, but notice that something is wrong. The boom has parted from the mast. I enter the water to find that the pivot arm securing the cleat to the mast has broken. I wave down a jet skier. Jim tows me back to shore. Regretfully, I pack my things and truly believe that summer is now over.

Sunday, September 02, 2007

Sudoku Lesson IV - Cycle Once and Take Advantage of Pairs

Sometimes you'll find that two pairs of numbers are marked in a pair of boxes. When these boxes line up in the same row or column, or are in the same square, they are known as "coupling pairs." During the second projection cycle, you should take advantage of such marked pairs. In this lesson, I will show you how to do that.



















In the above puzzle, I've marked all of the boxes in the lower three squares, for illustrative purposes only. DON'T DO THIS, as you should only mark boxes only if there is two occurrences of a number in the box. This marking is only to help you understand the principle of coupling pairs.

The numbers 2 and 5 in the bottom row, boxes (2, 9) and (6, 9) form a coupling pair in the bottom row. Consequently, boxes (4, 9) and (5, 9) can have all occurrences of 2 and 5 removed. This forms a second coupling pair of the numbers 7 and 9 within the lower middle square. Any other occurrences of 7 and 9 can be removed from that square. Box (5, 8) forms yet another coupling pair with box (6, 9) using numbers 2 and 5, and a new coupling pair is revealed in row 7. Here is the resultant marking:



















I've taken the liberty of removing the markings of 2 and 6 from the 7th column, since they must go in the 7th column in the top right box.

Remember in Lesson II when I told you to mark only boxes when there were two and no more than two possibilities? This is so that you can establish and recognize coupling pairs. I cheated above, just to show you how the coupling pairs come about, but don't cheat. Why is that so important? I'll tell you in the next two lessons. In the meantime, cycle through the numbers two times, like I've been telling you, but use these pairs to your solving advantage.

As you project and find solutions in a box, if the box already has a dot for a different number, find the other spot in that square with the dot and fill in that number too. It's like getting two-for-one.




















In the above example, I marked all the 1s and 2s. As I started to mark the 3s, I found that the top square had only one spot for a 3, in (3, 2), due to the upward projection of the virtual number pair of 3 from the bottom left square. So now, I can put a 3 in (3, 2) and a 2 in box (3, 3). After getting a two-for-one, then try to figure out why coupling pairs are so cool.