How to plot something like this??

1 回表示 (過去 30 日間)
Daniel Schilling
Daniel Schilling 2018 年 11 月 5 日
コメント済み: madhan ravi 2018 年 11 月 5 日
x = 0.6*(u(t+2)-(cos(pi*t)+1)*(u(t+1)-u(t-1))-u(t-2))
t = -5:51:5
plot(x,t)
When running this i get that u is an undefined variable. U in this case is a shifted step function however which is bounding my cos function. What am I missing here?

採用された回答

madhan ravi
madhan ravi 2018 年 11 月 5 日
  2 件のコメント
Daniel Schilling
Daniel Schilling 2018 年 11 月 5 日
Ok fair. I realized after I posted this I had to define the piecewise function for the step. Now my question is, using the example you provided, I'm being told piecewise is an undefined function. Is that not built in?
madhan ravi
madhan ravi 2018 年 11 月 5 日

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

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by