Last edited 7dec2011 by Adam Rosenbaum
Find this document at http://new.math.uiuc.edu/math198/rosenbm2/public_html/index.html

# The Hypercube

## Abstract

A hypercube is an n-dimensional cube. It is constructed of groups of parallel line segments of equal length, orthogonal to those in all other dimensions. A four dimensional hypercube uses the dimensions x, y, z, and w. A hypercube can be constructed in a similar way to constructing a three dimensional cube, by moving a second object of one lower dimension into the next dimension orthogonally and then connecting the corresponding vertices using lines of the correct length.
.

In 1966 Michael Noll created the first computer model of a hypercube. Then, in 1978, Thomas Banchoff created a custom computer graphics system to allow real time interactive computer animation of a hypercube. He also created the film "The Hypercube: Projections and Slicing" which gave a more complete viewing of an animated hypercube.

In order to view a hypercube, it must be projected onto three dimensions. To do this, you can simply divide the x, y, and z coordinates by the value of w. This makes objects that would be farther away in the w direction appear to be smaller in 3-dimensional space, according to the rules of linear perspective. In order to rotate the object in four dimensions, you can rotate about the plane that includes the w axis and either the x, y, or z axis. To do this you swap the values of the two axis in a cyclical fashion, allowing all parts of the object to be shown.

## Documentation

I created a four dimensional hypercube using PyOpenGL. When you run the program, the hypercube displays largely so that it can be easily seen. When you begin to rotate the hypercube in four dimensions, it immediately shrinks to allow the size to change with the rotations. To rotate about the *xw* plane, you use the "a" and "z" keys. To rotate about the *yw* plane, you use the "s" and "x" keys. To rotate about the *zw* plane, you use the "d" and "c" keys. To return the hypercube to it's original position, use the "r" key. The color of the lines progresses from blue to red in the order of the Euler's path used to create it.
.