# 4x4 algorithm



## Feanaro (Jun 15, 2008)

Does anybody know an algorithm that will swap only two pieces on a 4x4? For example, on a solved american colour scheme cube it would be like swapping a blue yellow piece and a green white piece on the same slice. Thanks for your help.


----------



## Johannes91 (Jun 15, 2008)

r U2 r U2 F2 r F2 l' U2 l U2 r2

Lower case means inner slice only. That swaps UFl and UBl (and also some centers, but I hope that doesn't matter).


----------



## Feanaro (Jun 15, 2008)

That one is good but I am looking for one that would swap a blue yellow and green white. Thanks for the algorithm, it is quite usefull.


----------



## Lucas Garron (Jun 15, 2008)

r' U2 r2 U2 r U2 r U2 (l r2') U2 r' U2 r U2 l' U2


----------



## Jason Baum (Jun 15, 2008)

You can use those algs to swap any two edge pieces, just do set up moves to bring the two pieces to UFl and UBl and undo the set up moves when you're done.


----------



## Feanaro (Jun 15, 2008)

Lucas Garron said:


> r' U2 r2 U2 r U2 r U2 (l r2') U2 r' U2 r U2 l' U2


YES!!! Thank you so much, this is exactly what I have been looking for! I am forever in your debt.  At leat until you ask me to do something.


----------



## deadalnix (Jun 17, 2008)

Lucas Garron said:


> r' U2 r2 U2 r U2 r U2 (l r2') U2 r' U2 r U2 l' U2



Yeah ! That's great !

Where have you found this alg ? If you found it by yourself, how ?*

(I'm very curious )


----------



## Lucas Garron (Jun 17, 2008)

deadalnix said:


> Lucas Garron said:
> 
> 
> > r' U2 r2 U2 r U2 r U2 (l r2') U2 r' U2 r U2 l' U2
> ...



ACube... (domino def)
And handpicking.

(Not entirely true, I actually got this alg from CE, but that was chance.)


----------



## Feanaro (Jun 22, 2008)

Does anyone also know a move that will swap two face pieces on a 4x4 without messing up any other faces?


----------



## MistArts (Jun 23, 2008)

Feanaro said:


> Does anyone also know a move that will swap two face pieces on a 4x4 without messing up any other faces?



Do you mean Centers? Just set up for a 3-cycle. Like:

Lower case = slice

r l F' l b2 l' F l b2 l2 r'


----------



## joey (Jun 23, 2008)

I think he meant two whole centres?


----------



## Feanaro (Jun 23, 2008)

joey said:


> I think he meant two whole centres?


No I meant two individual center pieces. Is is possible to only swap two?


----------



## andrewvo1324 (Jun 23, 2008)

nevermind he was banned already. *talks about the spammer 2 posts aobve me*


----------



## tim (Jun 23, 2008)

Feanaro said:


> joey said:
> 
> 
> > I think he meant two whole centres?
> ...



No, you have to use a 3-cycle to "swap" them.


----------



## joey (Jun 23, 2008)

It's possible to swap two, by cycling three!


----------



## tim (Jun 24, 2008)

joey said:


> It's possible to swap two, by cycling three!



Awesome post!


----------



## cmhardw (Jun 24, 2008)

Feanaro said:


> joey said:
> 
> 
> > I think he meant two whole centres?
> ...



Yeah, practically during a solve use a 3-cycle to appear to swap 2 pieces.

You can actually swap just two centers on a 4x4, but you must also swap two corners to do so. On a 4x4x4 supercube the parity of the corners *must* match the parity of the x-centers.

Chris


----------



## Lucas Garron (Jun 24, 2008)

cmhardw said:


> On a 4x4x4 supercube the parity of the corners *must* match the parity of the x-centers.


That is certainly true for simple mortal cubers like us.

However, I would like to note that this certainly does not hold for Frank Morris.


----------



## blah (Jun 24, 2008)

@Chris: I don't quite get what you mean, does this mean that on a 4x4x4 supercube, the edges, centers and corners are not 'independent'? i.e. there's a possibility/probability that each 'piece type' cannot be solved by cycling 'within' itself?

