0% found this document useful (0 votes)
20 views

Problem 3 4 Solution

This MATLAB code calculates path loss for different environments based on carrier frequency, base station antenna height, mobile unit antenna height, and distance from the base station. It runs calculations in a loop for distances from 1 to 30 km, plotting the path loss for large cities, medium cities, suburban areas, and rural areas. It then calculates the path loss exponent for each environment using the calculated path loss at 3 km.

Uploaded by

nguyen8008
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

Problem 3 4 Solution

This MATLAB code calculates path loss for different environments based on carrier frequency, base station antenna height, mobile unit antenna height, and distance from the base station. It runs calculations in a loop for distances from 1 to 30 km, plotting the path loss for large cities, medium cities, suburban areas, and rural areas. It then calculates the path loss exponent for each environment using the calculated path loss at 3 km.

Uploaded by

nguyen8008
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Problem 3& 4 hataloss.

m
clear
% hataloss.m Power loss calculations
carf=input('enter carrier freq. in MHZ...>>');
lcrf=log10(carf);
ht=input('enter the height of BS antenna in meters..>>');%height in meters of the BS
lht=log10(ht);
hr=input('enter the height of the MU antenna in meters..>>');%MU ant. height in meters
lhr=log10(11.75*hr);
N=60;%number of increments for distance
distmax=30;%coverage distance in Kms
for kk=1:1:59;
d(kk)=1+0.5*(kk-1);
fact1=69.55+26.16*lcrf-13.83*lht;
fact2=(44.9-6.55*lht)*log10(d(kk));
fftq=fact1+fact2;
%antenna correction factor MU...
ahr=3.2*(lhr)^2-4.97;% large cities; freq. above 400 MHz
amr=(1.1*lcrf-0.7)*hr-(1.56*lcrf-0.8);
alar(kk)=fftq-ahr;
amed(kk)=fftq-amr;
asub(kk)=amed(kk)-2*(log10(carf/28)).^2-5.4;
arur(kk)=amed(kk)-4.78*(lcrf.^2)+18.33*lcrf-40.94;
end;
subplot(2,2,1);
plot(d,alar);
xlabel('distance Km');
ylabel('power loss dB');
title('large city');
subplot(2,2,2);
plot(d,amed);
%axis([1 30 -140 -60]);
xlabel('distance Km');
ylabel('power loss dB');
title('medium city');
subplot(2,2,3);
Page 6 of 246
plot(d,asub);
%axis([1 30 -140 -60]);
xlabel('distance Km');
ylabel('power loss dB');
title('suburban');
subplot(2,2,4);
plot(d,arur);
%axis([1 30 -140 -60]);
xlabel('distance Km');
ylabel('power loss dB');
title('rural');
%loss at a reference distance of 100 m
Wave=3e8/900e6;%wavelength in meters
PL=10*log10((4*pi*100)^2/Wave^2);%relative loss at 100 meters
d3=d(3)*1000;%distance in meters
%use eqn. (2.19)
denom=10*log10(d3/100);%denominator of eqn. (2.19)
nuLarge=(alar(3)-PL)/denom%nu for large city
nuMed=(amed(3)-PL)/denom%nu for med city
nuSub=(asub(3)-PL)/denom%nu for suburbs city
nuRur=(arur(3)-PL)/denom%nu for rural city

You might also like