This is an extension of XYZ-Wing that uses four cells instead of three. A.k.a. Bent Quads.

I am grateful to**SudoNova** posting below and **StrmCkr** who posted about this strategy way back when on this page. I only got round to appreciating the insights recently but the much expanded version of WXYZ is now in version 1.96+ of the solver. Previously I'd restricted the scope to a very narrow definition. Using one of my test libraries, the 50k set from Ruud, I increased the detection from 299 instances to 8313, so it is definitely worth looking out for.

I'm going to start with my narrow definition if only to show how this is an extension of the three-cell XYZ-Wing.

I am grateful to

I'm going to start with my narrow definition if only to show how this is an extension of the three-cell XYZ-Wing.

Its name derives from the four numbers W, X, Y and Z that must be in exactly four cells. In my narrow definition we need a *hinge* cell containing all four candidates WXYZ and three outlier cells each containing a pair wZ, xZ and yZ - Z being the common number.

The easy principle is that each possible value of the hinge cell results in a Z value in one of the cells in the WXYZ-Wing pattern, thus leaving no room for a Z on any cell all four can 'see'.

The easy principle is that each possible value of the hinge cell results in a Z value in one of the cells in the WXYZ-Wing pattern, thus leaving no room for a Z on any cell all four can 'see'.

That's the narrow definition and a glance at XYZ Wing will show you its the same idea plus one more cell. You could expand it to a five cell pattern and five numbers.

Now, lets consider StrmCkr's more general definition:

**WXYZ-Wings can be considered as a group of 4 cells and 4 digits, that has exactly one non-restricted common digit.** We use that digit (Z) to eliminate since at least one of Z will be the solution.

Now, lets consider StrmCkr's more general definition:

So what is a non-restricted common digit?

Well, a restricted digit is one where all the instances of candidate N in the pattern can see each other. On the diagram to the left I have connected the W candidates - because they share the same box, and I can connect the Xs and Ys as they share a row. Only Z is non-restricted because some of the Zs - ie the one in C1 CANNOT see the Zs in B4 and B5.

Well, a restricted digit is one where all the instances of candidate N in the pattern can see each other. On the diagram to the left I have connected the W candidates - because they share the same box, and I can connect the Xs and Ys as they share a row. Only Z is non-restricted because some of the Zs - ie the one in C1 CANNOT see the Zs in B4 and B5.

In the first example I show a classic WYXZ wing - in that it has all four candidates (1/2/5/9) in the hinge cell D3 marked in brown. The three outlier cells, marked in yellow each contain a 9 (our Z) plus some of the other four candidates.

I have also marked in rings the spread of candidates 1, 2 and 5. You will see that both 1s can 'see' each other because they are in the same box. The 2s can 'see' each other because they are on the same row and the three 5s can all see each other since they share the same row as well. That makes 1, 2 and 5

Candidate 9 is different. At least one 9 (in F1) cannot see at least one other 9 - the 9s in D4 and D5. That makes it the only

Any WXYZ elimination will always be made on the non-restricted candidate. We are looking for a 9 elsewhere that can see every 9 in the four cells of our WXYZ pattern. That 9 is on D2.

It is important to note is that StrmCkr's rule says nothing about the hinge requiring four candidates and the other cells two. Like Quads, we need*in total* four candidates in four cells. This is a four-cell Locked Set. StrmCkr makes this point in his second corollary, So lets look at some examples where the is a thinner spread of four candidates.

Interestingly, where Z is present in less than four cells, ie three or just two cells of the four - more eliminations are possible because there are less cells that the eliminated candidates need to 'see'. I believe my new implementation WXYZ gives more variants than the 10 StrmCkr lists as exemplars.

It is important to note is that StrmCkr's rule says nothing about the hinge requiring four candidates and the other cells two. Like Quads, we need

Interestingly, where Z is present in less than four cells, ie three or just two cells of the four - more eliminations are possible because there are less cells that the eliminated candidates need to 'see'. I believe my new implementation WXYZ gives more variants than the 10 StrmCkr lists as exemplars.

