Unique Rectangle
A Unique Rectangle exploits the fact that valid Sudoku puzzles have exactly one solution. Certain candidate patterns would create multiple solutions — a deadly pattern. By preventing these patterns, we can make eliminations.
The Deadly Pattern
Imagine four cells at the corners of a rectangle:
- All four cells span exactly two boxes
- All four cells contain only candidates {A, B}
This creates a deadly pattern because you can swap A and B between the diagonals and still have a valid solution:
puzzle: S9B9E9E06030204080A0E08050O0F090A0S0G0U0S0W0A070H0E7O8M1I857P04820C0706087O030H82820F0B0A0D077O0607040A0H030E7O987W840A0G038A8I0H9U9I860H040F8202011N0R08020509071I1Q
mode: static
settings:
showCandidates: true
coordinateFormat: none
initial:
annotations:
- cells: [R4C1]
label: "A"
- cells: [R4C9]
label: "B"
- cells: [R6C1]
label: "B"
- cells: [R6C9]
label: "A"
Since valid puzzles have unique solutions, this pattern cannot occur. The different types of Unique Rectangle exploit this in various ways.
Type 1: Single Extra Corner
The simplest case. Three corners have only {A, B}, but the fourth has {A, B, C, ...}.
The Logic
- If the fourth corner were just {A, B}, we'd have a deadly pattern
- The extra candidates prevent this
- Therefore, the fourth corner MUST be one of the extra candidates
- Eliminate A and B from the fourth corner
Example
puzzle: S9B9E9E06030204080A0E08050O0F090A0S0G0U0S0W0A070H0E7O8M1I857P04820C0706087O030H82820F0B0A0D077O0607040A0H030E7O987W840A0G038A8I0H9U9I860H040F8202011N0R08020509071I1Q
mode: guided
settings:
showCandidates: true
showControls: true
showDescription: true
navigation: numbered
coordinateFormat: rncn
steps:
- text: >
Look for a rectangle spanning two boxes. R4C1, R4C9, R6C1, and R6C9 form
the corners of a potential Unique Rectangle.
technique: UR1
hint: subtle
state:
selection:
cells: [R4C1, R4C9, R6C1, R6C9]
- text: >
Examine the floor cells. R4C9 and R6C9 each contain only {2, 9} —
these are the bi-value "floor" cells of our rectangle.
technique: UR1
hint: obvious
state:
selection:
cells: [R4C9, R6C9]
annotations:
- cells: [R4C9, R6C9]
label: "Floor"
style: pattern
- text: >
Now look at R4C1 and R6C1 — it has {1, 2, 5, 9}. This are the "roof" cells with
extra candidates (1 and 5) beyond the deadly pair {2, 9}.
technique: UR1
hint: obvious
state:
selection:
cells: [R4C1, R6C1]
annotations:
- cells: [R4C9, R6C9]
label: "Floor"
style: pattern
- cells: [R4C1, R6C1]
label: "Roof"
style: pattern
- text: >
If R4C1 were reduced to just {2, 9}, we'd have four cells each containing
only {2, 9}. This creates a deadly pattern — swapping 2s and 9s would
give two valid solutions, which is impossible in a proper Sudoku.
technique: UR1
hint: detailed
state:
selection:
cells: [R4C1, R4C9, R6C1, R6C9]
- text: >
Therefore, R4C1 cannot be 2 or 9 — it must be one of the extra candidates.
**Eliminate 2 and 9 from R4C1**, leaving only {1, 5}.
technique: UR1
hint: detailed
state:
selection:
cells: [R4C1]
Type 2: Two Corners with Same Extra
Two cells have the same extra candidate. Two corners have {A, B}, two corners have {A, B, C}.
The Pattern
C4 C8
R2 {A,B} {A,B,C}
R6 {A,B} {A,B,C}
The Logic
- The two {A, B, C} cells share a row, column, or box
- The extra digit C MUST appear in one of them (to prevent deadly pattern)
- Eliminate C from any cell that sees BOTH of the {A, B, C} cells
Key Requirement
The two cells with the extra candidate must share a unit AND that unit must contain other cells with candidate C.
Example
puzzle: S9B0D022R0I2R2R0C0H0F1306130B4N4J070904082E090U062I020E0A070R4Z56BE037N0B0E09164I0162020F2I030B0V1J059MAI7N2I080N7R044602B6050F070608020G0Z0Z0D030I129U2Q1Q7Y8Q0H010B
mode: guided
settings:
showCandidates: true
showControls: true
showDescription: true
navigation: numbered
coordinateFormat: rncn
steps:
- text: >
Find the rectangle: R1C5, R1C6, R8C5, and R8C6 form a Unique Rectangle
spanning boxes 2 and 8.
technique: UR2
hint: subtle
state:
selection:
cells: [R1C5, R1C6, R8C5, R8C6]
- text: >
The floor cells R8C5 and R8C6 each contain only {1, 5} — these are the
deadly pair candidates.
technique: UR2
hint: obvious
state:
selection:
cells: [R8C5, R8C6]
annotations:
- cells: [R8C5, R8C6]
label: "Floor"
style: pattern
- text: >
The roof cells R1C5 and R1C6 both contain {1, 5, 7}. They share the same
extra candidate: **7**. Both roof cells are in the same box (Box 2).
technique: UR2
hint: obvious
state:
selection:
cells: [R1C5, R1C6]
annotations:
- cells: [R1C5, R1C6]
label: "Roof"
style: pattern
- text: >
To avoid the deadly pattern, at least one roof cell must be 7.
Since both roof cells are in Row 1 and Box 2, any cell that sees BOTH
of them cannot be 7.
technique: UR2
hint: detailed
state:
selection:
cells: [R1C5, R1C6]
- text: >
R1C3 sees both roof cells (same row), and R3C6 sees both (same box/column).
**Eliminate 7 from R1C3 and R3C6**.
technique: UR2
hint: detailed
state:
selection:
cells: [R1C3, R3C6]
Type 3: Pseudo-Naked Subset
Extra candidates form a naked pair/triple with another cell. Two corners have {A, B}, two have extra candidates that combine with a nearby cell.
The Pattern
C4 C8
R2 {A,B} {A,B,C}
R6 {A,B} {A,B,D}
+ nearby cell {C,D}
The Logic
- The two roof cells have extras {C} and {D}
- A bi-value cell {C, D} in the same unit as both roof cells
- Together they form a "naked triple" — {C, D} must occupy these three cells
- Apply standard naked subset elimination rules
This is essentially a hidden naked pair/triple using the rectangle to identify it.
Note: Type 3 is rare in practice. The pattern requires specific conditions where the extras form a naked subset with an external cell.
Type 4: Locked Candidate (Strong Link)
A conjugate pair within the rectangle forces elimination. One of the deadly pair digits is "locked" to the roof cells.
The Pattern
C7 C9
R2 {A,B,X} {A,B} ← roof cells
R7 {A,B,Y} {A,B} ← floor cells have only {A,B}
The Logic
- Look at candidate A in the roof cells (R2C7 and R7C7)
- If A forms a conjugate pair in column 7 (only two places for A)
- Then one roof cell MUST be A
- This prevents the deadly pattern
- Eliminate the OTHER digit (B) from both roof cells
Key Insight
The strong link "locks in" one of the deadly pair digits, breaking the pattern.
Example
puzzle: S9B8I8I43050B03040743052E0B082B047R067Q042E432B09064705020805070P0N09060L040302040643070509437N7N060S4A054403070208052E06019I047Q371F092M2M082H0L052B04030905022B0806
mode: guided
settings:
showCandidates: true
showControls: true
showDescription: true
navigation: numbered
coordinateFormat: rncn
steps:
- text: >
Find the rectangle: R2C7, R2C9, R7C7, and R7C9 form a Unique Rectangle
spanning boxes 3 and 9.
technique: UR2
hint: subtle
state:
selection:
cells: [R2C7, R2C9, R7C7, R7C9]
- text: >
The floor cells R2C9 and R7C9 each contain only {3, 9} — the deadly pair.
technique: UR2
hint: obvious
state:
selection:
cells: [R2C9, R7C9]
annotations:
- cells: [R2C9, R7C9]
label: "Floor"
style: pattern
- text: >
The roof cells R2C7 and R7C7 have extras beyond {3, 9}. Look at digit 9
in column 7 — it appears **only** in these two roof cells.
technique: UR2
hint: obvious
state:
selection:
cells: [R2C7, R7C7]
annotations:
- cells: [R2C7, R7C7]
label: "Roof"
style: pattern
- text: >
This creates a strong link: one of R2C7 or R7C7 **must** be 9.
If one roof cell is 9, the deadly pattern is broken.
technique: UR2
hint: detailed
state:
selection:
cells: [R2C7, R7C7]
- text: >
Since 9 is locked to the roof, 3 cannot also be in both roof cells
(that would still allow the deadly pattern). **Eliminate 3 from R2C7
and R7C7**.
technique: UR2
hint: detailed
state:
selection:
cells: [R2C7, R7C7]
Type 5: Diagonal Exclusion
A restricted digit forces diagonal placement. One of the deadly pair digits appears only within the rectangle cells.
The Pattern
C3 C5
R1 {A,B} {A,B} ← roof: A appears here AND in floor
R2 {A,B} {A,B} ← but B ONLY appears in rectangle
The Logic
- Digit B appears only in the rectangle cells (within rows 1-2 and columns 3-5)
- B must occupy exactly two cells — one per row and one per column
- This forces B into a diagonal: either (R1C3, R2C5) or (R1C5, R2C3)
- The other diagonal must contain A
- Eliminate A from the floor cells on the forced diagonal
Key Insight
When a digit is restricted to the rectangle, it must occupy a diagonal, forcing the other digit to the opposite diagonal.
Example
puzzle: S9B8I8I45050L03040743052E0L082D047R067Q042E432B09064705020805070P0N09060L040302040643070509437N7N060S4A054403070208052E06019I047Q371F092M2M082H0L052B04030905022B0806
mode: guided
settings:
showCandidates: true
showControls: true
showDescription: true
navigation: numbered
coordinateFormat: rncn
steps:
- text: >
Find the rectangle: R1C3, R1C5, R2C3, and R2C5 form a Unique Rectangle
spanning boxes 1 and 2.
technique: UR2
hint: subtle
state:
selection:
cells: [R1C3, R1C5, R2C3, R2C5]
- text: >
All four cells contain candidates {1, 2}. This looks like a deadly
pattern, but let's check if one digit is restricted.
technique: UR2
hint: obvious
state:
selection:
cells: [R1C3, R1C5, R2C3, R2C5]
- text: >
Look at digit 2 in rows 1-2 and columns 3-5. Digit 2 appears **only**
in the rectangle cells — nowhere else in these rows/columns!
technique: UR2
hint: obvious
state:
selection:
cells: [R1C3, R1C5, R2C3, R2C5]
- text: >
Since 2 must appear once per row and once per column, it must occupy
a diagonal: either (R1C3, R2C5) or (R1C5, R2C3).
technique: UR2
hint: detailed
state:
selection:
cells: [R1C3, R2C5]
- text: >
The opposite diagonal will contain 1. To avoid the deadly pattern,
**eliminate 1 from the floor cells** R1C5 and R2C3.
technique: UR2
hint: detailed
state:
selection:
cells: [R1C5, R2C3]
Summary Table
| Type | Configuration | Action |
|---|---|---|
| 1 | Three {A,B}, one {A,B,C...} | Eliminate A,B from fourth corner |
| 2 | Two {A,B}, two {A,B,C} same extra | Eliminate C from cells seeing both |
| 3 | Two {A,B}, two with extras forming subset | Apply naked subset elimination |
| 4 | Roof cells have strong link for A or B | Eliminate other digit from roof |
| 5 | Bi-value cell adjacent | Forces placement via chain |
Finding Unique Rectangles
- Look for rectangles — Four cells spanning exactly two boxes, two rows, two columns
- Check candidate pairs — Find cells with mostly the same two candidates
- Find the asymmetry — The "extra" candidates prevent the deadly pattern
- Identify the type — Match the pattern to apply the correct rule
Valid Puzzle Assumption
Unique Rectangle techniques rely on the puzzle having exactly one solution. If you're solving a puzzle that might have multiple solutions, these techniques could give incorrect results. All legitimate Sudoku puzzles have unique solutions.
More Puzzles
- Unique Rectangle ex. 1
- Unique Rectangle ex. 2
- Unique Rectangle ex. 3
- Unique Rectangle ex. 4
- Unique Rectangle ex. 5
- Unique Rectangle ex. 6
- Unique Rectangle ex. 7
- Unique Rectangle ex. 8
- Unique Rectangle ex. 9
- Unique Rectangle ex. 10
- Unique Rectangle ex. 11
- Unique Rectangle ex. 12
- Unique Rectangle ex. 13
- Unique Rectangle ex. 14
- Unique Rectangle ex. 15
Related Techniques
- BUG — Another uniqueness-based technique
- Hidden Pair — Similar pair-based logic