Rubik Slides

88
The Mathematics of the Rubik’s Cube February 23, 2010 The Mathematics of the Rubik’s Cube

Transcript of Rubik Slides

Page 1: Rubik Slides

The Mathematics of the Rubik’s Cube

February 23, 2010

The Mathematics of the Rubik’s Cube

Page 2: Rubik Slides

Almost everyone has tried to solve a Rubik’s cube. The firstattempt often ends in vain with only a jumbled mess of coloredcubies (as I will call one small cube in the bigger Rubik’s cube) inno coherent order. Solving the cube becomes almost trivial once acertain core set of algorithms, called macros, are learned. Usingbasic group theory, the reason these solutions are not incrediblydifficult to find will become clear.

The Mathematics of the Rubik’s Cube

Page 3: Rubik Slides

The Mathematics of the Rubik’s Cube

Page 4: Rubik Slides

I F means to rotate the front face 90 degrees clockwise.

I A counterclockwise rotation is denoted by lowercase letters (f)or by adding a ’ (F’). A 180 degree turn is denoted by addinga superscript 2 (F2), or just the move followed by a 2 (F2).

I To refer to an individual cubie or a face of a cubie, we use oneletter for the center cubies, two letters for the edge cubies,and three letters for the corner cubies, which give the faces ofthe cube that the cubie is part of. The first of the threeletters gives the side of the cubie we are referring to. Forexample, in the picture below, the red square is at FUR,yellow at RUF, blue at URF, and green at ULB:

The Mathematics of the Rubik’s Cube

Page 5: Rubik Slides

The Mathematics of the Rubik’s Cube

Page 6: Rubik Slides

The number of possible permutations of the squares on a Rubik’scube seems daunting:

I There are 8 corner pieces that can be arranged in 8! ways,each of which can be arranged in 3 orientations, giving 38

possibilities for each permutation of the corner pieces.

I There are 12 edge pieces which can be arranged in 12! ways.Each edge piece has 2 possible orientations, so eachpermutation of edge pieces has 212 arrangements.

I But in the Rubik’s cube, only 13 of the permutations have the

rotations of the corner cubies correct. Only 12 of the

permutations have the same edge-flipping orientation as theoriginal cube, and only 1

2 of these have the correctcubie-rearrangement parity, which will be discussed later.

The Mathematics of the Rubik’s Cube

Page 7: Rubik Slides

This gives:(8! · 38 · 12! · 212)

(3 · 2 · 2)= 4.3252 · 1019

possible arrangements of the Rubik’s cube.

The Mathematics of the Rubik’s Cube

Page 8: Rubik Slides

It is not completely known how to find the minimum distancebetween two arrangements of the cube. Of particular interest is theminimum number of moves from any permutation of the cube’scubies back to the initial solved state.

The Mathematics of the Rubik’s Cube

Page 9: Rubik Slides

Another important question is the worst possible jumbling of thecube, that is, the arrangement requiring the maximum number ofminimum steps back to the solved state. This number is referredto as “God’s number,” and has been shown (only as recently asAugust 12 this year) to be as low as 22.1

1Rokicki, Tom. “Twenty-Two Moves Suffice”.http://cubezzz.homelinux.org/drupal/?q=node/view/121. August 12, 2008.

The Mathematics of the Rubik’s Cube

Page 10: Rubik Slides

The lower bound on God’s number is known. Since the first twistof a face can happen 12 ways (there are 6 faces, each of which canbe rotated in 2 possible directions), and the move after that cantwist another face in 11 ways (since one of the 12 undoes the firstmove), we can find bounds on the worst possible number of movesaway from the start state with the following “pidgeonhole”inequality (number of possible outcomes of rearranging must begreater than or equal to the number of permutations of the cube):

12 · 11n−1 ≥ 4.3252 · 1019

which is solved by n ≥ 19.The solution mathod we will use in class won’t ever go over 100moves or so, but the fastest “speedcubers” use about 60.

The Mathematics of the Rubik’s Cube

Page 11: Rubik Slides

By definition, a group G consists of a set of objects and a binaryoperator, *, on those objects satisfying the following fourconditions:

I The operation * is closed, so for any group elements h and gin G, h ∗ g is also in G.

