JPL's Wireless Communication Reference Website

Chapter: Analog and Digital Transmission
Section: Multi-Carrier Modulation, OFDM, Effect of Doppler

MC-CDMA and OFDM with Doppler

Contributed by Jean-Paul Linnartz

The Matlab Code used in this MC-CDMA analysis:

ici.m

fc = 900000000;
v = 20;
c = 300000000;
fm0 = (v / c ) * fc;

N = 8000;
rb = 1000000;

tframe = N /rb;
fsub = 1/tframe;

axis = [];
y0 = [];
y1 = [];
y2 = [];
y3 = [];

for (ii=1:100)
fm = (v / c ) * fc * ii/10;
int0 = 0;
int1 = 0;
int2 = 0;
int3 = 0;
test = 0;

Msamp = 200;
for (i=-Msamp+1:Msamp-1)
f = fc + (i/Msamp) * fm;
fnorm = (f-fc)/fm;
fnorm2 = (f-fc)/fsub;
dop = dopplernorm(fnorm);
spectrum = dop * (sincc(fnorm2))^2;
int0 = int0 + spectrum;
test = test + dop;
spectrum1 = dop * (sincc(1-fnorm2))^2;
int1 = int1 + spectrum1;
spectrum2 = dop * (sincc(2-fnorm2))^2;
int2 = int2 + spectrum2;
spectrum3 = dop * (sincc(3-fnorm2))^2;
int3 = int3 + spectrum3;

end
test = test/( Msamp * pi );
int0 = int0/( Msamp * pi );
int2 = int2/( Msamp * pi );
int3 = int3/( Msamp * pi );
int1 = int1/( Msamp * pi );

xy = fm/fsub;

axis = [axis, xy];
y0 = [y0, int0];
y1 = [y1, int1];
y2 = [y2, int2];
y3 = [y3, int3];

end

semilogy(axis,y0, 'g--',axis,y1, 'r-',axis,y2, 'r-',axis,y3, 'r-');
xlabel('Normalized Doppler [fm/fsub]');
ylabel('Power, Variance of ICI');
text(.1,0.6,'P0');
text(.1,0.06,'P1');
text(1.6,0.06,'P2');
text(2.75,0.06,'P3');

 

%print -dpsc2 ici.ps

%==============================



Received power P0 (green), and the variances P1, P2, and P2 of the ICI (red) versus the normalized Doppler spread l for pT = 1.

MATLAB also uses dopplernorm.m to calculate the doppler

JavaScript

 

 

 

ber.m

Calculates Local-mean BER for BPSK, versus antenna speed for local mean SNR of 10, 20 and 30 dB. Comparison between MC-CDMA and uncoded OFDM

% New file ber_new_test_nov_99.m
% calculte effect of Doppler on MCCDMA and OFDM

 

xaxis = [];
y0 = [];
y1 = [];
y2 = [];
y3 = [];
y4 = [];
y5 = [];
y6 = [];
y7 = [];
y8 = [];

N = 8192;
rb = 9142900;

fc = 4000000000;
% 4 GHz

tframe = N /rb;
fsub = 1/tframe
% fsub = 1.17 kHz ???


for III=0:200

v = 0.2 *III;

c = 300000000;

 

fm = (v / c ) * fc ;
int0 = 0;
int1 = 0;
int2 = 0;
int3 = 0;
test = 0;

if (v > 0)

Msamp = 200;
for (i=-Msamp+1:Msamp-1)
f = fc + (i/Msamp) * fm;
fnorm = (f-fc)/fm;
fnorm2 = (f-fc)/fsub;
dop = dopplernorm(fnorm);
spectrum = dop * (sincc(fnorm2))^2;
int0 = int0 + spectrum;
test = test + dop;
spectrum1 = dop * (sincc(1-fnorm2))^2;
int1 = int1 + spectrum1;
spectrum2 = dop * (sincc(2-fnorm2))^2;
int2 = int2 + spectrum2;
spectrum3 = dop * (sincc(3-fnorm2))^2;
int3 = int3 + spectrum3;

end
test = test/(Msamp * pi );
int0 = int0/(Msamp * pi );
int2 = int2/(Msamp * pi );
int3 = int3/(Msamp * pi );
int1 = int1/(Msamp * pi );