The second WXYZ example is orientated in columns rather than rows, but works the same. The hinge cell in D6 conspicuously fails to contain the non-restricted candidate 5, but no matter. Whatever the final solution of D6 a 5 is forced into either E5 or one of the two cells G6/J6. The outliers are nice easy pairs - like my original narrow definition, but the improvement is not needing 5 (Z) in the hinge every time.

The solver tells us

WXYZ Wing

The four cells {D6,E5,G6,J6} contain in total 2/5/6/9.

Candidate 5 determines the 'wing' cells (in yellow) and one or other of those 5s must be true. Therefore...

5 can be taken off F6

5 can be taken off G5

5 can be taken off J5

Here is an example where the non-restricted common digit is present in just two pincer cells. We don't have to worry about 3s 'seeing' the brown cells as they don't have a 3 in them. Consider how the hinge cell in C1 solves when each digit is looked at. Suppose C1 is 4. That makes C8 contain 3/5. C8 + C3 + B2 now becomes an Y-Wing - and eliminates 3s in the same way. Interesting!

The solver returns

WXYZ Wing

The four cells {C1,B2,C8,C3} contain in total 3/4/5/9.

Candidate 3 determines the 'wing' cells (in yellow) and one or other of those 3s must be true. Therefore...

3 can be taken off B7

3 can be taken off B8

3 can be taken off B9

I'm ending this article with a nice Sudoku puzzle that has four Y-Wings an XYZ-Wings and four WXYZ-Wings. Here is the first of the later. It is worth following this through on the solver from the start.

Where next? StrmCkr's gives a theory example of a "double restricted common in a WXYZ-Wing when spanning the same band using box-box restraints" which I will explore at a future date. We can also go in the direction of a five cell VWXYZ-Wing but I think the next step is to exactly define the overlap and relationship with Almost Locked Sets - since a number of people have pointed out that these X-Wings are simple examples of ALSs.

Edit Sept 2015: There is an important post on WXYZ-Wings by Jon Welch which I recommend. I'm currently working through the implications but I'm definitely going to re-visit the Wings family again.

## Comments

## ... by: Matti

I have found a very practical way to look at ALSes in general.

ALS is often almost a Locked Set, it just has one extra candidate digit in its cells. N cells which all see each other, containing N+1 different candidates.

With a Locked Set you can eliminate candidates in row, column or block.

There are two cases:

1. The extra candidate (without which we have a Locked Set) is false: Check the eliminations which the Locked Set causes.

2. The extra candidate is true: Check the eliminations which the extra candidate itself causes.

Now you can make those eliminations which are common to cases 1. and 2.

This is actually how those finned Swordfishes, Jellyfishes etc. work.

WXYZ-Wing example 4:

Almost Locked Set {F2=[1,9], F4=[2,8,9], F6=[2,8,9]}, extra candidate is 1 in F2.

1. F2 is 9. We have the Locked Set which eliminates 8 from F3, (and 8 and 9 from F9). Since 8 has to be in either F4 or F6, 8 is eliminated from D4 and D6 (and E5).

2. F2 is 1. D1 is 8 which eliminates 8 from F3, D4 and D6 (and D3, D8, E2 and E3).

Thus, common eliminations for 8 are F3, D4 and D6, just like in the example picture.

I have found that checking ALSes is often pretty intuitive way to find eliminations and solutions to cells.

## ... by: Liz A.

Liz

## ... by: Robert

In my database of 244 "advanced" puzzles (those which require something more than naked/hidden singles/pairs/triples/quads, pointing pairs/triples, or box/line reduction), the addition of the various wing strategies gets me 13 fully solved, and 231 only partially solved.

Referencing my earlier post, the "star" configuration may exist, but it is either degenerate (any eliminations can be found by the basic strategies listed above, the Y-wing, and the XYZ-wing), or there are no eliminations at all (in the non-degenerate case, it is impossible for a target cell to be linked to all instances of the common digit). So the software I wrote doesn't search for this one, it only searches for the chain, the loop, the augmented triangle, and the diamond.

In any event, I found all four of these possibilities occur and result in eliminations, and disabling any one of them in my software results in some puzzles not fully solved.

