⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dbrec2.m

📁 用matlab编写的压缩解压缩程序
💻 M
字号:
function x=dbdec2(a,h,v,d,N)
%dbdec2  2-D Daubchies reconstruct 
%x=dbdec2(a,h,v,d,N)

sx=size(a);
ca1=a;
ch1=h;
cv1=v;
cd1=d;

%calculate the db filter
rhcoef=dbaux(N);
rgcoef=rh2rg(rhcoef);
lrhcoef=length(rhcoef);

%db  reconstruct
lcout=lrhcoef+(sx(2)-N+1)*2-1;
lrout=lrhcoef+(sx(1)-N+1)*2-1;

%db  reconstruct
ca1=wconv('col',dyadup(ca1,'row',1),rhcoef);
ca1=wconv('row',dyadup(ca1,'col',1),rhcoef);
ca=ca1(lrhcoef:lrout,lrhcoef:lcout)*2;
ch1=wconv('col',dyadup(ch1,'row',1),rgcoef);
ch1=wconv('row',dyadup(ch1,'col',1),rhcoef);
ch=ch1(lrhcoef:lrout,lrhcoef:lcout)*2;
cv1=wconv('col',dyadup(cv1,'row',1),rhcoef);
cv1=wconv('row',dyadup(cv1,'col',1),rgcoef);
cv=cv1(lrhcoef:lrout,lrhcoef:lcout)*2;
cd1=wconv('col',dyadup(cd1,'row',1),rgcoef);
cd1=wconv('row',dyadup(cd1,'col',1),rgcoef);
cd=cd1(lrhcoef:lrout,lrhcoef:lcout)*2;

x=ca+ch+cv+cd;

%-----------------------------------------------------%
% Internal Function(s)
%-----------------------------------------------------%
function rg=rh2rg(rh)
%rh2rg   Calculate the db filter coef 

for i=1:length(rh)
    rg(i)=-(-1)^i*rh(length(rh)-i+1);
end



⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -