Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 6

Name:-D.

siva sai srikar


Rollno:-15mce1036

Frequency Domain- Transforms


1. Discrete Fourier Transform
clc;
clear all;
close all;
%original image
I=imread('pout.tif');
imshow(I);
%fft of original image
%fft
a=fft2(I);
%_absolute
b=abs(a);
%absolute value of fft
m=mat2gray(b); figure; imshow(m)
%mat to gray conversion
c=20*log(b+1);
%logrithmic estimation
d=mat2gray(c); figure; imshow(d); %mat to gray conversion
2. Discrete Cosine Transform
%fft of rotated image
%rotated image
f=imrotate(I,35);
figure;
imshow(f);
%fft
g=fft2(f);
%_absolute
h=abs(g);
%absolute value of fft
i=mat2gray(h); figure; imshow(i)
%mat to gray conversion
j=20*log(h+1);
%log estimation
k=mat2gray(j); figure; imshow(k); %mat to gray conversion
3.Image Translation
%translation of image
l=((-1)^4)*(I);
figure; imshow(l);
%fft
m=fft2(l);

%_absolute
n=abs(m);
%absolute value of fft
o=mat2gray(n); figure; imshow(o)
%mat to gray conversion
p=20*log(n+1);
%mat to gray conversion
q=mat2gray(p); figure; imshow(q);
%mat to gray conversion

Fig1: Original image

Fig2: Image after Fourier transform with absolute values

Fig3: Image after Fourier transform with logarithmic estimation

Fig4: image after rotation at an angle 35 degrees

Fig5: Rotated image after Fourier transform with absolute values (DCT)

Fig6: Rotated image after Fourier transform with logarithmic estimation (DCT)

Fig7: Translated Image

Fig8: Translated image after Fourier transform with logarithmic values

You might also like