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

📄 time_phase.m

📁 经典《信号与系统》教程的matlab例程,对深入理解信号与系统相关概念有很大帮助
💻 M
字号:
%==========================================================================
%  Name:time_phase.m
%  
%==========================================================================
clear;close all,
t=-6:0.01:6;
x=(u(t)-u(t-2));
dw=0.1;
w=-50:dw:50;
phi=-2*w;
%phi=-atan(2*w);%-2*w;
H=exp(j*phi);
h=H*exp(j*w'*t)*dw/(2*pi); 
y=0.01*conv(x,h);
y=y([600:1800]);

subplot(221);plot(t,x,'r');grid on;title('The input signal x(t)');axis([-6,6,-0.2,1.2])
subplot(223);plot(t,y,'r');grid on;title('The output signal y(t)');
xlabel('Time t');axis([-6,6,-0.2,1.2])
subplot(222)
plot(t,h),title('The impulse response h(t)');xlabel('Time t'),grid on,
axis([-4,4,-3.5,max(h)])

⌨️ 快捷键说明

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