Orbit64.V2.State
Ranking of Orbit64 V2 cube states: the digit layout of FORMAT-V2.md.
A state is a Cube of orbit coordinates in the slot convention of V1.
Its rank is the mixed-radix combination of one digit per component. Parity
coupled components are not stored: they are recomputed on decoding.
Type Aliases
type alias Cube = { centers = Vector[Vector[Int32]], cornerPieces = Vector[Int32], cornerTwists = Vector[Int32], frame = Int32, midgeFlips = Vector[Int32], midgePieces = Vector[Int32], rotations = Vector[Int32], wings = Vector[Vector[Int32]] }§ SourceOrbit coordinates of one cube. Components a type lacks are left empty.
The caller normalizes the pose first: fixed centers of odd cubes are
implicitly home and frame carries the whole-cube orientation, which
must be 0 unless the type is odd and framed.
rotations holds r_U r_R r_F r_D r_L r_B and frame a frame rank.
Definitions
The (row, column) names of the center orbits, ordered by lowest facelet.
The rank of a valid state of the type, or the reason it is invalid.
The state with the given rank. value must be in [0, count(n, model, pose));
this is not checked here, Orbit64.V2.Codec.decode does.