Also, if there's an alg that swaps 2 center pieces and 2 corners, wouldn't it be more move-efficient to use this alg rather than solving the centers and corners independently? (which I _think_ most people do, at least that's what I do...)


----------



## deadalnix (Jun 24, 2008)

On a normal cube, center can interchange if they are the same color. So you can do like you permute two center using a third of the same color and cycing 3.

It is the practical side of the thing (Sorry, i think i'm not very clear, but i'm not a native english speaker and i find this idea difficult to explain with my vocabulary).

Mathematicaly :

On a 333, when you rotate a face, you permute 4 corner and 4 edges. cycling pieces 3 by 3, you end with 2 corner and 2 edges to permute. On a megaminx, as you cycle 5 edges and 5 corner, you can't have parity 

On a 444/555, it's more complexe because you have two type of moves : a slice move and a face move. I will deal with 444, the idea is the same for 555.

A face move cycle 2*4 wing, 4 centers and 4 corners. A slice move 2*4 centers and 4 wings. The important thing is in the 2*4.

You can solve 2*4 cycle of the same type of pieces using standard 3-cycles. So a slice move generate a parity on wing and a face move generate a parity on corner and a parity on center.


----------



## Feanaro (Jul 13, 2009)

Sorry for the bump, I just didn't want to make a new thread since this one was still related to my first question. 

Does anyone know the algorithm that swaps only 2 center faces, but also messes up the corners? I know there has been some talk about it, but it hasn't been posted as far as I've seen. Thanks


----------



## cmhardw (Jul 14, 2009)

Feanaro said:


> Does anyone know the algorithm that swaps only 2 center faces, but also messes up the corners? I know there has been some talk about it, but it hasn't been posted as far as I've seen. Thanks



To swap UBR with UFR and Ubr with Ufr do:
(Rr) U (Rr)' U' (Rr)' F (Rr)2 U' (Rr)' U' (Rr) U (Rr)' (Ff)' F' R' u' R U2 R' u R U2 (Ff) F R' F' r' F R F' r

This affects nothing else on a 4x4x4 supercube but those mentioned pieces.

--edit--
slightly more efficient and still supercube safe in regards to the other pieces of the cube.
(Rr) U (Rr)' U' (Rr)' F (Rr)2 U' (Rr)' U' (Rr) U (Rr)' R' F' r' F R F' r2 B' R B r' B' R' B

--edit 2--
yet a bit shorter. This one swaps UFL with UFR and Ufl with Ufr. Supercube safe.
U (Rr)2 (Bb)2 (Rr) F (Rr)' (Bb)2 (Rr) F' D' f' D F2 D' f D F2 (Rr) L F' L' f' L F L' f

Chris


----------



## Feanaro (Jul 14, 2009)

cmhardw said:


> Feanaro said:
> 
> 
> > Does anyone know the algorithm that swaps only 2 center faces, but also messes up the corners? I know there has been some talk about it, but it hasn't been posted as far as I've seen. Thanks
> ...



Thank you so much! This is exactly what I was looking for. 

BTW, I'm planning to go to the Big Cubes Comp, so I'll se you there! Hopefully I'll have my 4x4 bld down by then


----------



## rahulkadukar (Jul 24, 2009)

Can anyone please post an Algorithm that only swaps two center pieces. Preferably any two centers on the face and Up sides.

Assume that RGBYOW are the six colors and I have Yellow on top and Red on face then the cube looks like this

Up
WB
GY

Face
GY
GG

I want to swap the Green on Up with the Yellow on the face.

It should not mess anything up and be optimal and not Supercube safe


----------



## Feanaro (Jul 24, 2009)

Did you not read all of the before posts? It's impossible to swap only two pieces without messing something else up.


----------



## TMOY (Jul 24, 2009)

On your example, you can simply use niklaas the following way:

U2 r U' l' U r' U' l U'

Note that what this alg actually does is a 3-cycle (the third center involved is the upper-left G center on the front face). For parity reasons, you cannot perform a supercube-safe alg which swaps 2 centers and leaves anything else in place.


----------



## DavidWoner (Jul 24, 2009)

rahulkadukar said:


> Can anyone please post an Algorithm that only swaps two center pieces. Preferably any two centers on the face and Up sides.
> 
> Assume that RGBYOW are the six colors and I have Yellow on top and Red on face then the cube looks like this
> 
> ...



x U2 l U' r' U l' U' r


----------



## imaghost (Jul 24, 2009)

Say it was the top right corner of the center front and center up face, the two you would want to switch. Do this.
I use this for 7x7 and it is very flexible. And 6x6. Switches 2 center pieces and everything stays the same but those 2. Think about how it works and you can do it for other centers.
b r b' U2 b r' b' r U2 r' and maybe an extra U2 at the end. 

I figured this out, and use it.


----------



## Feanaro (Aug 17, 2010)

Bump again. Is there any shorter alg that could swap two centers and two corners? I need it for 4x4 blind so it needs to be relatively short


----------



## hawkmp4 (Aug 17, 2010)

"Parity" algorithms are beyond the scope of current optimal solvers, and must be found by hand. I'm sure cmowla will chime in here soon, and he knows much much much more on the subject than me, but you're not going to find a 'short' algorithm for what you're looking for. The algorithm is going to be longer than 3x3 PLL algorithms.


----------



## riffz (Aug 17, 2010)

Feanaro said:


> Bump again. Is there any shorter alg that could swap two centers and two corners? I need it for 4x4 blind so it needs to be relatively short



Just learn to use commutators and include an already solved center in the cycle, creating the illusion that only 2 centers have been swapped.

For instance, if it appears that Ufl and Rbu must be swapped to solve the centers, you could cycle Rbu -> Ubr -> Ufl using the following commutator:

[r' u r, U2] --> r' u r U2 r' u' r U2

small letters indicate inner slices only

Mike Hughey made a post explaining how he solves 4x4 BLD using commutators. I recommend you read that.


----------



## TMOY (Aug 17, 2010)

Feanaro said:


> Bump again. Is there any shorter alg that could swap two centers and two corners? I need it for 4x4 blind so it needs to be relatively short



The one I'm using is (I already posted it in another thread but I can't find it):
Fw2 Rw2 U' Lw2 U Rw2 U' Lw2 U Fw2 U' x' U L' U' l' U L U' l2 D' L D l' D' L' D x
It swaps the ULF and ULB corners and the Ulf and Ulb centers, leaving everything else in place. (The idea is to first swap two 1*2*2 blocks and then fix edges.)


----------



## Kenneth (Aug 18, 2010)

Centre cubies or centres solved?

Man, look at that, my LEET post =)