So the chain, the loop, the augmented triangle, and the diamond are all relevant.

I mention this, because some web sites I see seem to assume that the WXYZ-wing has a group of three cells that share a unit, and this is not the case in the chain or the loop.

I'll think now about how these are special cases of ALS . . .

## ... by: Howard

Please help me with my doubts on the WXYZ-Wing strategy.

As I understand, basically WXYZ-Wing is defined as a group of 4 cells with 4 digits, that has exactly one non-restricted common digit (NRCD). The NRCD cannot be the solution in any cells that (1) are outside the WXYZ-Wing group and (2) can see all the cells of the group where the NRCD is present. However, based on my experience, it seems that this applies to all the digits of the WXYZ-Wing group, not necessarily NRCD. Cells that are outside the WXYZ-Wing and can see all the group cells with the digit cannot have the digit as solution as well.

In the WXYZ-Wing example 2 above, I think digit 6 inD6 andJ6 allow removal of digit 6 in E6 although digit 5 is the NRCD.

May I have your comments, please.

Howard

In example 2 above, the 6 in F6 can be eliminated because it sees both 6s (D6 and J6), one of which must be ON. The 2 in C6 may also be eliminated because it sees both 2s (D6 and G6). Generally, any external candidate that sees all of one of the digits in the four WXYZ-Wing cells may be eliminated.

David

## ... by: Robert

I've spent a fair amount of time thinking about this one. The definition does not specify how the cells are linked to each other. It could even apply to four completely independent cells (that is, no cell linked to any other cell), but it would be somewhat trvial in this case, because at least one cell would have only the unrestricted value, and we could get the same inference using simpler methods.