else
int0 = 1;
int1 = 0;
int2 = 0;
int3 = 0;

end;

Ptot = int1 + int2 + int3;
P = int0;

 

xy = fm/fsub;

xy = v;

xaxis = [xaxis, xy];

c = 0.1;
[bw, bw2, ww] = moments_crude(c,P);
M1 = bw^2;
tel = M1 * P;
noem = (bw2 - M1)*P + ww*(Ptot +c);
BER = 0.5 * erfc( sqrt(tel/noem));
y0 = [y0 BER];

c = 0.1;
ctot = c + Ptot;
[bw, bw2, ww] = moments_crude(ctot,P);
M1 = bw^2;
tel = M1 * P;
noem = (bw2 - M1)*P + ww * ctot;
BER = 0.5 * erfc( sqrt(tel/noem));
y6 = [y6 BER];

 

c = 0.01;
[bw, bw2, ww] = moments_crude(c,P);
M1 = bw^2;
tel = M1 * P;
noem = (bw2 - M1)*P + ww*(Ptot +c);
BER = 0.5 * erfc( sqrt(tel/noem));
y1 = [y1 BER];

c = 0.01;
ctot = c + Ptot;
[bw, bw2, ww] = moments_crude(ctot,P);
M1 = bw^2;
tel = M1 * P;
noem = (bw2 - M1)*P + ww * ctot;
BER = 0.5 * erfc( sqrt(tel/noem));
y7 = [y7 BER];

c = 0.001;
[bw, bw2, ww] = moments_crude(c,P);
M1 = bw^2;
tel = M1 * P;
noem = (bw2 - M1)*P + ww*(Ptot +c);
BER = 0.5 * erfc( sqrt(tel/noem));
y2 = [y2 BER];

c = 0.001;
ctot = c + Ptot;
[bw, bw2, ww] = moments_crude(ctot,P);
M1 = bw^2;
tel = M1 * P;
noem = (bw2 - M1)*P + ww * ctot;
BER = 0.5 * erfc( sqrt(tel/noem));
y8 = [y8 BER];

c = 0.001;
BER = 1/2 - (1/2) * sqrt (P/(P + Ptot + c));
y3 = [y3 BER];
c = 0.01;
BER = 1/2 - (1/2) * sqrt (P/(P + Ptot + c));
y4 = [y4 BER];
c = 0.1;
BER = 1/2 - (1/2) * sqrt (P/(P + Ptot + c));
y5 = [y5 BER];

end
semilogy(xaxis,y0, 'y-',xaxis,y1, 'b-',xaxis,y2, 'g-',xaxis,y3,'r:',xaxis,y4,'r:',xaxis,y5, 'r:',xaxis,y6, 'g--',xaxis,y7, 'g--',xaxis,y8, 'g--');
xlabel('Antenna Speed (m/s)');
ylabel('Local-Mean BER');
text(1,0.002,'OFDM');
axis([0 40 0.0000001 1]);
text(3,0.000002,'MC-CDMA');
text(25,0.002,'a, b, c');

 

print -dpsc2 ber.ps

 

 


MATLAB ber.m
uses dopplernorm.m to calculate the doppler

function d = dopplernorm(q)

if (abs(q) <1)
d = 1 / sqrt(1 - q^2);
else
d = 0;
end


uses moments_crude2.m to calculte the multi-user interference in MC-CDMA, as used in various other programs

function [bw1 , mui , ww] = moments_crude2(c,p)

nsamples = 100;
nlength = 30;

%100, 30 werkt OK voor En/N) -30 tot + 80 dB
% 50, 15
csqr = c^2;
csqrt = sqrt(c);
c2p = c/p;
%-------------- M_11 --------------------

if (c2p < 1)
g = c2p;

if (c2p < 0.001)
d1 = - 0.57721566 -log(c2p);
else
a0 = -0.57721566;
a1 = 0.99999193;
a2 = -0.24991055;
a3 = 0.05519968;
a4 = -0.00976004;
a5 = 0.00107857;

g2 = g * g;
g4 = g2*g2;

