Chapter 10: Antennas, Diversity and Link Analysis

Example 10.1, Page 292

In [1]:
import math

#Variable declaration
D=10000;  #in metres
TxEIRP=30;  #Effective Isotropic Radiated Power(EIRP)dBW
lamda=0.2;  #in metres
Pt=10;  #Transmitted power in dBW
Gt=20; #transmitter gain in dBi
Gr=3;  #receiver gain in dBi
Lo=6;#total system lossses in dB
Nf=5;  #noise figure in dB
BW=1.25; #mHz
k=1.38*10**-23;  #Boltzmann constant
T=290;  #temperature in degree kelvin

#Calculations
Lp=20*math.log10(lamda/(4*math.pi*D));   #free space loss
Pr=Lp+Pt+Gt+Gr-Lo;# received power in dBW
No=10*math.log10(k*T);  #Noise density in dBW
NO=No+30;  #factor of '30' to convert from dBW to dBm
Pn=Nf+10*math.log10(BW*10**6)+NO;# noise signal power in dBm
SNR=(Pr+30)-Pn;

#Results
print 'The received signal power is %d dBm'%(round(Pr+30)); #factor of '30' to convert from dBW to dBm
print 'SNR is %d dB'%SNR
The received signal power is -59 dBm
SNR is 49 dB

Example 10.2, Page 293

In [2]:
import math

#Variable declaration
#As we have to use data from Eg 10.1, 
D=10000;  # in metres
TxEIRP=30;  #Effective Isotropic Radiated Power(EIRP)dBW
lamda=0.2;  #in metres
Pt=10;  #trasmitted power in dBW
Gt=20; #transmitter gain in dBi
Gr=3;  #receiver gain in dBi
Lo=6;#total system lossses in dB
Nf=5;  #noise figure in dB
BW=1.25; #mHz
k=1.38*10**-23;  #Boltzmann constant
T=290;  #temperature in degree kelvin
#additional data given in this eg
hr=40.; #height of receiver in metre
ht=2; #trasmittter antenna height in metres

#Calculations
Lp=20*math.log10(hr*ht/D**2);
Pr=Lp+Pt+Gt+Gr-Lo;# received power in dBW
No=10*math.log10(k*T);  #Noise density in dBW
NO=No+30;  #factor of '30' to convert from dBW to dBm
Pn=Nf+10*math.log10(BW*10**6)+NO;# noise signal power in dBm
SNR=(Pr+30)-Pn;

#Result
print 'The received signal power is %d dBm'%(round(Pr+30)); #factor of '30' to convert from dBW to dBm
print 'SNR is %d dB'%SNR
The received signal power is -65 dBm
SNR is 43 dB

Example 10.3, Page 299

In [3]:
import math

#Variable declaration
Pin=12.;  #Input power in watts
Ploss=3;  #resistive losses in Watts
D=5;  #Directivity

#Calculations
Eff=(Pin-Ploss)/Pin;
G=Eff*D;

#Results
print 'Gain of the antenna is %.2f dB = %.2f'%(10*math.log10(G),G);
Gain of the antenna is 5.74 dB = 3.75

Example 10.4, Page 299

In [4]:
#Variable declaration
G=12.; #Gain of antenna in dBi

#Calculations
Theta=101.5/10**(G/10);

#Result
print 'The 3-dB beam width of a linear element antenna is %.1f degrees'%Theta
The 3-dB beam width of a linear element antenna is 6.4 degrees

Example 10.5, Page 299

In [6]:
import math

#Variable declaration
N=12; #number of turns
fr=1.8; #frequency in GHz

#Calculations
lamda=3*10**8/(fr*10**9);
DH=lamda/math.pi;# diameter of helix in milli-meters
S=lamda/4;#turn spacing in millimetres
L=N*S;
G=15*N*S*(DH*math.pi)**2/lamda**3;
Theta=52*lamda/(math.pi*DH)*math.sqrt(lamda/(N*S));

#Results
print 'The optimim diameter is %d mm'%(DH*1000);
print 'Spacing is  %.1f mm'%(S*1000);
print 'Total Length of antenna is %d mm'%(L*1000);
print 'The antenna gain is %.1f dBi'%(10*math.log10(G));
print 'The BeamWidth of antenna is %d degrees'%Theta
The optimim diameter is 53 mm
Spacing is  41.7 mm
Total Length of antenna is 500 mm
The antenna gain is 16.5 dBi
The BeamWidth of antenna is 30 degrees

Example 10.6, Page 305

In [7]:
#Variable declaration
E0=1000.; #average SNR
Eg=10; #threshold value for SNR
M=3;  #3-Branch Combiner
e=2.71828; #Euler's number

#Calculations&Results
x=Eg/E0;
P3=(1-e**(-x))**M; #Considering 3-branch selection combiner
print 'By considering 3-branch selection combiner technique, probability comes to be %.e'%P3;
P1=(1-e**(-x));#M=1;
print ' BY not considering diversity technique, probability comes to be %.e'%P1;
By considering 3-branch selection combiner technique, probability comes to be 1e-06
 BY not considering diversity technique, probability comes to be 1e-02

Example 10.7, Page 312

In [8]:
#Variable declaration
SR=3.84; #spreading rate in Mcps

#Calculations
ChipDur=1./(SR*10**6);
Speed=3*10**8;
Dd=ChipDur*Speed;

#Result
print 'Minimum delay distance to successfully resolve the multipath components and operate the Rake receiver is %d m'%Dd
Minimum delay distance to successfully resolve the multipath components and operate the Rake receiver is 78 m