Arithmetic Encoding/Decoding

by

 

Arithmetic Encoding/Decoding using Matlab

aritmeticadec(code, symtable, m, n)
function matrix = aritmeticadec(code, symtable, m, n)
dec=arithdeco(code, symtable(:,2), sum(symtable(:,2)));

NewDec=dec;
for i=1:size(NewDec,2)
    indice=find(symtable(:,3)==dec(i));
    NewDec(i)=symtable(indice, 1);
end
matrix=NewDec;
matrix=reshape(matrix,m,n);
matrix=matrix';

Contact us