Flat Space of the Torus

Flat Earth!

To describe how space could be flat, finite, and yet unbounded, science writers sometimes use an analogy involving the surface of a torus (the mathematical abstraction of the doughnut shape). Such a surface has no boundary — no edge.  And despite being embedded in three-dimensional space, the torus surface, if seen in terms of compensating surface metric, is indeed flat.

Yet a natural issue people have is that the three-dimensional embedding is clearly curved, not flat. It’s easy to see how wrapping a flat 2D sheet into a cylinder doesn’t distort it, but hard to see why wrapping a cylinder around a torus doesn’t stretch the outside and compress the inside.

In fact it does, but there are ways to eat our cake (doughnut).

I’ll get to that, but let’s start with the torus itself.

A torus is a basic geometric shape defined by only two parameters: a major radius, R, and a minor radius, r. The former is the radius of the doughnut, the latter is the radius of the curved tube that comprises the doughnut body.

Figure 1. Torus major radius, R, and minor radius, r.

The ratio R/r is the aspect ratio (AR) of the torus. The larger that ratio, the skinnier the torus body. For a regular torus, AR>1 (Wiki says an actual doughnut has an AR of about 2 or 3). When AR<=1 the hole in the torus closes.

Create a torus by sweeping a perpendicular circle of the minor radius along a circle of the major radius.

Figure 2. Sweeping the the minor circle along the major circle.

Given this construction, coordinates on the torus surface have two angular values, one for each circle:

Firstly, there is the angle, θ (theta), from 0° to 360°, around the major circle. This angle points to a particular minor circle (like the “spokes” in Figure 2 do). This direction along the sweep of the torus is termed toroidal.

Secondly, given any minor circle, there is an angle, φ (phi), again from 0° to 360°, around that circle. The direction around a minor circle is termed poloidal (this will make more sense when we ask if torus world has any “poles”).

These two angles provide a coordinate system for the two-dimensional surface of the torus (note that a torus is a surface, not a solid object).

Figure 3. Torus coordinate system. Red lines indicate 90° intervals, black lines indicate 10° intervals. Green dot is origin. The AR of this torus is 5.

Note the green marker in Figure 3. It denotes the origin point of the coordinate system. Both θ and φ are equal to zero at that point. This is an arbitrary choice; it could be any point. Equally arbitrarily, rather than angles of 0° to 360°, let’s use the azimuth-elevation system of -180° to +180° (and never actually use -180° because +180° is the same angle).

Finally we’ll say that, as viewed in Figure 3, going “up” the minor circle from the green dot is the plus φ direction, and going “down” is the minus φ direction. This poloidal direction maps to elevation (so the inner ring is +180° from the green dot on the outer ring). Counterclockwise around the torus is the plus θ direction, and clockwise is the minus θ direction. The toroidal direction maps to azimuth.

This mapping give us torus coordinates analogous to the latitude and longitude coordinates of a sphere. For instance, a sphere like the Earth:

Figure 4. A fat (AR=2) Torus Earth! Same grid system as above.
[4000×3000 version]

Earth’s longitude and the torus azimuth angle, θ, are close parallels. Both are the angle around the body. Our latitude and the torus elevation angle, φ, are reasonable enough parallels especially if we imagine Torus Earth heated from the side making the “equator” warm and the inner “pole” — because blocked from that heat — cold.

Note that the coordinate system in Figure 3 maps onto Torus Earth’s. The green dot is at the location 0°0’0″ × 0°0’0″, the fat red poloidal line is the prime meridian, and the fat red toroidal line around the outside is the equator.

One difference in this mapping is that the north and south poles are connected. On the other hand there is no polar singularity where the longitude coordinates degenerate to a single pole point. On Torus Earth the pole is an inner equator.

Another difference is that, starting at the green dot and going “north,” one arrives at the “north pole” after traveling 180° — not 90° as one would on Sphere Earth.

A consequence is that the red line running along the top of Torus Earth (and the matching one running along the bottom) has a latitude of +90° (and -90°), whereas on Sphere Earth that same latitude is +45° (and -45°).

BTW: That Toroid Earth’s “pole” is located at the specific poloidal angle of 180° (but at all toroidal angles) is the connection I mentioned above. On both Earths, the pole(s) is as far away from the equator as possible.

§ §

