ft.m
来自「经典《信号与系统》教程的matlab例程,对深入理解信号与系统相关概念有很大帮助」· M 代码 · 共 15 行
M
15 行
% function name:FT
% [X,w]=ft(x,t,W)
% This program is used to compute the Fourier transform of a
% continuous-time signal x(t)
% x: The continous-time signal, vector
% t: The time vector corresponding x
% W: The range of frequency: -W~W, radians/sec
% X: Returned Fourier transform X of x, it is complex vector
% w: Returned frequency vector corresponding X, radians/sec
function [X,w]=ft(x,t,W)
p=t(2)-t(1);
N=512;
k=-N:N;
w=k*W/N;
X=x*exp(-j*t'*w)*p;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?