Hard

Unique Rectangle

Four cells forming a rectangle across two boxes. Preventing a deadly pattern that would allow two solutions.

What Is It?

A Unique Rectangle (UR) is a pattern involving four cells that form a rectangle, two rows, two columns, spanning exactly two boxes. If all four cells contained only the same two digits, you could swap those digits in all four cells and still have a valid solution. This is called a "deadly pattern" and violates the uniqueness of a proper Sudoku.

Since a valid Sudoku must have exactly one solution, we know this deadly pattern cannot occur. This lets us eliminate candidates that would create or complete the deadly pattern. There are several types of Unique Rectangles, each exploiting this principle in a different way.

Unique Rectangles are among the most commonly used advanced techniques. They're powerful because they leverage a meta-property of the puzzle (uniqueness) rather than pure constraint logic.

How It Works

Identify four cells forming a rectangle across two boxes, where two digits appear as candidates in all four corners. These are the "UR digits." If all four cells were bivalue with only these two digits, swapping would create two solutions.

Type 1: Three corners are bivalue (only the UR digits). The fourth has extra candidates. Remove the UR digits from that fourth corner, it must resolve to one of its extra candidates to prevent the deadly pattern.

Type 2: Two corners are bivalue. The other two (the "roof" cells) share the same single extra candidate C and are in the same row, column, or box. Since at least one roof cell must be C to break the pattern, C is locked between them — eliminate C from all other cells in their shared unit. If further constraints force C into one specific roof cell, the UR digits can also be eliminated from that cell.

Type 3: Two corners are bivalue. The other two have extra candidates. The combined extras from the roof cells form a naked subset (pair, triple) with another cell in their shared unit. Digits in that subset can be eliminated from other cells in the unit.

Type 4: Two corners are bivalue. The other two have different extras, but one UR digit forms a strong link between them (appears only in those two cells within their shared row or column). That digit must go in one of them, so the other UR digit can be eliminated from both.

Worked Example

Example 1: Unique Rectangle Type 1

Look at cells R5C2, R5C3, R9C2, R9C3, a rectangle spanning rows 5 and 9, columns 2 and 3, across boxes 4 and 7. The UR digits are {1, 3}.

Three corners (R5C2 {1, 3}, R5C3 {1, 3}, and R9C3 {1, 3}) are bivalue. The fourth corner R9C2 has {1, 3, 9}. If R9C2 were also bivalue {1, 3}, the deadly pattern would form. Therefore, remove 1 and 3 from R9C2.

R9C2 is reduced to just {9} and is immediately solved. The deadly pattern is prevented.

Example 2: Unique Rectangle Type 2

Now look at R5C2, R5C6, R6C2, R6C6, UR digits {3, 9}. Corners R5C2 and R6C2 are bivalue {3, 9}. The other two corners R5C6 and R6C6 each have the same extra candidate: 6.

To prevent the deadly pattern, at least one of the non-bivalue corners must be 6 (not {3, 9}). Since both share the extra digit 6, the UR digits can be eliminated from the more constrained corner. Eliminate 3 and 9 from R6C6.

R6C6 is reduced to {6}. The Type 2 elimination works because the shared extra candidate guarantees the deadly pattern cannot form.

Example 3: Unique Rectangle Type 3

Look at R1C8, R1C9, R8C8, R8C9 with UR digits {3, 8}. The floor cells R1C8 and R1C9 are bivalue {3, 8}. The roof cells R8C8 has {3, 4, 7, 8} and R8C9 has {3, 7, 8}.

To avoid the deadly pattern, at least one roof cell must resolve to a non-UR digit. Strip the UR digits from the roof cells: R8C8 has extras {4, 7} and R8C9 has extra {7}. The combined extras are {4, 7}.

In box 9, R7C7 also has candidates {4, 7}. The roof cells' extras together with R7C7 form a naked pair on {4, 7} in box 9. Therefore, eliminate 4 and 7 from all other cells in box 9: R7C8 loses {4, 7}, R7C9 loses {7}, R9C8 loses {4}.

Example 4: Unique Rectangle Type 4

Look at R3C5, R3C6, R8C5, R8C6 with UR digits {2, 7}. Corners R3C5 and R8C5 are bivalue {2, 7}. Corner R3C6 has {2, 6, 7} and R8C6 has {2, 7, 8}, different extra candidates.

In column 6, digit 7 appears only in R3C6 and R8C6, a strong link. One of these cells must be 7 to satisfy column 6. Since 7 is guaranteed in one of them, digit 2 can safely be eliminated from both.

Eliminate 2 from R3C6 and R8C6. R3C6 becomes {6, 7} and R8C6 becomes {7, 8}. The strong link on digit 7 prevents the deadly pattern.

Key Points

Related Techniques

All Sudoku Techniques

Explore all 28 solving techniques in our complete technique guide.