Spoiler










Documentation, I will post more and then it will not be understandable.


----------



## TMOY (Aug 18, 2010)

Center cubies of course.


----------



## Kenneth (Aug 18, 2010)

Yes, I later understood it is for classic Pochmann...

But still, an alg that swaps two solved centres and two corners can be useful if you have the two centres solved or near solved from the scramble.

r U2 r' l' U2 l is a nice start for that, then a little setup + T-PLL to do the rest.


----------



## Christopher Mowla (Aug 18, 2010)

Feanaro said:


> Bump again. Is there any shorter alg that could swap two centers and two corners? I need it for 4x4 blind so it needs to be relatively short


This is the best I could do for right now (maybe forever):

*Note:  This is in SiGN notation, *so click on the hyperlinks if you are not familiar with it.

r2 y r U l' u2 r U' 2R L2 x' 3d' 2R2 3d L' F' L 3d' 2R2 3d L' x U m U r2 y' (29q/23h)

I doubt the optimal algorithm is much shorter (if it's shorter at all). I hope you like it.


Also, note that the two double inner-layer turns can be converted to wide and affect 4 corners, but still swap just two x-center pieces:
r2 y r U l' u2 r U' 2R L2 x' 3d' r2 3d L' F' L 3d' r2 3d L' x U m U r2 y'


----------