Torus Earth is fun (or maybe I’m easily amused), and I will return to it, but the point here is flat space and how a torus can be an analogy for it.

Figure 5. 2D flat space, cylinder, and torus, all with a 20×10 grid.

Depicting a torus as flat usually starts with a flat sheet of graph paper that rolls into a cylinder by joining two of its opposing edges. Then the other two edges, now the mouths of the cylinder, join to form the torus.

While it’s obvious that the cylinder has a flat surface (no distortion of the grid), it’s equally obvious the torus does not preserve the spacing of the grid. The lines of longitude are compressed together on the inside and stretched apart on the outside.

We can quantify the distortion. The torus equator (the outside ring) has the largest circumference, and the torus pole (the inside ring) has the smallest circumference. We can easily calculate their sizes (remember that R and r are the major and minor radii):

\displaystyle{C}_{eqtr}={2}\pi({R}+{r})\\[0.4 em]{C}_{pole}={2}\pi({R}-{r})

All other circles of latitude have a circumference between those extremes. The punchline of this piece is that we can require a spacetime metric for the torus surface that counteracts this distortion.

[The main reason this sat in my Drafts folder for so long is that I hoped to learn enough about metric tensors to actually present and explore that metric. Sadly, thus far, tensors, let alone metric tensors, are beyond my grasp (but I’ll keep reaching).]

The circles of longitude are not distorted, so movement in the poloidal direction needs no special treatment. It’s only when we move in the toroidal direction that we need a warped metric.

§

Figure 6. Torus from above.

Figure 6 is an orthographic projection of a torus viewed from above.

The outer red circle is the equator (R+r); the inner red circle is the pole (Rr).

The middle red circle, with radius R, is the central “core” that runs through the torus. It’s also the top and bottom circles of latitude, the ones at ±90° (which map to Sphere Earth’s ±45° circles of latitude).

Because those ±90° circles of latitude have the same radius as the torus core, these are the only latitude circles that are not distorted. Moving towards the equator the toroidal direction is stretched; moving towards the pole it’s compressed.

Now we have three data points: stretching of the equator circle; compression of the pole circle; no change to the ±90° circles. Obviously we’re looking for a factor that runs from positive to zero to negative, and we know the min (Rr) and max  (R+r) values it has to take. We just need to figure out how it changes.

We’re in the world of circles, so it’s almost certainly not linear. A little thought and trigonometry tells us that cos(φ) gives us what we need.

Figure 7. r×cos(φ)

Remember that φ (phi) maps to the latitude, and that the cosine of an angle is how much X-ness is has (the sine is how much Y-ness it has).

Figure 7 illustrates this. The yellow line, which has length r, is a vector representing φ (it happens to be pointing to +130°) . The green line is the cosine projection down to the X-axis.

The cosine of +130° is -0.64 (note the negative sign), so we multiply that by r, and that gives us a negative value to add to R to determine the radius of the latitude circle for +130°.

So our distortion factor is simply:

\displaystyle{DF}=\frac{{R}+(r\times\cos(\phi))}{R}

One way to make the torus seem flat to the Flatlanders who live in its surface is to impose a spacetime metric that’s the opposite of that distortion factor.

§ §

But it’s not the only way. It’s just a way that allows a (relatively) normal torus to live in normal 3D space and yet have a truly flat metric (as if it was the original flat grid).

Another way — the way many video games work — is to leave the space literally flat and declare a higher-space dimensional warping that joins the opposite sides. Move off an edge; magically appear at the opposing edge.

Such a space obviously is flat, finite, and yet unbounded. Magical edge-joining isn’t satisfying as theories go, but it works fine in video games. It does serve as a simple illustration of a space that is flat, finite, and unbounded.

Another way is to declare the torus isn’t embedded in normal space, but in an alternate space that allows it to keep the flat metric of the cylinder. There are embeddings that accomplish this, and there is a special version of the torus, the Clifford torus, that is flat (but which requires four-dimensional space).

However alternative spaces and Clifford geometry are not the intuitive droids we’re seeking for a simple metaphor for flat, finite, and unbounded.

§

We can minimize — but not eliminate — the distortion by assuming an extremely large aspect ratio:

Figure 8. A large AR minimizes latitude distortion.

Then the difference between R+r and Rr is much smaller, and the distortion is much less.

