📄 ex_11_08_1.m
字号:
% ex_11_08_1.m : 习题 11.8
clear all;
close all;
load test x;
xpsd=pwelch(x,triang(32),16,4096,1);
mmax=max(xpsd);
xpsd=xpsd/mmax;
xpsd=10*log10(xpsd+0.000001);
psdx(1:2048)=xpsd(2049:4096);
psdx(2049:4096)=xpsd(1:2048);
t=-0.5:1/4096:0.5-1/4096;
figure('color','w')
subplot(211)
plot(t,psdx);grid on;
xpsd=pwelch(x,hamming(32),16,4096,1);
mmax=max(xpsd);
xpsd=xpsd/mmax;
xpsd=10*log10(xpsd+0.000001);
psdx(1:2048)=xpsd(2049:4096);
psdx(2049:4096)=xpsd(1:2048);
subplot(212)
plot(t,psdx);grid on;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -