rapidcube

1from .rapidcube import *
2
3__doc__ = rapidcube.__doc__
4if hasattr(rapidcube, "__all__"):
5    __all__ = rapidcube.__all__
class Cube2x2:

A compact 2x2 Rubik's Cube model with fast move operations.

def to_binary(self, /):

Return the corner and edge states as a tuple of 64-bit binary strings.

def get_corners(self, /):

Return the corner state as an array.

def is_solved(self, /):

Return true if the cube is solved.

def do_u_move(self, /):

Apply the U move (clockwise top face turn).

def do_u_prime_move(self, /):

Apply the U' move (counterclockwise top face turn).

def do_d_move(self, /):

Apply the D move (clockwise bottom face turn).

def do_d_prime_move(self, /):

Apply the D' move (counterclockwise bottom face turn).

def do_r_move(self, /):

Apply the R move (clockwise right face turn).

def do_r_prime_move(self, /):

Apply the R' move (counterclockwise right face turn).

def do_l_move(self, /):

Apply the L move (clockwise left face turn).

def do_l_prime_move(self, /):

Apply the L' move (counterclockwise left face turn).

def do_f_move(self, /):

Apply the F move (clockwise front face turn).

def do_f_prime_move(self, /):

Apply the F' move (counterclockwise front face turn).

def do_b_move(self, /):

Apply the B move (clockwise back face turn).

def do_b_prime_move(self, /):

Apply the B' move (counterclockwise back face turn).

def do_moves(self, /, moves):

Apply a whitespace-separated sequence of cube moves.

state
class Cube3x3:
def to_binary_corners(self, /):

Return the corner state as a 64-bit binary string.

def to_binary_edges(self, /):

Return the edge state as a 64-bit binary string.

def to_binary(self, /):

Return the corner and edge states as a tuple of 64-bit binary strings.

def get_corners(self, /):

Return the corner state as an array.

def get_edges(self, /):

Return the edge state as an array.

def is_solved(self, /):

Return true if the cube is solved.

def do_u_move(self, /):

Apply the U move (clockwise top face turn).

def do_u_prime_move(self, /):

Apply the U' move (counterclockwise top face turn).

def do_d_move(self, /):

Apply the D move (clockwise bottom face turn).

def do_d_prime_move(self, /):

Apply the D' move (counterclockwise bottom face turn).

def do_r_move(self, /):

Apply the R move (clockwise right face turn).

def do_r_prime_move(self, /):

Apply the R' move (counterclockwise right face turn).

def do_l_move(self, /):

Apply the L move (clockwise left face turn).

def do_l_prime_move(self, /):

Apply the L' move (counterclockwise left face turn).

def do_f_move(self, /):

Apply the F move (clockwise front face turn).

def do_f_prime_move(self, /):

Apply the F' move (counterclockwise front face turn).

def do_b_move(self, /):

Apply the B move (clockwise back face turn).

def do_b_prime_move(self, /):

Apply the B' move (counterclockwise back face turn).

def do_moves(self, /, moves):

Apply a whitespace-separated sequence of cube moves.

corners