d1 = a0 + a1*g +a2 * g2 + a3 *g2 * g + a4 * g4 + a5 * g4 * g - log(g);
end

d = g * d1 * exp(g);
int1 = d;

else
int1 = 0;
for I = 1:nlength*nsamples
x = I/nsamples;
x2 = x*x;
int1 = int1 + 1 /(x2+c) * x *exp(-x2/p);
end
int1 = c * int1 *2/(nsamples *p) ;

end
bw1 = 1 - int1;

%-------------- M_22 -----------------

mui = c2p *(1 - int1) - int1^2;

%-------------- M_02 ------------------

int3 = 0;
if (c2p < 1) % good channel

d1 = int1;
ww = (int1 *(1+c2p) - c2p)/c;

else % poor channel
int3 = 0;
overp = 1/p;
for I = 1:nlength*nsamples
x = I/nsamples;
x2 = x*x;
int3 = int3 + x2 * x *exp(-x2 * overp)/(x2+c)^2;
end
int3 = 2 * int3 /(nsamples*p) ;
ww = int3;
end;

 

 

 



JavaScript

 

capacity.m


calculates the OFDM capacity per subcarrier per dimension as 1/2 log2(1 + V P0Ts/N0)

function d = capacity(g)

d = 0.5 * log2(1 + 2 *g);

 

capray.m


function d = capray(gi)

a0 = -0.57721566;
a1 = 0.99999193;
a2 = -0.24991055;
a3 = 0.05519968;
a4 = -0.00976004;
a5 = 0.00107857;

g = 1/(2*gi);

if (g>1)
g
end;

g2 = g * g;
g4 = g2*g2;

d1 = a0 + a1*g +a2 * g2 + a3 *g2 * g + a4 * g4 + a5 * g4 * g - log(g);

d = d1 * exp(g)/(2*log(2));

%Abramowitz p 231 eq 5.1.53
%5th edition 4.331, p. 602.


calculates the capacity of the Rayleigh fading channel as

 

 

entropy.m


xaxis = [];
y0 = [];
y1 = [];
y2 = [];
y3 = [];
y4 = [];
y5 = [];
y6 = [];
y7 = [];

N = 8192;
rb = 9142900;

fc = 4000000000;
% 4 GHz

tframe = N /rb;
fsub = 1/tframe
% fsub = 1.17 kHz ???


for III=0:200

v = 0.2 *III;

c = 300000000;

 

fm = (v / c ) * fc ;
int0 = 0;
int1 = 0;
int2 = 0;
int3 = 0;
test = 0;

if (v > 0)

Msamp = 200;
for (i=-Msamp+1:Msamp-1)
f = fc + (i/Msamp) * fm;
fnorm = (f-fc)/fm;
fnorm2 = (f-fc)/fsub;
dop = dopplernorm(fnorm);
spectrum = dop * (sincc(fnorm2))^2;
int0 = int0 + spectrum;
test = test + dop;
spectrum1 = dop * (sincc(1-fnorm2))^2;
int1 = int1 + spectrum1;
spectrum2 = dop * (sincc(2-fnorm2))^2;
int2 = int2 + spectrum2;
spectrum3 = dop * (sincc(3-fnorm2))^2;
int3 = int3 + spectrum3;

end
% test = test/(2 * Msamp * pi );
test = test/(Msamp * pi );
int0 = int0/(Msamp * pi );
int2 = int2/(Msamp * pi );
int3 = int3/(Msamp * pi );
int1 = int1/(Msamp * pi );

else
int0 = 1;
int1 = 0;
int2 = 0;
int3 = 0;

end;

Ptot = int1 + int2 + int3; %total ICI due to Doppler
P = int0;

 

xy = fm/fsub;

xy = v;

xaxis = [xaxis, xy];

c = 0.1;
ctot = c + Ptot;
[bw, mui, ww] = moments_crude2(ctot,P);
M1 = bw^2;
tel = M1 * P;
noem = (mui)*P + ww * ctot;
cap = capacity(tel/noem);
y0 = [y0 cap];

