Changeset 1726
- Timestamp:
- 04/28/10 11:26:58 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/python/opacity.py
r1725 r1726 19 19 """ 20 20 This class implements opacity/atmospheric brightness temperature model 21 equivalent to the model available in MIRIAD. The actual math is a 21 equivalent to the model available in MIRIAD. The actual math is a 22 22 convertion of the Fortran code written by Bob Sault for MIRIAD. 23 It implements a simple model of the atmosphere and Liebe's model (1985) 23 It implements a simple model of the atmosphere and Liebe's model (1985) 24 24 of the complex refractive index of air. 25 25 26 26 The model of the atmosphere is one with an exponential fall-off in 27 the water vapour content (scale height of 1540 m) and a temperature 28 lapse rate of 6.5 mK/m. Otherwise the atmosphere obeys the ideal gas 27 the water vapour content (scale height of 1540 m) and a temperature 28 lapse rate of 6.5 mK/m. Otherwise the atmosphere obeys the ideal gas 29 29 equation and hydrostatic equilibrium. 30 30 31 Note, the model includes atmospheric lines up to 800 GHz, but was not 32 rigorously tested above 100 GHz and for instruments located at 31 Note, the model includes atmospheric lines up to 800 GHz, but was not 32 rigorously tested above 100 GHz and for instruments located at 33 33 a significant elevation. For high-elevation sites it may be necessary to 34 34 adjust scale height and lapse rate. … … 36 36 Parameters: 37 37 temperature: air temperature at the observatory (K) 38 pressure: air pressure at the sea level if the observatory 39 elevation is set to non-zero value (note, by 38 pressure: air pressure at the sea level if the observatory 39 elevation is set to non-zero value (note, by 40 40 default is set to 700m) or at the observatory 41 ground level if the elevation is set to 0. (The 41 ground level if the elevation is set to 0. (The 42 42 value is in Pascals or hPa, default 101325 Pa 43 humidity: air humidity at the observatory (fractional), 43 humidity: air humidity at the observatory (fractional), 44 44 default is 0.5 45 45 elevation: observatory elevation about sea level (in meters) 46 46 """ 47 47 self._atm = atmosphere(temp, self._to_pascals(pressure), humidity) 48 self.set_observatory_elevation(elevation) :48 self.set_observatory_elevation(elevation) 49 49 50 50 def get_opacities(self, freq, elevation=None): … … 79 79 Parameters: 80 80 temperature: air temperature at the observatory (K) 81 pressure: air pressure at the sea level if the observatory 82 elevation is set to non-zero value (note, by 81 pressure: air pressure at the sea level if the observatory 82 elevation is set to non-zero value (note, by 83 83 default is set to 700m) or at the observatory 84 ground level if the elevation is set to 0. (The 84 ground level if the elevation is set to 0. (The 85 85 value is in Pascals or hPa, default 101325 Pa 86 humidity: air humidity at the observatory (fractional), 86 humidity: air humidity at the observatory (fractional), 87 87 default is 0.5 88 88 """ … … 90 90 self._atm.set_weather(temperature, pressure, humidity) 91 91 92 def set_observatory_elevation(self, elevation :92 def set_observatory_elevation(self, elevation): 93 93 """Update the model using the given the observatory elevation 94 94 Parameters: … … 211 211 r"$\tau_{model}=%0.2f$" % om.get_opacities(freq*1e9), 212 212 color='grey') 213 213 214 214 pylab.title("IF%d : %s" % (ino, freqstr)) 215 215
Note:
See TracChangeset
for help on using the changeset viewer.