plot a inear sweep & stepped sweep
Mostrar comentarios más antiguos
Hello,
I am try to plot a linear sweep & stepped sweep. (The attached picture)
condition:
Freauency range from 20Hz-20kHz
Time from 0-100ms

How the code can do it ? Tnanks!
4 comentarios
Rik
el 1 de Jul. de 2023
What have you tried so far? And do you only want to have the plot, or do you need the time,frequency pairs at some resolution?
ting po chun
el 2 de Jul. de 2023
Editada: Image Analyst
el 2 de Jul. de 2023
Would the built-in chirp function help you?
help chirp
ting po chun
el 2 de Jul. de 2023
Respuestas (1)
KALYAN ACHARJYA
el 2 de Jul. de 2023
Editada: KALYAN ACHARJYA
el 2 de Jul. de 2023
t=0:8:100;
f=linspace(20,2000,length(t));
stairs(t,f);
xlabel('Time');
ylabel('Frequency');
hold on
plot(0:100,linspace(20,2000,101))
hold off
If the use of the inbuilt stair function is not allowed, modify the code according to the requirements, finding alternative methods such as the step function or other approaches can be done.
Categorías
Más información sobre Frequency-Domain Analysis en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!




