フィルターのクリア

generating a half wave sinusoid using Simulink

12 ビュー (過去 30 日間)
Cheryl
Cheryl 2014 年 10 月 5 日
編集済み: Rick Rosson 2014 年 10 月 6 日
I am pretty bad at using Simulink and have tried for days to obtain a half wave sinusoid of the following equation: I(t)=360sin(pi*t/0.4), 0<=t<=0.4 I(t)=0, 0.4<t<=1
I just used a Sine block of amplitude=360 and frequency of 7.85 rad/sec together with a pulse generator block and multiply them together.
Any suggestions? I want to get the one in blue but I only got the one in yellow. :(

回答 (1 件)

Rick Rosson
Rick Rosson 2014 年 10 月 5 日
編集済み: Rick Rosson 2014 年 10 月 5 日
Try feeding the output of the Sine Wave block to the input of a Saturation block. Set the lower limit to 0 and the upper limit to inf.
  2 件のコメント
Cheryl
Cheryl 2014 年 10 月 5 日
I had done that already but it doesn't work :( I've included a picture in my original post for a clearer picture
Rick Rosson
Rick Rosson 2014 年 10 月 5 日
編集済み: Rick Rosson 2014 年 10 月 6 日
Please check the Max step size parameter in the Solver Pane. My guess is that it is set either to auto or to a value that is too large relative to the period of the sine wave. With the sine wave having a period of 0.8 seconds, I would recommend that you set the max step size to 0.02 or even 0.01 seconds so that you will have high enough time resolution to represent the sine wave as a smooth curve.

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeSources についてさらに検索

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by