Posted on Tuesday 18 October 2005
I was just studying for tomorrow’s partial differential equations exam, and I tried to memorize (because it’s very hard to derive) the solution to the 1-dimensional heat equation:
With initial condition , u finite when x tends to infinity. Now the solution is given by:
Basically this corresponds physically (approximately) to the behaviour of a bar of material with initial temperature at points x given by f(x), and which we let ‘go’ in time. Here u is the temperature. The bar itself is isolated. Attempting to simplify the equation, I brushed up on Laplace transforms. I realized that in fact the above integral can be written as the ‘convolution’ , where
. g(x) has the form of a Gaussian error function, which you’ve probably seen in statistics (ie: the bell curve).
Convolution, Gaussian… where have I heard these terms? That’s right… Flash 8 manual! Indeed:
The ConvolutionFilter class applies a matrix convolution filter effect. A convolution combines pixels in the input image with neighboring pixels to produce an image. A wide variety of imaging operations can be achieved through convolutions, including blurring, edge detection, sharpening, embossing, and beveling.
In fact… You can do a Gaussian Blur with a ConvolutionFilter. WTF? That means that you take an error function , normalize and stretch it, and apply its values in a radius. to give a symmetric convolution matrix. Then applying this matrix in a ConvolutionFilter, you get a Gaussian blur. Still with me?
As it turns out, Flash’s ConvolutionFilter is not misnamed, it is in fact the discrete representation of the mathematical operation of convolution. You can find more about convolution along with some nice animated graphs at MathWorld.
So here’s the kicker: you can simulate the physical behaviour of temperature flow in a bar through time using nothing but Photoshop!!! Represent the initial condition f(x) by various intensities of black and white (for illustration: black = coldest, white = hottest). Then you can simply step through time by applying a Gaussian blur over and over and the new image represents the temperature distribution in the bar after a small time epsilon.
Pick any property of temperature in time in a bar and gaussian filters;’ll you get some weird connections. If you let an isolated bar get to equilibrium, it will have the average weighted temperature of the original distribution; if you apply a Gaussian blur with a very large radius to an image, you will get a uniform image of one color with the average color being the weighted average of all the color in the picture. It’s an isomorphism, ferchrissake!
Also, if you look at the equation backwards in time you find that it’s unstable. Well, so is the ‘inverse’ of the Gaussian blur, the unsharp mask (here stable := unsensitive to initial conditions).
Anyways… I had one of those ‘moments’. Stay tuned for my discussion of the relationship between flash.geom.Matrix and the group of automorphisms of , given an Euclidian metric.


