def test_single_location(self): # Location of the receiver ground stations lat = 41.39 lon = -71.05 # Link parameters el = 60 # Elevation angle equal to 60 degrees f = 22.5 * itur.u.GHz # Frequency equal to 22.5 GHz D = 1 * itur.u.m # Receiver antenna diameter of 1 m p = 0.1 # We compute values exceeded during 0.1 % of # the average year # Compute atmospheric parameters hs = itur.topographic_altitude(lat, lon) T = itur.surface_mean_temperature(lat, lon) P = itur.models.itu835.pressure(lat, hs) rho_p = itur.surface_water_vapour_density(lat, lon, p, hs) rho_sa = itur.models.itu835.water_vapour_density(lat, hs) T_sa = itur.models.itu835.temperature(lat, hs) V = itur.models.itu836.total_water_vapour_content(lat, lon, p, hs) # Compute rain and cloud-related parameters R_prob = itur.models.itu618.rain_attenuation_probability( lat, lon, el, hs) R_pct_prob = itur.models.itu837.rainfall_probability(lat, lon) R001 = itur.models.itu837.rainfall_rate(lat, lon, p) h_0 = itur.models.itu839.isoterm_0(lat, lon) h_rain = itur.models.itu839.rain_height(lat, lon) L_red = itur.models.itu840.columnar_content_reduced_liquid(lat, lon, p) A_w = itur.models.itu676.zenit_water_vapour_attenuation(lat, lon, p, f, h=hs) # Compute attenuation values A_g = itur.gaseous_attenuation_slant_path(f, el, rho_p, P, T) A_r = itur.rain_attenuation(lat, lon, f, el, hs=hs, p=p) A_c = itur.cloud_attenuation(lat, lon, el, f, p) A_s = itur.scintillation_attenuation(lat, lon, f, el, p, D) A_t = itur.atmospheric_attenuation_slant_path(lat, lon, f, el, p, D)
def ITU_loss(self, frequency, link, location=[41.39, -71.05], percentage=0.1): # calculate the matching dish diameter - assume efficiency of 65% if link == 'downlink': effective_diameter = (scipy.constants.c / (np.pi * frequency)) * np.sqrt( 10**(self.gs_rx_antenna_gain / 10) / 0.65) * itur.u.m else: effective_diameter = (scipy.constants.c / (np.pi * frequency)) * np.sqrt( 10**(self.gs_tx_antenna_gain / 10) / 0.65) * itur.u.m elevation = self.elevation # convert frequency to GHz frequency_ghz = (frequency / 1e9) * itur.u.GHz # Compute atmospheric parameters hs = itur.topographic_altitude(41.39, -71.05) T = itur.surface_mean_temperature(41.39, -71.05) P = itur.models.itu835.pressure(41.39, hs) rho_p = itur.surface_water_vapour_density(location[0], location[1], percentage, hs) rho_sa = itur.models.itu835.water_vapour_density(location[0], hs) T_sa = itur.models.itu835.temperature(location[0], hs) V = itur.models.itu836.total_water_vapour_content( location[0], location[1], percentage, hs) # Compute rain and cloud-related parameters R_prob = itur.models.itu618.rain_attenuation_probability( location[0], location[1], elevation, hs) R_pct_prob = itur.models.itu837.rainfall_probability( location[0], location[1]) R001 = itur.models.itu837.rainfall_rate(location[0], location[1], percentage) h_0 = itur.models.itu839.isoterm_0(location[0], location[1]) h_rain = itur.models.itu839.rain_height(location[0], location[1]) L_red = itur.models.itu840.columnar_content_reduced_liquid( location[0], location[1], percentage) A_w = itur.models.itu676.zenit_water_vapour_attenuation(location[0], location[1], percentage, frequency_ghz, h=hs) # Compute attenuation values A_g = itur.gaseous_attenuation_slant_path(frequency_ghz, elevation, rho_p, P, T) A_r = itur.rain_attenuation(location[0], location[1], frequency_ghz, elevation, hs=hs, p=percentage) A_c = itur.cloud_attenuation(location[0], location[1], elevation, frequency_ghz, percentage) A_s = itur.scintillation_attenuation(location[0], location[1], frequency_ghz, elevation, percentage, effective_diameter) A_t = itur.atmospheric_attenuation_slant_path(location[0], location[1], frequency_ghz, elevation, percentage, effective_diameter) # rain attenuation plus all other attenuations rain = A_r atmosphere = A_g + A_c + A_s return float(rain.value), float(atmosphere.value)
import itur # Location of the receiver ground stations lat = 41.39 lon = -71.05 # Link parameters el = 60 # Elevation angle equal to 60 degrees f = 22.5 * itur.u.GHz # Frequency equal to 22.5 GHz D = 1 * itur.u.m # Receiver antenna diameter of 1 m p = 0.1 # We compute values exceeded during 0.1 % of the average # year # Compute atmospheric parameters hs = itur.topographic_altitude(lat, lon) T = itur.surface_mean_temperature(lat, lon) P = itur.models.itu835.pressure(lat, hs) rho_p = itur.surface_water_vapour_density(lat, lon, p, hs) rho_sa = itur.models.itu835.water_vapour_density(lat, hs) T_sa = itur.models.itu835.temperature(lat, hs) V = itur.models.itu836.total_water_vapour_content(lat, lon, p, hs) print(('The ITU recommendations predict the following values for the point ' 'located at coordinates ({0}, {1})').format(lat, lon)) print( ' - Height above the sea level [ITU-R P.1511] {0:.1f}'. format(hs.to(itur.u.m))) print( ' - Surface mean temperature [ITU-R P.1510] {0:.1f}'.