So I am thinking the only configurations that are not trivial (that is, where we can't get the same inference by different methods) are shown below. Cells are called A, B, C, and D.

The "chain": links are A<->B, B<->C, and C<->D. No links between any other pairs of cells.

The "star": links are A<->B, B<->C, and B<->D. No links between any other pairs of cells.

The "loop": links are A<->B, B<->C, C<->D, and D<->A. No links between any other pairs of cells.

The "augmented triangle": links are A<->B, B<->C, C<->A, and A<->D. No links between any other pairs of cells.

The "diamond": links are A<->B, B<->C, C<->D, D<->A, and A<->C. No link between B and D.

These configurations are all possible logical arrangements with three, four, or five links between pairs of cells. In any configuration with zero, one, two, or six links between pairs of cells, we get the exact same inference as in WXYZ-wing, and possibly more, using simpler methods.

It also occurs to me that this method is very much analogous to Y-wing and XYZ-wing. If we defined a strategy as one in which there are three cells, containing a total of three disctinct numbers between them, with one of the three numbers unrestricted, then Y-wing plus XYZ-wing cover the non-trivial cases (those that cannot be analysed using simpler methods). The XYZ-wing is analogous to your original, simple version of WXYZ-wing, and the Y-wing is the additional non-trivial configuration if the definition is expanded analogously to the way WXYZ-wing was expanded.

Does that all sound correct?

## ... by: Arthur BÃ¡rbaro

I think you got it wrong: the restricted numbers in that case are 1 2 9 (because all 1s see each other, all 2s see each other, and all 9s see each other), and the not-restricted one is the 8 (because the 8s in F don't see the 8 in D). Thus, as by StrmCkr's rule, the 8 doesn't need to be in the hinge (F2), but all 8s to be eliminated need to see all other three non-hinge cells (as is the case in F3 D4 D6, as shown in the picture).

I hope I got it right and explained it well. =)

## ... by: Harold Binley

Once again thanks for your website giving me the ability to check my progress on Sudokus and also to provide a hint/solution to one more step.

Iâ€™ve been working through the Daily Telegraphâ€™s Diabolical Soduku 4684 and needed help in the next step. Your solver suggested an WXYZ wing so I looked up your documentation link for this strategy.

Working through your example WXYZ-Wing example 4 , after the 2 Y wings and the first XYZ wing, (IE before the XY cycle), the position includes the following candidates in these cells:

D1 1 8

F2 1 8 9

F4 2 8 9

F6 2 8 9

According to your website -â€œ StrmCkr's more general definition - WXYZ-Wings can be considered as a group of 4 cells and 4 digits, that has exactly one non-restricted common digit.â€ I believe in the current situation 1, 8, 9 are restricted digits.

If F2, as I believe, is still the hinge cell, then -

if F2 is 9 then F4 and F6 become a naked pair and eliminate the 8 in F3 and D4 and D6, (plus others);

if F2 is 1 then D1 is 8, so eliminates the 8s in F3 and D4 and D6, (plus others); and

if F2 is 8 then eliminates the 8 in D1, F3, F4 and F6, (plus others). And it is this, I believe, which prevents this strategy being applicable.

Am I right, or have I missed something?

I appreciate that not all strategies can be applied earlier than the appropriate stage, (eg a naked pair strategy can only be applied when there are only two candidates in each cell), but from what Iâ€™ve read the wxyz-wing strategy is applicable in this case.

H

## ... by: draco

^

In this statement from example 1, I think you mean: D4 and D6.

## ... by: tebo

A WXYZ-Wing is a Bent group of four cells with four candidates (naked), that have exactly one non-restricted common candidate, where the elimination cell(s) can see all occurances of the non-restricted candidate in the group.

In your example #1, Cells A1-A3-B3-E1 form a WXYZ-Wing according to StrmCkr's more general definition (as quoted). However, removal of 9 from D3 cannot be done because it does not "see" the hing cell. You later make the clarification when you state "We are looking for a 9 elsewhere that can see every 9 in the four cells". Strmckr also points out the importance of this distinction in his comment of 18-DEC-2015.

## ... by: tebo

A WXYZ-Wing is a Bent group of four cells with four candidates (naked), that have exactly one non-restricted common candidate, where the elimination cell(s) can see all occurrences of the non-restricted candidate in the group.

In your Example #1, Cells A1-A3-B3-E1 form a WXYZ-Wing according to StrmCkr's more general definition (as you quote). However, removal of 9 from D3 cannot be done because it does not "see" the hinge cell. You later make the clarification when you state "We are looking for a 9 elsewhere that can see every 9 in the four cells". Strmckr also points out the importance of this distinction in his comment of 18-DEC-2015.

## ... by: DENNEY C SMITH

On puzzle http://www.sudokuwiki.org/sudoku.htm?bd=090001700500200008000030200070004960200060005069700030008090000700003009003800040

it seems to me, and it was a eureka moment when I found it, that there is a WXYZ at cells A6 (1,3,8); D5 (1,9); D6 (1,3); F5 (8,9). In cell E6 the 5 is already eliminated. From E6 the WXYZ eliminates the 1 and 8 leaving only the 2. The solver says there is no WXYZ at this point in the puzzle. How am I misunderstanding the use of WXYZ?

## ... by: Strmckr

| 5 478 1 | 2 6 3 | 789 78 49 |

| 34 6 247 | 1 8 9 | 237 5 34 |

| 9 238 28 | 7 5 4 | 2368 2368 1 |

:---------------+------------+-----------------:

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

| 48 478 478 | 59 19 15 | 236 236 36 |

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

:---------------+------------+-----------------:

| 7 38 5 | 4 19 6 | 1389 38 2 |

| 36 1 9 | 8 7 2 | 36 4 5 |

| 468 248 248 | 59 3 15 | 16789 678 69 |

'---------------'------------'-----------------'

case study puzzle for technique testing.

als-xz double linked rule can and does apply to some formations of

wxyz-wings:

{that is if there is 2 restricted commons between A&B then all cells become locked sets and all peer cells for each candidate with in A&B can be eliminated}

Almost Locked Set XZ-Rule {double link rule}: A=r1c8 {78}, B=r79c8,r8c7 {3678}, X=7,8 => r3c8<>8, r7c7<>3, r9c79<>6

{ps the double linked rule is missing from your code on the als-xz, and als-xy engine.}

you might also note that this is also accounts for sue de coq eliminations as well. :)

