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

📄 ttfig2.m

📁 % Atomizer Main Directory, Version .802 里面信号含有分解去噪合成过程的代码 %---------------------------------------
💻 M
字号:
% ttfig2: Tutorial Demo -- Analyze a simple signal: Beryllium
% Signal: 
%	Beryllium
% Sample Size:	512
% Dictionary:
%	Wavelet Packet 
%	D = 6, qmf = (Symmlet, 8)
% Observation:
%	(a) Signal: Beryllium.
%	    Beryllium is an artificial signal made up of 4 nearby
%           orthognoal wavelet packet atoms.
%	(b) MOF solution is smeared out.
%	(c) BOB finds the right phase plane, since the best basis for
%           Beryllium is orthogonal.
%	(d) MP phase plane is a little messy about the true location,
%	    since MP couldn't resolve the similarity among the 4 atoms.
%	(e) BP does a perfect job as BOB.
%
fig_label=get(0,'Children');
for fi=1:prod(size(fig_label))
   if fi>2
      close (fig_label(fi));
   end
end
help ttfig2

%Sample Size
n = 512;

%Dictionary
D = log2(n) - 3;
qmf = MakeONFilter('Symmlet', 8);
NameOfDict = 'WP';
par1 = log2(n) - 3;
par2 = qmf;
par3 = 0;

%Signal
x = InputSignal('Beryllium', n);

%Decomposition
cMOF = MOF(x, 'WP', D, qmf, 0);
cBOB = BOB(x, 'WP', D, qmf, 0);
cMP = MP(x, 'WP', D, qmf, 0);
cBP = BP_Interior(x, 'WP', D, qmf, 0);

disp(' ')
disp('Plot ...')
%Figures
figure(1);clf
t = (1:n)' / n;
plot(t, x);
title('(a) Signal: Beryllium')
figure(3);
%phase planes:
%(1) make sure the 4 phase planes at the same scale
%(2) PhasePlane routine needs qmf for 'WP'
TFScale = 1;	
subplot(2,2,1);PhasePlane(cMOF, 'WP', n, qmf, 256, TFScale);
subplot(2,2,2);PhasePlane(cBOB, 'WP', n, qmf, 256, TFScale);
subplot(2,2,3);PhasePlane(cMP, 'WP', n, qmf, 256, TFScale);
subplot(2,2,4);PhasePlane(cBP, 'WP', n, qmf, 256, TFScale);
subplot(2,2,1); title('(b) Phase Plane: MOF')
subplot(2,2,2); title('(c) Phase Plane: BOB')
subplot(2,2,3); title('(d) Phase Plane: MP')
subplot(2,2,4); title('(e) Phase Plane: BP')

⌨️ 快捷键说明

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