Sudoku Solver

Expert

Unique Loop Type 1

Eliminate candidates from a single rescue cell to prevent a deadly pattern in a loop of 4 or more cells.

Unique Loop Type 1 is an advanced "uniqueness" strategy that extends the concept of Unique Rectangle (Type 1) to larger patterns. While Unique Rectangles work with exactly 4 cells, Unique Loops handle patterns of 6, 8, 10, or more cells that form a closed loop.

This strategy relies on a fundamental Sudoku rule: every valid puzzle must have exactly one unique solution.

Interactive Example

1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
5
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
4
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1
1 2 3 4 5 6 7 8 9
4
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
7
1 2 3 4 5 6 7 8 9
4
1 2 3 4 5 6 7 8 9
1
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
5
1 2 3 4 5 6 7 8 9
8
1 2 3 4 5 6 7 8 9
2
1 2 3 4 5 6 7 8 9
6
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
2
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
4
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
8
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
8
1 2 3 4 5 6 7 8 9
6
1 2 3 4 5 6 7 8 9
7
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
8
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
2
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
6
1 2 3 4 5 6 7 8 9
1
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
6
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
4
1 2 3 4 5 6 7 8 9
1
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9
9
1 2 3 4 5 6 7 8 9
7
1 2 3 4 5 6 7 8 9
4
1 2 3 4 5 6 7 8 9

Click "Apply Logic" to see the strategy in action.

Real Example Walkthrough

In the example puzzle above, the solver identifies a 6-cell Unique Loop:

The Loop Cells:

Cell Position Candidates Before
1 R1C2 {3, 9}
3 R1C4 {3, 9}
10 R2C2 {3, 9}
13 R2C5 {3, 9}
57 R7C4 {3, 9}
58 R7C5 {3, 5, 9} ← Rescue Cell

Step-by-Step Analysis:

  1. Identify the loop pair: Candidates {3, 9} appear in all 6 cells
  2. Count cells with extras: Only R7C5 has an extra candidate (5)
  3. Apply Type 1 logic: R7C5 cannot be 3 or 9, because that would complete the deadly pattern
  4. Eliminate: Remove 3 and 9 from R7C5

Result: R7C5 is reduced to {5}, which places the value 5 in that cell.

What Is a Unique Loop?

A Unique Loop is a series of cells that:

  1. Forms a closed loop (the chain returns to its starting cell)
  2. Contains 4 or more cells (most commonly 6 cells)
  3. All cells share the same two candidate values (the "loop pair")
  4. The loop alternates through rows, columns, and boxes in a specific pattern

If all cells in the loop contained only the loop pair (e.g., {3, 9}), the puzzle would have two valid solutions—you could swap the values around the loop and both arrangements would work. This is called a Deadly Pattern.

The Deadly Pattern Problem

Imagine a 6-cell loop where every cell contains exactly {3, 9}:

Cell Position Candidates
R1C2 {3, 9}
R1C4 {3, 9}
R2C2 {3, 9}
R2C5 {3, 9}
R7C4 {3, 9}
R7C5 {3, 9}

In this state, you could place either: - 3 in the odd positions and 9 in the even positions, OR - 9 in the odd positions and 3 in the even positions

Both arrangements satisfy all Sudoku rules—creating two solutions. Since a proper Sudoku cannot have multiple solutions, this pattern is impossible and must be prevented.

Type 1: The Single Rescue Cell

Unique Loop Type 1 applies when:

  • All cells in the loop contain the loop pair
  • Exactly one cell has extra candidates beyond the pair

This cell is called the "rescue cell" because it "rescues" the puzzle from having a deadly pattern.

The Logic

Since the deadly pattern cannot exist: - The rescue cell must NOT be one of the loop pair values - It must be one of its extra candidates - Therefore, we can eliminate the loop pair values from the rescue cell

How the Loop Forms

Unlike Unique Rectangles which use a simple 2×2 shape, Unique Loops follow a path through the grid:

Loop path (simplified): R1C2 → (Row 1) → R1C4 → (Column 4) → R7C4 → (Row 7) → R7C5 ↑ ↓ └── (Column 2) ← R2C2 ← (Row 2) ← R2C5 ← (Column 5) ←───┘

Key validation rules: - Each row/column/box visited by the loop must contain exactly 2 cells from the loop - These 2 cells must be at alternating positions in the loop (odd/even) - The loop must span exactly 2 boxes (not 1, not 3+)

How to Spot Unique Loop Type 1

  1. Find bivalue cells: Look for cells with exactly 2 candidates
  2. Look for matching pairs: Find multiple cells sharing the same pair of candidates
  3. Check for a loop: Verify the cells form a closed path through rows/columns
  4. Count rescue cells: For Type 1, exactly ONE cell should have extra candidates
  5. Eliminate: Remove the loop pair values from the rescue cell

Common Loop Sizes

Loop Size Cells Shape Description
4 cells 4 Standard Unique Rectangle
6 cells 6 This example (most common loop)
8 cells 8 Extended loop pattern
10+ cells 10+ Rare but possible

When Type 1 Doesn't Apply

Type 1 specifically requires exactly one rescue cell. If you find:

Comparison with Unique Rectangle

Feature Unique Rectangle Unique Loop
Cell count Exactly 4 4, 6, 8, 10...
Shape Rectangle (2 rows × 2 cols) Any closed loop
Box constraint Spans 2 boxes Spans 2 boxes
Complexity Easier to spot Harder to spot

Tips for Beginners

  1. Start with rectangles: Master Unique Rectangle (Type 1) first
  2. Use notation: Mark bivalue cells with their candidates
  3. Look for pairs: Cells with the same two candidates are your starting point
  4. Trace carefully: Loops can be tricky—trace the path step by step
  5. Verify the loop: Ensure each region has exactly 2 loop cells

Why This Strategy Works

The uniqueness principle states that a properly constructed Sudoku puzzle has one and only one solution. If a deadly pattern could exist, the puzzle would have multiple solutions—violating this principle.

By identifying potential deadly patterns before they form, we can deduce which candidates are impossible and eliminate them. The rescue cell's extra candidates are the only values that can prevent the deadly pattern, so the loop pair values must be false.

Related Strategies

Unique Loop Family

Unique Rectangle Family

Other Uniqueness Strategies

  • BUG+1 — Bivalue Universal Grave with single extra cell