Two right angles and the diagonal of a box
Worth reading first: Two squares, four triangles, and no algebra · The dot product is a shadow.
A box twelve units long, four deep and three high has a diagonal of exactly thirteen. Not approximately thirteen: thirteen, because .
That number arrives by using the theorem twice, and the second use is the interesting one, because its right angle is not an edge of the box. It is between a line drawn across the floor and a line going up, and those two were never fastened together by the construction. Something has to justify it.
The argument, in two steps
The floor is a rectangle twelve by four. Its diagonal is a hypotenuse in the ordinary sense: two edges meet at a corner at a right angle, and the theorem gives .
Now stand that diagonal up. The second triangle has the floor diagonal as its base, the vertical edge of height three as its other leg, and the box diagonal as its hypotenuse. Its legs are and , so the hypotenuse is
The square root and the square undo each other in the middle of that line, which is why the three-dimensional formula has no roots inside it. Applying the theorem times leaves one root and squares, and the intermediate diagonals never appear.
The right angle nobody built
The step worth examining is the claim that the vertical edge meets the floor diagonal at a right angle.
The box was built with three edges meeting squarely at each corner, so the vertical edge is perpendicular to the two floor edges. The diagonal is neither of those. It is a line drawn across the floor at an angle to both, and no part of the construction says anything about it.
What rescues the step is a small theorem about perpendicularity that gets used constantly and stated rarely: a line perpendicular to two intersecting lines in a plane is perpendicular to every line in that plane. The two floor edges span the floor; every direction in the floor is a combination of them; and perpendicularity survives that combination, because the dot product of the vertical with any combination is the same combination of two dot products, both of which are zero.
That is the dot product doing the work it exists for, and it is why the three-dimensional theorem is really a theorem about orthogonality rather than about boxes. The box is scaffolding.
Not three, but any number
Once the pattern is visible, nothing stops it. Four perpendicular directions give
and the argument is the same: find the diagonal of the three-dimensional face, then stand it up against the fourth edge.
That last remark is worth stopping on. A unit square holds a segment of length ; a unit cube holds one of ; the four-dimensional unit box holds one of length exactly , and the hundred-dimensional one holds a segment ten times longer than any side of the box containing it. Nothing has gone wrong. The box has more corners to be far apart in.
A second consequence of the same arithmetic is worth stating because it is so often met without being noticed. Adding a coordinate can only increase a distance, never decrease it, since a square is never negative — so shadows are always shorter than the objects casting them, and a projection of a set of points can bring two of them together but never push them apart. Every dimension-reduction method in use rests on that one-line fact, and every one of them accordingly distorts in the same direction.
Somewhere in that sequence the character of the statement changes. In two and three dimensions the formula is a theorem: right angles and lengths already have meanings, and the equation is a discovered fact relating them. In seventeen dimensions there is no prior notion of length to discover a fact about, so the formula is taken as the definition of distance, and the theorem becomes a convention that agrees with the theorem where both apply.
That is the moment the anchor of this ladder stops being about triangles. Choosing a formula for distance is choosing a geometry, and the sum of squares is one choice among many — the one whose unit ball is round, and the only one in which the theorem above is true.
The same theorem about areas
There is a second way to move the statement up a dimension, and it is not the same as the first. Instead of asking about the length of a diagonal, ask about the area of a face.
Cut a corner off a box with a single slanting plane. The piece that comes away has four triangular faces: three right triangles meeting at the corner, and one slanted face opposite it.
This is de Gua’s theorem, published in 1783 by Jean Paul de Gua de Malves and known to Descartes a century earlier. It is the Pythagorean theorem with lengths replaced by areas and a right angle replaced by a right corner — three faces meeting the way three walls meet in the corner of a room.
The reason it is a different statement from the box diagonal is that it does not reduce to the two-step argument. There is no intermediate face to stand up; the three squares are added at once. And unlike the length version, it is genuinely about the corner: a tetrahedron whose three faces at a vertex are not mutually perpendicular satisfies no such relation.
The generalisation to higher dimensions is the one a reader would guess, and for once the guess is right: for a simplex with a right corner in dimensions, the square of the -dimensional content of the face opposite the corner is the sum of the squares of the contents of the other faces. Every one of these is the same statement about a normal vector, decomposed into perpendicular components — which is the sum of squares again, one level up.
Where the sum of squares stops behaving
High dimensions are where this ladder’s rung earns the theme it is tagged with, because the small cases are actively misleading.
Take a cube of side four, and pack a unit sphere into each of its corner cells. Then drop a sphere into the middle, as large as will fit between them. Its centre is at the origin and each corner sphere’s centre is at distance — that is the theorem, applied to the point — so the inner sphere has radius .
In two dimensions that is : a small circle wedged between four big ones, exactly as the picture shows and exactly as intuition expects. In three dimensions it is . At nine dimensions it is , which is the half-width of the cube itself, so the inner sphere touches the faces from the inside. At ten dimensions and beyond, the sphere trapped between the corner spheres pokes out through the walls of the box that contains them.
Nothing is wrong with the arithmetic and nothing is wrong with the picture. What is wrong is the transfer of an intuition about between from two dimensions to ten. The corner spheres do not surround the middle in high dimensions; there are of them and they cluster near the corners, leaving the middle far more open than a two-dimensional imagination allows.
This is the same phenomenon that makes almost all of a high-dimensional distribution’s mass sit far from its mode and makes nearest-neighbour searching lose its meaning past a few dozen dimensions. In each case the mechanism is the sum of squares: adding many independent squared coordinates concentrates a distance around , and typical stops resembling central.
What it costs
The formula assumes perpendicular axes, and that assumption is doing more work than it looks.
Coordinates are a choice. Nothing forces the three edges of the box to be at right angles to each other, and plenty of natural coordinate systems are skew: crystal axes, oblique map grids, two measurements that are correlated. In skew coordinates the diagonal is not the root of the sum of squares — it is the root of a quadratic form with cross terms, , and the record the angles between the axes.
The sum of squares is the special case where all the cross terms vanish, which happens exactly when the axes are mutually perpendicular. So the clean formula is not a fact about space; it is a fact about a description of space, and the description was chosen to make it true. A change of basis rearranges the same information into a form where a different thing is obvious, and the rectangular basis is the one that makes distance obvious.
The builder’s version of the same problem is a good test of whether the assumption holds. A rectangular room can be checked by measuring its two floor diagonals, which agree exactly when the corners are square. A box cannot be checked that way: a parallelepiped can have all four space diagonals equal and still be skew, so equal diagonals verify a rectangle in the plane and verify nothing in three dimensions. The check has to be done face by face, which is three plane checks rather than one solid one.
The cost of that convenience is that the theorem cannot be used until orthogonality has been established, and establishing it is often the hard part. In a room with walls out of square, the box formula gives the wrong diagonal, and the error is second order in the skew — small enough to be invisible and large enough to matter.
Who noticed, and when
The three-dimensional case is old and anonymous: it is implicit in any calculation of a diagonal brace, and no one is credited with it because there is nothing to credit.
De Gua’s theorem has a more interesting record. De Gua published it in 1783; Descartes had it in an unpublished manuscript around 1620; Johann Faulhaber stated a version in 1622; and the same result was found again, independently, by Charles Tinseau in 1774. Four independent discoveries over a hundred and sixty years is a fair sign of a result that is easy to reach and easy to forget, which is exactly what a theorem with no application tends to be.
The extension past three dimensions is much later and did not come from geometry. Arthur Cayley wrote about -dimensional analytic geometry in 1843, and Hermann Grassmann’s Ausdehnungslehre of 1844 built the whole apparatus of linear combinations in any number of dimensions — and was so badly written that it was ignored for twenty years. What settled the matter was Riemann’s habilitation lecture of 1854, which proposed that a space carries a rule for measuring lengths locally, that the rule may vary from place to place, and that the sum of squares is merely the simplest such rule. Sixty years later that lecture was the mathematics general relativity needed, which is the standard advertisement for it, and the more useful point is the smaller one: after Riemann, distance is a structure a space is given rather than a property it has.
What the picture cannot show
Every figure here is a drawing of three dimensions on a flat page, which means every right angle in the box is drawn as an angle that is not right. The projection distorts each one, and the reader is asked to accept the corner as square on the strength of the caption. That is the ordinary bargain of an axonometric drawing and it is worth noticing rather than assuming, because the argument’s whole content is which angles are right.
The fourth dimension is worse: there is no drawing at all. The claim that a unit four-dimensional box has a diagonal of exactly is arithmetic with no picture behind it, and the figures showing the unit cube are analogies, not evidence. What the corner-sphere figure draws is the two-dimensional case, which is precisely the case that misleads; the surprising part of it is a curve, not a shape.
A curve is a weaker kind of picture, and admitting that is part of the argument. There is no honest illustration of a sphere leaving a box in ten dimensions. There is only , drawn against , crossing a line.
The ladder from here
Below this rung: the rearrangement proof, Euclid’s shearing argument, the whole-number solutions and the converse, which is the version that builds things. Above it: what happens when the space is curved, where the sum of squares survives only in the infinitesimal and the theorem becomes a statement about a metric tensor rather than about a box.
Sideways from here, the sum of squares is the quantity a circle’s rational points are about, the reason error-correcting codes measure distance in a cube of bits, and the object least squares minimises — each of them the same expression asked a different question.
Distance was never found lying around
The lasting point is the transition that happens between the third dimension and the seventeenth.
In the plane, the sum of squares is a theorem: length exists first, right angles exist first, and the equation is a discovery about the relationship. In seventeen dimensions the equation comes first and length is whatever it says. Nothing was discovered; something was decided, and the decision was made to agree with the theorem in the cases where a theorem was available.
That move — extending a proved relation into territory where it can only be a definition, and choosing it precisely because it agrees with the proof below — is one of the most common in the subject. It is how exponentiation is extended past the whole numbers, how the factorial is extended to the gamma function, and how the notion of size is extended to infinite sets. In each case the extension is not forced, and in each case the choice made is the one that keeps a picture true.
What links here
Computed from the collection, not written here: the essays that point at this one.
Reads more easily once this is understood
Essays that name this one as worth reading first.
Named objects
A dashed tag is an object no other essay names yet.
De gua theoremDimensionDistanceHypercubeOrthogonalityPythagorean theoremRight angle