• No results found

Solving Rubik’s Cube with Non-Standard Moves

N/A
N/A
Protected

Academic year: 2021

Share "Solving Rubik’s Cube with Non-Standard Moves"

Copied!
80
0
0

Loading.... (view fulltext now)

Full text

(1)

Solving Rubik’s Cube with

Non-Standard Moves

L A U R E N T V A N E E S B E E C K

(2)
(3)

Solving Rubik’s Cube with

Non-Standard Moves

L A U R E N T V A N E E S B E E C K

Master’s Thesis in Mathematics (30 ECTS credits)

Master Programme in Mathematics (120 credits)

Royal Institute of Technology year 2014

Supervisors at Université Catholique de Louvain, Belgien,

was Olivier Pereira

Supervisor at KTH was Tilman Bauer

Examiner was Tilman Bauer

TRITA-MAT-E 2014:55 ISRN-KTH/MAT/E--14/55--SE

Royal Institute of Technology

School of Engineering Sciences KTH SCI

(4)
(5)

Université catholique de Louvain

École polytechnique de Louvain

Louvain-la-Neuve

Royal Institute of Technology

Department of Mathematics

Stockholm

Thesis for the degree of

Master in Mathematical Engineering (UCL)

Master in Mathematics (KTH)

Solving Rubik’s Cube

with Non-Standard Moves

by

Laurent Van Eesbeeck

Supervisors

Olivier Pereira (UCL)

Tilman Bauer (KTH)

Readers

Christophe Petit (UCL)

Jean-Pierre Tignol (UCL)

(6)
(7)

Abstract

Still another thesis on Rubik’s cube? Is there still something new to write on that puzzle? In this document, we approach the cube with a rather unusual question: “how would you solve the cube if, instead of using the 6 classical rotations, you were restricted to a set of arbitrary moves?” To answer that question, we will dive into group theory.

Inspired by some previous work on the factorization of the symmetric group, we have developed an algorithm that answers our initial question. However, being able to solve the cube with any set of moves has a trade-off: while some algorithms solve the cube in 20 moves, ours requires several thousands.

(8)
(9)

Acknowlegdments

I would like to thank my three supervisors:

• Olivier Pereira for accepting to be my official UCL supervisor;

• Tilman Bauer for his support and his questions;

• Christophe petit for his weekly support, for recentering me to the main topic and for having endured the ups and downs of my productivity.

(10)
(11)

Contents

Contents 7

Introduction 9

1 Required Notions in Group Theory 11

1.1 A Very Short Introduction to Group Theory . . . 11

1.2 Quotient Groups and Semi-Direct Products . . . 15

1.3 Permutation Groups . . . 18

1.4 Conjugated Permutations and Commutators . . . 22

1.5 Notations and Conventions Used in this Document . . . 26

2 Introducing Rubik’s Cube 27 2.1 Permutations, Positionings and Orientations . . . 28

2.2 The Semi-Direct Product Behind G . . . 31

2.3 The Structure of G . . . 32

3 Factorizing the Symmetric Group 37 3.1 Finding a Permutation of Degree Less than n/4 . . . 39

3.2 Finding a 3-Cycle . . . 41

3.3 Factorizing any Target from a 3-Cycle . . . 47

4 Solving Rubik’s Cube with Non-Standard Moves 49 4.1 Factorizing Small Groups . . . 49

4.2 Factorizing A8× A12 . . . 51

4.3 Solving Rubik’s Cube with Non-Standard Moves . . . 52

Conclusion and Further Work 55 Bibliography 57 A Code Snippets 59 A.1 Rubik’s Cube . . . 59

A.2 Babai et al’s factorization of Sn . . . 60

A.3 Small Groups . . . 66

A.4 solving Rubik’s Cube with Non-Standard Moves . . . 73

(12)
(13)

Introduction

Still another thesis on Rubik’s cube? Didn’t people already do this?

Instead of presenting one other effective way to solve the cube or finding an alternative proof to God’s number (the minimal number of moves with which one can solve the cube from any configuration), through this thesis we are interested on the following question: “how would one solve the cube if, instead of the 6 classical face rotations, he was restricted to use an arbitrary set of moves?”

If odd, that question perfectly illustrates a far-from-trivial and deeply studied problem in group theory, the factorization problem: given a set S = {s1, . . . , sm} generating a group

G and an element g in that group G, how does one express g as a product of elements in S?

(This problem can be seen as a generalized version of the discrete logarithm problem and has potential applications in cryptography ([PQ11]). For some groups and some generating sets, the problem has well-known solutions. But in general, there is no obvious solution. Solving Rubik’s cube is merely the tip of the iceberg of a deeper problem.

This thesis is divided into four chapters.

• Chapter 1 is a warm-up. It introduces the notions in group theory that will be used later on, from the basic definitions to semi-direct products and permutation groups. The main notions are recaped in Section 1.5.

• Chapter 2 introduces the group structure behind Rubik’s cube (it is a semi-direct product) and presents a systematic strategy to solve it: first position the cubits right, then orient them right. As we will see, that solution requires about 1500 moves, far away from the world’s record of 20 moves.

• Chapter 3 dives into the litterature and presents a solution to the factorization problem for the symmetric group. As we will see, the studied algorithm does not work for small symmetric groups such as those encountered in Rubik’s cube.

• Chapter 4 is the central point of this thesis. Building upon the material presented in the Chapters 1 to 3, it presents a solution to Rubik’s cube that works for any given set of moves. It also provides a variant of the algorithm of Chapter 3 that works for small symmetric groups. Tests suggest that our algorithm requires about 6000 moves for the standard moves, and about 80 000 moves for any given set of moves.

(14)
(15)

Chapter 1

Required Notions

in Group Theory

This chapter provides a quick reminder of the group theory notions needed to understand the next chapters.

• Section 1.1 defines the very basic notions used in group theory: a group, a group action, a Cayley graph and a Schreier graph, a homomorphism and a subgroup.

• Section 1.2 presents cosets, Schreier coset graphs, normal subgroups, quotient groups and semi-direct products; the two latter being special groups that we will encounter in Chapter 2 and 4 when studying the group structure of Rubik’s cube.

• Section 1.3 gives a wide overview of permutation groups: definition, cycle representa-tion of a permutarepresenta-tion and its properties, parity of a permutarepresenta-tion and decomposirepresenta-tion of a permutation as a product of 2- and 3-cycles. Permutation groups will be used widely through this document and more specifically, the results of this section will be used in Chapters 3 and 4.

• Section 1.4 presents some nice properties of conjugated permutations and the com-mutator of two permutations. These properties will be used mainly in Chapter 3.

• Section 1.5 summarizes this chapter by listing the notations and conventions used through this document.

Readers familiar with all these notions may directly skip to Section 1.5; references to the main results of this chapter will be done when necessary.

1.1

A Very Short Introduction to Group Theory

Abstract algebra is a branch of mathematics where one defines mathematical structures by generalizing structures we commonly use and then studying the properties of these general objects. Groups are fundamental objects in abstract algebra, as they are used to define more complex objects such as rings, fields, modules, and so on.

Definition 1.1. A group (G, ?) is a set G supplied with an operator ? : G × G → G

satisfying the following axioms:

closedness ∀g1, g2 ∈ G, g1? g2∈ G;

(16)

associativity ∀g1, g2, g3∈ G, g1? (g2? g3) = (g1? g2) ? g3;

existence of a neutral element G has an identity element Id such that ∀g ∈ G, g ?Id =

Id ?g = g;

existence of inverses ∀g ∈ G, ∃g−1 ∈ G such that gg−1 = g−1g = Id.

If furthermore ? satisfies

commutativity ∀g1, g2∈ G, g1? g2= g2? g1

then (G, ?) is called a commutative group.

Remark. When the group operation is obvious from the context, (G, ?) is usually denoted

by G and the ? symbol either is a + or is ommitted: one writes g1 + g2 (for so-called additive groups) or g1g2 (for so-called multiplicative groups) instead of g1? g2. One also writes g + g + · · · + g | {z } n times = ng and gg · · · g | {z } n times = gn.

We are already familiar with different examples of groups: (R0, ×) is a commutative

group with identity 1 and as inverse r−1 = 1/r; (Z, +) is a commutative group with identity 0 and as inverse z−1 = −z. (Zn, +) is the cyclic group modulo n: Zn = {0, . . . , n − 1}

with operation a ? b = (a + b) mod n.1 As an example of non-commutative group, consider

GL(2, R), the multiplicative group of 2 × 2 matrices with non-zero determinant.

From the axioms of a group follow a couple of elementary properties. The reader interested in a proof of these properties may consult [DF04], §1.1.

Proposition 1.2. Let G be a group. Then the following holds:

• the identity of G is unique;

• every element g ∈ G has a unique inverse g−1 and (g−1)−1= g;

• the inverse of g1g2 is (g1g2)−1= g2−1g −1 1 ;

• the equations ax = b and xa = b have a unique solution x ∈ G for every a, b ∈ G;

• for every g, x, y ∈ G, if gx = gy then x = y and if xg = yg then x = y.

As we will see when we study permutation groups, some group elements have nice properties. The purpose for the moment is merely to mention their existence.

Definition 1.3. Two group elements g1 and g2 are said conjugate if there exists an h such

that g1h = hg2. The conjugate of g by h, noted gh, is the element h−1gh.

Note that (gh)−1= (h−1gh)−1= h−1g−1h = (g−1)h gh1h2 = (h 1h2)−1gh1h2= h−12 (h −1 1 gh1)h2= (gh1)h2 (g1g2)h= h−1(g1g2)h = (h−1g1h)(h−1g2h) = g1hgh2. 1

(17)

1.1. A VERY SHORT INTRODUCTION TO GROUP THEORY 13

Definition 1.4. The commutator of two elements g and h, noted [g, h], is defined as

[g, h] = g−1h−1gh.

When g and h commute, [g, h] = Id, so the commutator can be seen as a measure of “how much” two elements commute. Indeed, gh = hg[g, h]. One also notes that

[g, h]−1 = (g−1h−1gh)−1 = h−1g−1hg = [h, g].

Groups can interact with other structures through a mechanism called group actions.

Definition 1.5. A left group action of a group G on a set S is an operation ∗ : G × S → S

satisfying the two following actions: • for all s ∈ S, Id ∗s = s;

• for all g, h ∈ G, s ∈ S, (gh) ∗ s = g ∗ (h ∗ s).

Similarly, a right group action is an operation ∗ : S × G → S satisfying • for all s ∈ S, s ∗ Id = s;

• for all g, h ∈ G, s ∈ S, s ∗ (gh) = (s ∗ g) ∗ h.

As an example, the group operation is a (left and right) action of a group G on itself. Another example is the previously defined conjugacy operation: the operation

g · h = gh = h−1gh is a right group action of G on itself. We’ll see two more examples in

the context of permutation groups.

Remark. Some authors define the conjugate of g by h ashg = hgh−1and the commutator

of g and h as [g, h] = ghg−1h−1. With that definition, the operation h · g = hg is a left

group action.

Our choice of using the other convention is made to avoid confusions with Magma (Magma defines gh= h−1gh and (g, h) = g−1h−1gh) and because it is consistent with the

multiplication of permutations from left to right. (More about this in Section 1.3.) More generally, to be consistent with this convention, function composition must be done from left to right: (f g)(x) = g(f (x)). That’s why through this document, the image of x by a function f , f (x), will be noted xf and (f g)(x) = xf g = (xf)g. The group actions we will encounter will also, by convention, be right group actions.

Definition 1.6. The order of a group G, |G|, is the number of elements in G. The order

of an element g ∈ G, |g|, is the smallest positive integer n such that gn = Id. If such an integer does not exist, then by convention |g| = ∞.

The following result gives some information on the order of an element. Again, the proof can be found in [DF04], §3.2.

Proposition 1.7. If G is a finite group, then |g| divides |G|.

One way to describe a group is to use a generating set S = {s1, s2, . . . , sn}. One then

writes G = hSi to describe the group defined by the set of all finite products of elements of S with respect to the implicit group operation:

G =

si1si2· · · sik| ij ∈ {1, . . . , n} ∀j ∈ {1, . . . , k}

.

(18)

0 1 2

3

4 5

Figure 1.1: The Cayley graph of Z6 generated by {1, 2}, Γ(Z6, {1, 2}).

Definition 1.8. The (colored) Cayley graph of G with respect to a generating set S =

{s1, . . . , sn}, Γ(G, S), is the oriented graph with vertex set G and edge set (g, gsi) | g ∈

G, i ∈ {1, . . . , n}

. In a colored Cayley graph, the vertex (g, gsi) is colored in the ith

color.

Definition 1.9. Given a group G = hSi that acts on a set X with a left (right) group

action ∗ : G × X → X, the left Schreier graph Γ(G, S, X, ∗) is the oriented graph with vertex set X and edge set {(x, s ∗ x) | x ∈ X, s ∈ S}. The right Schreier graph has the same vertex set and {(x, x ∗ s) | x ∈ X, s ∈ S} as edge set.

Since the group multiplication is a group action, Schreier graphs generalize Cayley graphs. These graphs are regular (i.e., every vertex has the same number of neighbors), so they usually lead to very symmetric and structured drawings (Figure 1.1).

A group generated by a set S ⊂ G can also form a smaller group than G called a subgroup. E.G., h2i = {0, 2, 4} is a subgroup of Z6.

Definition 1.10. A subgroup H of G is a subset of G which forms a group under the

group operation in G. If H is a subgroup of G, one writes H ≤ G.

Since the associativity of the operation is ensured for every element in G (and hence also in H ⊂ G), one must only verify the closedness, existence of a neutral element and existence of inverses axioms in H to check that H is a subgroup of G. Note that the identity in H is also the identity in G. An equivalent way to show that H is a subgroup of G is the subgroup criterion. For a proof, see [DF04], §2.1.

Proposition 1.11 (The Subgroup Criterion). A subset H of a group G is a subgroup if

and only if 1. H 6= ∅

2. ∀x, y ∈ H, xy−1 ∈ H.

Definition 1.12. For G and H two groups, a map φ : G → H is called a homomorphism

if, ∀g1, g2 ∈ G,

(g1g2)φ= g1φ· g

φ

2.

A homomorphism from G to G is called an automorphism. If a homomorphism is bijective, it is called an isomorphism and G and H are said isomorphic, which is noted by G ∼= H.

One also has the following properties for homomorphisms (see [DF04], §3.1).

(19)

1.2. QUOTIENT GROUPS AND SEMI-DIRECT PRODUCTS 15

• Id= IdH;

• for every g ∈ G, (g−1)φ= g(φ−1);

• ker φ = {g ∈ G | gφ= Id} is a subgroup in G;

• Im φ = Gφ= {gφ| g ∈ G} is a subgroup in H.

Remark. Two isomorphic groups G and H can be seen as the same group up to the

differ-ence that its elements have different names from one group to another. The isomorphism linking these groups has the effect of “translating” an element of G to its equivalent in H.

1.2

Quotient Groups and Semi-Direct Products

Let us first review some results related to subgroups. Closely related to a subgroup is the notion of a coset.

Definition 1.14. For H ≤ G a subgroup of G and g ∈ G, gH = {gh | h ∈ H} is called a

left coset of H and Hg = {hg | h ∈ H} is a right coset. The elements of a coset are called its representatives.

Remark. Needless to say, what we say in this section is written with left cosets but can

just as well be written in terms of right cosets.

Two cosets of a same subgroup either are disjoint or are identical, and the set of cosets of a particular subgroup H ≤ G form a partition of G. Note also for all g0 ∈ gH, gH = g0H

(see [DF04], §3.1). This implies that all the cosets have the same number of elements. One notes [G : H], the index of H in G, as the number of distinct cosets H has in G. Hence, when G is finite, [G : H] = |G|/|H|.

Cosets have an equivalent links with graph theory as Cayley graphs and Schreier graphs: Schreier coset graphs.

Definition 1.15. Given a group G = hSi and a subgroup H ≤ G, the Schreier left

coset graph Γ(G, S, H) is the oriented graph with vertex set {gH | g ∈ G} and edge set {(gH, sgH) | g ∈ G, s ∈ S}. The Schreier right coset graph is the graph with vertex set {Hg | g ∈ G} and edget set {(Hg, Hgs) | g ∈ G, s ∈ S}.

For this section we need some particular subgroups called normal subgroups.

Definition 1.16. A subgroup N ≤ G is said normal if for all g ∈ G, n ∈ N ,

g−1ng ∈ N.

If N ≤ G is normal, one notes N E G.

Normal subgroups and kernels of homomorphisms are related. From [DF04], §3.1,

Proposition 1.17. A subgroup N ≤ G is normal if and only if it is the kernel of some

homomorphism.

One main result in group theory is that the set of distinct cosets of a normal subgroup, {gN | g ∈ G}, forms a group with the group operation

(20)

In other words: to multiply two cosets, take any element n1 ∈ g1N and any element

n2 ∈ g2N ; the coset (g1N )(g2N ) is the coset to which belongs n1n2. We won’t show here that this operation is well-defined, i.e., that the result of this operation is the same independently of the choice of representatives. (The interested reader can consult [DF04].) An equivalent approach of this operation is the following. Suppose that there is a homomorphism φ : G → H such that φ is a one-to-one relation between the cosets gN and the elements of H: for every g, for every n ∈ gN , nφ= h and h is uniquely and only determined by g. (This implies that Nφ = Id, i.e., that N is the kernel of φ.) Then the product of two cosets works as follows: for g1N and g2N , take the corresponding h1 and

h2 in H, and compute h1h2. The coset (g1N )(g2N ) is the one corresponding to h1h2. The group of cosets of N ≤ G supplied with the previously defined operation is called the quotient group G/N . Its identity is the coset Id N = N and the inverse of gN is (gN )−1 = g−1N .

To clarify this with an example, consider the normal subgroup of Z, 3Z = {. . . , −3, 0, 3, 6, . . . }. It has three distinct cosets: 0+3Z, 1+3Z = {. . . , −2, 1, 4, . . . }, 2+3Z = {. . . , −1, 2, 5, . . . }. 3Z is also the kernel of the homomorphism φ : Z → Z3, x 7→ x mod 3. One can then add 1 + 3Z and 2 + 3Z in two different ways:

• one can choose 7 ∈ 1 + 3Z and 5 ∈ 2 + 3Z. Their sum, 7 + 5 = 12 lies in 0 + 3Z, hence (1 + 3Z) + (2 + 3Z) = 0 + 3Z.

• φ maps 1 + 3Z to 1 and 2 + 3Z to 2. In the group Z3, 1 + 2 = 0 and 0 is associated to the coset 0 + 3Z. Hence, (1 + 3Z) + (2 + 3Z) = 0 + Z.

These two ways to multiply cosets in a quotient group are summarized in what is known as the first isomorphism theorem (see [DF04], §3.3).

Theorem 1.18. If φ : G → H is a group homomorphism, then ker φ is a normal subgroup

and G/ ker φ ∼= Im φ.

We can now move to the last topic: direct and semi-direct products.

Definition 1.19. The direct product between two groups (G1, ?) and (G2, ∗), noted G

G2, is the set {(g1, g2) | g1 ∈ G1, g2∈ G2} supplied with the operation

(g1, g2) · (g10, g20) = (g1? g10, g2∗ g02).

It is not difficult to check that (G1 × G2, ·) is a group. Closedness and associativity are inherited properties from G1 and G2, it has (IdG1, IdG2) as identity and (g1, g2)

−1 = (g1−1, g2−1).

The notion of semi-direct product is a generalization of the direct product. To introduce it, consider a group G with a normal subgroup N E G. If g1 and g2 ∈ G can be written as h1n1 and h2n2 for some n1, n2 ∈ N , then

g1g2 = (h1n1)(h2n2) = h1h2(h−12 n1h2)n2

But since N is normal, h−12 n1h2= n01 ∈ N . Hence,

(h1n1)(h2n2) = (h1h2)(n01n2)

(21)

1.2. QUOTIENT GROUPS AND SEMI-DIRECT PRODUCTS 17

x 7→ xf g = (xf)g. (Observe that with quotient groups we introduced groups of sets, here we introduce a group of functions.) The homomorphism φ : H → Aut(N ) hence means that

• for every h ∈ H, φ(h) is a homomorphism from N to N : (n1n2)φ(h) = n1φ(h)· n2φ(h); • for h1, h2 ∈ H, φ(h1h2) is the homomorphism n 7→ nφ(h1h2)= (nφ(h1))φ(h2);

• φ(Id) is the identical homomorphism: nφ(Id)= n.

With this example in mind, we can now state the definition of a semi-direct product.

Definition 1.20. Given two groups H and N and a homomorphism φ : H → Aut(N ), the

semi-direct product H nφN is the set {(h, n) | h ∈ H, n ∈ N } supplied with the operation

(h1, n1) · (h2, n2) = (h1h2, n1φ(h2)n2).

In the introductary example, nφ(h) = h−1nh = nh. For a direct product, φ(h) is the identity automorphism: nφ(h)= n.

The semi-direct product is a group: • Closedness is obvious. • Associativity:  (h1, n1)(h2, n2)  (h3, n3) = h1h2, n1φ(h2)n2  (h3, n3) = h1h2h3, n1φ(h2)n2 φ(h3) n3 = (h1h2h3, n1φ(h2h3)n2φ(h3)n3) (h1, n1)  (h2, n2)(h3, n3)  = (h1, n1)(h2h3, n2φ(h3)n3) = (h1h2h3, n1φ(h2h3)n2φ(h3)n3).

• Existence of a neutral element: (Id, Id) is the neutral element of the group. Indeed,

(h, n)(Id, Id) = (h · Id, nφ(Id)· Id) = (h, n) (Id, Id)(h, n) = (Id ·h, Idφ(h)·n) = (n, h).

• Existence of inverses: (h, n)−1 = h−1, (n−1)φ(h−1)

. Indeed,

(h, n) h−1, (n−1)φ(h−1)

= hh−1, nφ(h−1)· (n−1)φ(h−1)

= (Id, (nn−1)φ(h−1)) = (Id, Id)

h−1, (n−1)φ(h−1)

(h, n) = (h−1h, (n−1)φ(h−1)φ(h)· n)

= (Id, (n−1)φ(h−1h)· n) = (Id, Id).

The discussion behind the introductory example is summarized in the following theo-rem.

Theorem 1.21 ([DF04], §5.5). Suppose G is a group with N, H two subgroups of G such

(22)

Remark. When one follows the convention that nh = hnh−1, the reasoning in the intro-ductory example becomes

(n1h1)(n2h2) = n1(h1n2h1−1)h1h2= (n1n2h1)(h1h2) and the definition of the semi-direct product naturally becomes

N oφH =



(n, h) ∈ N × H | (n1, h1) · (n2, h2) = (n1n2φ(h1), h1h2)

.

To make the difference between these definitions, one uses either the sign n or o.

1.3

Permutation Groups

Permutation groups are among the most common finite groups and are closely linked to the notion of symmetry.

Definition 1.22. A permutation on a set A is a bijection from A to A. The set of

all permutations on A, supplied with the function composition, is a group called SA. If

A =

1, . . . , n

, SA is called Sn.

Proposition 1.23. SA is a group.

Proof. One needs to check the axioms of a group:

1. ∀f, g ∈ SA, f g ∈ SA: true since the composition of two bijections is still a bijection; 2. ∀f, g, h ∈ SA, (f g)h = f (gh): true since the function composition is associative;

3. SA has an identity element: the identity function Id : x 7→ x is a bijection and

∀f ∈ SA, f · Id = Id ·f = f ;

4. every f ∈ SA has an inverse: true since f is a bijection.

Note, however, that SA is not commutative. Through this document, we will only

consider permutation groups over the finite set 

1, . . . , n

.

For a given permutation f ∈ Sn, one notes xf the image of x ∈ {1, . . . , n} by f . This

induces the natural right group action ∗ : {1, . . . , n} × Sn → {1, . . . , n}, x ∗ f = xf. It is

a group action:

x ∗ Id = xId= x, x ∗ (f g) = xf g = (xf)g = (x ∗ f ) ∗ g.

Permutations also naturally act on vectors by the right group action ∗ : Rn × Sn

Rn, (x1, . . . , xn) ∗ f = (x(1f), . . . , x(nf)). One then naturally notes (x1f, . . . , xnf) =

(x1, . . . , xn)f.

The previous action is particular because it also defines a homomorphism φ : Sn → Aut(Rn) which maps x → xφ(f ) = xf. (Note that every homomorphism φ : G → Aut(H)

induces a group action of G on H but that the converse is not true in general.) It is a homomorphism because

(x + y)f = (x1+ y1, . . . , xn+ yn)f = (x1f + y1f, . . . , xnf + ynf) = xf + yf.

Hence, from the previous section, the group

(23)

1.3. PERMUTATION GROUPS 19

Definition 1.24. A permutation group G ≤ Sn is said k-transitive if for every pair of

k-tuples (t1, . . . , tk) and (t01, . . . , t0k) with ti 6= tj and t0i6= t0j for every i 6= j, there exists a

permutation f ∈ G such that f (t1) = t01, . . . , f (tk) = t0k. A 1-transitive permutation group

is said transitive.

Definition 1.25. The support of a permutation f , supp(f ), is the set of elements in 

1, . . . , n

that are moved by f . The degree of f , deg f , is the number of elements that it moves.

Note that supp(f ) = supp(f−1) and that deg(f ) = deg(f−1). Also, if = i if and only if i 6∈ supp(f ).

The most straightforward way to represent a permutation is the line representation: put the elements a ∈ A on a first line and put their corresponding values f (a) on a second line. For example, in S4, the function f mapping 1 to 3, 2 to 4, 3 to 2 and 4 to 1 is represented as

f = 1 2 3 4

3 4 2 1

!

.

Multiplying two functions with this representation is straightforward too. For example, if

g maps 1 to 4, 2 to 3, 3 to 2 and 4 to 1, f g = 1 2 3 4 3 4 2 1 ! · 1 2 3 4 4 3 2 1 ! = 1 2 3 4 2 1 3 4 !

However, the line representation is quite heavy. A more popular one is the cycle representation: in the previous example, f maps 1 to 3, 3 to 2, 2 to 4 and 4 to 1, so its cycle representation is

f = (1, 3, 2, 4).

As a second example, g maps 1 to 4 and 4 to 1; 2 to 3 and 3 to 2, which makes 2 distinct cycles:

g = (1, 4)(2, 3).

As a third example, the product f g is

f g = (1, 2)(3)(4);

however, since the cycles (3) and (4) do not carry any relevent information, they are omitted from the representation:

f g = (1, 2).

The cycle representation of a permutation is unique up to a reordering of its cycles,

g = (1, 4)(2, 3) = (2, 3)(1, 4),

and up to starting each cycle with another element of the cycle:

f = (1, 3, 2, 4) = (3, 2, 4, 1) = (2, 4, 1, 3) = (4, 1, 3, 2).

(24)

Proposition 1.26. Write n = 1n1+ 2n2+ · · · + knk. There are

n!

Qk

i=1inini!

different permutations that have n1 1-cycles, n2 2-cycles, . . . , nk k-cycles.

Proof. We can represent every permutation as a string containing all the integers 1, . . . , n

exactly once and split these strings according to the fixed cycle structure. (This represen-tation explicitly includes the 1-cycles.) There are n! such strings.

But amongst these strings, some are equivalent representations of the same permuta-tions:

• every k-cycle can be written in k equivalent different ways, which makes a total factor Q

iini;

• in this string representation, we can swap cycles of same length among them: e.g., for n = 9, n1 = n2= 1 and n3= 2, the strings

123 45 6 789 and 789 45 6 123

represent the same permutation. This makes the factor Q

ini!.

Multiplying two permutations from their cycle representation is a bit less obvious and is given by the following algorithm.

1. Start a new cycle with the smallest element x in supp(f ) ∪ supp(g) that hasn’t been used yet.

2. Do this for every cycle in the product, starting from the cycle on the left and moving to the right: if x belongs to the cycle, replace x by the element next to it in the cycle.

3. If the new x is equal to the first element of the cycle under construction, close that cycle and go to step 4. Else, add x to the current cycle, add it to the list of elements already used and go back to step 2.

4. If the list of elements that haven’t been used yet is empty, remove the 1-cycles; the algorithm is done. Else, go back to step 1.

As an example, consider the product f2g = f f g with f and g defined as previous:

f2g = (1, 3, 2, 4)(1, 3, 2, 4)(1, 4)(2, 3).

The multiplication algorithm goes as follows. First, start a new cycle with 1. In the first cycle, 1 goes to 3. In the second cycle, 3 goes to 2. 2 does not appear in the third cycle, so it remains 2. In the fourth cycle, 2 goes to 3. Hence,

f2g = (1, 3 . . .

In the first cycle, 3 goes to 2. In the second, 2 goes to 4. In the third, 4 goes to 1. 1 does not appear in the fourth cycle, closing the first cycle of the product:

(25)

1.3. PERMUTATION GROUPS 21

We then start a new product with an element that hasn’t been used yet: 2. In the first cycle, 2 goes to 4. In the second, 4 goes to 1. In the third, 1 goes to 4. 4 does not appear in the last cycle. Then,

f2g = (1, 3)(2, . . .

One easily checks that 2 goes to 4, closing so the second cycle:

f2g = (1, 3)(2, 4).

The cycle representation is convenient to extract some characteristics of a permutation. Indeed, the support of a permutation is the set of elements in its cycle representation and its degree is the number of elements in it. It also makes the following result trivial.

Proposition 1.27. Every permutation of Sncan be written as a product of disjoint cycles.

From the algorithm of multiplication between permutations, we also have that

Proposition 1.28. Disjoint cycles commute.

In addition of providing a compact representation of permutations, the cycle represen-tation of a permurepresen-tation gives some information about its order.

Proposition 1.29. The order of a k-cycle is k.

Proof. Observe that (a0, . . . , ak−1)n is a permutation that sends ai to a(i+n) mod k. Hence

n = k is the smallest positive power such that (a0, . . . , ak−1)nsends ai to ai.

Proposition 1.30. When a permutation is written as a product of disjoint cycles, its

order is the LCM of the length of its cycles.

Proof. Write f = C1C2· · · Ck where C1, . . . , Ckare disjoint cycles and write l1. . . , lk their

lengths. Since they are disjoint, fn= C1n· · · Cn

k. By the previous result, fn= Id only if n

is a multiple of both l1, . . . , lk. Hence the order of f is the LCM of l1, . . . , lk.

But there is still more to say about permutations and cycles.

Proposition 1.31. Every permutation f ∈ Sn can be expressed as a product of at most

n − 1 2-cycles.

Proof. A k-cycle can be expressed as a product of (k − 1) 2-cycles in the following way:

(a1, a2, a3, . . . , ak) = (a1, a2)(a1, a3) · · · (a1, ak).

Applying this formula to every cycle of the cycle representation of f proves the result. A permutation of j distinct cycles of lengths l1, . . . , lj can be written as a product of

(l1− 1) + · · · + (lj − 1) ≤ n − j 2-cycless. The worst case is then the case of one single

n-cycle, which is then expressed as a product of (n − 1) 2-cycles.

Definition 1.32. A permutation f ∈ Sn is said even if it can be expressed as an even

product of 2-cycles. Else it is said odd. The signature of a permutation f , sgn(f ), is defined as

sgn(f ) =

(

(26)

Proposition 1.33. The signature function is a homomorphism. Proposition 1.34. Even cycles are odd, odd cycles are even.

Proof. Direct from the previous result.

Proposition 1.35. The signature function, sgn, is a homomorphism.

Proposition 1.36. Every even permutation f can be expressed as a product of at most

n − 1 3-cycles.

Proof. Write first f = c1c2· · · c2k as a product 2k ≤ n − 1 of 2-cycles and then apply the following relation pairwise to the product:

(a, b)(a, b) = Id (a, b)(a, c) = (a, b, c)

(a, b)(c, d) = (a, b, c)(a, d, c)

Proposition 1.37. An is a group.

Proof. From Proposition 1.11, since An⊂ Sn, one must only check the following:

1. Id ∈ An: trivial since (a, b)(a, b) = Id;

2. ∀f ∈ An, f−1∈ An: if f is an even product of 2-cycles, f = c1c2· · · c2k, since ci = c−1i

then f−1 = c2kc2k−1· · · c2c1 is also even;

3. ∀f, g ∈ An, f g ∈ An: if f = c1c2· · · c2k and g = c01c02· · · c02k0, then obviously f g =

c1c2· · · c2kc10c02· · · c02k0 is even.

1.4

Conjugated Permutations and Commutators

As announced in Section 1.1, conjugated permutations and commutators have some nice properties.

Proposition 1.38. The conjugate of a k-cycle c = (c1, . . . , ck) is a k-cycle. In particular,

cg = g−1cg = (c1g, . . . , ckg).

Proof. g−1cg acts on cig as follows:

(cig)g −1cg = cicg= ( ci+1g if i ∈1, . . . , k − 1 c1g if i = k

Hence, g−1cg contains the k-cycle (c1g, . . . , ckg).

To show that g−1cg is that k-cycle, notice that if ic= ci = j, then

(ig)g−1cg = (ic)g = jg.

Hence, if i 6∈ supp(c), then ic = i and (ig)g−1cg = ig and ig 6∈ supp(g−1cg). Hence,

deg(g−1cg) ≤ deg(c) = k. But since g−1cg contains a k-cycle, deg(g−1cg) = k and gcg−1

(27)

1.4. CONJUGATED PERMUTATIONS AND COMMUTATORS 23

Corollary 1.39. For any permutation g, f and fg have the same cycle structure. In

particular, if f = (a1, . . . , ak1)(b1, . . . , bk2) · · · then fg = (a1g, . . . , ak1 g)(b 1g, . . . , bk2 g) · · ·

i.e., the cycle decomposition of fg is obtained by replacing each i by ig in the cycle decom-position of f .

Proof. Writing f into its disjoint cycle representation, f = C1· · · Ck, one has

fg = g−1(C1· · · Ck)g = (g−1C1g)(g−1C2g) · · · (g−1Ckg).

Applying the previous proposition to each g−1Cig proves the result.

Corollary 1.40. For any permutations f and g, supp(fg) = (supp(f ))g and deg(f ) =

deg(fg).

The two previous corollaries justify why the notation fg is used for f conjugated by g: conjugating f by g is the same as applying g elementwise to the cycle structure of f . They also justify why the convention fg = g−1f g is used instead of the convention fg = gf g−1: if the latter was used, the permutation fg would be such that every element i in the cycle representation of f is replaced i(g−1), which would be confusing to remember.

Corollary 1.41. Two permutations f and g are conjugate in Sn if and only if they have

the same cycle structure.

Proof. We already saw that if f and g are conjugate, then they have the same cycle

struc-ture. Suppose that f and g have the same cycle structure when written as a product of dis-joint cycles: f = C1C2. . . Ck g = C10C20 . . . Ck0, Ci = (ci,i1, . . . , ci,im), C

0

i = (c0i,i1, . . . , c

0

i,im).

Since C1, . . . , Ck have disjoint supports and since C10, . . . , Ck0 also have disjoint supports,

then there is (at least) one permutation h which sends ci,ij to c0i,i

j. By the previous

corollary, fh= g.

This corollary does not apply for permutations in An: (1, 2, 3) and (1, 3, 2) are not

conjugate in A4. However, one has the following result.

Corollary 1.42. All 3-cycles are conjugate in An, n ≥ 5.

Proof. Take f = (f1, f2, f3) and g = (g1, g2, g3) in An. Write h = (f1, g1)(f2, g2)(f3, g3). By Proposition 1.38, fh = g. If h is even, we are done. Suppose h is odd. Since n ≥ 5, there exist f4, f5 ∈ {1, . . . , n} \ {f1, f2, f3} such that f4 6= f5. Write h0 = (f4, f5)h. By construction, f and (f4, f5) commute, hence

fh0 = h−1(f4, f5)−1(f1, f2, f3)(f4, f5)h = h−1(f4, f5)−1(f4, f5)(f1, f2, f3)h = h−1(f1, f2, f3)h = fh= g.

Since h0 is even, f and g are conjugate in An.

As the two following propositions show, looking at how the support of two permutations overlap tells us some information on their commutator.2

Proposition 1.43. If f, g ∈ Sn are such that supp(f ) ∩ supp(g) =a , then the

commu-tator [f, g] is the 3-cycle (a, ag, af).

(28)

Proof. First, observe the action of [f, g] on a. Since af±1 6∈ supp(g) and ag±1 6∈ supp(f ), (af±1)g±1 = af±1 and (ag±1)f±1 = ag±1. Hence, af−1g−1f g = ((af−1)g−1)f g = (af−1)f g = ag; (ag)f−1g−1f g = (ag)g−1f g = af g = af; (af)f−1g−1f g = ag−1f g = ag−1g = a.

Hence, [f, g] includes the 3-cycle (a, ag, af).

Second, observe the action on [f, g] on k 6∈ {a, f (a), g(a)}.

• If k 6∈ supp(f ) ∪ supp(g), then obviously kf−1g−1f g = k.

• If k ∈ supp(g) \ {a, g(a)}, then kg−1

∈ supp(g) \ {a} and k, kg−1

6∈ supp(f ). Hence,

kf−1 = k and (kg−1)f = kg−1 and

kf−1g−1f g = ((kf−1)g−1)f g = (kg−1)f g = kg−1g = k.

• If k ∈ supp(f ) \ {a, f (a)}, then kf−1

∈ supp(f ) \ {a} and k, kf−1

6∈ supp(g). Hence, as in the previous case, (kf−1)g−1 = kf−1 and kg = k

kf−1g−1f g = ((kf−1)g−1)f g = (kf−1)f g = kg = k

Hence, supp([f, g]) = {a, ag, af} and [f, g] = (a, ag, af).

Proposition 1.44. If f, g ∈ Sn such that | supp(f ) ∩ supp(g)| = k, then deg([f, g]) ≤ 3k.

Proof. Write A = supp(f ) ∩ supp(g). The proof consists of showing that for all x ∈

supp([f, g]), x ∈ A ∪ Af∪ Ag and thus, supp([f, g]) ≤ 3|A| = 3k.

For the proof, let us write F = supp(f ) and G = supp(g). (Then, A = F ∩ G.) Let us also note the following statements:

xf−1 = xx 6∈ F (1.1)

(xg−1)f = xg−1 ⇔ xg−1 6∈ F (1.2) (xf−1)g−1 = xf−1 ⇔ xf−1 6∈ G (1.3)

xg= xx 6∈ G (1.4)

It is not hard to see that either when (1.1) and (1.2) or (1.3) or (1.4) are satisfied,

x[f,g]= x. Logically written, (1.1) and (1.2) or (1.3) and (1.4) ⇒ x[f,g] = x i.e., x 6∈ supp([f, g]) or equivalently, by contraposition, x ∈ supp([f, g]) ⇒ ¬(1.1) or ¬(1.2) and ¬(1.3) or ¬(1.4)

Hence, if x ∈ supp([f, g]), there are 4 different cases:

1. ¬(1.1) and ¬(1.3): x ∈ F and xf−1 ∈ G. Since x ∈ F , xf−1 ∈ F and hence xf−1 ∈ A,

(29)

1.4. CONJUGATED PERMUTATIONS AND COMMUTATORS 25

2. ¬(1.1) and ¬(1.4): x ∈ F and x ∈ G. Then, obviously, x ∈ A.

3. ¬(1.2) and ¬(1.3): xg−1 ∈ F and xf−1 ∈ G. We can’t say anything from here, but

looking at the 4 subcases we see that x ∈ A ∪ Af ∪ Ag:

a) (1.1) and ¬(1.2) and ¬(1.3) and (1.4): this subcase never occurs because (1.1) and (1.4) imply that xf = xg−1 = x, hence (xg−1)f = xf = x = xg−1. Yet, this contradicts ¬(1.2) which states that (xg−1)f 6= xg−1.

b) ¬(1.1) and ¬(1.2) and ¬(1.3) and (1.4): this subcase is dealt with in the case 1: x ∈ Af.

c) (1.1) and ¬(1.2) and ¬(1.3) and ¬(1.4): this subcase is dealt with in case 4:

x ∈ Ag.

d) ¬(1.1) and ¬(1.2) and ¬(1.3) and ¬(1.4): this case is dealt with in cases 1, 2 and 4: x ∈ A ∩ Af∩ Ag.

4. ¬(1.2) and ¬(1.4): (xg−1 ∈ F and x ∈ G. Since x ∈ G, xg−1 ∈ G and hence xg−1 ∈ A,

hence x ∈ Ag.

Remark. Proposition 1.44 does not exactly generalize Proposition 1.43. While the latter

gives an equality on the degree of the commutator, the former only provides an upper bound, which:

• could not be better: indeed, by Proposition 1.43, we know that the bound is reached when | supp(f ) ∩ supp(g)| = 1;

• may be far too pessimistic: if f = g, then obviously | supp(f ) ∩ supp(g)| = deg(f ) but deg([f, g]) = 0  3 deg(f ).

(30)

1.5

Notations and Conventions Used in this Document

Following Magma’s convention, permutations are multiplied from left to right. That is,

f g is the permutation that sends i to g(f (i)) (also noted if g = (if)g). Group elements are multiplied from left to right and group actions in this document are all right group actions.

xf (also f (x)). The image of x by a function f (a homomorphism, a permutation, . . . ).

If x is a set, xf = {yf| y ∈ x}. If x is a vector of n elements and f a permutation in

Sn, xf = (x(1f), . . . , x(nf)).

xi. The ith element of a vector x.

Graphs. Given a group G generated by a set S, a left (or a right) group action ∗ :

G × X → X and a subgroup H ≤ G,

1. the Cayley graph Γ(G, S) is the oriented graph with vertex set G and edge set {(g, gs) | g ∈ G, s ∈ S};

2. the left Schreier graph Γ(G, S, X, ∗) is the oriented graph with vertex set X and edge set {(x, s ∗ x) | x ∈ X, s ∈ S}; the right Schreier graph has the same vertex set and {(x, x ∗ s) | x ∈ X, s ∈ S} as edge set;

3. the Schreier left coset graph is the oriented graph with vertex set {gH | g ∈

G} and edge set {(gH, sgH) | g ∈ G, s ∈ S}; the Schreier right coset graph

Γ(G, S, H) has {Hg | g ∈ G} as vertex set and {(Hg, Hgs) | g ∈ G, s ∈ S} as edge set.

Order of an element/a group. The smallest positive integer n such that xn= Id/the

number of elements of a group.

Parity/Signature. If a permutation g can be written as an even product of 2-cycles, its

parity is even/has signature +1. Else, it is odd/has signature −1.

Permutation groups. Sn is the group of all permutations over 1, . . . , n , An is the

group of all even permutations over

1, . . . , n

.

Support. The set of elements that are moved by a permutation π (noted supp(π)) Degree. The number of elements that are moved by a permutation π (noted deg(π))

Conjugate. The conjugate of a permutation f by a permutation g is fg = g−1f g.

Commutator. The commutator between two permutations f and g is [f, g] = f−1g−1f g.

Semi-direct product. Given N, H two groups and φ : H → Aut(N ) a homomorphism,

N oφH =(n, h) ∈ N × H | (n1, h1) · (n2, h2) = (n1n2φ(h1), h1h2)

(31)

Chapter 2

Introducing Rubik’s Cube

Rubik’s cube is a famous 3-D puzzle consisting of 26 colored small cubes forming together one bigger cube, Rubik’s cube. Through a ingenious mechanism, each face of the cube can rotate by 90, 180 or 270 degrees (Figure 2.1). The aim of the puzzle is to rotate the faces cleverly in order to put back each small cube at its initial position.

In this chapter, we present the mathematical structure behind the cube. As we will see, two different groups are linked to the cube: a group G consisting of all the possible arrangements of the smaller cubes, and a group G of the arrangements that are reacheable by rotating the faces of the cube. As we will see, these two groups are not equal: G is a subgroup of G.

This chapter is divided in three sections: • Section 2.1 introduces the groups G and G; • Section 2.2 shows that G is a semi-direct product;

• Section 2.3 presents the structure of G by showing which elements in G are in G. In this section we will see that G is a subgroup of order 12 of G and we will also present one way to solve the cube.

The content of this chapter is inspired of [Isa12], [Che78], [BHH+10] and [Ban82]. [Isa12] presents Rubik’s cube from an abstract point of view; [Che78] are the notes of a summer camp and include a very accessible introduction to group theory; [BHH+10]’s approach is not so far from ours; and [Ban82] has a fair list of useful moves to solve the cube.

Figure 2.1: Through a ingenious mechanism, each face of the cube can independently rotate by 90, 180 or 270 degrees.

(32)

front back left righ t down up

Figure 2.2: When one fixes the centers of the cube in space, the faces are called up, down, left, right, front and back.

2 34 13 42 17 36 4 26 19 38 8 30 10 40 23 46 3 25 6 27 9 29 12 31 21 45 24 47 15 41 18 43 20 44 16 35 5 28 7 37 132 11 39 22 48 14 33

Figure 2.3: Numbering the facets from 1 to 48 enables us to describe any state of Rubik’s cube by a permutation in S48.

2.1

Permutations, Positionings and Orientations

For clarity, we will call cubits the 26 smaller cubes composing Rubik’s cube and cubicles the placeholders where the cubits lie.

Without loss of generality, we may fix the center cubits in space and call its faces up, down, left, right, frond and back (Figure 2.2). There are then 20 moveable cubits consisting of 48 colored facets. A given configuration of the cube can hence be described by a permutation in S48.

To ease things for later, we chose to number the corner facets from 1 to 24 and the side facets from 25 to 48. The corner facets are numbered (3k − 2), (3k − 1), 3k clockwisely and the side facets are numbered (24 + 2k − 1) and (24 + 2k) (see Figure 2.3). Observe that there are two numberings in place: one for the cubit facets and one for the cubicle facets. The ith cubicle facet is a mental location in space, while the ith cubit facet is the colored tile of the cube which has the number i written on it. In the solved configuration, the two numberings match each other.

Given that context, we represent naturally a configuration c of the cube as the permu-tation in S48 which sends i to ci, where ci is the number written on the cubit facet lying

(33)

2.1. PERMUTATIONS, POSITIONINGS AND ORIENTATIONS 29 1 5 6 2 7 3 4 8 7 6 2 3 1 4 8 5 1 2 3 4 7 8 5 6 5 9 6 1 7 3 8 11 10 6 2 7 4 8 12 5 1 2 3 4 11 12 9 10

Figure 2.4: The numbering of the cubicles is coherent with the numbering of the facets: the facets 3i − 2, 3i − 1, 3i lay on the ith corner cubicle and the facets 24 + 2i − 1, 24 + 2i lay on the ith side cubicle.

line representation): U = 1 2 3 4 5 6 7 8 9 10 11 12 25 26 27 28 29 30 31 32 10 11 12 1 2 3 4 5 6 7 8 9 31 32 25 26 27 28 29 30 ! = (1, 10, 7, 4)(2, 11, 8, 5)(3, 12, 9, 6)(25, 31, 29, 27)(26, 32, 30, 28) D = 13 14 15 16 17 18 19 20 21 22 23 24 41 42 43 44 45 46 47 48 16 17 18 19 20 21 22 23 24 13 14 15 43 44 45 46 47 48 41 42 ! = (13, 16, 19, 22)(14, 17, 20, 23)(15, 18, 21, 24)(41, 43, 45, 47)(42, 44, 46, 48) L = 4 5 6 7 8 9 16 17 18 19 20 21 27 28 35 36 37 38 43 44 9 7 8 20 21 19 5 6 4 18 16 17 38 37 28 27 44 43 36 35 ! = (4, 9, 19, 18)(5, 7, 20, 16)(6, 8, 21, 17)(27, 38, 43, 36)(28, 37, 44, 35) R = 1 2 3 10 11 12 13 14 15 22 23 24 31 32 33 34 39 40 47 48 14 15 13 3 1 2 24 22 23 11 12 10 34 33 48 47 32 31 40 39 ! = (1, 14, 22, 11)(2, 15, 23, 12)(3, 13, 24, 10)(31, 34, 47, 40)(32, 33, 48, 39) F = 1 2 3 4 5 6 13 14 15 16 17 18 25 26 33 34 35 36 41 42 6 4 5 17 18 16 2 3 1 15 13 14 35 36 25 26 41 42 33 34 ! = (1, 6, 16, 15)(2, 4, 17, 13)(3, 5, 18, 14)(25, 35, 41, 33)(26, 36, 42, 44) B = 7 8 9 10 11 12 19 20 21 22 23 24 29 30 37 38 39 40 45 46 12 10 11 23 24 22 8 9 7 21 19 20 39 40 29 30 45 46 37 38 ! = (7, 12, 22, 21)(8, 10, 23, 19)(9, 11, 24, 20)(29, 39, 45, 37)(30, 40, 46, 38)

Rotating a face corresponds to apply its permutation to the current configuration of the cube. One defines G as the subgroup of S48 generated by {U, D, L, R, F, B}, the group of all configurations that can be reached using valid rotations of the cube.

Alternatively to the permutation representation, one may describe a configuration of the cube by giving the positioning and the orientation of the cubits in the cubicles.

The positioning of the cubits describes which cubit stays in which cubicle independently of its orientation. Since the facets are numbered 3k − 2, 3k − 1 and 3k for the corners, we define the ith corner cubit and cubicle as the cubit and cubicle including the number 3i. Samewise, we define the ith side cubit and cubicle as the cubit and cubicle with the number 24 + 2i (see Figure 2.4). The corner and side positionings are then permutations in S8 and S12 which send i to the cubit lying in the ith cubicle.

From the way we chose our facet numbering, the positionings of the corners and sides,

(34)

2 1 2 1 1 2 1 2 2 1 2 1 1 2 1 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 1 1 1 1 1 1 1 1 1

Figure 2.5: The visual representation of the orientation of a cubit is the following. Choose one reference tile per corner (resp. side) cubicle. In the solved configuration, number 0, 1, 2 (resp. 0, 1) the facets of each corner cubit clockwise starting from the reference facet of the cubicle. The orientation of the cubit in the ith cubicle then corresponds to the number in the reference facet of that cubicle.

cube:

πc(c) =

1 2 · · · 8 d3c/3e d6c/3e · · · d24c/3e

!

πs(c) =

1 2 · · · 12

d(26c− 24)/2e d(28c− 24)/2e · · · d(48c− 24)/2e

!

(Following Section 1.5, ic corresponds to the image of i by the permutation c.)

The orientation of a corner cubit is defined as the number of clockwise rotations (1, 2 or 3) it needs to go through to get back to its solved configuration. This definition only works when cubits lie in there initial cubicles. To generalize it, we mark one facet per corner cubit and cubicle as the reference facet of that cubit and cubicle. The definition is then extended as follows: the orientation of the cubit in a cubicle is the number of clockwise rotations it needs to go through to align its reference tile to the reference tile of the cubicle it lies in (see Figure 2.5). We chose these reference tiles as the tiles 3, 6, . . . , 24. Since the corner cubits all have been numbered clockwisely, their orientations are nicely derived from the permutation representation of a configuration: given a configuration c, the orientations of the cubits in the 8 corner cubicles are described by the vector

ρc(c) = (3cmod 3, 6cmod 3, . . . , 24cmod 3).

The orientation of a side cubit is defined in a similar way: given a reference facet per side cubit and cubicle, the orientation of the cubit lying in the ith cubit is the number of flips (0 or 1) that cubit must go through to align its reference facet with the cubicle’s one. For the side cubits and cubicles, we chose the reference facets as the facets 26, 28, . . . , 48. As for the corners, the side orientations are nicely derived from the permutation representation: given a configuration c, the orientations of the cubits in the 12 side cubicles are described by the vector

ρs(c) = (26cmod 2, 28cmod 2, . . . , 48cmod 2).

The positioning permutations and orientation vectors associated to the 6 clockwise face rotations are as follows:

(35)

2.2. THE SEMI-DIRECT PRODUCT BEHIND G 31

Given the design of Rubik’s cube, a configuration is fully described by the position-ing and orientation of its cubits. That means that there exists an inverse map from (pc, ps, rc, rs) ∈ S8× S12× Z83× Z122 to c ∈ S48: c = inv(pc, ps, rc, rs) =    1 2 3 · · · 24 3 · 1pc 3 · 1pc 3 · 1pc · · · 3 · 8pc

(−(rc)1+ 2) mod 3 (−(rc)1+ 1) mod 3 (−(rc)1) mod 3 · · · (−(rc)8) mod 3

25 26 · · · 48

2 · 1ps+ 24− 2 · 1ps+ 24− · · · 2 · 12ps+ 24−

(−(rs)1+ 1) mod 2 (−(rs)1) mod 2 · · · (−(rs)12mod 2)

  

or, in a more compact way: inv(pc, ps, rc, rs) is the permutation that sends

3i −  → 3 · ipc− (−(r

c)i+ ) mod 3 for i ∈ {1, . . . , 8} and  ∈ {0, 1, 2}

24 + 2i −  → 24 + 2 · ips − (−(r

s)i+ ) mod 2 for i ∈ {1, . . . , 12} and  ∈ {0, 1}

(2.2) Both the permutation representation and the position-orientation representation are useful. The former is useful when we want to see the result of a sequence of moves, since Magma easily multiplies permutations, while the latter shows us more easily what a configuration looks like on the cube. To ease calculations, the functions presented in this section are implemented in Magma (see Code A.1).

We define G as inv(S8, S12, Z83, Z122 ) ≤ S48, the group of all the possible configurations of the cube. There is a one-to-one mapping between elements in G and elements in S8×

S12× Z83× Z122 . As mentioned before, G is a subgroup of G.

2.2

The Semi-Direct Product Behind G

In this section we show that G has the structure of a semi-direct product.

Theorem 2.1 ([BHH+10], Theorem 1.2.23). For c, d ∈ G,

c(cd), πs(cd), ρc(cd), ρs(cd)) =πc(c) · πc(d), πs(c) · πs(d), ρc(c) + ρc(d) πc(c) , ρs(c) + ρs(d) πs(c) (2.3)

In other words: G ∼= (Z83× Z122 ) oφ(S8× S12) where φ : (S8× S12) → Aut(Z8

3 × Z122 ) is

such that φ(pc, ps) sends (rc, rs) to (rc, rs)φ(pc,ps)= (rcpc, rsps).

The proof is spread over the two following propositions. We will end this section with a more straightforward proof of the semi-product of G which, however, does not highlight the group operation in S8× S12× Z8

3× Z122 .

Proposition 2.2. πc and πs are homomorphisms: πc(cd) = πc(c) · πc(d) and πs(cd) =

πs(c) · πs(d).

Proof. For any c and d ∈ G, πc(c) is the permutation that sends i → d(3i)c/3e, πc(d)

sends j → d(3j)d/3e. Hence, π

c(cd) sends i → d(3i)cd/3e while πc(c) · πc(d) sends i →



3d(3i)c/3ed

/3

. To prove that πcis a homomorphism, one must show that the relation

d(3i)cd/3e =

3d(3i)c/3ed

(36)

is true for any i ∈ {1, . . . , 8} and any c, d in G.

Let c, d ∈ G and take any i ∈ {1, . . . , 8}. Suppose that πc(c) sends i → j and that

πc(d) sends j → k. Then, by (2.2), c must send 3i to 3j −  for an  ∈ {0, 1, 2}, and d must

send 3j −  to 3k − δ for a δ ∈ {0, 1, 2}. Then,

d(3i)cd/3e = d(3j − )d/3e = d(3k − δ)/3e = k

On the other side,

 3d(3i)c/3ed /3 = 3d(3j − )/3ed /3 = d(3j)d/3e = d(3k − δ)/3e = k.

Hence, πc is a homomorphism. The proof for πs is similar.

Proposition 2.3. For any c and d ∈ G,

ρc(cd) = ρc(c) + ρc(d)πc(c) = ρc(c) + ρc(d) ∗ πc(c)

ρs(cd) = ρs(c) + ρs(d)πs(c) = ρs(c) + ρs(d) ∗ πs(c)

where ∗ is the natural action of Sn on Zn.

Proof. ρc(c) is the vector whose ith component is (3i)cmod 3 and ρc(d) is the vector whose

jth component is (3j)dmod 3. By (2.2), (3i)c= 3 · iπc(c)− (−(ρ c(c))i mod 3) (3i)cd = (3 · iπc(c)− (−(ρ c(c))imod 3))d = 3 · (iπc(c))πc(d)− (−(ρ c(d))iπc(c)+ (−ρc(c))i mod 3) mod 3. Hence, ρc(cd)i = (3i)cdmod 3 = ρc(d)iπc(c)+ ρc(c)  i or, vectorwise, ρc(cd) = ρc(c) + ρc(d)πc(c).

