Borrar filtros
Borrar filtros

Create a triangular wave/sawtooth function error...

9 visualizaciones (últimos 30 días)
Alejandro Urbina
Alejandro Urbina el 11 de Abr. de 2016
Comentada: Romana Nourin el 13 de Sept. de 2021
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

Respuesta aceptada

reen2015
reen2015 el 11 de Abr. de 2016
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 comentarios
Image Analyst
Image Analyst el 26 de Jun. de 2021
@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 el 13 de Sept. de 2021
Thank you!

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Dates and Time en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by