Sunday, October 19, 2008

Soap Bubbles

I've been playing around with POV-Ray in the background quite a bit since my first post about it. I spent a lot of evening hours hanging out with Sarah in front of the tv working on a soap bubble effect (I had no idea this would turn into the diversion it did), and I wanted to share my best effort on it so far :)


It took some obsessiveness to get this far. Sarah was helpful, and after a number of iterations I'm sure she tired of being shown sets of two ever-so-slightly-different pictures to choose the best one. Luckily she humors me.

I want to share a little more about this picture because I wasn't thinking about rendering soap bubbles at all when starting it. That really was just a diversion. I am interested in projections from 4D to 3D of the hypersphere (the four dimensional mathematical analogue of a familiar sphere) because I am trying to understand that object better. Just like a sphere in 3D, this is the set of points that is a fixed distance from a center point, only in a higher space. (I feel the need to give some background - an ordinary sphere is a surface of dimension 2 that lives in 3 dimensions.  A hypersphere is a 3 dimensional object, and mathematicians call these the 2-sphere and 3-sphere, respectively - the names can lead to confusion because in an everyday sense most think of a sphere as a 3D object rather than a 2D one.  Spheres don't even have to be embedded in a higher dimensional space, but that is a digression here.)

I'm going to continue to blab a bit, but stay with me (or just skim this paragraph) because the most interesting part I want to share is at the end of this post...  We can't stereographically project every point of the hypersphere from 4D down to 3D (the resulting set of points would cover all of 3D space plus one more point at infinity, and hence the full projection doesn't help my unfailing need to see pictures of things to understand them). So we try to do the best we can by looking at discrete subsets of points (and lines, and surfaces) of the hypersphere. The picture above is one such subset, a regular tiling of the hypersphere called an 8-cell, and is more commonly known as the hypercube. This is one way of representing the hypercube anyway, which involves first stretching the edges of the 4D cube outwards so they lie on the hypersphere (causing them to be curved), then stereographically projecting that from 4D to 3D. I'll (hopefully) explain more about stereographic projection when I share a short animation I've been working on in POV-Ray (if you're too excited to hold your breath for that, check out dimensions-math.org for some excellent and free downloadable videos. I recommend those regardless!!).  Some more cool properties about the picture above... All the edges are "great circles" of the hypersphere, and all the bubble surfaces are "great spheres" of the hypersphere. Stereographic projection preserves circles and spheres, meaning a shape that is a circle in 4-space before the projection is still a circle after the projection. How cool is that? (Before you go on an extrapolation binge like I always do, know that the centers of the circles and spheres are not preserved during projection though, i.e. the center of a projected circle is not the projection of the center of the corresponding unprojected circle.  Peter piper picked a peck of pickled peppers.)

No worries if the above didn't make too much sense, but let me share something really astonishing about all this. Amazingly, you can make the shape of a hypercube like this picture in our real 3D universe with real bubbles because of the way bubbles try to minimize their surface area! Here is a youtube video showing a bubble performer make a "square bubble". But taking the above into consideration, the performance is really is much more spectacular than a square bubble. Using only bubbles, he's effectively projected a 4D object (a regular polychoron) for us to see and admire! This is truly magical and a nice example of the unreasonable effectiveness of mathematics in describing our physical universe.

We can theoretically "project" more complicated tilings of the hypersphere using bubbles as well. Though I don't imagine a bubble magician could pull this one off, here is a computer rendering of the 120-cell in bubbles.

Couple all this with Sarah discovering it is tons of fun to blow bubbles off our balcony, and there are smiles all around :)

(btw, sorry for all the parentheses (I can't seem to help myself (it's what I do)))

5 comments:

  1. is the Polychoron the intersection of 4 spheres?
    mario
    mariodegrossi@gmail.com

    ReplyDelete
  2. I see what you're getting at, though a polychoron isn't accurately described as such. It seems fair to make a statement like this about the volume enclosed by this particular projection of this particular 4D object (though it would be the intersection of six spheres rather than four - this would be easier to see if I had an animation rotating the picture around). But the 8-cell lives in 4 dimensions, and is built up of 8 non-intersecting portions of the hypersphere. These 8 "cells" touch each other at boundaries that are portions of 2D spheres. There are 24 of these spherical boundaries, and they are the soap films rendered in the picture, though many of them look flat instead of spherical due to the projection. Other polychora will have different properties than the 8-cell.

    ReplyDelete
  3. What software tool do you use to design those bubbles?

    ReplyDelete
    Replies
    1. I did it all directly in POV-Ray, which allows scripting. https://www.povray.org/

      Delete
    2. In case, I fail at learning this POV-Ray tool enough to produce those merging bubbles, I seek permission to use your image in a book I'm finishing writing on various topics of science.

      Delete