## ... by: Howard

If there is more than one non-restricted common digit, is the group still a WXYZ-Wing?

## ... by: Howard

If there is more than one non-restricted common digit, is the group still a WXYZ-Wing?

## ... by: YBB

2) wing: A4,B6,C5,I6 hinge: B6 eliminates: 5 in C6

3) wing: A9,B9,C5,C7 hinge: C7 eliminates: 1 in C8

4) wing: A9,B9,C5,C8 hinge: C8 eliminates: 1 in C7

5) wing: D3,D4,D6,F1 hinge: D3 eliminates: 9 in D2

6) wing: D4,F1,F4,F7 hinge: F4 eliminates: 9 in F6

7) wing: G2,G3,H1,H8 hinge: H1 eliminates: 1 in H3

8) wing: G2,G3,H3,H8 hinge: H3 eliminates: 1 in H1

Could you kindly verify the list and explain why certain of them are invalid.

Also note the elimination in H3,H1 and C7,C8.

Would these constitute as contradictions?

Unfortunately, the example would still be correct even if all the eliminations are effected. I am afraid, this wouldn't be so with every puzzle.

## ... by: strmckr

potential wxyz wing eliminations only occur when the elimination cell sees all "z" candidates contained in the wxyz wing.

ie: a2 cannot directly see the "3" in h1

## ... by: Fred Kong

I am very thankful to have learned about your WXYZ-Wings theory. With this skill I have solved quite a few very toughed puzzles in my not-completed storage.

However, I met an exception. That is Puzzle 125 in your book: Extreme Sudoku For Dummies.

Please take a look at where I cannot go any further:

| 6 35 8 | 579 4579 4579 | 1 347 2 |

| 1 4 7 | 3 6 2 | 9 58 58 |

| 239 25 29 | 8 457 1 | 46 467 37 |

|----------------------+----------------------+----------------------|

| 4 28 1 | 256 3 56 | 7 9 568 |

| 78 9 3 | 1567 14578 4567 | 458 2 568 |

| 278 6 5 | 279 4789 479 | 3 48 1 |

|----------------------+----------------------+----------------------|

| 289 1 269 | 4 59 3 | 568 5678 79 |

| 39 7 4 | 56 2 8 | 56 1 39 |

| 5 38 69 | 1679 179 679 | 2 38 4 |

I found there is a WXYZ-Wing set as C1, G1, H1 and I2. I thought the Z should be 3, and I could eliminate the 3 in A2 cell. But I could not go to the right end. According to the Answer page, A2 cell is 3.

Please tell me why I cannot use WXYZ-Wing as the above.

Thanks.

Fred Kong

## ... by: strmckr

Correct and I've put your link in the text. I have now completed the expansion of the search algorithm to get these cases.

thanks for the update, as for the remark on more then 10 cases, true there is a large list of positional locations for the 4 cells{ i originally mapped out 20 ish cases}, however after rotation, reflection, relabeling, band swaping ect is applied the 1 - 4 types I've identified and cross checked via programing should be the minimal exemplars. if you do have any examples cases that don't match my 4 primary types and hold additional eliminations feel free to email me as id love to examine them.

strmckr

## ... by: Caleb Andrews

## ... by: Gcd

| 159 58 19 | 6 2489 2489 | 1458 7 3 |

| 2379 23678 3679 | 4789 5 1 | 48 469 68 |

|----------------------+----------------------+----------------------|

| 37 9 2 | 1378 1378 58 | 6 35 4 |

| 6 1 4 | 39 239 259 | 35 8 7 |

| 357 357 8 | 347 347 6 | 9 1 2 |

|----------------------+----------------------+----------------------|

| 12379 237 1379 | 5 6 489 | 13478 34 18 |

| 8 4 1369 | 139 139 7 | 135 2 156 |

| 137 367 5 | 2 1348 48 | 13478 346 9 |

Your Solver shows this wxyz uses H4, H5,G6 G9 3,9,8,1 With 1 being excluded from H7. This is from your Sunday daily puzzle of a Sudoku from early September.\

