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

📄 examp33.m

📁 ADSP TOOLBOX: Version 2.0 and gui m-files
💻 M
字号:

clc,echo on 
%EXAMPLE 33 
F0=0.05;F1=0.4;                       % Digital frequencies
N=800;n=0:N-1;                        % Number of points and DT index
xc=cos(2*pi*(n*F0+(F1-F0)*n.*n/2/N)); % Chirp signal
plot(n,xc),pause(2)                   % Plot chirp
timefreq(xc);pause(2)                 % Look at its spectrum
psdwelch(xc);pause(2)                 % Look at its spectrum
n1=-80:80;                            % Index for filter coefficients
ha=0.4*cos(0.4*n1*pi).*sinc(0.2*n1);
h=udelta(n1)-ha;                      % Generate filter coefficients
yf=filter(h,1,xc);
plot(n,yf), pause(2)                  % Filter the chirp and plot
timefreq(yf);pause(2)                 % Spectrum of filtered chirp
psdwelch(yf);pause(2)                 % Spectrum of filtered chirp
h1=0.3*sinc(0.3*n1);                  % Generate filter coefficients
yf1=filter(h1,1,xc);
plot(n,yf1),pause(2)                  % Filter the chirp and plot
timefreq(yf1);pause(2)                % Spectrum of filtered chirp
psdwelch(yf1);                        % Spectrum of filtered chirp
echo off %end of example

⌨️ 快捷键说明

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