The proof is similar for ρs.

We can now give another proof that G is a semi-direct product.

Proof of Theorem 2.1. Define π : G → S8× S12, g → π(g) = (πc(g), πs(g)). From

Proposi-tion 2.2, π is a homomorphism. Let K = ker π and H = inv(Id, Id, Z83, Z122 ). K and H are subgroups of G and by Proposition 1.17, K is normal. From the design of the cube, every

g ∈ G can be written as a unique product kh with k ∈ K, h ∈ H. Hence, by Theorem 1.21,

G ∼= H nφK where φ maps k to h−1kh = kh.

2.3

The Structure of G

By definition, G is a subgroup of G. In this section we prove the following result.

Theorem 2.4. [[BHH+10], Theorem 1.2.23] An element g = inv(p

c, ps, rc, rs) ∈ G belongs to G if and only if sgn(pc) = sgn(ps) X i (rc)i ≡ 0 (mod 3) X i (rs)i≡ 0 (mod 2).

(37)

2.3. THE STRUCTURE OF G 33

One direction of the proof is easy with regard of the results of the previous section: since G is a subgroup of G, (2.3) also applies for elements in G.

Proposition 2.5. If g ∈ G, then sgn(πc(g)) = sgn(πs(g)) X i ρc(g)i ≡ 0 (mod 3) X i ρs(g)i≡ 0 (mod 2).

Proof. From (2.1), one observes that for every x ∈ {U, D, L, R, F, B},

• sgn(πc(x)) = sgn(πs(x)) is odd;

• P

i(ρc(x))i ≡ 0 (mod 3);

• P

i(ρs(x))i ≡ 0 (mod 2).

Take g = x1x2· · · xk ∈ G with x1, . . . , xk∈ {U, D, L, R, F, B}.

• By Proposition 2.2, πc and πs are homomorphisms. Since sgn is a homomorphism and since πc(x) = πs(x) for x ∈ {U, D, L, R, F, B},

sgn(πc(g)) = sgn(πc(x1· · · xk)) = sgn(πc(x1) · · · πc(xk)) = sgn(πc(x1)) · · · sgn(πc(xk)) = sgn(πs(x1)) · · · sgn(πs(xk)) = sgn(πs(x1) · · · πs(xk)) = sgn(πs(x1· · · xk)) = sgn(πs(g)). • By Proposition 2.3, X i ρc(cd)i= X i h ρc(c)i+ ρc(d)iπc(c) i =X i h ρc(c)i+ ρc(d)i i X i ρs(cd)i= X i h ρs(c)i+ ρs(d)iπs(c) i =X i h ρs(c)i+ ρs(d)i i Hence, sinceP

