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

📄 thfig51.m

📁 % Atomizer Main Directory, Version .802 里面信号含有分解去噪合成过程的代码 %---------------------------------------
💻 M
字号:
% thfig51: BP Thesis Figure 5.1 -- DeNoising noisy Carbon
% Signal:	Noisy Carbon, SNR = 1
% Signal Length: 512
% Dictionary:	Wavelet Packets with D = log2(n) and qmf = (Symmlet, 8)
% Observations:
%	(a) Signal: Carbon
%	(b) The Noised: SNR = 1
%	(c) Denoising by MOF: it simply shrinks every coordinates.
%	(d) Denoising by BOB: it cannot recover the dirac due to the
%	    nonorthogonality between the dirac and the sinusoid.
%	(e) Denoising by MP: it does not recover the sinosoid properly.  
%	(f) BPDenoising: visually much better, though the amplitude is 
%	    somewhat attenuated.
%

help thfig51

n = 512; D = log2(n); SNR = 1;
qmf = MakeONFilter('Symmlet', 8); bell = 'Sine';

x = InputSignal('Carbon', n);
%Noise level = 1
randn('seed', 12345678);
[x y]= NoiseMaker(x, SNR);
sigma = 1;
time = cputime;
xrecMOF = MOFDN(y, 'WP', D, qmf, 0);
cputime1 = cputime - time;
time = cputime;
xrecBOB = BOBDN(y, 'WP', D, qmf, 0);
cputime2 = cputime - time;
time = cputime;
xrecMP = MPDN(y, 'WP', D, qmf, 0);
cputime3 = cputime - time;
time = cputime;
xrecBP = BPDN_Interior(y, 'WP', D, qmf, 0);
cputime4 = cputime - time;

fprintf('\n')
fprintf('CPU Running Time of MOFDN = %8.4e\n', cputime1);
fprintf('CPU Running Time of BOBDN = %8.4e\n', cputime2);
fprintf('CPU Running Time of  MPDN = %8.4e\n', cputime3);
fprintf('CPU Running Time of  BPDN = %8.4e\n', cputime4);

%Figure
figure(1);clf
t = (1:n)' / n;
subplot(3,2,1); plot(t, x); title('(a) The Truth')
AXIS = axis;
subplot(3,2,2); plot(t, y); 
titlestr = sprintf('(b) The Noised: SNR = %g', SNR);
title(titlestr)
subplot(3,2,3); plot(t, xrecMOF); title('(c) Recovered: MOF')
axis(AXIS);
subplot(3,2,4); plot(t, xrecBOB); title('(d) Recovered: BOB')
axis(AXIS);
subplot(3,2,5); plot(t, xrecMP); title('(e) Recovered: MP')
axis(AXIS);
subplot(3,2,6); plot(t, xrecBP); title('(f) Recovered: BP')
axis(AXIS);
subplot(3,2,1); title('(a) Signal: Carbon');

⌨️ 快捷键说明

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