Now that that's out of my system...
This activity is -like the title says- about the basics of scilab, especially in terms of image processing. In this activity we were made to create different synthetic images using scilab.
The first created image was just a practice run, in which we were given a premade code on making a numerical aperture.
Figure 1. Basic numerical aperture of size 0.7 |
The next image is a centered square aperture, as shown below:
Figure 2. Centered Square Aperture |
The third image is that of a sinusoid along the x-direction, also known as a corrugated roof:
Figure 3. Sinusoid along the X-direction. |
Truth be told, the grating took me the longest time to create. this is because my initial plan was so complicated that in the end I opted not to use it. My initial plan was to use a variable that switches every number of pixels to create the bars for the grating. But before I finished it I realized that if I just set all the positive values to one and negative values to zero in the sinusoid, I would basically get the grating I needed:
Figure 4. Grating along the X- direction. |
The annulus was created by using 2 circular aperture images like the one on figure 1 but with different sizes. We then multiply the 2 images element by element so that only those pixels with a value of one for both images would remain. the final product would then become something like this:
Figure 5. Annulus |
The final image we needed to make was to make a circular aperture with Gaussian transparency. This was accomplished by first making a Gaussian transparency filter as shown below:
Figure 6. Gaussian Filter |
Figure 7. Circular aperture with Gaussian transparency |
In this activity, I would give myself a 10/10 since I was able to create of the images I needed. Although there have been troubles with this activity, I had fun creating these images^^. I would like to thank MP in this activity for lending me his scilab which knows imshow and imwrite. I would like to resolve this problem before the next activity and Tracy told me that it may be because of the scilab version. That's why I will be trying to change my scilab to a 4.xx version. I hope that would fix the problem.
No comments:
Post a Comment