Pulse train with multiple bandwidth

6 visualizaciones (últimos 30 días)
Hossein khonsari
Hossein khonsari el 11 de Abr. de 2021
Respondida: Shubham Khatri el 20 de Abr. de 2021
I want to generate the pulse train which consists of guasepulses with different bandwidth. Can anyone help me? This is the code that I have
warning('off')
clc
clear
fs = 1e6;
Tr=1*10^-3;
Trs = zeros(1, Tr*fs);
idxdelay=4;
bandwidth = 2:20000:62000;
multisignal = []; %initialize an empty array to contain the final multisignal
xi = zeros(1, idxdelay);
bandwidth = bandwidth(randperm(length(bandwidth)));
f=25*10^5;
fx= @(y,t) (1-cos(2*pi*f*t/y)).*sin(2*pi*f*t).*(t<(y/f));
for c=1:idxdelay
t=linspace(0,2*bandwidth(c)/f,500);
x =fx(bandwidth(c),t);
xi(c) = norm(x);
multisignal=[multisignal x Trs];
%figure(1),hold on;
end
plot(multisignal)

Respuestas (1)

Shubham Khatri
Shubham Khatri el 20 de Abr. de 2021
Hi,
The function gauspuls can be used to generate Gaussian pulses. According to the script provided, you are generating sinusoidal pulses with varying bandwidth. Replacing the sinusoidal function with the Gaussian pulse function can generate a Gaussian pulse train. You can refer to the following code snippet for more information:
warning('off')
clc
clear
fs = 1e6;
Tr=1*10^-3;
Trs = zeros(1, Tr*fs);
idxdelay=4;
bandwidth = 2:20000:62000;
multisignal = []; %initialize an empty array to contain the final multisignal
xi = zeros(1, idxdelay);
bandwidth = bandwidth(randperm(length(bandwidth)));
f=25*10^5;
frac_bandwidth = bandwidth/f;
for c=1:idxdelay
t=linspace(0,2*bandwidth(c)/f,500);
x = gauspuls(t,f,frac_bandwidth(c));
xi(c) = norm(x);
multisignal=[multisignal x Trs];
%figure(1),hold on;
end
plot(multisignal)
Hope this helps!

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by