資源簡介
本代碼為自適應(yīng)局部迭代濾波(ALIF)處理振動信號,內(nèi)有可運(yùn)行的示例(demo文件),添加了相關(guān)注釋,matlab2018可以直接運(yùn)行,其他版本請自行嘗試。ALIF是2016年Antonio Cicone提出的一種自適應(yīng)信號處理方法,原作者論文已附在壓縮包中,代碼中的示例效果并不代表最佳效果,只作為運(yùn)行展示使用。

代碼片段和文件信息
function?[IMFmask_lengths]?=?ALIFv5_4(foptions)
%
%?Generate?the?decomposition?of?a?signal?f?:
%
%??f?=?IMF(1:)?+?IMF(2:)?+?...?+?IMF(size(IMF?1)?:)
%
%?where?the?last?component?is?the?trend?and?other?components?are?IMFs
%
%
%????????????????????Input
%
%???f??????????Signal?to?be?decomposed
%
%???options????Structure?generated?using?function?decompSettings_v5?containing
%??????????????all?the?parameters?needed?in?the?various?algorithms
%
%???????????????????????????????Output
%
%???IMF???????????Matrices?containg?in?row?i?the?i-th?IMF.?The?last?row
%??????????????????contains?the?remainder-trend.
%
%???mask_lengths??Mask?length?functions?used?for?each?IMF
%
%???See?also?SETTINGS_ALIF?IF_V8_3?SETTINGS_IF_V1?GET_MASK_V1?MAXMINS_v3?PLOT_IMF_V8.
%
%??Ref:?A.?Cicone?J.?Liu?H.?Zhou.?‘Adaptive?Local?Iterative?Filtering?for?
%??Signal?Decomposition?and?Instantaneous?Frequency?analysis‘.?Applied?and?
%??Computational?Harmonic?Analysis?Volume?41?Issue?2?September?2016?
%??Pages?384-411.?doi:10.1016/j.acha.2016.03.001
%??ArXiv?http://arxiv.org/abs/1411.6051
%
%??A.?Cicone.?‘Nonstationary?signal?decomposition?for?dummies‘.?
%??To?appear?in?the?book?Advances?in?Mechanics?and?Mathematics.
%??ArXiv?https://arxiv.org/abs/1710.04844
%
%??A.?Cicone?H.?Zhou.?‘Iterative?Filtering?algorithm?numerical?analysis?
%??with?new?efficient?implementations?based?on?FFT‘
%??ArXiv?http://arxiv.org/abs/1802.01359
%%?We?deal?with?the?input
if?nargin?==?0??help?ALIFv5_4;?return;?end
if?nargin?==?1?options?=?Settings_ALIF;?end
extensionType?=?‘p‘;?%?used?in?the?calculations?of?mins?and?maxs
N?=?length(f);
if?size(f1)>size(f2)
????f?=?f.‘;
end
if?size(f1)>1
????disp(‘Wrong?dataset?the?signal?must?be?a?single?row?vector‘)
end
IMF?=[];
if?options.plots>0
????if?options.saveplots==1
????????nameFile=input(‘Please?enter?the?name?of?the?file?as?a?string?using?‘‘?and?‘‘?<?‘);?%‘v081_Ex2‘;
????end
end
%%?Main?code
fprintf([‘\n\n?????????******************?WARNING?******************\n\n?‘...
????‘We?assume?periodicity?in?the?signal?and\n\n??its?instantaneous?periods\n\n‘?...
????‘?????????*********************************************\n‘])
pause(0.5)
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%???????Adaptive?Local?Iterative?Filtering???????????%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
tic
load(‘prefixed_double_filter‘‘MM‘);
if?length(f)>length(MM)
????fprintf([‘\n\n??????********???Warning??*********\n\n‘...
????????‘?The?filter?MM?should?contain?more?points\n‘...
????????‘?to?properly?decompose?the?given?signal\n\n‘...
????????‘?We?will?use?interpolation?to?generate?a\n‘...
????????‘?filter?with?the?proper?number?of?points\n\n‘...
????????‘??????*****************************\n\n‘])
end
%%%%%%%%%%%%%%%?Identify?extreme?points?%%%%%%%%%%%%%%
maxmins_f=Maxmins_v3(fextensionType);
while??length(maxmins_f)?>?(options.ALIF.ExtPoints)
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件???????15416??2019-10-10?20:35??ALIFv5_4.m
?????文件????????1267??2019-10-10?20:42??demo.m
?????文件???????19449??2019-10-10?20:32??IF_v8_3.m
?????文件????????5747??2019-10-10?20:42??normal1500.mat
?????文件?????4977059??2017-10-23?20:38??normal1500.txt
?????文件?????????696??2018-09-06?06:31??plot_imf_v7.m
?????文件????????5855??2019-09-27?17:02??plot_imf_v8.m
?????文件??????182727??2018-09-06?06:31??prefixed_double_filter.mat
?????文件????????4791??2019-09-29?11:29??Settings_ALIF.m
?????文件????????6730??2018-11-26?05:02??Settings_IF_v1.m
?????文件?????3458236??2019-07-26?14:53??(原文章)Adaptive?local?iterative?filtering?for?signal?decomposition?and?instantaneous?frequency?analysis.pdf
評論
共有 條評論