# Can two corners be swapped using commutators?

This question is about solving a Rubik's cube using commutators and conjugates - it is a question about the group theory of the Rubik's cube, rather than a "how do I" kind of question.

This video gives a very helpful overview of how to use commutators and conjugates to solve Rubik's cubes and their larger versions.

When it comes to corner moves, the only commutators it describes are 3-cycles and orientation swaps. Both of these now seem very simple and intuitive to me.

However, sometimes my cube gets into a state where all corners are solved apart from two of them on the last face. These may be adjacent or opposite corners. The other six corners are all in the correct positions and oriented correctly, so I just need to swap the remaining two. The edges are solved only in one layer, as I generally solve the corners first.

Swapping two corners doesn't fit the pattern of what can be done with commutators: a 3-cycle swaps the positions of three cubies, and an orientation swap changes the orientation of two, but I need to change the position of two.

I know that algorithms for this exist - one can be found here, for example - and I'm not asking for an algorithm in this question. Rather I would like to understand the following:

• Can a corner swap be performed using commutators and conjugates only, or is it a "parity" case that requires a non-commutator move to accomplish?

• If it can be done with commutators, is there a nice intuitive way that I could see how to create my own commutator to solve this case? I can now do this easily with 3-cycles and orientation swaps, but not with this kind of 2-cycle.

• If it can't, is there some easy principle through which the parity can be removed? I mean something along the lines of the parities in the 4x4 cube (explained towards the end of the video above), where a single quarter-turn removes the parity, putting the cube into a state that can be solved with commutators and conjugates only, although it does take quite a few moves to do so. (I tried making a single quarter turn of my cube, but re-solving it with combinators just put it into the same state, of needing two corners to be swapped.)

(Note: my cube is a 4x4x4, but I'm solving the corners first, so I don't care about moving edges or even centres around. I had assumed the same situation could arise on all cubes if the edges aren't solved, but if this is wrong it would be interesting to know.)

• Just to be clear, we are talking about 2x2x2s or 4x4x4s here I assume. Because a 3x3x3 (or other odd-layered cubes above it) can never have two corners unsolved and everything else solved. – Kevin Cruijssen May 20 '18 at 10:29
• In the 'law of cubes', when two corners are swapped, (at least) two edges should be swapped as well. On a 2x2x2 and 4x4x4 this is possible due to hidden edges (see a 2x2x2 as a 3x3x3 where the corners are made bigger to hide the edges and centers; same as a 4x4x4 would hide the 5x5x5 edges and centers). This is what causes parity on even-layered cubes which cannot happen on odd-layered ones. When you have parity on a 4x4x4, in reality some of the hidden 5x5x5 edges are incorrectly solved. – Kevin Cruijssen May 20 '18 at 10:32
• @KevinCrujissen it's a 4x4x4, but I generally solve the corners first, so don't care if edges move around. (I had imagined the corners all cubes would behave the same, as long as you ignore all the other pieces. Is that correct?) – Nathaniel May 20 '18 at 11:28
• @KevinCruijssen (to be precise, it's a 4x4 but I've paired up all the edges and solved one face as if it's a 3x3 - it doesn't matter if the other edges get jumbled around. It's kind of interesting if the corner swap can't be done without unpairing some of the edges. But I'm happy with answers that assume a 2x2 cube.) – Nathaniel May 20 '18 at 11:41

No, it cannot be done with purely commutators.

Commutators are of the form $ABA^{-1}B^{-1}$, so consists of an even number of moves. The permutation it does of the corners is therefore also even.

A single swap of corners is an odd permutation on the set of corners. It is therefore impossible to achieve with only commutators.

You can get on odd corner permutation of corners by doing a single face turn, which is a 4-cycle. Then using commutators you can apply a 3-cycle in the opposite direction, leaving only a corner swap.

I'm going to quickly preface my answer stating that I'm not going to use any computer aid, but merely what can be done intuitively. I am also going to accomplish what you want by permuting some of the U face edges. I will preserve the orientation of all the pieces though.

Can a corner swap be performed using commutators and conjugates only

Yes. You probably already know a conjugate of a commutator to do this.

[F: [R, U]]

Note how that algorithm did two adjacent swaps to the corners leaving the cube in a state where the corner permutation is no longer solved. I'll leave proving that you can solve the orientation from this state using commutators and conjugates as an exercise for the reader.

If it can be done with commutators, is there a nice intuitive way that I could see how to create my own commutator to solve this case?

This is pretty boring alone. You can simple do [U2, T perm]. To make this interesting, let's make a single commutator that can be made using only 1 move long sequences put into other commutators.

Following the above objective. I found [U2, [L, [R', F]] [L', U'] [U2, L']] by hand. It is a single commutator to perform a Nb permutation. The 3 cycle commutators you have done are pure commutators which preserve the whole cube minus the pieces you are cycling. Since we want to swap two corners and two edges we can not use a pure commutator.

The real meat of the algorithm above is [R', F]. Sledgehammer does a adjacent swap. Sledgehammer alone isn't enough because it's pretty much destroyed the whole cube. We don't even have all the F2L ce pairs in their slots. If think to what a commutator is, it allows us to undo a sequence we had just done. In the commutator we are looking for, we want to preserve the ce pair on the top layer and the UF edge which got it's orientation flipped. If we get rid of the worthless moves for creating a commutator with, we are left with L and B'. These are the only moves I would consider because the ULB corner is the only one which we can both freely move and is a U corner (remember we are trying to swap 2 U corners). If you now take a look at the two commutators that we came up with: [L, [R', F]] and [B', [R', F]] you'll see that the first leaves us with an AS ocll and the second laves us with a L ocll. The AS ocll is much easier to solve using commutators. In fact the regular antisune alg can be rewritten to be a commutator. R U2 R' U' R U' R' can be rewritten as [R, U2] [U, R]. In fact any one of the sunes can be written as a variation of that. I ended up doing it for a lefty sune: [L', U'] [U2, L']. Now our algorithm so far is [L, [R', F]] [L', U'] [U2, L'] and it performs an adjacent swap. We are almost done, we just have one problem. This is three commutators and not one like what our objective was. If you remember what my lame answer was above, we used an adjacent corner swap algorithm (T perm) conjugated with a U2 to make a commutator for doing a corner swap. We can do that same thing with the adjacent corner swap algorithm we found. Finally we arrived at the algorithm found above [U2, [L, [R', F]] [L', U'] [U2, L']] which performs the corner swaps.

Pretty much that whole solution was intuitive minus the part where I started us off with [R', F]. I knew what sledgehammer did beforehand, but what if I did not know how it affected the cube? Recall that $$<$$RU$$>$$ aka 2gen will not change your corner permutation. (Nor will $$<$$RL$$>$$ since the faces don't even touch) This leaves us with only 2 possibilities for the meat of our algorithm: $$<$$RF$$>$$ and $$<$$RB$$>$$. These are both mirrors of each other so it doesn't really matter which one we choose. With simple experiment with that move set you could come up with [R', F].

• "Note how that algorithm did a diagonal swap to the corners." Actually it does two adjacent swaps, which is an even permutation. To get the diagonal corner swap you need to do an additional U or U' move. – Jaap Scherphuis May 23 '18 at 12:03
• By diagonal swap, I was talking about relative to solving corner permutation (reducing the solution of the corners to <RU>). I will reword it though since I understand where you are coming from. – gyroninja May 24 '18 at 20:46