i=imread('Ehsan-Shahnazi.jpg');
i2=rgb2gray(i);
i3=imadjust(i2);

h1 = fspecial('motion');
h2 = fspecial('prewitt');
h3 = fspecial('sobel');
h4 = fspecial('log');
h5 = fspecial('gaussian');
h6 = fspecial('average');
h7 = fspecial('disk');
h8 = fspecial('laplacian');
h9 = fspecial('unsharp');

fs1 = imfilter(i3,h1);
fs2 = imfilter(i3,h2);
fs3 = imfilter(i3,h3);
fs4 = imfilter(i3,h4);
fs5 = imfilter(i3,h5);
fs6 = imfilter(i3,h6);
fs7 = imfilter(i3,h7);
fs8 = imfilter(i3,h8);
fs9 = imfilter(i3,h9);

figure;
subplot(3,3,1);
imshow(fs1);
title('motion fspecial');

subplot(3,3,2);
imshow(fs2);
title('prewitt fspecial');

subplot(3,3,3);
imshow(fs3);
title('sobel fspecial');

subplot(3,3,4);
imshow(fs4);
title('log fspecial');

subplot(3,3,5);
imshow(fs5);
title('gaussian fspecial');

subplot(3,3,6);
imshow(fs6);
title('average fspecial');

subplot(3,3,7);
imshow(fs7);
title('disk fspecial');

subplot(3,3,8);
imshow(fs8);
title('laplacian fspecial');

subplot(3,3,9);
imshow(fs9);
title('unsharp fspecial');
