contents
§3

State vector: (cp, co, ep, eo)

A 3×3×3 cube has 8 corners and 12 edges. Centres are fixed (they define the colour scheme). The full state is captured by four arrays:

positions of the 8 corners (permutation)
orientation of each corner (twist)
positions of the 12 edges
orientation of each edge (flip)

These are the standard coordinates Kociemba chose in the 1990s for his two-phase solver [7]. All of cube algebra is built on this 4-tuple: each generator is a fixed "permute cp + add offsets to co/ep/eo" combination.

3.1 Unfolded layout & cubie indexing

The 3×3×3 unfolded: 54 stickers but only 26 cubies (8 corners × 3 stickers each, 12 edges × 2, 6 centres × 1). Centres are immobile, so the state needs only describe the 8 + 12 = 20 movable cubies.

U
L
F
R
B
D

The cubie indexing used throughout (following Kociemba):

corners:   0:URF   1:UFL   2:ULB   3:UBR   4:DFR   5:DLF   6:DBL   7:DRBedges:   0:UR 1:UF 2:UL 3:UB 4:DR 5:DF 6:DL 7:DB 8:FR 9:FL 10:BL 11:BR

3.2 Orientation convention

Each corner at a fixed position has 3 possible orientations (its "U/D-coloured sticker" can face one of three axes). Each edge has 2 orientations ("good" or "flipped" relative to the F/B-axis convention). So:

The exact definition depends on convention. Here we use Kociemba's: corner orientation tracked by the U/D sticker; edge orientation by the F/B sticker. Singmaster and others use slightly different bases — the algebraic structure is unchanged.

3.3 Tensor representation of generators

Each face turn corresponds to a (permutation, orientation offset) pair. For example, R:

4-cycle on corners
corner twist deltas
4-cycle on edges
R does not affect EO (since R is on the RL-axis)

Similarly: F flips the EO of 4 edges (UF, DF, FR, FL each +1 mod 2). U/D turns change neither CO nor EO — only positions. This clear axis-specific structure makes both state compression and solver search highly efficient:

Compare: naively storing colours for all 54 stickers takes 162 bits ≈ 21 bytes, with no compression. The structured encoding halves memory and intrinsically excludes illegal states.

Interactive § State tensor

A cube state is the 4-tuple (cp, co, ep, eo). Type any alg, watch the four arrays mutate.

cp ∈ S₈ — corner permutation
04
11
23
32
40
55
66
77
co ∈ (ℤ/3)⁸ — corner twist
02
10
20
32
42
50
60
70
ep ∈ S₁₂ — edge permutation
08
11
22
30
44
55
66
77
83
99
1010
1111
eo ∈ (ℤ/2)¹² — edge flip
00
10
20
30
40
50
60
70
80
90
100
110
corner cycle type
2-cycle × 2-cycle
edge cycle type
3-cycle

3.4 Counting degrees of freedom

Treat cp / co / ep / eo as four independent coordinates. Their raw cardinalities:

CoordCodomainSize
8! = 40,320
3⁸ = 6,561
12! = 479,001,600
2¹² = 4,096
product (free space F)
cube group G

So "position + orientation" carries bits of information, but G only sits in of those. The missing bits are precisely the three invariants of §5 (ℤ/3 × ℤ/2 × ℤ/2).

3.5 ℓ₁ and ℓ∞ distances to the origin

Embed state vectors into (20 position indices + 8 mod-3 + 12 mod-2) and ask "distance to origin." Two natural norms:

Crucial: these norms are not equivalent to the HTM metric (§2.2). They are weak lower bounds on d_S(e, g), used as heuristics by §22's solvers. The true d_S(e, g) is the Cayley-graph distance — no closed form; computed only by Korf IDA* or Kociemba two-phase.

cuberoot.me · Rubik's Cube as a Group · 2026