How to plot sawtooth wave sawtooth function?

2 ビュー (過去 30 日間)
Issie
Issie 2018 年 12 月 1 日
編集済み: Issie 2018 年 12 月 6 日
  1 件のコメント
Jos (10584)
Jos (10584) 2018 年 12 月 1 日
What have you tried so far?

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

採用された回答

Star Strider
Star Strider 2018 年 12 月 1 日
You are very close.
Try this:
f = @(x) rem(x+3,2)-1
figure
fplot(f, [-3,3])
It offsets the ‘x’ value, subtracts 1 so the limits are appropriate, then does the plot.
It may not be universally applicable, for all ‘x’. It works here for this particular problem.

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by