%Copyright WaVe 2012
%Friis free space path loss
%rx = -90; %dBm
f = 86; %freq in Ghz
%gt = 1; %transmit antenna gain
%gr = 1; %receive antenna gain
r = 35786; %vertical distance between ES and SS in km
El = 49.8; %elevation
El = El*pi/180

r = r.*1000/sin(El);
f = f.*10^9;
lambda = (3*10^8)./f;
pathloss = 20.*log10((4.*pi)./lambda)+ 20.*log10(r) %path loss
