Question 33
Let $n$ be a positive integer. By a lattice point in the $xyz$-space we mean a point $(k, l, m)$ where $k, l, m$ are integers. A line segment connecting two lattice points contained in the region $0 \le x, y, z \le n$ and distance 1 between them is called a lattice segment. We can assign a direction to each lattice segment (e.g., for a lattice segment with end points $A$ and $B$ assign one and only one of the directions $A \rightarrow B$, or $A \leftarrow B$). Call a square a lattice square if all of the four sides of the square are lattice segments. Let us say that two lattice squares are congruent if by rotation and a parallel displacement one can place one of the squares on top of the other square with further requirement that the directions of all four sides coincide. How many ways of assigning directions to lattice segments are there assuring that all the lattice squares are congruent?