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

📄 thfig34.m

📁 % Atomizer Main Directory, Version .802 里面信号含有分解去噪合成过程的代码 %---------------------------------------
💻 M
字号:
% thfig34: BP Thesis Figure 3.4 -- Analyzing Gong
% Signal: Gong
%	s = cos(t * pi/2 * n) ./ ((1:n) .^ .5)';
%	s = [zeros(n/2,1); s(1:(n/2))];
% Signal Length: 1024
% Dictionary: Cosine Packets with D = log2(n)-4
% Observation:
%	(a) Signal Gong
%	(b) MOF phase plane: weak and smeared out.
%	(c) BOB phase plane misses the decay structure of the Gong.
%	(d) MP is better the BOB, but still doesn't give a good
%	    description of the decay structure.
%	(e) BP phase plane reveals the decaystructure precisely.
%

help thfig34

n = 1024; D = log2(n);
t = (1:n)' ./ n;
x = cos(t * pi/2 * n) ./ ((1:n) .^ .5)';
nn = n / 2;
x = [zeros(nn,1); x(1:(n - nn))];


time = cputime;
cMOF = MOF(x, 'CP', D, 0, 0);
cputime1 = cputime - time;
time = cputime;
cBOB = BOB(x, 'CP', D, 0, 0);
cputime2 = cputime - time;
time = cputime;
cMP = MP(x, 'CP', D, 0, 0);
cputime3 = cputime - time;
time = cputime;
cBP = BP_Interior(x, 'CP', D-4, 0, 0);
cputime4 = cputime - time;

fprintf('\n')
fprintf('CPU Running Time of MOF = %8.4e\n', cputime1);
fprintf('CPU Running Time of BOB = %8.4e\n', cputime2);
fprintf('CPU Running Time of  MP = %8.4e\n', cputime3);
fprintf('CPU Running Time of  BP = %8.4e\n', cputime4);


figure(1);clf
subplot(3,2,1);
plot(t, x);title('(a) Signal: Gong');
subplot(3,2,6); [TF TFScale]=PhasePlane(cBP, 'CP', n);
title('(c) Phase Plane: BP');
subplot(3,2,3); PhasePlane(cMOF, 'CP', n, 0, 256, TFScale);
title('(d) Phase Plane: MOF');
subplot(3,2,4); PhasePlane(cBOB, 'CP', n, 0, 256, TFScale);
title('(e) Phase Plane: BOB');
subplot(3,2,5); PhasePlane(cMP, 'CP', n, 0, 256, TFScale);
title('(f) Phase Plane: MP');

subplot(3,2,3); axis([.48 .65 0 1])
subplot(3,2,4); axis([.48 .65 0 1])
subplot(3,2,5); axis([.48 .65 0 1])
subplot(3,2,6); axis([.48 .65 0 1])
brighten(-.5);
brighten(-.5);
brighten(-.5);

⌨️ 快捷键说明

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