Thursday 5 May 2011

Step-by-step example

The following is an example of a step-by-step solution of a Sudoku puzzle, using SP Notation. This puzzle was published in page B8 of the Toronto Star on Thursday, May 5, 2011. 

A
B
C
D
E
F
G
H
I
1


8
6





2




4
3
1


3






9
8
6
4


7


4

2
8
5
5



1



7
6
4
2

9


3


7
2
6
9






8


4
3
2




9





5
2









008600000
000043100
000000986
007004028
500010007
420900300
269000000
004320000
000005200

Each stage in the solution has multiple steps. Each of the steps can be made independently of the other steps in the same stage. The steps in the following stages are based on all the steps being made in previous stages.
 
Stage 1:
1      B3 = 4 R
2      B5 = 8 B
3      B8 = 5 B
4      D2 = 8 BR
5      D4 = 5 N
6      E4 = 3 BC
7      H5 = 9 B

Stage 2:
1      C5 = 3 BR
2      D5 = 2 N
3      G4 = 6 N
4      G5 = 4 BR

Stage 3:
1      A2 = 6 C
2      A3 = 3 R
3      C6 = 6 B
4      C9 = 1 N
5      F5 = 6 NR

Stage 4:
1      B2 = 9 R
2      B9 = 3 BC
3      E9 = 6 BC
4      H8 = 6 R

Stage 5:
1      A4 = 9 BCR
2      A9 = 8 R
3      B1 = 7 C
4      B4 = 1 N
5      E1 = 9 C
6      F8 = 9 B
7      H2 = 7 R
8      I9 = 9 R

Stage 6:
1      A1 = 1 BCN
2      A8 = 7 BCN
3      D9 = 7 R
4      E3 = 5 BC
5      G1 = 5 N
6      G8 = 8 R
7      H9 = 4 N
8      I8 = 1 NR

Stage 7:
1      C2 = 5 BCR
2      C3 = 2 N
3      D3 = 1 N
4      D7 = 4 BCR
5      E6 = 7 C
6      E7 = 8 N
7      F1 = 2 N
8      F3 = 7 BR
9      G7 = 7 BCNR
10     H1 = 3 N
11     H6 = 1 BCR
12     I1 = 4 BCR
13     I2 = 2 N
14     I6 = 5 N
 
Stage 8:
1      F6 = 8 BCNR
2      F7 = 1 BCNR
3      H7 = 5 BCNR
4      I7 = 3 BCNR


The steps that have multiple reasons are easier to find than those with only a single reason. For an explanation on the notation, please see the first blog (May 3, 2011).

3 comments:

  1. Stage 1, Step 1 Why B3 = 4 R ?

    I can understand B3 = 4 B
    even B3 = 4 C would make more sense to me.

    ReplyDelete
  2. Ooops, I see the error in my ways and Why Stage 1 Step 1 is correct. I used Hodoku to see it.

    It seems there is some "method to your madness" here as far as what ends up in a stage? I see a column scan priority from left to right. However,
    it seems you skip over NAKED cells at first. Would you explain the priority of naked cells?

    ReplyDelete
  3. The steps in each stage can be done in any order. They are independent of each other. Except for the first stage, the other stages require a step or more from the previous stage.

    Regarding naked cells or cells that can take on only one value, the step is denoted by the the reason N. If some of my solutions defer this step, it is only because this step is more difficult to find.

    What I call a jammed puzzle, has only one step that can be made. It is used to illustrate the more difficult puzzles and how they can be solved. The difficult steps have only a single reason for the step. Of the 4 reasons (B, C, R and N), the naked cell "N" is the most difficult to spot.

    A jammed puzzle is different from a locked puzzle. The locked puzzle is even more difficult and it requires an elimination step (or more) to solve it.

    ReplyDelete