Introduction to the rubik package
Calling Sequence:
function(args)
rubik:-function(args)
Description:
-
To use a rubik function, either define
that function alone using the command with(rubik, function), or define
all rubik functions using the command with(rubik). Alternatively, invoke
the function using the long form rubik:-function. This long form notation
is necessary whenever there is a conflict between a package function name
and another function used in the same session.
-
The functions available are:
-
The functions jl, mb, mx, px, rc2,
rc3, rc4, rc5 and sb simulate the movements of the jewel, the masterball,
the megaminx, the pyraminx, the Rubik's 2x2 cube, the Rubik's 3x3 cube,
the Rubik's 4x4 cube, the Rubik's 5x5 cube or the skewb, respectively.
-
For more information on a particular
function see rubik:-function.
Examples:
> restart;
> with(rubik);
Change 3 corners of Rubik's 2x2
cube:
> X:=[1/R,1/D,R,1/D,1/F,D,F,1/D,F,D^2,1/F,U,F,1/(D^2),1/F,D,1/F,1/D,F,D,1/R,D,R,1/U]:
> rc2(X,A2);
Turn the front faceof the Rubik's
2x2 cube to the top:
> Y:=[R,1/L]:
> rc2(Y,A2);