I The operation * is associative, so for any elements f , g , andh, (f ∗ g) ∗ h = f ∗ (g ∗ h).

I There is an identity element e ∈ G such thate ∗ g = g ∗ e = g .

I Every element in G has an inverse g−1 relative to theoperation * such that g ∗ g−1 = g−1 ∗ g = e.

Note that one of the requirements is not commutativity, and it willsoon become clear why this is not included.

The Mathematics of the Rubik’s Cube

Page 12: Rubik Slides

Keep in mind the following basic theorems about groups:

I The identity element, e, is unique.

I If a ∗ b = e, then a = b−1

I If a ∗ x = b ∗ x , then a = b

I The inverse of (ab) is b−1a−1

I (a−1)−1 = e

The Mathematics of the Rubik’s Cube

Page 13: Rubik Slides

The following are some of the many examples of groups youprobably use everyday:

I The integers form a group under addition. The identityelement is 0, and the inverse of any integer a is its negative,−a.

I The nonzero rational numbers form a group undermultiplication. The identity element is 1, and the inverse ofany x is 1

x .

I The set of n × n non-singular matrices form a group undermultiplication. This is an example of a non-commutativegroup, or non-abelian group, as will be the Rubik group.

The Mathematics of the Rubik’s Cube

Page 14: Rubik Slides

We can conveniently represent cube permutations as groupelements. We will call the group of permutations R, for Rubik (notto be confused with the symbol for real numbers).

The Mathematics of the Rubik’s Cube

Page 15: Rubik Slides

Our binary operator, *, will be a concatenation of sequences ofcube moves, or rotations of a face of the cube. We will almostalways omit the * symbol, and interpret fg as f ∗ g . This operationis clearly closed, since any face rotation still leaves us with apermutation of the cube, which is in R. Rotations are alsoassociative: it does not matter how we group them, as long as theorder in which operations are performed is conserved. The identityelement e corresponds to not changing the cube at all.

The Mathematics of the Rubik’s Cube

Page 16: Rubik Slides

I The inverse of a group element g is usually written as g−1.We saw above that if g and h are two elements of a group,then (hg)−1 = g−1h−1.

I If we think of multiplying something by a group element as anoperation on that thing, then the reversed order of theelements in the inverse should make sense. Think of puttingon your shoes and socks: to put them on, you put on yoursocks first, then your shoes. But to take them off you mustreverse the process.

The Mathematics of the Rubik’s Cube

Page 17: Rubik Slides

I Let F be the cube move that rotates the front face clockwise.Then f , the inverse of F , moves the front facecounterclockwise. Suppose there is a sequence of moves, sayFR, then the inverse of FR is rf : to invert the operations theymust be done in reverse order. So the inverse of an elementessentially “undoes” it.

The Mathematics of the Rubik’s Cube

Page 18: Rubik Slides

The different move sequences of cube elements can be viewed aspermutations, or rearrangements, of the cubies. Note movesequences that return the same cube configuration are seen to bethe same element of the group of permutations. So every movecan be written as a permutation. For example, the move FFRR isthe same as the permutation (DF UF)(DR UR)(BR FR FL)(DBRUFR DFL)(ULF URB DRF).

The Mathematics of the Rubik’s Cube

Page 19: Rubik Slides

It is easier to discuss these permutations first using numbers. Anexample of a permutation written in canonical cycle notation is:

(1)(234)

This means that 1 stays in place, and elements 2, 3, and 4 arecycled. For example, 2 goes to 3, 3 goes to 4, and 4 goes to 2.(234)→ (423).

The Mathematics of the Rubik’s Cube

Page 20: Rubik Slides

The steps in writing down combinations of permutations incanonical cycle notation are as follows:

1. Find the smallest item in the list, and begin a cycle with it. Inthis example, we start with 1.

2. Complete the first cycle by following the movements of theobjects through the permutation. Do this until you close thecycle. For instance, in (1 2 4)(3 5) * (6 1 2)(3 4), we startwith 1. 1 moves to 2 in the first permutation, and 2 moves to6 in the second, so 1 moves to 6. Following 6 shows that itmoves back to 1, so 6 and 1 form one 2-cycle.

3. If you have used up all the numbers, you are done. If not,return to step 1 to start a new cycle with the smallest unusedelement. Continuing in this manner gives (1 6)(2 3 5 4).

