We hear the word “dimension” all the time: “3D graphics”, “the fourth dimension”, the “parallel dimensions” of science fiction. A mathematician means something very simple by it, and that simple meaning holds up in any number of dimensions — four or a thousand.
How many numbers it takes to say where
Picture a bead on a taut thread. To say where it is, one number is enough: its distance from the end of the thread. The thread is one-dimensional. An ant on a sheet of paper already needs two numbers: how far to the right and how far up. The sheet is two-dimensional. A fly in a room needs three: right, forward, up. The room is three-dimensional.
That is the whole definition: the dimension is the number of independent numbers (coordinates) needed to pin down a point. “Independent” means that none of them can be computed from the others. If the ant crawls along a circle, it still has two coordinates $x$ and $y$, but they are tied together by the equation $x^2 + y^2 = 1$, and one number — an angle — is enough. A circle drawn on a plane is still one-dimensional.
Physicists say the same thing in other words: the dimension is the number of degrees of freedom, the number of independent directions you can move in. The bead can only slide back and forth, the ant can also go sideways, the fly can also go up. A four-dimensional space is a place where every point has four coordinates $(x, y, z, w)$ and there is a fourth direction perpendicular to all three of ours.
“Perpendicular to all three” sounds like nonsense: there is no such direction in our room. For algebra, though, it is no problem at all. Two vectors are perpendicular when their dot product vanishes, $a_1b_1 + a_2b_2 + a_3b_3 + a_4b_4 = 0$, and the vector $(0, 0, 0, 1)$ is perpendicular to each of $(1,0,0,0)$, $(0,1,0,0)$ and $(0,0,1,0)$. The formulas do not know that we cannot picture it. This whole guide is about getting around the limits of our imagination by leaning on formulas and analogies.
Distance: Pythagoras in any number of dimensions
Coordinates alone are not yet geometry: we also need to measure distances. In the plane the Pythagorean theorem does it: the distance between $(x_1, y_1)$ and $(x_2, y_2)$ is $\sqrt{(x_2-x_1)^2 + (y_2-y_1)^2}$. In space a third term joins in. After that the pattern never breaks.
In $n$-dimensional Euclidean space the distance between $a = (a_1, \dots, a_n)$ and $b = (b_1, \dots, b_n)$ is $$|ab| = \sqrt{(b_1-a_1)^2 + (b_2-a_2)^2 + \dots + (b_n-a_n)^2}.$$
Induction on $n$. For $n = 1$ it is just $|b_1 - a_1|$. Suppose the formula holds in dimension $n - 1$. Take the point $c = (b_1, \dots, b_{n-1}, a_n)$: all its coordinates are those of $b$ except the last, which is that of $a$. The points $a$ and $c$ lie in the “horizontal” hyperplane $x_n = a_n$, so by the induction hypothesis $|ac|^2 = \sum_{i
The first consequence is amusing. The long diagonal of the unit $n$-cube, from $(0, \dots, 0)$ to $(1, \dots, 1)$, is $\sqrt{n}$. For a square that is $\sqrt2 \approx 1.41$, for a cube $\sqrt3 \approx 1.73$, and for a tesseract exactly $\sqrt4 = 2$: the diagonal is twice as long as an edge. A hundred-dimensional cube has a diagonal ten times its edge, and in the chapter on many dimensions we will see truly strange effects grow out of that.
The second consequence is the definition of a sphere. A sphere is the set of points at the same distance from a centre, so the unit sphere in four dimensions is given by $$x^2 + y^2 + z^2 + w^2 = 1.$$ This is the 3-sphere $S^3$: the vertices of every polytope on the showcase live on it, and it has a chapter of its own.
Science does not fully know why our space has three dimensions, but there is a lovely argument that living in any other would be hard. In 1917 Paul Ehrenfest noticed that in $n$ dimensions gravity falls off as $1/r^{n-1}$ (the flux of the field through a sphere of radius $r$ is constant, while the sphere's area grows as $r^{n-1}$). For $n = 3$ this is the familiar inverse-square law, and planetary orbits are stable. For $n \ge 4$ there are no stable circular orbits: the slightest nudge and a planet either falls into its star or flies away. The same goes for an electron in an atom. So four-dimensional geometry can be studied as much as you like, but a four-dimensional universe with the same physics would be an uncomfortable place to live.
A ladder from a point to a tesseract
The most tangible way to climb into the fourth dimension is to build a ladder where each rung is obtained from the one before by the same operation.
- 0D — a point. It has no length, width or height. One vertex.
- 1D — a segment. Take the point, make a copy and slide it in a new direction. Join the point to its copy. Two vertices, one edge.
- 2D — a square. Take the segment, copy it, slide the copy in a direction perpendicular to it and join the matching ends. Four vertices, four edges.
- 3D — a cube. A square, its copy slid “upward”, and four new edges between them. Eight vertices, twelve edges, six faces.
- 4D — a tesseract. A cube, its copy slid in the fourth direction, and eight new edges. Sixteen vertices, thirty-two edges, twenty-four square faces and eight cubic cells.
Every step is the same: copy, slide perpendicular to everything so far, connect. We do not need to “see” the fourth direction to carry out this instruction — it is enough to give each vertex one more coordinate. In the widget below the edges are coloured by the direction they run in: each dimension has its own colour.
Press 4D and watch the copy of the cube “slide out” in the fourth direction. On the screen it ends up inside the original cube — which does not mean the tesseract is built like a “cube within a cube”. That is just how its perspective shadow looks: the copy that is farther away in the fourth dimension appears smaller. Shadows are the subject of the chapter on projections.
Counting vertices, edges and faces
The ladder is good for counting as well as drawing. The vertices double at every step: the $n$-dimensional cube has $2^n$ of them. The edges are a little trickier: the copy has as many edges as the original, plus one new edge for every vertex. That gives the recurrence $$E_n = 2E_{n-1} + 2^{n-1},$$ and from it $E_1 = 1$, $E_2 = 4$, $E_3 = 12$, $E_4 = 32$, $E_5 = 80$.
We can count faces of every dimension at once. It helps to think of the $n$-dimensional cube as the set of points $[0,1]^n$: every point has $n$ coordinates, and each of them lies between 0 and 1.
The $n$-dimensional cube has exactly $\displaystyle f_k = 2^{\,n-k}\binom{n}{k}$ faces of dimension $k$.
A $k$-dimensional face is the set of points of the cube in which $k$ coordinates vary freely from 0 to 1 while the other $n-k$ are fixed at the boundary: each equals 0 or 1. The $k$ free coordinates can be chosen in $\binom{n}{k}$ ways. Each of the remaining $n-k$ coordinates has two boundary values, 0 and 1, for $2^{n-k}$ options in all. Multiply. ∎
Let us check it on the cube ($n = 3$): $2^3 \cdot 1 = 8$ vertices, $2^2 \cdot 3 = 12$ edges, $2 \cdot 3 = 6$ faces. It all adds up. For the tesseract:
| $n$ | shape | vertices | edges | 2-faces | 3-faces | 4-faces |
|---|---|---|---|---|---|---|
| 0 | point | 1 | ||||
| 1 | segment | 2 | 1 | |||
| 2 | square | 4 | 4 | 1 | ||
| 3 | cube | 8 | 12 | 6 | 1 | |
| 4 | tesseract | 16 | 32 | 24 | 8 | 1 |
| 5 | penteract | 32 | 80 | 80 | 40 | 10 |
A beautiful law hides in this table. Take the alternating sum — vertices minus edges plus faces minus cells and so on, counting the cube itself as its only $n$-dimensional “face”: $$\sum_{k=0}^{n} (-1)^k\, 2^{\,n-k}\binom{n}{k} = (2-1)^n = 1.$$ This is simply the binomial theorem for $(2 + (-1))^n$. Drop the cube itself from the sum and you are left with its surface; for the ordinary cube that gives the famous $V - E + F = 8 - 12 + 6 = 2$, Euler’s formula for polyhedra. For the tesseract, $V - E + F - C = 16 - 32 + 24 - 8 = 0$. The boundary of a convex polytope gives 2 in even dimensions and 0 in odd ones. This is the Euler characteristic, and we will meet it again in the chapter on the regular polytopes.
Beyond four: how to draw a ten-dimensional cube
The ladder does not stop at the tesseract. The five-dimensional cube (it is called a penteract) is two tesseracts joined by 16 edges. The six-dimensional one is two penteracts. The ten-dimensional cube has 1024 vertices and 5120 edges. Drawing it “in perspective”, like the tesseract, no longer works: every step down in dimension squeezes the picture, and everything melts into a mess.
Geometers came up with another way: project the cube onto one special plane, the Coxeter plane (also called the Petrie plane). Give each of the $n$ axes a unit vector in the plane, turned by the angle $\pi i / n$, and send the vertex $(v_1, \dots, v_n)$ to the point $$P(v) = \sum_{i=1}^{n} v_i \,\Bigl(\cos\frac{\pi i}{n},\; \sin\frac{\pi i}{n}\Bigr).$$ With this choice the symmetry of the cube shows in full: the outline becomes a regular $2n$-gon, and inside it a pattern appears that looks like a rosette or a woven fabric.
An edge of the $n$-cube is always parallel to one of the axes: its two vertices differ in exactly one coordinate. So in the picture the edges run in only $n$ directions, and the widget gives each direction its own colour. Move the tilt slider: the projection plane starts to “breathe”, and you can see how much is hidden in this flat shadow.
To work with a many-dimensional shape you do not need to picture it. It is enough to know the rule it is built by (copy, slide, connect) and to be able to count. A picture is always a shadow, and a shadow can be cast in different ways.
Other kinds of “dimension”
The number of coordinates is the most intuitive definition, but not the only one. Mathematicians use several, and in familiar cases they all give the same answer.
- The dimension of a vector space is the number of vectors in a basis, that is, in a set through which every vector can be expressed in exactly one way. The polynomials of degree at most three have the basis $1, x, x^2, x^3$ — a four-dimensional space, even though there is nothing “spatial” about it.
- The dimension of a manifold is how many coordinates you need locally. The surface of the Earth as a whole is a sphere, but any small patch of it looks like a piece of the plane: the sphere is a two-dimensional manifold. The three-dimensional sphere, the heroine of the chapter on the hypersphere, is a three-dimensional manifold living in four-dimensional space.
- Topological dimension is defined through coverings: how thickly you are forced to overlap small pieces when you cover a shape. For a curve the overlaps can be made double, for a surface triple, for a solid quadruple.
And there is a dimension that can be fractional. Take the ladder again, but look at it from another side: scale a segment up by 2 and it is made of 2 copies of the original. A square is made of $4 = 2^2$ copies, a cube of $8 = 2^3$. The exponent is the dimension: $$N = s^{D} \quad\Longrightarrow\quad D = \frac{\log N}{\log s},$$ where $s$ is the scale factor and $N$ is the number of copies. Now take the Sierpiński triangle: scale it up by 2 and it is made of three copies of itself. So its dimension is $D = \log 3 / \log 2 \approx 1.585$ — more than a line, less than a plane. The Koch curve gives $\log 4 / \log 3 \approx 1.262$. This is the similarity dimension, a special case of the Hausdorff dimension. If you want to see such fractals alive, have a look at Patterns: fractals have their own layers there.
The quaternion Julia set in the showcase is a fractal in four dimensions. We see its three-dimensional slices, and its boundary, like that of every true fractal, has a fractional dimension.
Summary
- The dimension is the number of independent coordinates needed to pin down a point — or, equivalently, the number of independent directions of motion.
- Four-dimensional space consists of points $(x, y, z, w)$. The fourth direction is perpendicular to all three of ours in the algebraic sense: the dot product is zero.
- Distance in $n$ dimensions is the same Pythagorean theorem with $n$ terms; the diagonal of the unit $n$-cube is $\sqrt{n}$, exactly 2 for the tesseract.
- A cube of any dimension is built by one operation: copy, slide, connect. The $n$-cube has $2^{n-k}\binom{n}{k}$ faces of dimension $k$.
- The alternating sum of the face counts — the Euler characteristic — takes one line to compute for a cube of any dimension, thanks to the binomial theorem.
- There are other dimensions too, fractional ones among them: the Sierpiński triangle’s is about 1.585.
Next comes Flatland: how reasoning by analogy with two-dimensional creatures tells us what we would see if a four-dimensional body passed through our world.
Sources
- H. S. M. Coxeter. Regular Polytopes. 3rd ed. New York: Dover, 1973 — face counts of the $n$-cube and other counting formulas.
- P. Ehrenfest. In what way does it become manifest in the fundamental laws of physics that space has three dimensions? Proceedings of the KNAW 20 (1918), 200–209.
- M. Tegmark. On the dimensionality of spacetime. Classical and Quantum Gravity 14 (1997), L69–L75.
- B. Mandelbrot. The Fractal Geometry of Nature. W. H. Freeman, 1982.
- K. Falconer. Fractal Geometry: Mathematical Foundations and Applications. Wiley, 3rd ed. 2014 — similarity and Hausdorff dimension.