%% example-rot2.tex %% January 20, 2014 %% RWD Nickalls & A Syropoulos %% example file for rubikrotation package %% Requires TikZ and rubikcube, and rubikrotation packages %% uses Perl script rubikrotation.pl %% experiment by un-commenting different RubikRotation commands, %% and reviewing the .log file for details of rotations performed. %%----------------------------------------------------- %% USAGE: pdflatex --shell-escape example-rot2.tex %% ---------------------------------------------------- \documentclass[a4paper]{article} \usepackage{tikz,rubikcube,rubikrotation} \pagestyle{myheadings} \markright{\textsc{rubikrotation} package; \hspace{2cm}file = example-rot2.tex} %%-------------- %% some well known sequences (see the web page of Reid) \newcommand{\sixT}{*sixT,F2,R2,U2,Fp,B,D2,L2,F,B} \newcommand{\cubeincube}{*cubeincube,F,L,F,Up,R,U,F2,L2,Up,Lp,B,Dp,Bp,L2,U} \newcommand{\sixspot}{*sixspot,U,Dp,R,Lp,F,Bp,U,Dp} \newcommand{\errors}{*errors,U,Dp,RR,Lpp,Fq,Bp,U,Dp,cat} %================ \begin{document} \RubikCubeSolved % sets up a solved cube %---------------- %\RubikRotation{R,FFF} %%this will show up the command FFF as being an error %\RubikRotation{U,D,L,R,F,B} %% some basic rotations in sequence %\RubikRotation{U2,D2,L2,R2,F2,B2} %% makes an interesting pattern %\RubikRotation{\sixT} %% generates a T on each face %\RubikRotation{\cubeincube} %% generates a cube-in-cube effect %\RubikRotation{random,67} %% makes 67 random rotations \RubikRotation{x,y,\sixspot} %% shows a sixspot effect %\RubikRotation{\errors} %% sixspot with errors (errors will be shown if using \ShowRobotErrors) \begin{tikzpicture} \DrawRubikCubeFlat %% shows cube as half cube half flat %\DrawRubikFlat %% shows cube as a flat representation \end{tikzpicture} %%-------------- \ShowRubikErrors %% will show error file underneath the image \end{document}