The Mathematics of the Rubik’s Cube

Page 21: Rubik Slides

If P consists of multiple cycles of varying length, then the order ofthat permutation is n, since applying P n times returns thebeginning state. If P consists of multiple cycles of varying length,then the order is the least common multiple of the lengths of thecycles, since that number of cycle steps will return both chains totheir starting states.

The Mathematics of the Rubik’s Cube

Page 22: Rubik Slides

Below are several examples:

(1 2 3)(2 3 1) = (1 3 2) order 3(2 3)(4 5 6)(3 4 5) = (2 4 3)(5 6) order 6

(1 2) order 2

The Mathematics of the Rubik’s Cube

Page 23: Rubik Slides

Permutations can also be described in terms of their parity. Anylength n cycle of a permutation can be expressed as the product of2-cycles.2 To convince yourself that this is true, look at thefollowing examples:

(1 2) = (1 2)(1 2 3) = (1 2)(1 3)

(1 2 3 4) = (1 2)(1 3)(1 4)(1 2 3 4 5) = (1 2)(1 3)(1 4)(1 5)

The pattern continues for any length cycle.

2for proof see Davis, Tom. Permutation Groups and Rubiks Cube. May 6,2000.

The Mathematics of the Rubik’s Cube

Page 24: Rubik Slides

Then the parity of a length n cycle is given by the number 2 cyclesit is composed of. If n is even, an odd number of 2-cycles isrequired, and the permutation is odd, and vise versa. So oddpermutations end up exchanging an odd number of cubies, andeven ones an even number.

The Mathematics of the Rubik’s Cube

Page 25: Rubik Slides

Now we will prove an important fact about cube parity that willhelp us solve the cube later:Theorem: The cube always has even parity, or an even number ofcubies exchanged from the starting position.

The Mathematics of the Rubik’s Cube

Page 26: Rubik Slides

Proof (by induction on the number of face rotations, n):Base Case: After n = 0 moves on an unsolved cube, there are nocubies exchanged, and 0 is even.

The Mathematics of the Rubik’s Cube

Page 27: Rubik Slides

I Let P(n) : after n rotations, there are an even number ofcubies exchanged. We assume P(n) to showP(n)→ P(n + 1). Any sequence of moves is composed ofsingle face turns.

I As an example of the permutation created by a face turn, lookat the move F = (FL FU FR FD)(FUL FUR FDR FDL) =(FL FU)(FL FR)(FL FD)(FUL FUR)(FUL FDR)(FUL FDL).

I Since each of the length 4 chains in this permutation can bewritten as 3 2-cycles for a total of 6 2-cycles, the parity of theface turn is even. This fact applies to any face turn, since allface turns, no matter which face they are applied to, areessentially equivalent.

The Mathematics of the Rubik’s Cube

Page 28: Rubik Slides

I After n moves the cube has an even number of cubiesexchanged. Since the n + 1 move will be a face turn, therewill be an even number of cubies flipped. There was alreadyan even number exchanged, and so an even parity of cubieexchanges is preserved overall�.

The Mathematics of the Rubik’s Cube

Page 29: Rubik Slides

Since any permutation of the Rubik’s cube has even parity, there isno move that will exchange a single pair of cubies. This meansthat when two cubies are exchanged, we know there must be othercubies exchanged as well. We will get around this problem by using3-cycles that will cycle 3 cubies, including the two that we wantto exchange.

The Mathematics of the Rubik’s Cube

Page 30: Rubik Slides

When talking about the cycle structure of cube moves, thefollowing notation will be helpful:

I φcorner describes the cycle structure of the corner cubies

I φedge describes the cycle structure of the edge cubies

The Mathematics of the Rubik’s Cube

Page 31: Rubik Slides

There might come a time when we want to focus first on orientingall the edge pieces correctly, and don’t care about the corners. Inthis case, we can deal only with φcorner and ignore whateverhappens to the edge pieces. It is helpful to separate the two. Alsonote that any cycles in φcorner can never contain any cubies thatare also involved in φedge since an cubie cannot be both an edgeand a corner. We never talk about φcenter since the center of thecube is fixed.

The Mathematics of the Rubik’s Cube

Page 32: Rubik Slides

