Curvature of the Mind

Thoughts from a Recreational Physicist

Nothing fancy: Winter bubbles

My inspiration board on pinterest has been filling up, so I wanted to take a few hours to whip up something quick. I really liked the simplicity of winter trees. I didn’t want to do a direct copy, so this is my riff on the composition.

winter bubbles

Winter Bubbles

Related Images:

Rough and Random page

I’ve had this sitting on my computer for a while and thought I’d publish it rather then just leave it sitting there. This simulates a pulse of light expanding out like my compression wave examples. This time however, we are looking at a pulse of light expanding in the vicinity of a black hole. Rather than expanding out in a circular wave pulse, it wraps around the hole and circles back to the original location traveling around the hole forever.

I’m still trying to wrap my head around what this implies. Most General Relativity texts cover light cones tipping over at various distances from the black hole, and particular light paths including distances where light orbits the hole. The code is pretty rough and ugly right now, but is a fun little application of solving differential equations in javascript.

black-hole-light

Related Images:

Something I’m playing around with.

This is something that I just stumbled onto while working on something else. I’ve taken a quick break from the atomic orbital viewer. I’m trying to make the IFS fractals more visually interesting. One approach is to create Mandelbrot versions of the IFS fractals which should break up the uniformity. Instead of showing one image that is an exact copy of parts of itself, each part of it would be locally similar to a different fractal. The images I’ve been creating up until this point have all been analogs of Julia sets. I’m hoping the Mandelbrot versions will turn out more interesting. It also opens up the potential of higher dimension renderings as Mandelbrot sets exist in parameter space, not the actual fractal space.

Voronoi and a trip far afield

In order to do that, I need to estimate the “basin of attraction” for each mapping in the fractal. A voronoi diagram is one way to do that. I started out just generating standard simple diagrams as a test. Sometimes images are just the best way to see what is going on. Using a very simple algorithm, I just iterated through a list of random points and colored pixels based on the closest one. That meant I kept track of the minimum distance and the matching index. Which lead to renders of that distance, followed by the sine of the distance.

Now that I’m looking at alternate renderings, I figured the easiest way to find the borders of domains was to track the second closest point as well and whenever the distances between first and second point were equal you were on a boundary. That looked ok, but lead to some artifacts.

Now that I was collecting this info, I figured I’d try to do something else with it, so I applied it to the alpha channel and switched over to the taxicab metric just for fun.

Related Images:

I’m thinking about how best to handle this

I like the idea of putting demos up directly on the blog like the last one. However, they don’t show up on feed readers so you either get the text without the image and then click through. I can throw down some javascript to include a place holder link to the demo in the feed, or do excerpts, which I really don’t like, or go back to the old format of talking about something and linking to it at the end, which I don’t really like either.

Does anyone have any ideas or suggestions on how they handle this issue?

Related Images:

The best surprises come from unexpected places

This page requires a modern browser like chrome
This time I'm back with some more physics visualizations with a flat 2d canvas. I'm skipping over some demos of basic physics to get at some orbital mechanics animations that I found surprising. I've derived and calculated solutions for two objects gravitationally bound to each other from my freshman physics classes back in college. Then I did it again with more sophisticated mathematics, and again when I did quantum mechanics of the atom. As I think about it, I was writing BASIC programs back in high school to simulate the 3 body problem. All of those equations and simulations had some pretty severe limits. For one they only involved one or two bodies in motion. What you are looking at here are roughly 185 test particles orbiting one massive object like planets in circular orbits around the sun. While each of these test particles start close to each other, their mutual interactions are ignored. If they weren't there would be much more complicated dynamics going on. What caught me off guard was how fast the inner bodies were moving in relation to the outer planets. Whenever I had pictured the slow ponderous motion of the planets, I had pictured them moving more or less like a uniform disk. Whoa, was I wrong. The inner bodies are just whipping around at a frenetic pace, while the outer ones just plod along at a snail's pace. In fact there is a rather conspicuous divergence in the speed of motion as the distance between the particles decreases. I plan to have something more to say about that in the future. You might be wondering why I picked 185 test bodies? In this case it comes from looking at orbits in the range of 5 to 375. Which corresponds to Mercury (.4AU) to Neptune (30AU) a ratio of 1 to 75. If our solar system was build from evenly spaced bodies in circular orbits, this is what it would look like. So when I set this up, I never expected the slow graceful curve of the spiral slowly winding around the center. As I play with it, it seems so obvious, but that's why I find this stuff so fascinating. I've calculated and simulated these same orbits for well over 20 years now, and they can still surprise and awe me with just the slightest change of perspective.

