📄 db.m
字号:
%this funcion is to make FFT Discrete Fourier transform When N=1024
%then change into db form scale to the maxium point
%fs is the sampling frequency
%y is the input vector
%x is the cutpoint of fs
%dy is the spectrum of y in db form scale to the maxium point
function [x,dy]=db(fs,y)
N=1024;
Fy=fft(y,N);
Dy=20*log10(abs(Fy));
dy=Dy-max(Dy);
x=[0:fs/N:fs];
x=x(1:N)*1e-6;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -