# GMSK modulation: Simulation in Matlab for BT <0.3

My previous questions

I study gmsk modulation last 2 month and tested my simulation with only BT = 0.5 or 0.3 GSM standard.

Matab code og GMSK modulation I use

function [y, bt, phi, I, Q, ht] = gmsk_mod(a,M,BT)
Tb= 2;
Ts = Tb/M;
Fs = 1/Ts;
a=a(:);
ct = kron(a,ones(M,1));%
% Gaussian filter
k=4;
B = BT/Tb;
t=-k*Tb:Tb/M:k*Tb;
h = sqrt(2*pi*B^2/(log(2)))*exp(-t.^2*2*pi^2*B^2/(log(2)));
ht=h/sum(h);
% Modulator
bt = conv(ht,ct,'full');
bt = bt/max(abs(bt));
phi = filter(1,[1,-1],bt*Ts);
phi = phi *0.5*pi/Tb;
I = cos(phi);
Q = sin(phi);
% base band signal
y = I - 1i*Q;

% Spectrum
spectrum = 10*log(abs(fftshift(fft(y))) / length(y));
precision = Fs/length(y);
f = linspace(-Fs/2+precision/2, Fs/2-precision/2, length(y));

figure
plot(f,spectrum)
title( [ 'GMSK Spectrum , M = ',  num2str(M),',  ',  'BT = ',  num2str(BT),',  ',  'k = ',  num2str(k)]);
xlabel(' Frequency')
ylabel(' Spectrum,  [dB]')
end



My questions:

1. Under Question 1, Mr Müller wrote me "you did not reach it ( - 65 ...-70dB suppresion) for a BT=0.5 Gaussian filter, at all. You reached it for a sinc-filter with slightly Gaussian window. As you said yourself, your first filter is not Gaussian at all after truncation. You broke it. "

Does it mean I have a limit for truncation?

Signal after convolution with the truncated Gaussian filter will look like abs(sinc): signal is oversampled to rectungle pulse, right ?

1. Under the question 2, User "Anna Koroleva "wrote the following comment:

Hi guys! If I want to "improve" sidelobs, for example I want to reach -70dB in case BT = 0.25, what do I need to do? I dont see any difference in the implementation gmsk modulation if BT = 0.5 or BT = 0.25. But I see you reach -70dB with BT =0.5, but it is not possible for BT = 0.25. I am note sure if we need to increase the truncated length of the gaussian filter.

For GMSK BT =0.25 I use Gaussian filter with truncated length k = 4 and oversampling ratio M = 4

I test it with precoded NRZ signal:

N = 1000;
% input data
a = randi([0,1],N,1);
% nrz
ak = 2*a-1;
% precoded data
ak_1 =  zeros(size(ak));
ak_1(1) = 1;
for i = 1: length(ak)-1
ak_1(i+1) = ak(i);
end
for i = 1 : length(ak)
akp = (-1)^i .* ak.*ak_1;
end

M = 4;
BT025 = 0.25;
[y_025, bt_025, phi_025,  I_025, Q_025, ht_025]= gmsk_mod(akp,M,BT025);


The spectrum of baseband signal which is output of the GMSK modulator As you can see, -65 ... -70dB suppression of higher-frequency spectral components is not achieved at BT=0.25.

Have I mistaken in my simulation? Now I am totally confused :(

or

Should I note something for case BT < 0.3?

Does it mean I have a limit for truncation?

Yes, the truncation length is directly related to the achievable limit for sideband suppression. Further as the Bandwidth-Time (BT) product is reduced, the pulse energy extends further in time, requiring a longer time duration to get the same sideband suppression level. We see this directly by comparing the GMSK Pulse (which is itself a truncated Gaussian convolved with a Rect function in time) for $$BT=0.5$$ and $$BT=0.25$$. Notice specifically how the $$BT=0.25$$ case is wider in time. In my response to this post is shown the expected spectrum (as the Fourier Transform of the base GMSK pulse) for the case of $$BT=0.5$$ and notably it is demonstrated that a 3 symbol pulse duration would be more than sufficient to achieve greater than 100 dB of sideband suppression. Below is the result repeating this for the case of $$BT=0.25$$ where it is clear that a duration of 5 symbols or more would be required to achieve greater than 100 dB of sideband suppression (and if only 3 symbol duration was used, the truncation effects of the Gaussian pulse would limit the suppression to about -55 dB!). As for the second question, I believe the question is:

Have I mistaken in my simulation?

No, the simulation appears correct noting the result that is approximately -80 dB for a modulated waveform is consistent with the predicted spectrum I created from the Fourier Transform of the GMSK base pulse itself.

The direct way to increase sidelobe suppression is to include more of the underlying Gaussian pulse (which itself in true form extends to $$\pm \infty$$, and as we see if we decrease the Bandwidth-Time product, we must increase the total duration in order to maintain a sidelobe suppression level. If for some reason we were restricted in total pulse duration in a given implementation, the sidelobe level can be decreased substantially by multiplying the base pulse with a window (such as a Kaiser window), but this would be at the cost of waveform quality; it would add a deterministic distortion to the Gaussian waveform, and in most cases insignificant compared to a given waveform quality requirement. It is a viable approach as long as it is done with consideration to the waveform quality degradation and managed carefully.

The Python code used is pasted below:

def gpulse(ts, b, fs, t):
# ts: symbol period
# b: 3 dB bandwidth
# (b * ts is the bandwidth-time product)
# fs: sampling rate
# t: time vector
sigma = np.sqrt(np.log(2))/(2*np.pi*b*ts)
rect = np.ones(int(fs/Ts))
h = 1 / (np.sqrt(2*np.pi) * sigma * ts) * np.exp(-t**2 / (2 * sigma**2 * ts**2))
g=  np.convolve(rect/int(fs/ts), h)[int(fs/ts//2-1):int(-fs/ts//2)]
return g

nsyms=8
ts=1
b=0.25
fs=20
b2 =0.5
tsim = np.arange(nsyms * ts * fs)/fs - nsyms * ts/2
pulse = gpulse(ts, b, fs, tsim)
pulse2 = pulse[np.where(np.abs(tsim)<1)]
pulse3 = pulse[np.where(np.abs(tsim)<1.5)]
pulse4 = pulse[np.where(np.abs(tsim)<2)]
pulse5 = pulse[np.where(np.abs(tsim)<2.5)]
pulse6 = pulse[np.where(np.abs(tsim)<3)]
faxis = fft.fftshift(fft.fftfreq(2**16))
fout2 = fft.fftshift(fft.fft(pulse2, 2**16))
fout3 = fft.fftshift(fft.fft(pulse3, 2**16))
fout4 = fft.fftshift(fft.fft(pulse4, 2**16))
fout5 = fft.fftshift(fft.fft(pulse5, 2**16))
fout6 = fft.fftshift(fft.fft(pulse6, 2**16))

plt.figure()
plt.plot(faxis, 20*np.log10(np.abs(fout2)/fs), label= "2 symbols")
plt.plot(faxis, 20*np.log10(np.abs(fout3)/fs), label= "3 symbols")
plt.plot(faxis, 20*np.log10(np.abs(fout4)/fs), label= "4 symbols")
plt.plot(faxis, 20*np.log10(np.abs(fout5)/fs), label= "5 symbols")
plt.plot(faxis, 20*np.log10(np.abs(fout6)/fs), label= "6 symbols")

• very nice answer! I should have written something similar to FrHart's questions on their previous question, but never gotten around to it. It also would've been at most -12dB as good as this! May 24, 2022 at 15:43
• @MarcusMüller thank you! I am sure it would have been just as good or perhaps 12 dB better. May 24, 2022 at 15:47
• @MarcusMüller Many thanks to both of you! May 25, 2022 at 5:56
• as you explain, it is plot is the dB magnitude of zero padded FFT's of truncated pulses. I have already tested with the truncated length 5 symbols my code( precoder, upsampling, convolution with rect pulse) and as Mr Müller comments under my post my spectrum does not look like Gaussian, so I decided I have mistaken somewhere in my simulation May 25, 2022 at 5:59
• The spectrum looks correct and for the parameters listed matches the result I give. May 25, 2022 at 6:04