Related Images:

Just a quick update

I’ve uploaded my very very super rough fractal canvas image editor. This is what I’ve been putting the galleries together with. It’s super rough, I’ll be improving it in random fits and spurts, and putting some demo posts up as well. Also, someone please please suggest a decent title for this one. I’ve got nothing.

Fractal Draw?

Related Images:

I’m just playing around with particles for this one

This has come together more quickly than any of the other demos. I wanted to see what I could do with a more abstract particle system driven through the same equations I’ve been using for fractals. The old formulas didn’t have quite enough pizazz, so I moved over to the sylvester library for matrices and bumped it up to 3d, which gave me the twisting, darting and zooming I was looking for.

Bubbles 3d

Related Images:

The most basic IFS Fractal of all – the cantor set

cantor set

The cantor set is the simplest IFS fractal out there

What is that, Morse code? That my friends is the cantor set. It is one of the examples of basic topology and one of the objects that highlight many of the non-intuitive aspects of infinities.

The most common construction is to take a line and remove the middle third. Next you remove the middle thirds of the two remaining segments. You keep removing the middles of every segment that is left. If you could continue for ever, you would be left with an infinite “dust” of disconnected points.

We can build one with two simple transforms. Just contract by 2/3rds at two different points and the attractor is a cantor set. The next images are going to be simple tweaks of the cantor set, and the fractal space will grow from there.

Related Images:

Speed of sound

I’ve finally written some code that works in IE8.0, chrome and firefox. Rather than drawing complex fractals and solutions to equally archane differential equations, I’m trying to build some simple demos using more easily understood principles and mathematics.

Now this is a very simple model that just shows the general principles of how something like a shockwave can build up from basic building blocks. Before I go into too much description, give it a spin and see if you can figure out what is going on. Try sliding the speed back to zero, then to one and up past one, racing supersonic!

This page requires a modern browser like chrome
Mach:0.5

I first encoutered the mathematics for this little demo in a beautiful Russian book of mathematics aimed at high school students. It demoed families of curves from physical problems and then used basic calculus to find interesting related curves. It was a trancendent text and it introduced me to the theory of evelopes

Here is what’s going on. Imagine a little super bee sitting on a flower just beating his wings. The sound waves radiate in circles at the speed of sound around him. That’s what you see when you slide the speed down to zero. The waves expand concentricly and uniformly in space.

Now our bee is done colecting polen and starts heading back to the hive at a leisurly pace. At each moment the sound waves still expand in a circle around him, but now that he is moving he’s not at the same place when he emits the next one. Now things are no longer uniform. The waves of pressure are bunching up ahead of him, and spreading out behind.

Now his bee sense starts tingling and he kicks is in gear to get to a disturbance at the hive. He approaches the speed of sound. Now things get interesting as he hits the speed of sound. He still emits sound the same way, but now by the time the next wave is released, he’s caught up with it, and the same with the one right after, and so on. All these waves keep piling up building a huge wave of pressure right on top of him. In this model with non-interacting waves and constant velocity, the pressure wave is infinite. The wave still exists in more realistic models, but things like changes in air pressure, temperature and density put a limit on how much pressure actually builds up.

Just a little more speed, push it, push it, and he’s through. Once he’s moving faster than sound, the waves can’t even catch up, and expand out in a cone behind him perfect to sneak up on wrong doers, as noone can hear him outside of the cone training behind him, and by then it’s too late. POW!

In reality, this just shows where the simple model breaks down. There are many more effects that kick in and become important long before these speeds are reached, however I love how this simple model using nothing more than addition and multiplication can explain some of the features of supersonic travel.

Related Images:

Closer to a good stopping point

I’ve finally got the chrome crashing bug and crazy memory usage fixed, so I’ve taken a little bit of time while my 3 week old daughter is sleeping here and there to add some refinements. I’ve added basic shading back in, added a link to the blog and a couple of bookmarking links. I’m going to go take a nap now, so check it out:

fractal getdown

I’ve also submitted this version to canvas demos, it would be nice if it was picked up there since I haven’t heard anything after submitting an earlier version to chrome experiments.

Related Images:

« Previous Page
Next Page »