I Given a group R, if S ⊆ R is any subset of the group, thenthe subroup H generated by S is the smallest subroup of Rthat contains all the elements of S .

I For instance, {F} generates a group that is a subgroup of Rconsisting of all possible different cube permutations you canget to by rotating the front face, {F ,F 2,F 3 F 4}.

I The group generated by {F ,B,U, L,R,D} is the whole groupR.

The Mathematics of the Rubik’s Cube

Page 33: Rubik Slides

Below are some examples of some generators of subroups of R:

I Any single face rotation, e.g., {F}I Any two opposite face rotations, e.g., {LR}I The two moves {RF}.

The Mathematics of the Rubik’s Cube

Page 34: Rubik Slides

I We define the order of an element g as the number m, suchthat gm = e, the identity. The order of an element is also thesize of the subgroup it generates. So we can use the notion oforder to describe cube move sequences in terms of how manytimes you have to repeat a particular move before returning tothe identity.

I For example, the move F generates a subgroup of order 4,since rotating a face 4 times returns to the original state. Themove FF generates a subroup of order 2, since repeating thismove twice returns to the original state. Similarly, anysequence of moves forms a generator of a subgroup that has acertain finite order.

The Mathematics of the Rubik’s Cube

Page 35: Rubik Slides

Since the cube can only achieve a finite number of arragnements,and each move jumbles the facelets, eventually at least somearrangements will start repeating. Thus we can prove that if thecube starts at the solved state, then applying one move over andover again will eventually recyle to the solved state again after acertain number of moves.

The Mathematics of the Rubik’s Cube

Page 36: Rubik Slides

Theorem: If the cube starts at the solved state, and one movesequence P is performed successively, then eventually the cube willreturn to its solved state.

The Mathematics of the Rubik’s Cube

Page 37: Rubik Slides

Proof: Let P be any cube move sequence. Then at some numberof times m that P is applied, it recycles to the same arrangementk , where k < m and m is the soonest an arrangement appears forthe second time. So Pk = Pm. Thus if we show that k must be 0,we have proved that the cube cycles back to P0, the solved state.

The Mathematics of the Rubik’s Cube

Page 38: Rubik Slides

If k = 0, then we are done, since P0 = 1 = Pm. Now we prove bycontradiction that k must be 0. If k > 0: if we apply P−1 to bothPk and Pm we get the same thing, since both arrangements Pk

and Pm are the same. Then PkP−1 = PmP−1 → Pk−1 = Pm−1.But this is contradictory, since we said that m is the first time thatarrangements repeat, so therefore k must equal 0 and every movesequence eventually cycles through the initial state again firstbefore repeating other arrangements.

The Mathematics of the Rubik’s Cube

Page 39: Rubik Slides

Try repeating the move FFRR on a solved cube until you get backto the starting position. How many times did you repeatit?(hopefully 6) No matter what, that number, the size of the

subgroup generated by FFRR, must be a divisor of (8!·38·12!·212)(3·2·2) .

Lagrange’s Theorem tells us why.

The Mathematics of the Rubik’s Cube

Page 40: Rubik Slides

Before we prove Lagrange’s Theorem, we define a coset and notesome properties of cosets. If G is a group and H is a subgroup ofG , then for an element g of G :

I gH = {gh : h ∈ H} is a left coset of H in G .

I Hg = {hg : h ∈ H} is a right coset of H in G .

The Mathematics of the Rubik’s Cube

Page 41: Rubik Slides

So for instance if H is the subgroup of R generated by F, then oneright coset is shown below:

The Mathematics of the Rubik’s Cube

Page 42: Rubik Slides

Lemma: If H is a finite subgroup of a group G and H contains nelements then any right coset of H contains n elements.

The Mathematics of the Rubik’s Cube

Page 43: Rubik Slides

Proof: For any element g of G , Hg = {hg |h ∈ H} defines theright coset. There is one element in the coset for every h in H, sothe coset has n elements.

The Mathematics of the Rubik’s Cube

Page 44: Rubik Slides

Lemma: Two right cosets of a subgoup H in a group G are eitheridentical or disjoint.

The Mathematics of the Rubik’s Cube

Page 45: Rubik Slides

Proof: Suppose Hx and Hy have an element in common. Then forsome h1 and h2:

h1x = h2y

Then x = h−11 h2y , and some h3 = h−1

