Daubechies filters: Frequency response
4 ビュー (過去 30 日間)
古いコメントを表示
I need to know the frequency response of Db4 (6 levels) filters. I mean, I need to know the amplitude of the power spectral density (or similar) vs frequency (Hz)[using the frqz comand] for each of the levels of the Daubechies 4. Some one know how to do this?????
0 件のコメント
採用された回答
Wayne King
2012 年 7 月 30 日
編集済み: Wayne King
2012 年 7 月 30 日
Hi Lorena, you have to determine the equivalent filter at each level of the wavelet tree. As a simple example, I'll show you how to compare the db4 scaling filter at level 1 and level 2.
Note to get the equivalent scaling filter at level 2 you have to lowpass filter at level 1 followed by downsampling by two and then lowpass filter for level 2.
[LoD,HiD] = wfilters('db4');
[H1,W1] = freqz(LoD);
% getting the equivalent impulse response for level 2
scal2 = conv(upsample(LoD,2),LoD)./sqrt(2);
[H2,W2] = freqz(scal2);
plot(W1,abs(H1),'k'); hold on;
plot(W2,abs(H2),'r');
legend('Level 1 Scaling Filter','Level 2 Scaling Filter');
xlabel('Radians/sample'); ylabel('Magnitude');
This is for 1st and 2nd level db4 wavelet (detail) filters.
[LoD,HiD] = wfilters('db4');
[H1,W1] = freqz(HiD);
% getting the equivalent impulse response for level 2
wav2 = conv(upsample(HiD,2),LoD)./sqrt(2);
[H2,W2] = freqz(wav2);
plot(W1,abs(H1),'k'); hold on;
plot(W2,abs(H2),'r');
axis tight;
legend('Level 1 Wavelet Filter','Level 2 Wavelet Filter', ...
'Location','SouthEast');
xlabel('Radians/sample'); ylabel('Magnitude');
2 件のコメント
choma community
2012 年 10 月 17 日
please help me wayne, I need to know the frequency response of gabor wavelet and linear predictive coding (LPC)...
その他の回答 (1 件)
Miguel Alfonso Mendez
2017 年 3 月 28 日
編集済み: Miguel Alfonso Mendez
2017 年 3 月 28 日
Very interesting answer. Could you continue with the level 3 ?
For example, should the level 3 approximation be
scal3=conv(upsample(scal2,2),LoD)./sqrt(2) ?
In this case the length of the impulse response is 53, but It should be 50.
I am missing something :(
I also add one more question: Downsampling and then filtering by a filter having transfer function G(z) should be equal to filter by G(z^2). Therefore the second level low pass filter should have transfer function G(z)*G(z^2), no ? Similarly the second level high pass should have G(z)*H(z^2).
Therefore, I would be tempted to compute the transfer function at level 2 as follow:
% Level 1
[LoD,HiD] = wfilters('db4'); %Impulse Response
[Hl,Wl] = freqz(LoD); % Low Frequency Part
[Hh,Wh] = freqz(HiD); % High Freq Part
z=Wl/pi; %Take the z axis
G=abs(Hl)/max(abs(H1)); %Transfer Function Filter 'Low'
LL=G.*interp1(z.^2,G,z); %Transfer Function Filter 'Low'*'Low'
% Filter LH:
H=abs(Hh)/max(abs(Hh)); %Transfer Function Filter 'Low'
LH=G.*interp1(z.^2,H,z); %Transfer Function Filter 'Low'*'High'
figure(1)
plot(z,LH,'k') %Low*High
hold on
plot(z,LL,'r') %Low*Low
Now... this is giving a very different result from what you have proposed: where is the mistake ?
Thank you
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Filter Analysis についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!