Hilbert 下载本文

内容发布更新时间 : 2024/5/23 20:12:38星期一 下面是文章的全部内容请认真阅读。

Hilbert

关于Hilbert-Huang的matlab实现,材料汇总,比较杂...感谢所有网络上的贡献者们:)

核心:以下代码计算HHT边际谱及其对应频率

工具包要求:G-Rilling EMD Toolbox,TFTB Toolbox

附:黄锷先生课题组开发的工具包(可以在 这里 找到),这里并未用到。

% Empirical mode decomposition, resulting in intrinc mode functions.

% Without parameter 'MAXMODES' the process may be seriously delayed by

% decompose original signals into too many IMFs (not necessary, 9 is % enough generally)

imfs = emd(oriSig, 'MAXMODES', 9); % HHT spectrum: hhtS [A, f, t] = hhspectrum(imfs); [hhtS, ~, fCent] = toimage(A, f, t);

% Marginal hilbert spectrum: hhtMS, xf: correspondig

frequency

for k = 1 : size(hhtS, 1)

hhtMS(k) = sum(hhtS(k, : )) * 1 / fs; end

xf = fCent(1, :) .* fs;

G-Rilling EMD Toolbox工具包相关配置:了凡春秋 简单来说,设置好路径之后输入 install_emd 即可。

Matlab关于EMD分解后希尔伯特谱分析(相关函数均隶属 G-Rilling EMD Toolbox)

hhspectrum 函数说明(8楼:老老的学生)

% [A,f,tt] = HHSPECTRUM(imf,t,l,aff) % Input:

%- imf : matrix with one IMF per row % 将emd分解得到的IMF代入就可以,就是你的程序中写的c变量,不用加最后一行的趋势项

%- t : time instants % 瞬时时间或持续时间 ??(写[1:信号长度]就可以,真实的时间可以根据采样率转换 %- l : estimation parameter for instfreq % 瞬时频率的

估计参数 ??(写1就可以,决定瞬时频率估计时的边界从第几个点开始

%- aff : if 1, displays the computation evolution % 显示计算进程选项,不想显示写0就可以 % % Output:

% - A : amplitudes of IMF rows % - f : instantaneous frequencies

% - tt : truncated time instants % 截止时间 ??(截断时间,返回的是瞬时频率对应的时间,要比原来信号的时间按短,由前面的l值决定) % % calls:

% - hilbert : computes the analytic signal

% - instfreq : computes the instantaneous frequency % 瞬时频率 %

% Example:

[A,f,tt] = hhspectrum(c(1:end-1,:),[1:n],1,0); [im,tt,ff] = toimage(A,f,tt,512); disp_hhs(im,tt,[],fs);