Strategies for Number Puzzles of all kinds
  Print Version
Solvers
Puzzles
Basic Strategies
Tough Strategies
Diabolical Strategies
Extreme Strategies
Depreciated Strategies
Str8ts
Other
The Logic of Sudoku
  3D Medusa

3D Medusa extends Simple Colouring (or 'Single's chains') into a third dimension. Simple Colouring looked for pairs of X in rows, columns and boxes. Wherever the chains led they stuck to the same candidate number. This is good for tracking an elimination when you have made notes on a paper Sudoku for a particular number but it limits the scope of the strategy. The way we extend the search is up through the bi-value cells which contain two different numbers. You can think of the different candidate numbers as existing in a third dimension lifting up from the page with 1 at the bottom and 9 at the top.

The devastating effect of colouring is that we are showing that ALL of one colour will be the solution. We don't know which set yet - but if any one of those cells becomes the solution we can know for certain ALL the cells of the same colour

Rule 1 - twice in a cell

There are six different ways we eliminate - six contradictions. The first is in the example to the right. It doesn't matter where you start on the grid. In this example I've started with the 4s in row B. By colouring one green and the other yellow we mentally draw a line between them, done graphically on the diagram. Going into the third dimension in B7 when we colour the 4 yellow we can colour the 9 green - since there are only two values left in the cell.

Continue to look for bi-value and bi-location candidates and you soon build up a web of connections. This is where the image of Medusa was perhaps attached to this strategy - her head being a tangle of snakes.
3D Medusa Rule 1
3D Medusa Rule 1: Load Example or : From the Start
When you have built up a web of connections, alternating between two colours you might find a cell with the same colour set twice. This has been ringed in H2. Since we know that if yellow candidates have the potential to be ALL true we can't have a situation where two yellow numbers are competing for the same cell. This is a contradiction and therefore we can state that no yellow numbers can be the solution!

Rule 1 is: If two candidates in a cell have the same colour - all of that colour can be removed

Now I stated that if the solution is not one colour then it must be the other. There is a catch - you can't just set every cell with a green number to be the solution. When you eliminate a yellow number it *might* leave only a green number - in which case green is the solution. But look at H1. 1 is marked as green but there are other un-coloured candidates there. 1 *could* be the solution but it might not be. Always remove the yellow numbers and see what's left - don't just set green as the solution automatically.

Note: this rule does not exist in Simple Colouring since the same number does not appear twice in the same cell.

As an exercise, try colouring any of the highlighted cells starting from a different position. You may end up swapping the colours around and you may find some new connections. But eventually - in this example - you will get two of the same colour on H2. This is a very powerful yet simple strategy.

Rule 2 - Twice in a Unit

This rule is shared with Simple Colouring. Its the same principle as the first rule but we are looking for two coloured occurrences of X in the same unit (row, column or box) as opposed the two of the colour in the same cell.

The example shows most of the links between bi-value and bi-location candidates, coloured between green and yellow. Ringed in red are two 7s in row 7. Since both cannot be true neither can be true and all yellow coloured candidates can be removed
3D Medusa Rule 2
3D Medusa Rule 2: Load Example or : From the Start
Rule 3 - Two colours in a cell

If you had unticked 3D Medusa in the solver this example would have been found by a number of later strategies, particularly Alternating Inference Chains as the pattern is a classic Nice Loop. 3 and 7 alternate. It doesn't matter where you start in a Nice Loop but you can trace the on / off or green/blue round the loop. 3s and 7s neatly occur twice in units and cells.

But 3D Medusa is not about loops, its about the network of links. This example just happens to be the same formation. We know that either ALL the blue candidates will be true, or ALL the green ones. If there are any another candidates in any cell with two colours, they cannot be solutions. Hence the 8 can be removed from C2. In Nice Loop terms, this is an off-chain elimination.
3D Medusa Rule 3
3D Medusa Rule 3: Load Example or : From the Start
Simple Colouring cannot produce this elimination since it is restricted to a single candidate number.

Rule 4 - Two colours in a unit

If we can eliminate "off chain" in a cell we can certainly do so off-chain in a unit. In this example there are quite a few links between 2s, 4s and 6s. Most have been drawn on the diagram. We are certain than ALL blues are the solution or ALL greens. Therefore where there are candidates that can see both colours they can be removed. By 'see' we mean any candidates that are the same number as members of the blue/green links.

The 2s in row H are these. The 2 in H2 is removed because of the coloured 2s in row H. The 2s in H8 and H9 can see blue and green 2s in row H and box 9.
3D Medusa Rule 4
3D Medusa Rule 4: Load Example or : From the Start

Rule 5 - Two colours 'elsewhere'

Given the above possibilities, its tempting to generalise. The example to the right we have some 6s in row F. Both can see a green 6 in E9 and a blue 6 F5. This is not exactly like Rule 4 but very close. The 6s can be removed because they can see two different coloured candidates of 6 elsewhere.
3D Medusa Rule 5
3D Medusa Rule 5: Load Example or : From the Start
Rule 6 - Two colours Unit + Cell

The last type of elimination looks to be the most complex - but inconveniently it is the most common. It's well worth looking out for. The rule says

If an uncoloured candidate can see a coloured candidate elsewhere (it shares a unit) and an oppositely coloured candidate in its own cell, it can be removed..

So its a combination of unit and cell - the colours green and blue are found looking along a unit and within the same cell. The example to the right demonstrates this with four eliminations.

The logic is very appealing. Consider 1 in E5. If 1 were the solution to the cell it would remove a green 1 from E6 AND a blue 7 from its own cell in E5. Since we know ALL blue or ALL green must be solutions we have a contradiction.

3D Medusa Rule 6
3D Medusa Rule 6: Load Example or : From the Start

breakline

Comments...

Monday 7-Jun-2010

... by: suneet

Hello Andrew,

In the latest version you have removed multi-coloring and Multi-Value X-wing. What is the reason.
I know at least some problem which can be solved by multi-coloring but not by the 3D Medusa and simple coloring type 4 and 5.

Please explain.
Strange, but these strategy Multi coloring etc are present in kendoku 6 by 6 solver.
Regards suneet.

Wednesday 24-Mar-2010

... by: Oliver Paulsen

Hello Andrew,
my request do not concern Medusa but the top sudoku on this page. I want to know if there is some kind of unique rectangles (I call them forbidden bubbles) but in a larger form. There are 2 floors with 1 and 7 in line 1 and 5 and there is a strong link of them in row 9. The roof is in line 2 - cell B1 (147) and cell B8 (137). To avoid 17 for 6 times in this circle I would argue that the 7 in the roof-cells of line 2 have a strong link. There is no other place to stay in line 2. But the 1 can find a place in cell B6. So I would eleminate both 1 in the roof-cells and in B1 has to be the last 1 of this row. Is this argumentation which refers to unique rectangles type 4B correct in this case? Please let me hear

Kind regards Oliver

Andrew Stuart writes:
If you untick 3D Medusa it does find a Hidden Unique Rectangle, but not the one you identified. A deadly pattern is must be four cells sharing exactly 2 rows, 2 columns and 2 boxes, but you refer to many more than that so I don't immediatey get your example. You might have a loop there. In the next version of the solver I hope so present all alternatives at any one stage so if there is a pattern there is should pop out.

Add your comments

A confirmation email will be sent to you after submitting.

Your Name

Email Address - required for confirmation (it will not be displayed here)

Your comment or question

Remember me


Please keep your comments relevant to this article. Email addresses are never displayed, but they are required to confirm your comments.

When you enter your name and email address, you'll be sent a link to confirm your comment. If you want to be remembered, the check box above will store a cookie with your name and email address on your computer.

Line breaks and paragraphs are automatically converted — no need to use <p> or <br> tags.



Article created on 6-March-2010. Views: 5324
This page was last modified on 11-March-2010, at 10:10.
All text is copyright and for personal use only but may be reproduced with the permission of the author.
Copyright Andrew Stuart @ Scanraid Ltd, 2010