I download the matlab code about HHT from Matlab central (http://www.mathworks.com/matlabcentral/fileexchange/19681), in the code, the auther calculate the Hilbert transform for each IMFs, but I do not understand the meaning of the parameters, would you guys help me to figure out how this code works. Thanks so so much.
function plot_hht(x,Ts)
% Plot the HHT.
% plot_hht(x,Ts)
% :: Syntax
% The array x is the input signal and Ts is the sampling period.
% Example on use: [x,Fs] = wavread('Hum.wav');
% plot_hht(x(1:6000),1/Fs);
% Func : emd
% Get HHT.
imf = emd(x); %emd is a function, it returns the IMF (intrinsic mode functions)
%%%%%%% The following one is to calculate Hilbert transform for each IMFs, but I do no know how it works???????@#$%%
for k = 1:length(imf)
b(k) = sum(imf{k}.*imf{k});
th = angle(hilbert(imf{k}));
d{k} = diff(th)/Ts/(2*pi);
end
[u,v] = sort(-b);
b = 1-b/max(b);
% Set time-frequency plots. I do not how it plot the time-frequency figures too
N = length(x);
c = linspace(0,(N-2)*Ts,N-1);
for k = v(1:2)
figure, plot(c,d{k},'k.','Color',b([k k k]),'MarkerSize',3);
set(gca,'FontSize',8,'XLim',[0 c(end)],'YLim',[0 1/2/Ts]); xlabel('Time'), ylabel('Frequency');
end
Thanks for your help.
Linda