Sudoku Unique Rectangle Guide: Complete Types 1/2/3/4 Tutorial
Unique Rectangle (UR) is one of the most important advanced Sudoku techniques. It leverages the rule that a valid Sudoku must have exactly one solution. When the grid shows a rectangular pattern that could form a "Deadly Pattern," we can use this to eliminate certain candidates and ensure the puzzle has a unique solution.
If four cells (at the intersection of two rows and two columns, distributed across exactly two boxes) all contain only the same two candidates {a, b}, then these four cells would have two valid ways to be filled (forming a Deadly Pattern), resulting in multiple solutions. Since a proper Sudoku must have a unique solution, this pattern cannot occur, and we can use this to eliminate candidates.
The Unique Rectangle technique has several types based on the candidate distribution in the rectangle cells. This article explains the four most common types: Type 1 (Basic), Type 2 (Same Extra Candidate), Type 3 (Subset), and Type 4 (Strong Link).
Terminology
- Floor Cells: Cells in the rectangle containing only the two candidates {a, b}. If all cells were floor cells, they would form a Deadly Pattern
- Roof Cells: Cells in the rectangle containing {a, b} plus additional candidates. These extra candidates are key to breaking the Deadly Pattern
- UR Pair: The two candidates {a, b} that form the Unique Rectangle
Before reading this article, we recommend mastering the Sudoku naming conventions and basic candidate techniques.
Type 1: Basic
Type 1 is the simplest and most intuitive Unique Rectangle type. It is characterized by: three floor cells (containing only {a, b}) and one roof cell (containing {a, b} plus other candidates).
Type 1 Rule
If three of the four UR cells contain only {a, b} and one contains {a, b, x...},
Then that roof cell must be filled with one of x... (not a or b), so we can eliminate a and b from the roof cell.
Example Analysis
Observe the grid. We find the following four cells forming a rectangular structure:
- R1C4: Candidates {4, 5} (floor cell)
- R1C8: Candidates {4, 5} (floor cell)
- R3C4: Candidates {4, 5} (floor cell)
- R3C8: Candidates {1, 4, 5, 8} (roof cell, with extra candidates 1, 8)
These four cells are at the intersection of rows 1, 3 and columns 4, 8, distributed across boxes 2 and 3, satisfying the Unique Rectangle conditions.
Unique Rectangle Type 1: R1C4, R1C8, R3C4, R3C8 contain {4, 5}
Eliminate candidates 4 and 5 from R3C8, leaving {1, 8}
Type 2: Same Extra Candidate
Type 2 is characterized by: two floor cells (containing only {a, b}) and two roof cells, where both roof cells contain the same extra candidate x.
Type 2 Rule
If a UR has two floor cells {a, b} and two roof cells {a, b, x} (same extra candidate),
Then at least one roof cell must contain x (otherwise a Deadly Pattern forms), so other cells that see both roof cells can have candidate x eliminated.
Example Analysis
Observe the Unique Rectangle structure:
- R2C4: Candidates {6, 8, 9} (roof cell)
- R2C7: Candidates {6, 8} (floor cell)
- R3C4: Candidates {6, 8, 9} (roof cell)
- R3C7: Candidates {6, 8} (floor cell)
Both roof cells R2C4 and R3C4 have extra candidate 9, and they are in the same column (column 4).
- R2C6 (row 2 sees R2C4): Eliminate candidate 9
- R3C5 (row 3 sees R3C4, box 2 sees R2C4): Eliminate candidate 9
- R7C4 (column 4): Eliminate candidate 9
- R9C4 (column 4): Eliminate candidate 9
Unique Rectangle Type 2: R2C4, R2C7, R3C4, R3C7 contain {6, 8}, extra candidate 9
Eliminate candidate 9 from R2C6, R3C5, R7C4, R9C4
Type 3: Subset
Type 3 combines Unique Rectangle with hidden/naked subset techniques. The two roof cells have different extra candidates, and these extra candidates form a subset relationship with other cells in the same unit.
Type 3 Rule
If two roof cells contain {a, b, x} and {a, b, y} (or {a, b, x, y} combinations),
And these extra candidates {x, y...} form a naked subset with other cells in the same row/column/box,
Then other cells in that unit can have the corresponding candidates eliminated according to subset rules.
Example Analysis
Observe the Unique Rectangle structure:
- R4C1: Candidates {7, 8} (floor cell)
- R4C2: Candidates {2, 7, 8} (roof cell, extra candidate 2)
- R8C1: Candidates {7, 8} (floor cell)
- R8C2: Candidates {2, 6, 7, 8} (roof cell, extra candidates 2, 6)
- R5C2: Eliminate candidate 2
- R7C2: Eliminate candidates 2 and 6
Unique Rectangle Type 3: R4C1, R4C2, R8C1, R8C2 contain {7, 8}
Roof cells must keep at least one of {2, 6}, forming a subset with R9C2, locking {2, 6} in column 2
Eliminate 2 from R5C2, eliminate 2 and 6 from R7C2
Type 4: Strong Link
Type 4 utilizes the concept of strong links. When two roof cells are in the same row/column/box, and one of the UR pair candidates appears only in these two roof cells within that unit, a special elimination can be made.
Type 4 Rule
If two roof cells are in the same unit (row/column/box) and UR pair candidate a appears only in these two roof cells within that unit,
Then one of these roof cells must contain a (strong link), so they cannot both contain b. Therefore, we can eliminate the other UR pair candidate b from both roof cells.
Example Analysis
Observe the Unique Rectangle structure:
- R5C1: Candidates {3, 6} (floor cell)
- R5C7: Contains {3, 6} plus extras (roof cell)
- R6C1: Candidates {3, 6} (floor cell)
- R6C7: Contains {3, 6} plus extras (roof cell)
The two roof cells R5C7 and R6C7 are both in column 7 and both contain candidates 3 and 6.
- R5C7: Eliminate candidate 6
- R6C7: Eliminate candidate 6
Unique Rectangle Type 4: R5C1, R5C7, R6C1, R6C7 contain {3, 6}
R5C7, R6C7 must have 3 in column 7 (strong link), cannot both be 6
Eliminate candidate 6 from R5C7, R6C7
Comparison of Four Types
| Type | Floor Cells | Roof Cells | Characteristic | Elimination Target |
|---|---|---|---|---|
| Type 1 | 3 | 1 | Single roof cell has extra candidates | Eliminate UR pair from roof cell |
| Type 2 | 2 | 2 | Both roof cells have same extra candidate x | Eliminate x from cells seeing both roof cells |
| Type 3 | 2 | 2 | Extra candidates form subset with other cells | Eliminate by subset rules from same unit |
| Type 4 | 2 | 2 | One UR pair candidate forms strong link in roof cells' unit | Eliminate other UR pair candidate from roof cells |
How to Find Unique Rectangles?
- The four UR cells must be distributed across exactly two boxes (not in one box, and not in three or four boxes)
- The UR pair {a, b} must be common candidates in all four cells
- The Unique Rectangle technique assumes the Sudoku has a unique solution; it doesn't apply to puzzles that may have multiple solutions
Summary
- Core Idea: Use the "Sudoku must have a unique solution" rule to avoid Deadly Patterns
- Identification: Four cells forming a rectangle across two rows, two columns, and two boxes, all containing the same two candidates
- Type Selection: Choose handling method based on floor/roof cell counts and extra candidate distribution
- Application: Advanced Sudoku solving, especially when other techniques cannot make progress
Unique Rectangle is a powerful advanced technique that requires practice to master. Suggestions:
- Start practicing with Type 1 - it's easiest to identify and understand
- Get comfortable with pencil marks - this makes it easier to spot potential rectangular patterns
- Remember the key criteria: four cells, two rows, two columns, two boxes, same pair
- Types 3 and 4 require knowledge of other techniques (subsets, strong links) - master those first
Start a hard difficulty Sudoku game and try to find and apply the Unique Rectangle technique!