Plotting dirac delta function's spectrum
5 ビュー (過去 30 日間)
古いコメントを表示
I used the following code to plot the spectrum of some functions. but it doesn't work for the function dirac(t-t0) at t0=0. How can I fix it?
syms t w;
syms g h U;
g(w)=fourier(dirac(t));
h=abs(g);
w=-10:.5:10.1;
U=angle(g);
figure;
plot(w, subs(h));
figure;
plot(w,subs(U));
1 件のコメント
Marcos Duraes
2019 年 4 月 30 日
編集済み: Marcos Duraes
2019 年 4 月 30 日
%Para plotar a o gráfico de uma variable type syms utilize a função fplot(); Logo.
syms t w;
syms g h U;
g(w)=fourier(dirac(t));
h=abs(g);
U=angle(g);
figure;
fplot(g);
採用された回答
Star Strider
2017 年 11 月 3 日
The Fourier (and Laplace) transforms of the Dirac delta function are uniformly 1 for all omega (or ‘s’).
That is the result you get in ‘g(w)’.
2 件のコメント
Star Strider
2017 年 11 月 3 日
It does if you use fplot rather than plot:
syms t w g h U;
g(w)=fourier(dirac(t));
h=abs(g);
w=-10:.5:10.1;
U=angle(g);
figure;
fplot(g)
figure;
fplot(U)
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Calculus についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!