TITLE: The rotation of dice on a grid
QUESTION [11 upvotes]: Imagine you have a plane, flat surface with a square grid drawn on it. You have a standard cubic die  which is placed flat on the surface. Its length is the same as the length of side of each grid square. The only way to move the die to an adjacent square is by tipping the die into the square. So obviously the die cannot move diagonally.
Since this grid is infinitely large, there are infinite round trips that can be made with the die. Some of these round-trips can cause a rotation of the die. The set of all round trips can be categorized into equivalence sets, where each class represents a particular rotation following a round-trip. These rotations naturally constitute a group.
Can anyone list out all possible rotations in this configuration? Also, when moving the die around, I noticed that it was impossible for a round-trip to produce a 90 degree rotation about the the axis perpendicular to the surface. Can anyone give me a simple proof of this? It seems to be an easy proof, but I am unable to show it.
Also, if we generalize this to a n-sided die, what are the impossible rotations? If anyone could provide a related paper or reference as well, I would really appreciate it.

REPLY [6 votes]: Here's a slick method: label the die with the usual numbers of pips (so 1 is opposite 6, 2 is opposite 5, and 3 is opposite 4) and label the grid like a chessboard. Then place the die on a black square with the die angled in an isometric view (think Q*bert) with the numbers 1,4,5 visible (for instance).
Now, what happens if you make a 90 rotation around an edge? Two of the faces remain visible, but the face which is hidden is replaced with its opposite face. The important point to note: opposite faces have opposite parity (odd/even), so the resulting sum of visible faces now also has opposite parity!

(In the above image, note that the 4(even) is replaced with a 3(odd), changing the sum of the visible faces from 10(even) to 9(odd).)
Thus, no matter how you manipulate the die, it will always have an even sum of visible faces when positioned on the black squares, and it will always have an odd sum of visible faces when positioned on the white squares. Of course, if the die began instead with an odd sum of visible faces on a black square or an even sum of visible faces on a white square, then it will always have an odd sum of visible faces when positioned on the black squares and an even sum of visible faces when positioned on the white squares.
That is sufficient to answer your question. It's not hard to show further that there exist round trips to rotate a die into any configuration of the same parity.
(As an aside, this is a useful trick to solving a puzzle from Zero Escape: Virtue's Last Reward.) [1] [2]