A torus with a major radius of 93 million miles (the distance from the Sun to the Earth) and a minor radius of 4000 miles (the radius of the Earth), would give us a tube world a bit akin to Larry Niven’s Ringworld. Its AR is a whopping 23,250 (so its expansion on the equator is just 1.000043)!

Even so, a putative Flatland civilization would eventually notice that and wonder why.

§

Figure 9. “Parallel” lines of longitude converge and meet on a sphere.

Spheres, of course, are finite and unbounded, but obviously not flat because parallel lines always converge. (In hyperbolic spaces, they diverge!)

Despite the distortion, part of what makes a torus flat (or at least flat-ish) is that parallel lines don’t converge or diverge, they remain parallel. That’s a key characteristic of flat space.

Look again at Figure 3 or Figure 4. The latitude circles are clearly parallel with each other. They’re essentially just nested circles (and in Figure 6).

The longitude circles by definition are parallel even though in 3D space the distance between them changes (the angular distance does not). But they never meet, and that’s critical to parallel lines.

[Another characteristic of flat space is that the corners of triangles sum to 180° — and that I’m not sure about (maybe?). I think I need to understand tensors and curvature to know. (Always another hill to climb.) I also don’t know how the putative distortion compensation metric might affect that.]

§

Lastly there is a paper about corrugating the surface of a torus to give it flat metric even though it’s embedded in normal 3D space.

The paper quickly goes over my head mathematically (the pictures are interesting). The question is whether Flatlanders living on the surface of the torus — and utterly ignorant of 3D space — would think their space was flat. We face the same question in our space (we’re mostly sure it’s flat; we have no real idea about finite or bounded).

Figure 10. Torus Earth distortion factor for a torus with AR=3.

The compensating metric I have in mind for an otherwise normal torus in normal 3D space would compress and expand spacetime and therefore it affects the speed of light on the surface. Distances, as measured by light, always indicate flat space. Flatlanders would have no way of knowing the 3D distances are different.

Viewed from the 3D outside, light goes slower on the inside of the torus and faster on the outside.

(It’s magic, but a small magic. The point is finding a way to make the torus analogy work as a reasonable analogy.)

§ §

This post sat in my Drafts folder for years, and I’m tired of giving it free room and board. There’s more to explore on Torus Earth, especially If I learn about metric tensors, parallel transport, and curvature. I’d like to be able to calculate specific paths along the surface to see what effect the compensating metric has.

No doubt you’ll be waiting for that in taut torrid toroidal tension. 😉

Stay toroidal, my friends! Go forth and spread beauty and light.

About Wyrd Smythe

The canonical fool on the hill watching the sunset and the rotation of the planet and thinking what he imagines are large thoughts. View all posts by Wyrd Smythe

