Minimal Sudoku
Learn Section

Sudoku Techniques: Mastering X-Wing and Swordfish

You've conquered naked and hidden subsets, you're comfortable with scanning and pencil marks, and you're hungry for even more advanced Sudoku techniques. If you're ready to tackle the toughest puzzles out there, then it's time to learn about X-Wing and Swordfish. These powerful strategies, based on identifying specific candidate patterns, will give you the edge you need to crack those seemingly unsolvable grids. X-Wing and Swordfish are similar in concept. X-Wing is the simplest form, Swordfish is an extension of X-Wing to a 3x3 set of candidates and a Finnyed Swordfish incorporates a 4th partially complete row, column or box.

Understanding the X-Wing

X-Wing is a powerful technique that can eliminate candidates and break through challenging Sudoku puzzles. Here's how it works:

  • The Pattern: X-Wing occurs when a candidate number appears in only two cells in each of two different rows (or columns), and those cells also align in two corresponding columns (or rows). This creates a rectangular or "X" shape.
  • The Logic: If a number can be placed in only two cells in a given row, one of these two cells must be occupied by this number. If these two rows are interconnected by the fact that the two cells of each row lie in the same columns, this logic can be extended. Since one of the options must contain the correct number in the first row, and one of the options must contain the correct number in the second row, one of the two columns must contain the correct number in the first row, and the other column must contain the correct number in the second row. Therefore, any other cell matching the identified number in these columns can be eliminated.
  • Elimination: Because of the either/or nature of the X-Wing, you can eliminate that candidate number from any other cells in those two columns (or rows).

Example

Consider a scenario where:

  • In Row 2, the number 5 can only be placed in Column 3 and Column 8.
  • In Row 7, the number 5 can only be placed in Column 3 and Column 8.

This forms an X-Wing. You can confidently eliminate the number 5 as a candidate from any other cells in Column 3 and Column 8.

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

Figure 1: X-Wing Example Highlighting cells (Row 2 Column 8) and (Row 7 Column 3), as well as (Row 2 Column 3) and (Row 7 Column 8).

Diving into Swordfish

Swordfish is essentially an extension of the X-Wing concept, applied to three rows and three columns instead of two.

  • The Pattern: In Swordfish, a candidate number appears in only two or three cells across three different rows, and these cells also align in the same three columns. This creates a more complex pattern that resembles a "swordfish" or grid shape.
  • The Logic: Similar to X-Wing, the logic dictates that the candidate number must be placed somewhere within those defined rows and columns. The logic can be extended in a similar manner to X-Wing. Since one of the options must contain the correct number in each of the three rows, one of the three columns must contain the correct number in each of the first, second, and third row. Therefore, any other cell matching the identified number in these columns can be eliminated.
  • Elimination: You can eliminate the candidate number from any other cells in those three columns (or rows).

Example

Imagine a case where:

  • In Row 1, the number 3 can be placed in Columns 2, 5, and 9.
  • In Row 4, the number 3 can be placed in Columns 2 and 5.
  • In Row 6, the number 3 can be placed in Columns 2 and 9.

This forms a Swordfish. You can then eliminate the number 3 as a candidate from any other cells in Columns 2, 5, and 9.

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

Figure 2: Swordfish Example Highlighting cells, (Row 1 Column 2), (Row 1 Column 5), and (Row 1 Column 9) as well as (Row 4 Column 2), (Row 4 Column 5), and lastly (Row 6 Column 2) and (Row 6 Column 9).

Finnyed Swordfish

The Finnyed Swordfish is a slight variation of the standard Swordfish. A standard Swordfish consists of 3 rows and 3 columns, with the target number limited to these rows and columns. In a Finnyed Swordfish, the target number has one additional possible cell outside of the 3x3 grid.

Example

  • In Row 1, the number 3 can be placed in Columns 2, 5, and 9.
  • In Row 4, the number 3 can be placed in Columns 2 and 5.
  • In Row 6, the number 3 can be placed in Columns 2 and 9, and also Column 7.

If Column 7 did not contain a possible placement for number 3, then according to the logic described in the Swordfish section, we could eliminate any other cells matching number 3 in columns 2, 5, and 9. However, since Column 7 contains an additional option for number 3, this is not necessarily true. You can eliminate other 3s in columns 2, 5, and 9 if, and only if, the additional cell in Column 7 can be eliminated due to it sharing a row or a box with one of the cells in the Swordfish pattern.

9. In this example, the additional cell in Column 7 shares a box with one of the cells identified in our Swordfish. If any of the other cells in this box already contains a 3, then it is not possible for the additional cell in Column 7 to contain a 3. In this case, since the additional cell in Column 7 cannot be 3, we can eliminate the number 3 as a candidate from any other cells in Columns 2, 5, and 9.

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

Figure 3: Finnyed Swordfish Example Highlighting cells, (Row 1 Column 2), (Row 1 Column 5), and (Row 1 Column 9) as well as (Row 4 Column 2), (Row 4 Column 5), and lastly (Row 6 Column 2), (Row 6 Column 9) and (Row 6 Column 7).

Tips for Spotting X-Wings and Swordfish

Identifying these patterns can be tricky, even for experienced players. Here are some tips to help you spot them:

  • Focus on Rows and Columns with Limited Candidates: Pay close attention to rows and columns where a particular candidate number appears only two or three times.
  • Use Pencil Marks Effectively: Properly using pencil marks is crucial for visualizing potential X-Wings and Swordfish patterns.
  • Practice Makes Perfect: The more you practice looking for these patterns, the easier it will become to identify them in actual puzzles.
  • Look for Symmetry: Both X-Wings and Swordfish have a certain degree of symmetry to their patterns. Training your eye to recognize this symmetry can help.

Putting Your Knowledge to the Test

The best way to master X-Wings and Swordfish is to practice! Try applying these techniques to challenging Sudoku puzzles.

  • Minimal Sudoku's Advanced Puzzles: We offer a selection of extremely difficult Sudoku puzzles specifically designed to challenge even the most seasoned players. Test your skills here: [Link to your advanced Sudoku puzzles page]
  • Seek Out Expert-Level Puzzles: Look for puzzles labeled "Expert" or "Diabolical" that are likely to require advanced techniques like X-Wing and Swordfish. You can also try to use the Sudoku solver on our website to analyze difficult puzzles and identify instances of X-Wings or Swordfish: [Link to your Sudoku solver page]

Conclusion

X-Wing and Swordfish are powerful tools in the advanced Sudoku player's arsenal. They may seem complex at first, but with patience and practice, you can master these techniques and conquer even the most daunting Sudoku grids. Remember to use pencil marks effectively, look for the characteristic patterns, and keep practicing! Now, go forth and put your new knowledge to the test. Visit us at Minimal Sudoku [Link to your website] to challenge yourself with expert-level puzzles and continue your Sudoku journey!

Play Advanced Sudoku Now