i(ρc(x))i ≡ 0 (mod 3) and Pi(ρs(x))i ≡ 0 (mod 2) for

x ∈ {U, D, L, R, F, B}, X i ρc(g)i = X i ρc(x1· · · xk)  =X i h ρc(x1)  i+ · · · + ρc(xk)  i i ≡ 0 mod 3 X i ρs(g)i = X i ρs(x1· · · xk)= X i h ρs(x1)i+ · · · + ρs(xk)i i ≡ 0 mod 2

The other direction of the proof goes by giving an algorithm that solves the cube start-ing from any configuration g = inv(pc, ps, rc, rs) such that sgn(pc) = sgn(ps),Pi(rc)i ≡ 0

(mod 3) and P

i(rs)i ≡ 0 (mod 2). It works in four steps: 1, position the edge cubits

right; 2, position the corner cubits right; 3, orient the corner cubits right and 4, orient the edge cubits right. These four steps are spread over the next propositions.

The full algorithm requires at most 187 + 196 + 392 + 572 = 1347 moves, which is far worse than the famous God’s Number1. We did not intend to write an effective solution to the cube; we prefered a systematic method that illustrates the strategy we will adopt in Chapter 4.

1

(38)

Proposition 2.6. Given g = inv(pc, ps, rc, rs) ∈ G, there exists a permutation g1 ∈ G

