Wednesday, July 8, 2009

Activity 6 - Properties of the 2D Fourier Transform

6.A - Familiarization with FT of different 2D patterns

In this part of the activity, Fourier transforms (FT) of different apertures were investigated. Here, we familiarize on the patterns formed by this images upon applying FT.



Figure 1. (lower row) FTs of the images on the upper row.

The figure above shows the patterns obtained as a result of taking the FT of images of different apertures (Fig.1 upper row). We see here interesting patterns. For example, the FT of a square is a sinc function along the x and y-axis. Many other shapes can be applied with FT and may observe other patterns as well.


6.B. Anamorphic property of the Fourier transform



Figure 2. (below) FT of (above)sinusoid images of different frequencies (left) 1Hz (middle) 4 Hz and (right) 10 Hz)

The two points in the FT of the images are the frequencies (f and -f) of the sinusoid used (0 Hz is located between the two points). As the frequency of the sinusoid increases, the distance between the two points also increases. The points get farther away from the center as the frequency is increased.
Usual images don't have negative pixel values -- in other words the image is biased. The problem now arises, since the image is biased, is how to determine correctly the frequencies contained in the image. This is one of the powerful uses of Fourier transformation.



Figure 3. FT of 10 Hz-sinusoid images with (upper left)constant bias and (upper right)sinusoidal bias with 1 Hz frequency

The figure above shows the a biased sinusoid image with their FTs. Fig.3(upper left) is constant-biased and the Fig.3(upper right) is sinusoid-biased. As seen, the FT of the constant-biased image has three points -- the peripheral points are the frequencies (f and -f)of the image and the point at the center (at 0 Hz) accounts for the bias. The frequency of the image can now be correctly determined ignoring the bias.
What if the image has a sinusoidal bias? These biases include noise, etc. Usually, in signals and images, non-constant biases are of low frequencies. If the frequencies contained in the image is sufficiently high, we can separate easily separate the low from the high frequencies using the FT. An example is demonstrated in Fig. 3 (right). Fig.3(upper right) is a 10 Hz-sinusoid with a 1 Hz-sinusoid bias. using FT, 2 distinct frequencies were observed: (1) the one closer to the center and (2) farther away the center. The frequency closer to the center (meaning of low frequency) accounts for the bias and the farther accounts for the frequency of the image. The low-frequency can be disregard and we are able to find the frequencies contained in the image.
The obtained FT can also be multiplied with a function that to remove low frequencies. We can take its inverse FT to retrieve a better image. Note, however, that this technique cannot always serve its purpose right. Once the frequency contained in the image is close to the frequency of the bias, doing such might destroy the image.

In this part, we rotate the image the image and look into how the FTs change with the rotation.



Figure 4. (below) FTs of the (above) rotated images at : (left) 30o (mid) 40o and (right) 50o

We can observe in Fig. 2 and 3, that the axis of the dots of the FT is perpendicular to the bands of the image. This observation is the same even when the image is rotated. The FTs rotate as the image is rotated. This is another property of the Fourier transformation. The axis of the FTs are just rotated and same frequencies were obtained.

Images may contain different frequencies (assuming the image has no biases). It can be a combination of sinusoids of with these frequencies (i.e summation or multiplication of sinusoids). Below are images of sinusoidal combinations and their FTs.



Figure 5. (upper row) Images formed from sinusoidal combinations and (lower row) their FTs. (upper left) z = sin(2*pi*f*X)+ sin(2*pi*f*Y) ; (upper right) z = sin(2*pi*f*X)sin(2*pi*f*Y)

The FT of the sum of 2 sinusoids (Fig. 5(lower left)) is just the sum of the FT of each sinusoid:

Ft =F{sin(2*pi*f*X)} + F{sin(2*pi*f*Y)}

This is another property of FT -- linearity. The FT of sum is the sum of FT.
This property holds regardless of the number of additions to the orignal pattern. This is illustrated in the figure below.
For the product combination,

z = sin(aX)sin(bY),

the expression can be expanded into sum of cosines given below:

z = [cos(aX - bY) - cos(aX + bY)]/2 or
z = [sin(aX - bY + pi/2) - sin(aX + bY + pi/2)]/2

This is just sum of rotated sines at opposite directions (due difference in signs of bY). This results to a pattern in Fig.5(lower right).


Figure 6. Product combination of 2 sinusoids as in Fig. 5(upper right) with additional two rotated sinusoids with frequencies 10 Hz and 25 Hz. The 10 Hz signal is rotated at 30o. The 25 Hz-sinusoid is rotated from 30o, 60o and 90o.

Using the pattern in Fig.5 (upper right) plus additional rotated patterns, since FT is a linear transform, an expected pattern is:

Foverall = F{pattern1} + F{pattern2} + F{pattern3}

Indeed, the prediction is right. The FT of the product combination is retained, the FT of the rotated 10 Hz sinusoid (as in Fig.4(lower left)), and the FT of the 25 Hz sinusoid at different rotation angles.

In this activity, I give myself a grade of 10.

I thank Jica Monsanto, Miguel Sison, Orly Tarun, and Jayson Villangca for useful discussions. Special thanks to Sison for making me realize that some of my images were wrong.










No comments:

Post a Comment