Most of my work this month has been about testing FITSFlow by creating some synthetic images and flows, distorting the test images by the flows, and then using FITSFlow to see if the correct fields could be recovered.

Actually, this image was created just to test the orientation in FITSRegister and my various Unix programs. The origin of the XY axes is the first pixel in the FITS file. When processing actual Venus images, we usually flip the Y axis so that the image is displayed with the same orientation as the IRTF guider.






This is the first test image deemed appropriate for input to FITSFlow. It is constructed by superimposing 750 Gaussians of the form exp(-(r^2) / (2 * sigma^2)) / (2 * pi * sigma^2) for sigma = image diagonal / 75. In many ways the resulting overlapping random pattern seems similar to the cloud features in the actual images of Venus we are using, although I have performed no real statistics to quantify this intuition.

This is the second test image submitted to FITSFlow, and is constructed of 500 superimposed Gaussians of the same form as above, with sigmas ranging from 0.5 to 1.5 that of the previous image. Again, this image seems to share some of the features of the cloud images of Venus. In any case, both test images appear to contain non-repeating random features with about the same spatial scale and resolution as the real Venus images.

Here the length of each arrow is 14.14 at a 45 degree angle.

Each vector is orthogonal to its radius, and has a length of its radius / 10. The resulting image was somewhat jagged, due to the integer truncation of the pixel projections, so I created an interpolation to anti-alias the distorted image.

Each pixel (1 square unit) that is projected to non-integer coordinates is distributed over 4 pixels according to the values of a, b, c, and d above, where x and y are the fractional coordinates. The distorted image is the sum of all such distributed pixels.


Each vector is radial and has a length of its radius / 10. Due to the expansion, slight overlaps appear in the result. To alleviate this effect, I performed the distortion using several iterations of the flow at a fraction of its full value. 10 iterations seemed enough to eliminate most of the artifacts, while 100 performed little better.


Each vector has the direction of a dipole field of 1 / r^2 intensity for two opposite charges. All vectors are normalized to a length of 10. To distort the test image, 10 iterations of 1/10 field strength were used to eliminate some artifacts.

Each vector has an x value of y / 10, and a y value of 0.

Each vector has the components dx = 10 * cos(y / 50) and dy = 10 * cos(x / 50).

Each vector has the components dx = 10 * cos(x / 50) and dy = 10 * cos(y / 50).

Each vector has the components dx = 10 and dy = 10 * cos(x / 25). Note that this field has a similar effect on the grid as #6 above, although its effect on the test image is somewhat different.

where u is the flow and psi is the image. Scot defined a slightly different equation:

which makes use of the gradient rather than the divergence. The two may be equivalent, but neither worked when I tried them on the various distortions, using a dt of 0.1 or less. Here is the result of integrating the first equation for a translational flow. The second equation produces essentially the same results:

I understand that integration of these equations is a complex topic, and I didn't try anything fancy. For example, I just used Euler's method for integration. I may have done something wrong, but otherwise these equations aren't doing what they advertise. I should say that I'm always suspicious of any numerical technique that relies on taking derivatives. Integration is OK, but differentiation should be avoided, in my experience. Nevertheless, I wasn't too concerned with these results, as the projective method of distortion illustrated above seemed to work fine for our purposes.

To combat this problem, I developed what is essentially a dynamic simulation in which the real coordinates of each pixel projected along the flow are maintained at each iteration. Only after the last step are pixel coordinates truncated to integers. This allows an image to be projected along a flow for as long as desired without blurring:

Although the integration used is again simple Euler's, it is sufficient to project an image many times along a flow field. For example, here is a grid and test image projected 10 times along the vortical flow (#6 above) with a dt of 0.01. A problem which still remains in this approach are the gaps produced by stretching a pixel neighborhood. Each pixel moves independently of its neighbors rather than diminishing in intensity and creating new intermediate pixels:
