The S -transform with windows of arbitrary
and varying shape
想畫如上的三張圖,可是問題
(1)濾波窗口的平滑實現
The filter (applied to the full 200£400 S-transform matrix)
is constructed in Matlab by constructing a two-dimensional
“boxcar”, using
filter = zeros(200,400);
filter(69:128,180:240)=1;
The filter edges are then smoothed by setting the value of
each pixel equal to the average of its four adjacent pixels (this
procedure is repeated 100 times).
(2)S變換中的頻率與短時傅里葉變換頻率怎么對應
我畫出來的頻率不太對。。邊緣也還沒處理。。
clear all % x1=readEIS('35006_6_2121_秒.txt'); % x=x1(:,2); x1=load('qzh_3.txt'); % x=qzh_3; points=length(x1); figure subplot(211),plot(0:0.02:0.02*(points-1),x1);title('原始信號');grid on; [st_matrix,st_times,st_frequencies] = st(x1) ; % imagesc(st_times,st_frequencies,abs(st_matrix)) % imcontour(abs(st_matrix)) ST=abs(st_matrix); filter = zeros(1501,3000); filter(100:800,900:1400)=1; STF=ST.*filter; STF(STF==0) = NaN; subplot(212),h=imagesc(STF);%其中C為包含有nan的數據 set(h,'alphadata',~isnan(STF)) ylim([0 1000]) % set(gca, 'ydir', 'reverse'); colorbar colormapeditor