⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 est_tf.m

📁 该工具箱为时频分析中的一类重要变换,离散时频分布的工具箱,其中提供基本算法的程序.可直接应用
💻 M
字号:
function [t, f] = est_tf(x, c, d, M, decf)% est_tf -- Estimate the location in time and frequency of the chirp.%%  Usage%    [t f] = est_tf(x, c, d, M, decf)%%  Inputs%    x     signal vector%    c     current estimate of the chirp rate (optional, default is 0)%    d     current estimate of the duration (optional, default is 5)%    M     number of points to compute in frequency (optional, default is 64)%    decf  time decimation factor of the spectrogram (optional, default is 1)%%  Outputs%    t     estimate of the location in time%    f     estimate of the location in frequency%% Given the current estimates of the chirp rate and duration, estimate% the location in time and frequency from the maximum value of the% spectrogram.  M and decf serve to decrease computations but could % decrease performance.  Algorithm is O(NM/decf log M)% Copyright (C) -- see DiscreteTFDs/Copyrighterror(nargchk(1, 5, nargin));if (nargin < 2)  c = 0;endif (nargin < 3)  d = 5;endif (nargin < 4)  M = 64;endif (nargin < 5)  decf = 1;endM = 2*floor(M/2);  % want M to be evenx = x(:);N = length(x);% compute spectrogram window and prune to save computationshN = 2*round(32*d/5)-1;  % lessens  truncation of the windowhN = min(hN, 4*M+1);hN = min(hN, 2*floor(N/2)-1);h = conj(chirplets(hN, [1 (hN+1)/2 0 c d]));% compute spectrogram and find the location of the maximumS = spec2(x,1,M,decf,h);[m t] = max(max(S,[],1));[m f] = max(S(:,t));% convert from sample number to real unitst = (t-1)*decf + 1;f = 2*pi*(f-1)/M - pi;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -