Proper wavelet scaling / restricted frequency analysis

1 回表示 (過去 30 日間)
Peter
Peter 2013 年 5 月 16 日
コメント済み: Akshay Ravindran 2017 年 7 月 2 日
Dear all, I sample a signal with 20000 Hz and I'm using e.g. the morlet wavelet to analyze the frequency content of short time periods (e.g. 500 ms). Two questions: The scaling os correlated to the pseudo-freuency range of the wavelet transfrom. How can I determine the optimal scaling factor? I'm just interested in the frequency range of 100-300 Hz. Is there a possibility - e.g. through the factors - to focus the wavelet analyses on this frequency range? Looking forward to your advice. Best, Peter

採用された回答

Wayne King
Wayne King 2013 年 5 月 16 日
編集済み: Wayne King 2013 年 5 月 16 日
Yes, it is possible, but you have to remember that the CWT is not as localized in frequency as the Fourier basis, so you have to give yourself some wiggle room. A sine wave will not be localized at one scale in the CWT. The way to do it best depends on whether you are using cwt.m or cwtft.m.
I'll create a signal consisting of 100-Hz and 300-Hz sine waves in noise. The 100-Hz signal will occur over the first 500 msec, the 300-Hz sine wave over the interval from 500 msec to 1 second.
Here is cwt.m:
fs = 2e4;
t = 0:1/fs:2-1/fs;
x = ...
2*cos(2*pi*100*t).*(t<0.500)+3*cos(2*pi*300*t).*(t>0.500 & t <1)+randn(size(t));
dt = 1/fs;
minscale = centfrq('morl')/(300*dt);
maxscale = centfrq('morl')/(100*dt);
scales = minscale-10:maxscale+10;
cfs = cwt(x,scales,'morl','plot');
Now for cwtft (using an analytic Morlet wavelet)
MorletFourierFactor = 4*pi/(6+sqrt(2+6^2));
s0 = (0.002*MorletFourierFactor);
smax = (1/100*MorletFourierFactor);
ds =0.2;
nb = ceil(log2(smax/s0)/ds+1);
scales = struct('s0',s0,'ds',0.5,'nb',nb,'type','pow','pow',2);
cwtS1 = cwtft({x,dt},'scales',scales,'wavelet','morl');
sc = cwtS1.scales;
freq = 1./(sc*MorletFourierFactor);
contour(t,freq,abs(cwtS1.cfs));
xlabel('Time'); ylabel('Pseudo-Frequency');
  5 件のコメント
vinod naidu
vinod naidu 2016 年 5 月 10 日
編集済み: vinod naidu 2016 年 5 月 10 日
I wanted to do in the same way for my recorded audio signal I have a [x, fs]=audioread('rec2.wav'); which loads x [81410x1] double and fs=44100
I want to scale the signal 1.65 to 2 & with the decrement of 0.005 for choosing high frequency contents ,and i want to know which one represents the a,b coefficents ? in
Akshay Ravindran
Akshay Ravindran 2017 年 7 月 2 日
Hi ,
Can i use the scale generated after performing cwtft as input to cwt function ( older version of cwt) .
I am a bit confused as you seem to assign linear scaling based on frequency of interest as input. How exactly does the scale factor in the older version of cwt work?

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeContinuous Wavelet Transforms についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by