Whether convolution followed by down sampling equals wavelet decomposition
조회 수: 3 (최근 30일)
이전 댓글 표시
I know that wavelet decomposition equals convolution followed by down sampling by two.I tried to test this on mat lab on haar wavelet. I write the below code and compared with the default wavedec command in mat lab. The code I wrote is shown below.
% clear all
clc
h=[0.7071 0.7071];% Haar scaling filter
g=[-0.7071 0.7071];%Haar wavelet filter
x=[1:10];% Input
h=fliplr(h);% h(-m)
g=fliplr(g);%g(-m)
s=conv(h,x);
s=downsample(s,2)
d=conv(g,x);
d=downsample(d,2)
[a L]=wavedec(x,1,'haar') % for comparison
if true
% code
end
After running this program I get ` s = 0.7071 3.5355 6.3639 9.1923 12.0207 7.0710. d = 0.7071 0.7071 0.7071 0.7071 0.7071 -7.0710 and the wavedec out put as a = 2.1213 4.9497 7.7782 10.6066 13.4350 -0.7071 -0.7071 -0.7071 -0.7071 -0.7071. L = 5 5 10`
I dont know why wavedec and my code gives different out puts, will any one help???
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Discrete Multiresolution Analysis에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!