c = 0.01;
ctot = c + Ptot;
[bw, mui, ww] = moments_crude2(ctot,P);
M1 = bw^2;
tel = M1 * P;
noem = (mui)*P + ww * ctot;
cap = capacity(tel/noem);
y1 = [y1 cap];

c = 0.001;
ctot = c + Ptot;
[bw, mui ww] = moments_crude2(ctot,P);
M1 = bw^2;
tel = M1 * P;
noem = (mui)*P + ww * ctot;
cap = capacity(tel/noem);
y2 = [y2 cap];

 

c = 0.001;
%BER = 1/2 - (1/2) * sqrt (P/(P + Ptot + c));
cap = capray(P/(Ptot + c));
y3 = [y3 cap];

c = 0.01;
%BER = 1/2 - (1/2) * sqrt (P/(P + Ptot + c));
cap = capray(P/(Ptot + c));
y4 = [y4 cap];

c = 0.1;
%BER = 1/2 - (1/2) * sqrt (P/(P + Ptot + c));
cap = capray(P/(Ptot + c));
y5 = [y5 cap];

end

plot(xaxis,y0, 'y-',xaxis,y1, 'b-',xaxis,y2, 'g-',xaxis,y3,'r--',xaxis,y4,'r--',xaxis,y5, 'r--');

%semilogy(xaxis,y0, 'y-',xaxis,y1, 'b-',xaxis,y2, 'g-',xaxis,y3, 'r.');
xlabel('Antenna Speed (m/s)');
ylabel('bits per dimension');
text(1,5.05,'10 dB');
text(1,3.5,'20 dB');
text(1,1.94,'30 dB');

text(1,4.1,'10 dB');
text(1,2.8,'20 dB');
text(1,1.64,'30 dB');

text(25,4, ' - - OFDM');
text(25,3.7,' - MC-CDMA');

 

%text(3,0.000002,'MC-CDMA');
%text(25,0.002,'a, b, c');

print -dpsc2 capacity.ps

Capacity in bits per dimension for OFDM and MC-CDMA versus antenna speed.

 

 

entropy_no_doppler.m

Calculates the capacity for a fading channel with OFDM and with MC-CDMA

%entropy no Doppler.m

xaxis = [];
y0 = [];
y1 = [];
y2 = [];
y3 = [];
y4 = [];
y5 = [];
y6 = [];
y7 = [];

for III=-15:40

xy = 10^(III/10);
% xy = En/N0

xaxis = [xaxis, III];

cap = capacity(xy);
y2 = [y2 cap];

int = 0;
for ii = 1:500
x = ii/100;
int = int + exp(-x) * capacity(x * xy);
end
int = int/100;
y4 = [y4 int];

cap = capray(xy);
y5 = [y5 cap];

 

P =1;
ctot = 1/xy;
[bw, mui, ww] = moments_crude2(ctot,P);
M1 = bw^2;
tel = M1 * P;
noem = mui*P + ww * ctot;
cap = capacity(tel/noem);
y0 = [y0 cap];

 

end

plot(xaxis,y0, 'b*',xaxis,y2, 'g-',xaxis,y4,'r.',xaxis,y5, 'r-');
xlabel('Local-mean En/N0 (dB)');
ylabel('Capacity: Bits per Subcarrier');
text(10,1, '-* : Rayleigh');
text(10,0.6,' * : MC-CDMA');
text(10,0.2,' - : LTI');

%text(20,1.5,'- math, * numerical');
%semilogy(xaxis,y0, 'y-',xaxis,y1, 'b-',xaxis,y2, 'g-',xaxis,y3, 'r.');
axis([-5 40 0 7]);

text(3,0.000002,'MC-CDMA');
text(25,0.002,'a, b, c');

 

uses capacity.m and capray.m

 

 

mccdma_gain.m

xaxis = [];
y0 = [];
y1 = [];
y2 = [];
y3 = [];
y4 = [];
y5 = [];
y6 = [];
y7 = [];

for III=-6:40
II = III * 2;
xy = 10^(II/10);
% xy = En/N0

xaxis = [xaxis, II];
cap1 = xy;
cap1 = 10 * log10(cap1);
y7 = [y7 cap1];

 