1 h2 gives x = h3y . So everyelement of Hx can be written as an element of Hy :

hx = hh3y

for every h in H. So if Hx and Hy have any element in common,then every element of Hx is in Hy , and a similar argument showsthe opposite. Therefore, if they have any one element in common,they have every element in common and are identical �.

The Mathematics of the Rubik’s Cube

Page 46: Rubik Slides

We now can say that the right cosets of a group partition thegroup, or divide it into disjoint sets, and that each of thesepartitions contains the same number of elements.

The Mathematics of the Rubik’s Cube

Page 47: Rubik Slides

Lagrange’s Theorem: the size of any group H ⊆ G must be adivisor of the size of G . So m|H| = |G | for some m ≥ 1 ∈ N+.

The Mathematics of the Rubik’s Cube

Page 48: Rubik Slides

Proof: The right cosets of H in G partition G . Suppose there arem cosets of H in G . Each one is the size of the number ofelements in H, or |H|. G is just the sum of all the cosets:G = h1G + h2G + . . .+ hnG , so its size is the sum of the sizes ofall the cosets. So we can write |G | = m|H| �.

The Mathematics of the Rubik’s Cube

Page 49: Rubik Slides

Below is a list3 of some group generators and their sizes, all factorsof the size of R:

Generators Size FactorizationU 4 22

U, RR 14400 26 · 32 · 52

U, R 73483200 26 · 38 · 52

RRLL, UUDD, FFBB 8 23

Rl, Ud, Fb 768 28 · 3RL, UD, FB 6144 211 · 3FF, RR 12 2 · 32

FF, RR, LL 96 25 · 3FF, BB, RR, LL, UU 663552 213 · 34

LLUU 6 2 · 3LLUU, RRUU 48 24 · 3LLUU, FFUU, RRUU 82944 210 · 34

LLUU, FFUU, RRUU, BBUU 331776 212 · 34

LUlu, RUru 486 2 · 35

3Davis, Tom Group Theory via Rubik’s CubeThe Mathematics of the Rubik’s Cube

Page 50: Rubik Slides

Most of the moves we use will generate relatively small subgroups.Play around with some of the smaller size subgroups above andwatch the cube cycle back to its original configuration.

The Mathematics of the Rubik’s Cube

Page 51: Rubik Slides

A useful way to gain insight into the structure of groups andsubgroups is the Cayley graph. The following properties describea Cayley graph of a group G :

I Each g ∈ G is a vertex.

I Each group generator s ∈ S is assigned a color cs .

I For any g ∈ G , s ∈ S , the elements corresponding to g and gsare joined by a directed edge of color cs .

The Mathematics of the Rubik’s Cube

Page 52: Rubik Slides

Drawing the Cayley graph for R would be ridiculous. If would have43 trillion vertices! Instead, we’ll look at some Cayley graphs ofsmall subgroups of R.

The Mathematics of the Rubik’s Cube

Page 53: Rubik Slides

The following is the Cayley graph for the subgroup generated by F :

The Mathematics of the Rubik’s Cube

Page 54: Rubik Slides

The moves φ = FF and ρ = RR generate the following graph(note that φ2 = ρ2 = 1):

The Mathematics of the Rubik’s Cube

Page 55: Rubik Slides

What happens when we try to draw the graph for U? Or RRBB?They will have the same Cayley graphs as those shown above,respectively. If two groups have the same Cayley graph, they haveessentially the same structure, and are called isomorphic. Twoisomorphic groups will have the same order and same effect on thecube. For instance, performing FFRR has the same effect asrotating the cube so that the L face is now in front and thenperforming RRBB.

The Mathematics of the Rubik’s Cube

Page 56: Rubik Slides

We first define some properties of cube group elements, and thenuse these properties and what we learned above to develop somemacros or combinations of cube moves that will help usaccomplish specific cubie rearrangements that will enable us tosolve the cube.

The Mathematics of the Rubik’s Cube

Page 57: Rubik Slides

The move sequence operations on a Rubik’s cube are prettyobviously not commutative. For example, rotate the front face(F ), then rotate the right face (R) to make a move FR. This isclearly not the same as rotating the right face followed by the frontface, or RF . One useful tool to describe the relative commutativityof a sequence of operations is the commutator, PMP−1M−1,denoted [P.M], where P and M are two cube moves. If P and Mare commutative, then their commutator is the identity, since theterms can be rearranged so that P cancels P−1 and same with M.

The Mathematics of the Rubik’s Cube

Page 58: Rubik Slides

Let the support of an operator be all the cubies changed by it.Then two operations are commutative if either they are the sameoperation or if supp(P) ∩ supp(M) = ∅, that is, if each moveaffects completely different sets of cubies.

The Mathematics of the Rubik’s Cube

Page 59: Rubik Slides

If the commutator is not the identity, then we can measure the“relative commutativity” by the number of cubies changed byapplying the commutator. Looking at the intersection of thesupports of the two operations gives insight into this measure.Useful pairs of moves have only a small number of cubies changedin common, and you will see macros involving commutators comeup again and again.

The Mathematics of the Rubik’s Cube

Page 60: Rubik Slides

A useful theorem about commutators that we will not prove butwill make use of is the following:If supp(g)∩supp(h) consists of a single cubie, then [g , h] is a3-cycle.

The Mathematics of the Rubik’s Cube

Page 61: Rubik Slides

Below are some useful building blocks for commutators that can beused to build macros:

I FUDLLUUDDRU flips exactly one edge cubie on the top face

I rDRFDf twists one cubie on a face

I FF swaps a par of edges in a slice

I rDR cycles three corners

The Mathematics of the Rubik’s Cube

Page 62: Rubik Slides

Let M be some macro that performs a cube operation, say athree-cycle of edge pieces. Then we say for some cube move P,PMP−1 is the conjugation of M by P. Conjugating a groupelement is another very useful tool that will help us describe andbuild useful macros.

The Mathematics of the Rubik’s Cube

Page 63: Rubik Slides

First we will introduce a couple useful definitions: An equivalencerelation is any relation ∼ between elements that are:

I Reflexive: x ∼ x

I Symmetric: If x ∼ y then y ∼ x

I Transitive: If x ∼ y and y ∼ z then x ∼ z

The Mathematics of the Rubik’s Cube

Page 64: Rubik Slides

We will let the relation ∼ be conjugacy. So if for some g ∈ G ,x ∼ y , then gxg−1 = y Here we prove that conjugacy is anequivalence relation:

I Reflexive: gxg−1 = x if g = 1, so x ∼ x

I Symmetric: If x ∼ y , then gxg−1 = y , so multiplying eachside by g on the right and g−1 on the left gives x = g−1yg

I Transitive: If x ∼ y and y ∼ z , then y = gxg−1 andz = hyh−1, so z = hgxg−1h−1 = (hg)x(hg)−1, so x ∼ z

The Mathematics of the Rubik’s Cube

Page 65: Rubik Slides

An equivalence class c(x), x ∈ G is the set of all y ∈ G : y ∼ x .We can partition G into disjoint equivalence classes, or conjugacyclasses.We will not give a formal proof here, but two permutationelements of R are conjugates if they have the same cyclestructure. The following example should make this more clear.

The Mathematics of the Rubik’s Cube

Page 66: Rubik Slides

In solving a cube, one straightforward approach is to solve it layerby layer. Once you get to the third layer, some of the edge piecesmight be flipped the wrong way, as in the following picture:

The Mathematics of the Rubik’s Cube

Page 67: Rubik Slides

We want to flip these pieces correctly, but leave the bottom twolayers intact. We can use conjugation to do so. Consider the moveconsisting of the commutator g = RUru. Applying g to the cubehas the effect shown below:

The Mathematics of the Rubik’s Cube

Page 68: Rubik Slides

You can see that 7 cubes are affected, 2 of which are not in thetop layer, but are instead in the R layer. We can fix this byperforming a rotation before we use the macro that will put toplayer cubies in all the positions affected by the macro, so that onlytop layer cubies are rearranged.

The Mathematics of the Rubik’s Cube

Page 69: Rubik Slides

Now take the conjugate of g by F to get the move FRUruf:

The Mathematics of the Rubik’s Cube

Page 70: Rubik Slides

By first performing F and then reversing this action with f after themacro is performed, we ensure that only the top row pieces areaffected. We can use our permutation notation to describe whatthis macro does. First look at g before conjugation. φcorner is ofthe form (12)(34), since it switches the top back corners and theupper right corners. φedge is of the form (123), since it 3-cycles theedge pieces FR, UR, and UB.

