資源簡介
通過matlab語言實現(xiàn)小波變換在信號故障診斷中的應(yīng)用,實現(xiàn)結(jié)果良好,可供大家使用,互相學(xué)習(xí)。

代碼片段和文件信息
%調(diào)入含突變點的信號
load?freqbrk;
x=freqbrk;
N=length(x);
t=1:N;
figure(1);
plot(tx‘LineWidth‘2);xlabel(‘時間?t/s‘);ylabel(‘幅值?A‘);
%一維小波分解
[cl]?=?wavedec(x6‘db5‘);
%重構(gòu)第6層逼近系數(shù)
a6?=?wrcoef(‘a(chǎn)‘cl‘db5‘6);
%重構(gòu)第1~6層細節(jié)系數(shù)
d6?=?wrcoef(‘d‘cl‘db5‘6);
d5?=?wrcoef(‘d‘cl‘db5‘5);
d4?=?wrcoef(‘d‘cl‘db5‘4);
d3?=?wrcoef(‘d‘cl‘db5‘3);
d2?=?wrcoef(‘d‘cl‘db5‘2);
d1?=?wrcoef(‘d‘cl‘db5‘1);
%顯示重構(gòu)系數(shù)和細節(jié)系數(shù)
figure(2)
subplot(711);plot(d6‘LineWidth‘2);ylabel(‘d6‘);
subplot(712);plot(d5‘LineWidth‘2);ylabel(‘d5‘);
subplot(713);plot(d4‘LineWidth‘2);ylabel(‘d4‘);
subplot(714);plot(d3‘LineWidth‘2);ylabel(‘d3‘);
subplot(715);plot(d2‘LineWidth‘2);ylabel(‘d2‘);
subplot(716);plot(d1‘LineWidth‘2);ylabel(‘d1‘);
subplot(717);plot(a6‘LineWidth‘2);ylabel(‘a(chǎn)6‘);
xlabel(‘時間?t/s‘);
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件?????????876??2005-09-09?15:10??cmt.m
?????文件??????169472??2011-01-09?21:07??編程題.doc
評論
共有 條評論