How to generate a sine curve?
古いコメントを表示
I want to generate a sine curve with a frequency of 1 Hz, amplitude of 0.2, and for a time of 15 seconds. I want the sampling rate to be 30 samples per second. This is something that I have so far:
Amp = 0.20;
Freq = 1;
Time.Val = [0:482-1];
Sig = Amp*...
sin(Freq*2*pi*Time.Val);
However, I keep getting an error. Can anyone help?
4 件のコメント
per isakson
2013 年 2 月 26 日
編集済み: per isakson
2013 年 2 月 26 日
Whit does AMP.Mod.Time stand for? Is it defined?
Sarah
2013 年 2 月 26 日
Youssef Khmou
2013 年 2 月 26 日
hi Sarah; you get one period because the time axis is not sampling with F=30Hz; beside you code does nt respect Nyquist condition
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Get Started with Curve Fitting Toolbox についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!