The Mathematics of the Rubik’s Cube

Page 71: Rubik Slides

Then for the conjugated macro, φcorner has the form (12)(34),since it switches two pairs of corners: the top front and the topback. φedge is of the form (123), since it leaves one edge piece inplace and 3-cycles the other 3 edge pieces. So the original macroand its conjugate have the same cycle structures. The onlydifference between a macro and its conjugate are the actual piecesinvolved in the cycles. Once you find a sequence of moves thatperforms the operation you want, e.g., cycling 3 pieces, flippingpieces, etc., than you can apply it to the desired pieces byconjugating it with the appropriate cube move.

The Mathematics of the Rubik’s Cube

Page 72: Rubik Slides

The ScrewDriver Method: We won’t be going over this one inclass, and in fact you should never need it again. It involvesturning one face 45 degrees, prying out the edge piece sticking out,and disassembling the cube using a screwdriver. Not much mathhere so we’ll move on.

The Mathematics of the Rubik’s Cube

Page 73: Rubik Slides

The Bottom up method: This is one of the most intuitive, butprobably one of the slowest, ways to solve the cube. It averagesabout 100 moves per solution.

The Mathematics of the Rubik’s Cube

Page 74: Rubik Slides

The First LayerThis first layer must be done by inspection. There is usually no setalgorithm to follow. It is helpful to focus on getting a cross firstwith the edge pieces correctly in place, and then solving thecorners one by one.

The Mathematics of the Rubik’s Cube

Page 75: Rubik Slides

The Second LayerNow rotate the bottom (solved) layer so that its edges on theother faces are paired with the correct center pieces. Your cubeshould look as follows:

The Mathematics of the Rubik’s Cube

Page 76: Rubik Slides

For this layer we only have to solve the four middle layer edgepieces. If an edge piece is in the top layer, use the followingmacros:

The Mathematics of the Rubik’s Cube

Page 77: Rubik Slides

If an edge pieces is not in the top layer, but is not orientedcorrectly, use the following to put the piece in the top layer andthen proceed as above:

The second layer should now be solved.

The Mathematics of the Rubik’s Cube

Page 78: Rubik Slides

The Third LayerWe will do this layer in 3 steps.

The Mathematics of the Rubik’s Cube

Page 79: Rubik Slides

Step 1: Flip the edges to form a cross on the top: To flip a toplayer edge correctly, use this macro:

The Mathematics of the Rubik’s Cube

Page 80: Rubik Slides

Repeat until all the edge pieces form a cross on the top:

The Mathematics of the Rubik’s Cube

Page 81: Rubik Slides

Step 2: Position the top layer edges correctly: Now position thetop layer so that one of the edges is solved. If all the edges aresolved, move on to the next step. If not, use the followingalgorithms to permute the edges correctly:

The Mathematics of the Rubik’s Cube

Page 82: Rubik Slides

The Mathematics of the Rubik’s Cube

Page 83: Rubik Slides

If none of these work, apply one of them until you get to a positionwhere one of these will work, then proceed.

The Mathematics of the Rubik’s Cube

Page 84: Rubik Slides

Step 3: Flip the top layer corners: For each corner that does nothave the correct color on the top layer, position it at UBR andperform RDrd repreatedly until it is oriented with the correct coloron top. Then, without rotating the cube, position the nextunsolved corner at UBR and repeat the process. The bottom twolayers will appear to be a mess, but they will be correct once allthe four corners are facing the correct direction.

The Mathematics of the Rubik’s Cube

Page 85: Rubik Slides

The Mathematics of the Rubik’s Cube

Page 86: Rubik Slides

Position the top layer corners correctly: Now the top layer shouldhave all the same color faces, but the corners might not beoriented correctly. Position one corner correctly, and thendetermine whether the others are solved, need to be rotatedclockwise, or need to rotated counterclockwise, and then apply thefollowing (let x = rD2R):

The Mathematics of the Rubik’s Cube

Page 87: Rubik Slides

The Mathematics of the Rubik’s Cube

Page 88: Rubik Slides

You should end with a solved cube!

The Mathematics of the Rubik’s Cube