信号与系统实验:Matlab 求连续时间信号的傅⾥叶变换
1.⽤Matlab符号运算求解法求单边指数信号的FT
MATLAB源程序为:
ft =sym ('exp(-2*t)*heaviside(t)');
fw =fourier (ft )
运⾏结果为:
fw =
1/(2 + w *1i )
2.⽤Matlab符号运算求解法求的IFT。
解:matlab源程序为
syms t
fw =sym ('1/(1+w^2)');
ft =ifourier (fw ,t )运⾏结果为:
ft =
exp (-abs (t ))/2
3.⽤Matlab命令绘出信号的频谱图。
Matlab源程序为:
ft =sym ('exp(-2*t)*heaviside(t)');
fw =fourier (ft );
subplot (211)
ezplot (abs (fw )),grid on
title ('幅度谱')
phase =atan (imag (fw )/real (fw ));
subplot (212)
ezplot (phase );grid on
title ('相位谱')
f (t )=e u (t )−2t F (jw )=1+w 21
f (t )=e u (t )−2t
调⽤heaviside函数需要与我们定义的函数名⼀致,⼀开始h⼤写了,就报错,后来改为⼩写就正确了。
>matlab傅里叶变换的幅度谱和相位谱

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。