How to draw spectrum of signal?

25 visualizaciones (últimos 30 días)
Adnan
Adnan el 12 de Nov. de 2024 a las 15:22
Respondida: Image Analyst el 12 de Nov. de 2024 a las 15:37
Hello. I have problem with understanding how to draw spectrum of this shape in matlab because amplitude is constant when frequency is lower than 1500 and then it change from 1500 to 3000Hz. Thank you.

Respuesta aceptada

Image Analyst
Image Analyst el 12 de Nov. de 2024 a las 15:37
Did you try plot()?
fm = 1000; % whatever
f = [0, 0, fm/2, fm];
X2 = [0, 1, 1, 0];
plot(f, X2, 'r-', 'LineWidth', 4);
xlabel('f [Hz]');
ylabel('X2(f)');
grid on;

Más respuestas (0)

Categorías

Más información sobre Fourier Analysis and Filtering en Help Center y File Exchange.

Productos


Versión

R2024b

Community Treasure Hunt

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

Start Hunting!

Translated by