But if you change to G9 to G8, you now have 1,3,8,4 and the 3 in H7 now see's 3'3 all of the wing 3's yet it cannot be excluded. Why not? Where have I made my error?

## ... by: strmckr

http://forum.enjoysudoku.com/wxyz-wings-t30012.html

however it can be noted that most if not all wxyz - wings are specific simplified cases of als-xz rule.

## ... by: SudoNova

On various Sudoku sites on the internet I have found about a dozen different cases for the use of this technique. I would like to propose the following 'one-size-fits-all' strategy and so allow many more cases to be found.

The strategy for Bent Quads (WXYZ-wing) can be summarised like this. If there are 4 cells having 4 digits each (W, X, Y, Z) distributed within them such that any 2 cells aren't a pair and any 3 cells aren't a triple. The cells aren't all in the same house but they are inter-linked somehow.

One of the cells in the quad has digits WZ (I call this a 'spy' cell), and the other 3 cells of the quad form an 'alliance'. Outside the quad is a 'rogue' cell with digit Z among its candidates and if the rogue declares war, the spy acts as a 5th columnist - unless the alliance can prevent this.

The rogue cell can see all the Z-digits in the alliance and the spy cells. The spy cell can see all the other W-digits in the alliance. So if the Z-digit is given as a solution in the rogue cell, all the Z-digits are eliminated from the quad, and the W-digit is now placed in the spy cell removing the W-digits from the alliance cells.

This leaves the X and Y digits distributed in the 3 remaining cells of the quad

There are { 27 } combinations in which X, Y or XY can be distributed in 3 cells so that the allies can then defeat the rogue Z-digit

these are . . .

XY-XY-XY these cells must all be in the same house { 1 }

XY-XY-X, XY-XY-Y, XY-X-XY, XY-Y-XY, X-XY-XY, Y-XY-XY

same house { 6 }

the next 3 cases follow a similar pattern

XY-X-Y, etc the cell with XY must be a pivot { 6 }

XY-X-X, etc the cells X-X must be in the same house { 6 }

X-X-Y, etc the cells X-X must be in the same house { 6 }

and the last 2 are . . .

X-X-X, Y-Y-Y impossible! it means that the 4th digit

is missing { 2 }

If any of the above conditions are met then the Z-digit can be eliminated from the rogue cell.

This idea could be extended to form any N-wing format, but the logistics are astronomical.

The number of combinations of the remaining (N-2) digits to fit in

the (N-1) alliance cells is given by the formula

C = {[2^(N-2)]-1}^{N-1}

So the above 4-wing has 27 (3^3), a 5-wing has 2401 (7^4) and the 6-wing has 759375 (15^5).

Also, we could remove the restriction that the spy cell only has W and Z in its candidates and have any combination with X or Y included, but using a modified version of the above formula means that the 4-wing now has 2401 combinations of W, X or Y to consider instead of just 27

combinations of X or Y.

## ... by: Mats Anderbok

## ... by: Nassir M

Thanks

## ... by: rich schrader

## ... by: Jeff Sanborn

Must there be one cell within the box and two cells in the row, or is it just a total of three cells that is important?

Furthermore, could you have a VWXYZ-wing if you had a hinge cell with five values and four outlying cells?

Yes you could have a 5-cell VWXYZ-wing although I've not searched for one.

## ... by: LokiMomus

The theory still holds. Filling in the 9 in the yellow box will result in an invalid situation, so i can scratch the 9 in the yellow box.

In other words, the more generic requirement should be that there can be n cells of the same cellgroup as long as they have n+1 distinct symbols. (the +1 is for the symbol (9 in this case) that we are considering). The other rules stay intact.

The substrategy of wxyz-wing would be with n=1.

My question to you is: Is this strategy already mentioned on the site? If not, can it be solved by using multiple others?

Note:

This strategy can be even made more generic if there are more than 3 dimensions (special sudokus). In a traditional sudoku there are 3 dimensions (a cell is part of a horizontal cellgroup, a vertical cellgroup and a 3x3 cellgroup). A 4-dimensional sudoku would for example be a jigsaw sudoku on top of a traditional one.