expressible as a product of at most 187 moves such that gg1= inv(p0c, Id, rc0, rs0) with p0can even permutation in S8.

Proof. Consider the move M = U R3U3B3U BR (found in [BHH+10], Theorem 1.3.8). With the help of Magma, one computes M = (1, 3, 2)(4, 10, 5, 11, 6, 12)(25, 28, 26, 27)(31, 32) and πs(M ) = (1, 2). In other words, M is a 2-cycle that swaps two adjacent side cubits

(and also affects the corner cubits’ positioning and the cubits’ orientation, but we are not interested in these). By symmetry of the cube, one can modify M to get any 2-cycle among adjacent side cubits.

Among the side cubits, there are 4 different kinds of 2-cycles, and they can all be expressed by using M :

• between two adjacent cubits on the same face (e.g., the side cubits 1 and 2): M ;

• between two opposite cubits on the same face (e.g., the side cubits 1 and 9): DL2M L2D3; • between two cubits on two different layers (e.g., the side cubits 1 and 7): L3M L;

• between two diametrally opposite cubits on the cube (e.g., the side cubits 1 and 11):

D3L2M L2D.

We hence found formulas with which we can express any 2-cycle among the side cubits. All these formulas require at most 17 moves. By Proposition 1.31, ps can be expressed as a product of at most 11 2-cycles. By picking the corresponding moves of the cube in the appropriate order, one can then build a permutation g1 as a product of at most 11 × 17 = 187 moves such that πs(gg1) = Id.

Since gg1∈ G, sgn(πc(gg1)) = sgn(πs(gg1)) = sgn(Id) is even.

Proposition 2.7. Given g = inv(pc, Id, rc, rs) ∈ G, there exists a permutation g2 ∈ G

expressible as a product of at most 196 moves such that gg2= inv(Id, Id, r0c, r0s).

Proof. The idea behind this proof is similar to the previous proof, but this time we are

looking for moves in G that act as 3-cycles on the corner cubits while leaving the side cubits where they are.

Consider M = F3R3F L3F3RF L = [RF, L] (found in the Maneuver Index of [Ban82]).

With Magma, one computes that

M = (1, 4, 9)(2, 5, 7)(3, 6, 8) πc(M ) = (1, 2, 3) πs(M ) = Id .

Among the corner cubits, there are 3 types of 3-cycles and they can be derived from M (or one of its equivalents):

• a 3-cycle of 3 corners on a common face (e.g., the permutation (1, 2, 3)): M ;

• a 3-cycle spread on two adjacent faces (e.g., the permutation (1, 2, 7)): BM B3;

• a 3-cycle spread on 3 opposite corners (e.g., the permutation (1, 6, 3)): R3F3RM R3F R.

All these permutations have no effect on the positionning of the side cubits.

References

Related documents

Facebook, business model, SNS, relationship, firm, data, monetization, revenue stream, SNS, social media, consumer, perception, behavior, response, business, ethics, ethical,

Det valda ämnet och det resultat som framkom blir av relevans för sjuksköterskan då hon någon gång i sin yrkesutövning kommer att vårda personer med blodsmitta, exempelvis

IT- Sophistication Infrastructure IT- Barriers Benefits Costs External pressures Support IS/IT environment Organisational structure Actors Organisational processes

Kjeldsen menar att det finns någon som han kallar för inledande ethos medans Lindqvist-Grinde säger att det inte exciterar någon retorisk term för hur vi uppfattar en person innan

The new level of ambition endeavours to strengthen the EU as a security provider both in terms of soft and hard power. This part of the analysis points to

Foucault talar om att kunskap inte kommer till mänskligheten i ren form utan att den alltid är förmedlad eftersom det i samhället finns en utbredd vilja att uppnå sanning

Det som är viktigt är dels en tydlig närvaro av lärare eller andra vuxna inom skolan, ytor där lärare och barn kan umgås tillsammans utanför lektionstid, samt placering av

Models previously proposed to describe how the light field is sampled by differ- ent image capturing systems range from, simple ray-based geometrical models to complete wave