Beruflich Dokumente
Kultur Dokumente
(1/sqrt(8)) (1/2)*(cos(3*pi/16))
(1/2)*(cos(3*pi/16) (1/2)*(cos(6*pi/16))
(1/2)*(cos(9*pi/16)) (1/2)*(cos(12*pi/16)) (1/2)*(cos(15*pi/16))
(1/2)*(cos(18*pi/16)) (1/2)*(cos(21*pi/16));
(1/sqrt(8)) (1/2)*(cos(15*pi/16))
(1/2)*(cos(15*pi/16)) (1/2)*(cos(30*pi/16))
(1/2)*(cos(45*pi/16)) (1/2)*(cos(60*pi/16)) (1/2)*(cos(75*pi/16))
(1/2)*(cos(90*pi/16)) (1/2)*(cos(105*pi/16))];
subplot(2,2,2)
imagesc(d)
colormap(gray);
subplot(2,2,3)
imagesc(dt)
4- En calculer et afficher le DCT :
C= d*a*dt
DCT= round( C );
Les coefficient de « dct » :
dct =
a
d
D’ DCT
5- Quantification :
a- Représentent la matrice Q de quantification :
Q=[16 11 10 16 24 40 51 61;
12 12 14 19 26 58 60 55;
14 13 16 24 40 57 69 56;
14 17 22 29 51 87 80 62;
18 22 37 56 68 109 103 77;
24 35 55 64 81 104 113 92;
49 64 78 87 103 121 120 101;
72 92 95 98 112 100 103 99];
figure(4);
imagesc(Q);
11 -5 13 -33 3 0 1 0
-4 1 -3 0 -11 0 0 0
8 -33 0 0 0 0 0 0
-33 1 0 0 0 0 0 0
4 -11 0 0 0 0 0 0
0 0 0 0 0 0 0 0
1 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
for d=2:64
for i=1:8
for j=1:8
if((i+j)==d)
t=t+1;
t;
if(c==0)
new(t)=dctq(j,d
new(t)=dctq(j,d-j);
else
new(t)=dctq(d
new(t)=dctq(d-j,j);
end
end
end
end
end
dctq
new
Résultats:
new =
[ 11 -5 -4 8 1 13 -3
- -3 -3 -3 4 1 0 0 3 0 -11 0 0 -1 0
1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 00]
La valeur du coefficient DC de la DCT si (1er valeur) :
DC= 11
Les suite des coefficients AC de la DCT si (63 derniers valeurs) :
AC = -5 -4 8 1 13 -3 -3 -3 -3 4 1 0 0 3 0 -1 0 0 -1 0
1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0
Codage RLC :
La Suite est [ 11 -5 -4 8 1 13 -3 -3 -3 -3 4 1 0 0 3 0 -1 0
0 -1 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0]
1)
Code RLC =(11,0)(-5,0)(-4,0)(8,0)(1,0)(13,0)(-3,0)(-3,0)(-3,0)(-3,0)(4,0)(1,0)(3,2)(-1,1)
(-1,2)(1,1) (1,5)
Codage Huffman :