39 responses to “Flat Space of the Torus

  • Wyrd Smythe

    FWIW, this article in Vice is what prompted me to kick this post out into the world:

    The Universe Is a Giant Donut That We Live Inside, New Research Suggests

    I meant to link to it in the post. Better late than never!

    • Wyrd Smythe

      Or here’s a link to the paper the Vice article is about:

      The variance of the CMB temperature gradient: a new signature of a multiply connected Universe

      Submitted just this last June.

    • Wyrd Smythe

      In the Vice article, Thomas Buchert, one of the paper’s authors is quoted on an answer to the question of whether a long enough (warp drive) journey would return to the starting position:

      “If you would complete the loop and come back, Earth might no longer exist.”

      I recently read Tau Zero (1970), by Poul Anderson, which is about a spaceship with a drive that can sustain 1G (or better) indefinitely. They lose the ability to stop and their speed gets closer and closer to c. Because of Special Relativity, they end up many billions of years in the future and circle the universe as it collapses in the “big crunch” and is reborn. (This was before we discovered dark energy and realized the universe will never collapse.) They ride the wave of the new Big Bang and figure by the time they can slow down the new universe will have evolved to a nice age.

      So they return to where they started, but the whole universe they knew isn’t there anymore.

    • Wyrd Smythe

      Lee Smolin mentions that the universe could be closed in his book Time Reborn.

      We can avoid the implications of the tragedy of an infinite universe by denying that the universe is infinite in space. Whereas, of course, we can’t see past a certain distance, it seems plausible and sensible to me to hypothesize that the universe is finite in spatial extent — as in Einstein’s proposal that it is finite but unbounded. This means that the universe has an overall topology of a closed surface, like a sphere or a doughnut (that is, a torus).

      Later he writes:

      If the average curvature of space is flat, like a plane, then there is also one choice for a finite universe, which is the three-dimensional analogue of a doughnut’s two-dimensional topology.

      The other possibilities are that, if curvature is positive, then only the three-dimensional analogue of the sphere is the geometry; and if the curvature is negative, then there are infinite possible “saddle-shapes” for its geometry.

      We think the curvature of our universe is flat. Unfortunately, a difference below the error value, a difference we can’t distinguish from measurement error, would be enough to tip the balance into either of the curved models.

    • Wyrd Smythe

      I totally forgot to post a link to this video:

  • Wyrd Smythe

    Some math-y bits:

    The torus surface is defined at the set of points that satisfy f(x,y,z)=0 where:

    f(x,y,z)=\left(\sqrt{x^2+y^2}-R\right)^2+z^2-r^2=0

    This is similar to how the surface of a sphere is defined by the set of point satisfying:

    f(x,y,z)={x^2}+{y^2}+{z^2}=1

    Given some angular location [θ, φ] on the torus, the 3D coordinates are:

    {x}={R}\cos(\theta)+{r}\cos(\theta)\cos(\phi)\\[0.4 em]{y}={R}\sin(\theta)+{r}\sin(\theta)\cos(\phi)\\[0.4 em]{z}={r}\sin(\phi)

    Going the other way is a tricky concept because not all 3D points are on the torus surface. In fact, the vast fraction of them are not. Those that happen to be on the surface satisfy the f(x,y,z) function above, all the others don’t.

    [It is possible to project from any 3D point in space to the closest point on the torus. That just requires first getting the θ angle via the arctangent of the x and y values. That angle picks out the closest minor circle on the torus to the 3D point. Then it’s just a matter of projecting from the center of that circle to the point. Where that line passes through the minor circle is the closest point on the torus to that 3D point.]

    Now if I could only figure out how to do geodesics and parallel transport on a torus…

  • Sai Sundar S

    Very interesting ! When I read this soon came in to my mind ; The magnetic field inside a solenoid and a toroid is the same!! So the flat surface can be changed in to a solenoidal form and then in to a toroid without changing the property or with small distortion

  • Catxman

    I’d like to do some mathematics posts for my blog (which is otherwise about girls, how to shag them, and the fall of the American empire).

    Can you tell me how you made the symbols for your equations?

    Also, where did you learn about the torus?

  • Sai Sundar S

    some thing went wrong !!
    I made a mathematics post then also it went wrong

  • Wyrd Smythe

    Whoa, I never noticed this before:

    The area and circumference of a circle are:

    \displaystyle{A}=\pi{r}^{2}\\[0.4 em]{C}={2}\pi{r}

    And the volume and surface area of a sphere are:

    \displaystyle{V}=\frac{4}{3}\pi{r}^{3}\\[0.4 em]{SA}={4}\pi{r}^{2}

    Maybe this is common knowledge among mathematicians (it must be), but the circle’s circumference is the derivative of its area. Going the other way, the area is the integral of the circumference. Which does make sense — the integral is the area under a curve.

    The same thing is true for spheres. The sphere’s surface area is the derivative of its volume. Or the volume is the integral of the surface area. Again, the area under the curve.

    It’s actually rather obvious, but it’s one of many rather obvious things I’ve never noticed before. (The fun part is discovering stuff like this for oneself rather than being told.)

    The trend is exact in the circle and sphere, but proportional in other shapes. For instance the area and perimeter of a square is:

    \displaystyle{A}={s}^2\\[0.4 em]{P}={2}\times{2}{s}

    And the volume and surface area of a cube is:

    \displaystyle{V}={s}^3\\[0.4 em]{SA}={2}\times{3}{s}^{2}

    In both cases I wrote the derivative to illustrate how it’s off by just a factor of two.

    One more, here’s a cylinder:

    \displaystyle{V}=\pi{r}^{2}{h}\\[0.4 em]{SA}={2}\pi{r}{h}+{2}\pi{r}^{2}={2}\pi{r}({h}+{r})

    The first term is the exact derivative, but the second term is extra, so it’s not so neat in all cases, but it’s an interesting thing to check out and look into.

    • Wyrd Smythe

      Yeah, a brief search shows it’s well-known. Seems to apply mainly to circles and spheres, although it applies to squares and cubes if the length unit is s/2 rather than s. That makes it analogous to radius, which is d/2.

      It works, apparently, because of the symmetry of these shapes. Asymmetrical shapes have a more complex relationship between surface area and volume.

      What an interesting new fact I learned today!

    • Wyrd Smythe

      It works for the torus, too, if R is taken as a constant:

      \displaystyle{V}=({2}\pi{R})(\pi{r}^{2})={2}\pi^{2}{R}{r}^{2}\\[0.5 em]{SA}=({2}\pi{R})({2}\pi{r})={4}\pi^{2}{R}{r}

      The surface area is the derivative of the volume. I assume it works here because the torus is so closely related to the sphere. Symmetry around the origin seems important, although the ellipsoid doesn’t seem to work this way.

      The formulae are:

      \displaystyle{V}=\frac{4}{3}\pi{a}{b}{c}\\[0.5 em]{SA}={4}\pi\left[\frac{(ab)^{\frac{5}{3}}+(ac)^{\frac{5}{3}}+(bc)^{\frac{5}{3}}}{3}\right]^{\frac{3}{5}}

      And maybe there is something of a derivative relationship (some is apparent), but I haven’t seen a strong match here. I suppose the ellipticity might be a factor — the wrong kind of symmetry maybe? (The a, b, and c, are the radii of the ellipsoid.)

  • Wyrd Smythe

    Heh. Largely ignored when it was first published (only 19 hits that first month), I see this post has been getting attention lately. Just had its best month, in fact, with 33 hits.

    Is it the picture of Torus Earth? I bet it’s the picture of Torus Earth.

  • 2022: I Hardly Knew Ya | Logos con carne

    […] Flat Space of the Torus (2021, 161) […]

  • The Blogging Dozen | Logos con carne

    […] surprise recently is the Flat Space of the Torus post — the second-most viewed post so far in 2023 (first most-viewed, as always, is the From the […]

  • The Dozen Year Charts | Logos con carne

    […] Flat Space of the Torus (762): This post attracted almost no attention when first published, but this year it really took off (and the year isn’t over yet). I suspect people just like the big image of Torus Earth, but — as always, and yes, it bugs me — I have no idea what the draw actually is. Oddly, perhaps, I wrote it to try to explain something to someone who persisted in thinking I didn’t know what I was talking about. For all the good it did (hint: none). […]

  • theinfinitewedge

    Hi there! Nice article and really great image of Torus Earth. Can you tell me how you generated it? I’m working on a project that would benefit from an image like this. Thank you!

    Peter

    • Wyrd Smythe

      Hello. Thanks! I used a 3D ray-tracing freeware, called POV-Ray. A torus is a basic shape in POV-Ray, so it’s simple to create the torus itself. Torus Earth comes from wrapping a cylindrical projection map around the torus.

      POV-Ray is fairly primitive and can do this with ease, so I’d guess that any modern 3D modeling package would also have the capability. Just wrap the cylindrical project map image around a torus, and you can make any Torus World you like. (Torus Jupiter would be interesting.)

      • theinfinitewedge

        Thanks so much for getting back to me! That was just the information I was looking for!!

      • theinfinitewedge

        Hi, Wyrd, so far I’ve had good luck using POV-Ray to render a torus with a map on its surface. Next I’d like to render toroidal coordinates as you did in your image. Did you use POV-Ray for that? Abstractly, I know how to parameterize the curves – I just don’t know if it’s possible to do this in POV-Ray. Can you share how you did it? Thanks so much, Peter

      • Wyrd Smythe

        Yep, all done in POV-Ray. the lines of longitude and latitude are just very thin torii set onto the surface of the main torus. Figure 3 in the post shows the network of torii comprising them. The poloidal lines (longitude) are just torii that are rotated and translated using POV-Ray rotate and translate, no trig required. The toroidal lines (latitude) require a bit of trig (sin and cos) to calculate the height and main radius.

  • 2023: All the Charts | Logos con carne

    […] One surprise is my most-viewed post in 2023, Flat Space of the Torus: […]

And what do you think?