P = 1;
ctot = 1/xy;
[bw, mui, ww] = moments_crude2(ctot,1);
M1 = bw^2;
tel = M1 * P;
noem1 = ww * ctot;
noem2 = mui * P;

if (mui < 0)
xy;
end;

noem = noem1 + noem2;

cap0 = 10 * log10(tel/noem);
cap0 = cap0 - cap1;
y0 = [y0 cap0];

cap = 10 * log10(tel/noem1);
cap = cap - cap1;
y1 = [y1 cap];

cap2 = 10 * log10(tel/noem2);
cap2 = cap2 - cap1;
y2 = [y2 cap2];

end

plot(xaxis,y0,'r-',xaxis,y1,'b-.',xaxis,y2,'g--');

xlabel('Local-mean En/N0 after FFT ');
ylabel('EN/N0 per MC-CDMA symbol');

text(-10,-5, 'MUI + Noise');
text(21,-5,'Noise');
text(21,2,'MUI');

 

MC-CDMA figure of merit z in dB versus the local-mean SNR on Rayleigh channel. MATLAB

 

moments_crude2.m

function [bw1 , mui , ww] = moments_crude2(c,p)

nsamples = 100;
nlength = 30;

%100, 30 werkt OK voor En/N) -30 tot + 80 dB
% 50, 15
csqr = c^2;
csqrt = sqrt(c);
c2p = c/p;
%-------------- M_11 --------------------

if (c2p < 1)
g = c2p;

if (c2p < 0.001)
d1 = - 0.57721566 -log(c2p);
else
a0 = -0.57721566;
a1 = 0.99999193;
a2 = -0.24991055;
a3 = 0.05519968;
a4 = -0.00976004;
a5 = 0.00107857;

g2 = g * g;
g4 = g2*g2;

d1 = a0 + a1*g +a2 * g2 + a3 *g2 * g + a4 * g4 + a5 * g4 * g - log(g);
end

d = g * d1 * exp(g);
int1 = d;

else
int1 = 0;
for I = 1:nlength*nsamples
x = I/nsamples;
x2 = x*x;
int1 = int1 + 1 /(x2+c) * x *exp(-x2/p);
end
int1 = c * int1 *2/(nsamples *p) ;

end
bw1 = 1 - int1;

%-------------- M_22 -----------------

mui = c2p *(1 - int1) - int1^2;

%-------------- M_02 ------------------

int3 = 0;
if (c2p < 1) % good channel

d1 = int1;
ww = (int1 *(1+c2p) - c2p)/c;

else % poor channel
int3 = 0;
overp = 1/p;
for I = 1:nlength*nsamples
x = I/nsamples;
x2 = x*x;
int3 = int3 + x2 * x *exp(-x2 * overp)/(x2+c)^2;
end
int3 = 2 * int3 /(nsamples*p) ;
ww = int3;
end;

 

Calcultes the multi-user interference in MC-CDMA, as used in various other programs

 

 

For more textual details we refer to the following subsections:

  1. Formulation of the Model,
    Average ICI power
  2. Effect of Doppler on on BER for OFDM
  3. Receiver Model for MC-CDMA
  4. Effect of Doppler on BER for MC-CDMA
  5. Numerical and Simulation Results
  6. Channel Capacity A comparison between OFDM and MC-CDMA
  7. References used in the above pages

 



JPL's Wireless Communication Reference Website © Jean-Paul M.G. Linnartz, 2001.

Publications for scientific reference:

PDF J.P.M.G. Linnartz, "Performance Analysis of Synchronous MC-CDMA in mobile Rayleigh channels with both Delay and Doppler spreads", IEEE VT, Vol. 50, No. 6, Nov. 2001, pp 1375-1387.

450k PDF A. Gorokhov, J.P.M.G. Linnartz, "Robust OFDM receivers for dispersive time varying channels: equalization and channel acquisition", IEEE Transactions on Communications, Vol. 52, No. 4, april 2004, pp. 572-583

PDF 500k S. Tomasin, A. Gorokhov H. Yang, J.P.M.G. Linnartz, "Iterative Interference cancellation and channel estimation for mobile OFDM", IEEE Transaction in Wireless Communication, Vol. 4, No. 1, Jan. 2005, pp. 238-245.