Im trying to build a sawtooth function but matlab is not letting me run it... this is what its saying, i post a couple of hours ago and the reply i got is that its working for them but its still not working for me... i dont know what its wrong on it... ill appreciate any help thank you

 採用された回答

reen2015
reen2015 2016 年 4 月 11 日

0 投票

Please change your file name. You saved it as sawtooth.m, note that sawtooth is an inbuilt function in matlab. try using mysaw.m

4 件のコメント

Alejandro Urbina
Alejandro Urbina 2016 年 4 月 11 日
it worked out, i appreciate your help thank you
Chad Robke
Chad Robke 2021 年 6 月 26 日
I am having the same problem as above, I changed the saved name of the file with no luck. Any ideas what i am doing wrong?
Image Analyst
Image Analyst 2021 年 6 月 26 日
@Chad Robke, something else must be wrong. I hand typed in all your code and in ran just fine:
T = 2*4;
Fs = 1000;
dt = 1/Fs;
t = 0 : dt : T-dt;
x = sawtooth(2 * pi * t);
x = (x + 1) * 5
plot(t, x, 'b-', 'LineWidth', 2);
grid on;
Romana Nourin
Romana Nourin 2021 年 9 月 13 日
Thank you!

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

その他の回答 (0 件)

カテゴリ

Community Treasure Hunt

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

Start Hunting!

Translated by