clear;close all
i=imread('pout.tif');
figure,imhist(i);
j=imadjust(i,[75/255 175/255],[]);
k=histeq(i);
figure,subplot(1,3,1),imshow(i)
subplot(1,3,2),imshow(j)
subplot(1,3,3),imshow(k)
figure,subplot(1,3,1),imhist(i,64)
subplot(1,3,2),imhist(j,64)
subplot(1,3,3),imhist(k,64)
hgram=0:255
m=histeq(i,hgram);
figure, subplot(1,2,1),imshow(m);
subplot(1,2,2),imhist(m);
figure,subplot(2,3,1),imshow(i);
n=imnoise(i, 'gaussian ',0,0.002);
subplot(2,3,2),imshow(n);
h=[1 1 1
1 1 1
1 1 1];
h=h/9;
k=conv2(n,h);
subplot(2,3,3),imshow(k,[]);
g=medfilt2(n);
subplot(2,3,4),imshow(g);
w=wiener2(n,[5 5])
subplot(2,3,5),imshow(w);
wl=wiener2(w,[5 5])
subplot(2,3,6),imshow(w)
figure,subplot(2,3,1),imshow(i);
n=imnoise(i, 'salt & pepper', 0.05);
subplot(2,3,2),imshow(n);
h=[1 1 1
1 1 1
1 1 1];
h=h/9;
k=conv2(n,h);
subplot(2,3,3),imshow(k,[]);
g=medfilt2(n);