How can I make a repeating rectangular wave with a specified period?
7 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello, this is my first post so I am hoping that my formating is okay. I need to plot a descrete rectangular wave 7 units wide and that repeats with a period of 35 units. I know how to make the intial signal using the rectangularPulse function but I am not sure how to go about repeat it with the desired period. I need to show a minimum of 4 full cycles. Any help would be greatly appreciated.
n = -20:20;
y = rectangularPulse(-3.5,3.5,n);
stem(n,y);
0 Kommentare
Antworten (1)
KSSV
am 11 Mär. 2019
n = -20:20;
y = rectangularPulse(-3.5,3.5,n);
y1 = repmat(y,1,4) ;
n1 = 1:length(y1) ;
stem(n1,y1);
0 Kommentare
Siehe auch
Kategorien
Mehr zu Multirate Signal Processing finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!