atmosphere

class atmosphere[source]

Atmosphere model

Methods Summary

addSpectralWindow

Add a new spectral window, uniformly sampled, this spectral window having no sideband.

atmosphere

This is used to construct an atmosphere tool.

close

Destroy the atmosphere tool

done

Destroy the atmosphere tool

getAbsCOLines

Get CO lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

getAbsDryCont

Get Dry Continuum Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

getAbsH2OCont

Get H2O continuum Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

getAbsH2OLines

Accessor to get H2O lines Absorption Coefficient at layer nl, spectral window spwid and channel nf.

getAbsN2OLines

Get N2O lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

getAbsO2Lines

Get O2 lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

getAbsO3Lines

Get O3 lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

getAbsTotalDry

Get total dry Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

getAbsTotalWet

Get total wet absorption coefficient at layer nl, spectral window spwid and frequency channel nf

getAirMass

Accessor to get airmass.

getAtmVersion

Returns the version of ATM library implemented to this tool.

getAverageTebbSky

Returns the average Equivalent Blackbody Temperature in spectral window spwid, for the current conditions and a perfect sky coupling.

getAverageTrjSky

Returns the average Rayleigh-Jeans Temperature in spectral window spwid, for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

getBandwidth

Get the frequency range encompassing the list of frequency grid points for the specified spectral window.

getBasicAtmParms

Gets the current basic atmospheric parameters of the model.

getCOLinesOpacity

Get the integrated CO Lines Opacity for one channel in a band.

getCOLinesPathLength

Retrieve the integrated Atmospheric Path length (due to CO Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

getChanFreq

Return the channel frequency for a given grid point for the specified spectral window.

getChanNum

Return the channel number for given frequency in the specified spectral window relative to the reference channel number.

getChanSep

Return the channel separation of the given spectral window

getDispersivePathLength

Retrieve the integrated zenith H2O Atmospheric Path length (Dispersive part) along the atmospheric path corresponding to the user water column for channel nc in spectral window spwid.

getDispersivePhaseDelay

Get the integrated zenith H2O Atmospheric Phase Delay (Dispersive part) for the current conditions, for channel number nc of spectral window spwid.

getDispersiveWetPathLength

Retrieve the integrated wet Atmospheric Path length (Dispersive part) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

getDispersiveWetPhaseDelay

Function to retrievethe the integrated Atmospheric Phase Delay (Dispersive part) along the atmospheric path corresponding to the 1st guess water column.

getDryContOpacity

Get the integrated Dry Continuum Opacity for one channel in a band.

getDryOpacity

Get the integrated Dry Opacity for one channel in a band.

getDryOpacitySpec

Get the integrated Dry opacity along the atmospheric path on each channel in a band.

getGroundWH2O

Method to get the zenith column of water vapor.

getH2OContOpacity

Get the integrated zenith H2O Continuum Opacity for one channel in a band.

getH2OLinesOpacity

Get the integrated zenith H2O Lines Opacity for one channel in a band.

getMaxFreq

Get highest frequency channel for the specified spectral window.

getMinFreq

Get lowest frequency channel for the specified spectral window.

getN2OLinesOpacity

Get the integrated N2O Lines Opacity for one channel in a band.

getN2OLinesPathLength

Retrieve the integrated Atmospheric Path length (due to N2O Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

getNonDispersiveDryPathLength

Retrieve the integrated dry Atmospheric Path length (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

getNonDispersiveDryPhaseDelay

Function to retrieve the integrated dry Atmospheric Phase Delay (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column.

getNonDispersivePathLength

Get the integrated zenith H2O Atmospheric Path length (Non-Dispersive part) for the current conditions, for channel nc in spectral window spwid.

getNonDispersivePhaseDelay

Get the integrated zenith H2O Atmospheric Phase Delay (Non-Dispersive part) for the current conditions, for channel number nc of spectral window spwid.

getNonDispersiveWetPathLength

Retrieve the integrated wet Atmospheric Path length (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

getNonDispersiveWetPhaseDelay

Function to retrieve the integrated wet Atmospheric Phase Delay (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column.

getNumChan

Return the number of channels of ith band ( passes in as parameter ).

getNumLayers

Returns the number of layers in the atmospheric profile.

getNumSpectralWindows

Get number of spectral windows

getO2LinesOpacity

Get the integrated O2 Lines Opacity for one channel in a band.

getO2LinesPathLength

Retrieve the integrated Atmospheric Path length (due to O2 Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

getO3LinesOpacity

Get the integrated O3 Lines Opacity for one channel in a band.

getO3LinesPathLength

Retrieve the integrated Atmospheric Path length (due to O3 Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

getProfile

Get the atmospheric profile.

getRefChan

Return the reference channel of the given spectral window

getRefFreq

Return the reference frequency of the given spectral window

getSkyBackgroundTemperature

Get the sky background temperature

getSpectralWindow

Return the spectral grid for the specified spectral window.

getTebbSky

Gets the Equivalent Blackbody Temperature in spectral window spwid and channel nc, for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

getTebbSkySpec

Gets the Equivalent Blackbody Temperatures in a spectral window spwid for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

getTrjSky

Gets the Rayleigh-Jeans Temperature in spectral window spwid and channel nc, for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

getTrjSkySpec

Gets the Rayleigh-Jeans Temperatures in a spectral window spwid for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

getUserWH2O

Get user zenith water vapor column for forward radiative transfer calculations.

getWetOpacity

Get the integrated zenith Wet Opacity for one channel in a band.

getWetOpacitySpec

Getthe integrated zenith Wet Opacity along the atmospheric path on each channel in a band.

initAtmProfile

An atmospheric profile is composed of 4 quantities as a function of altitude z:

initSpectralWindow

function that defines a spectral window, computes absorption and emmision coefficients for this window, using the atmospheric model profile.

listAtmosphereTypes

Returns a list of index numbers and corresponding atmosphere types used by the ATM library.

setAirMass

Setter for air mass in SkyStatus without performing water vapor retrieval.

setSkyBackgroundTemperature

Set sky background temperature in SkyStatus without performing water vapor retrieval

setUserWH2O

Set user zenith water vapor column for forward radiative transfer calculations.

updateAtmProfile

This is used to update the atmosphere tool when basic atmospheric parameters.change.

addSpectralWindow(fCenter=350, fWidth=0.008, fRes=0.002)[source]

Add a new spectral window, uniformly sampled, this spectral window having no sideband.

Parameters

  • fCenter (double=350) - frequencies - Quantum with a double value and unit of frequency, GHz

  • fWidth (double=0.008) - frequency width of band - Quantum with a double value and unit of frequency, GHz

  • fRes (double=0.002) - resolution inside band - Quantum with a double value and unit frequency, GHz

Returns

int

Examples

fC2 = qa.quantity(350.0, 'GHz')
fW2 = qa.quantity(0.008, 'GHz')
fR2 = qa.quantity(0.002, 'GHz')
nc = at.addSpectralWindow(fC2, fW2, fR2)
print "New spectral window has ", nc, " channels"
atmosphere()[source]

This is used to construct an atmosphere tool.

close()[source]

Destroy the atmosphere tool

done()[source]

Destroy the atmosphere tool

getAbsCOLines(nl='', nf=0, spwid=0)[source]

Get CO lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsCOLines(0, 0, 0)
print "CO lines absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsDryCont(nl='', nf=0, spwid=0)[source]

Get Dry Continuum Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsDryCont(0, 0, 0)
print "Dry Continuum absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsH2OCont(nl='', nf=0, spwid=0)[source]

Get H2O continuum Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsH2OCont(0, 0, 0)
print "H2OCont absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsH2OLines(nl='', nf=0, spwid=0)[source]

Accessor to get H2O lines Absorption Coefficient at layer nl, spectral window spwid and channel nf.

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsH2OLines(0, 0, 0)
print "H2O lines absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsN2OLines(nl='', nf=0, spwid=0)[source]

Get N2O lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsN2OLines(0, 0, 0)
print "N2O lines absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsO2Lines(nl='', nf=0, spwid=0)[source]

Get O2 lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsO2Lines(0, 0, 0)
print "O2 lines absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsO3Lines(nl='', nf=0, spwid=0)[source]

Get O3 lines Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsO3Lines(0, 0, 0)
print "O3 lines absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsTotalDry(nl='', nf=0, spwid=0)[source]

Get total dry Absorption Coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsTotalDry(0, 0, 0)
print "Total dry absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAbsTotalWet(nl='', nf=0, spwid=0)[source]

Get total wet absorption coefficient at layer nl, spectral window spwid and frequency channel nf

Parameters

  • nl (int='') - atmospheric layer number. The value must be >= 0.

  • nf (int=0) - frequency channnel number. The value must be >= 0.

  • spwid (int=0) - spectral window id. The value must be >= 0.

Returns

Quantity

Examples

ac = at.getAbsTotalWet(0, 0, 0)
print "Total wet absorption coefficient for layer 0, channel 0 is ", ac['value'][0], ac['unit']
getAirMass()[source]

Accessor to get airmass.

getAtmVersion()[source]

Returns the version of ATM library implemented to this tool.

getAverageTebbSky(spwid=0, wh2o=-1)[source]

Returns the average Equivalent Blackbody Temperature in spectral window spwid, for the current conditions and a perfect sky coupling.

Parameters

  • spwid (int=0) - Spectral window (0-based). The value must be >= 0.

  • wh2o (double=-1) - User specified water column length in mm. Default is not to use wh2o.

Returns

Quantity

Examples

wh2o = qa.quantity(0.4,'mm')
print "(INPUT CHANGE) water vapor column:", wh2o['value'], wh2o['unit']
print "(NEW OUTPUT) T_EBB =", at.getAverageTebbSky(0,wh2o)['value'][0], at.getAverageTebbSky(0,wh2o)['unit']
getAverageTrjSky(spwid=0, wh2o=-1)[source]

Returns the average Rayleigh-Jeans Temperature in spectral window spwid, for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

Parameters

  • spwid (int=0) - Spectral window (0-based). The value must be >= 0.

  • wh2o (double=-1) - User specified water column length in mm. Default is not to use wh2o.

Returns

Quantity

Examples

wh2o = qa.quantity(0.4,'mm')
print "(INPUT CHANGE) water vapor column:", wh2o['value'], wh2o['unit']
print "(NEW OUTPUT) T_RJ =", at.getAverageTrjSky(0,wh2o)['value'][0], at.getAverageTrjSky(0,wh2o)['unit']
getBandwidth(spwid=0)[source]

Get the frequency range encompassing the list of frequency grid points for the specified spectral window.

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

print "Total bandwidth retrieved: ", at.getBandwidth()['value'][0], at.getBandwidth()['unit']
getBasicAtmParms()[source]

Gets the current basic atmospheric parameters of the model.

getCOLinesOpacity(nc=-1, spwid=0)[source]

Get the integrated CO Lines Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total CO Lines Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getCOLinesOpacity()
getCOLinesPathLength(nc=-1, spwid=0)[source]

Retrieve the integrated Atmospheric Path length (due to CO Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

getChanFreq(chanNum=0, spwid=0)[source]

Return the channel frequency for a given grid point for the specified spectral window.

Parameters

  • chanNum (int=0) - Int standing for channel number (0-based). The value must be >= 0.

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

for spwid in range(at.getNumSpectralWindows()):
        numCh = at.getNumChan(spwid)
        print "Spectral window ", spwid, " has ", numCh, " frequency channels"
        for n in range(numCh):
                freq = at.getChanFreq(n, spwid)
                print "Channel ", n, " Frequency:", freq['value'][0], freq['unit']
getChanNum(freq='', spwid=0)[source]

Return the channel number for given frequency in the specified spectral window relative to the reference channel number.

Parameters

  • freq (double='') - Frequency

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

# List current spectral window setting of SPW0
at.getRefFreq()['value'][0], at.getRefFreq()['unit']
# (90.0, 'GHz')
print at.getChanSep()['value'][0], at.getChanSep()['unit']
# 10.0 MHz
at.getRefChan()
# 32

# Get grid positions
at.getChanNum(qa.quantity(90., 'GHz'))
# 0.0

at.getChanNum(qa.quantity(90., 'GHz'), 0)
# 0.0

at.getChanNum(qa.quantity(90.08, 'GHz'), 0)
# 8.0

at.getChanNum(qa.quantity(89.985, 'GHz'), 0)
# -1.5

at.getChanNum(qa.quantity(89.98,'GHz'), 0)
# -2.0
getChanSep(spwid=0)[source]

Return the channel separation of the given spectral window

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

cs = at.getChanSep()
print "Channel separation retrieved: ", cs['value'][0], cs['unit']
getDispersivePathLength(nc=-1, spwid=0)[source]

Retrieve the integrated zenith H2O Atmospheric Path length (Dispersive part) along the atmospheric path corresponding to the user water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getUserWH2O()
nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
nfR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total Dispersive Delay at ", fC['value'][0], fC['unit'], " for 1.0 air mass: ",\
      at.getDispersivePathLength()['value'][0] /  w['value'][0], " meters per mm of water vapor"
print "(",100*(at.getDispersivePathLength()['value'][0] /  w['value'][0])/(at.getNonDispersivePathLength()['value'][0] / w['value'][0]),\
      "% of the Non-dispersive one )"
getDispersivePhaseDelay(nc=-1, spwid=0)[source]

Get the integrated zenith H2O Atmospheric Phase Delay (Dispersive part) for the current conditions, for channel number nc of spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getUserWH2O()
numSpw = at.getNumSpectralWindows()
for spwid in range(numSpw):
        numCh = at.getNumChan(spwid)
        print "Spectral window ", spwid, " has ", numCh, " frequency channels"
        for n in range(numCh):
                freq = at.getChanFreq(n, spwid)
                print "Total Dispersive Phase Delay at ",freq['value'][0], freq['unit'], " for 1.0 air mass: ",\
                      (at.getDispersivePhaseDelay(n, spwid)['value'][0])/(w['value'][0])," degrees per mm of water vapor (", \
                      ((100*at.getDispersivePhaseDelay(n, spwid)['value'][0])/(w['value'][0]))/(at.getNonDispersivePhaseDelay(n,spwid)['value'][0]/w['value'][0]),\
                      "% of the Non-dispersive one )"
getDispersiveWetPathLength(nc=-1, spwid=0)[source]

Retrieve the integrated wet Atmospheric Path length (Dispersive part) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getGroundWH2O()
nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
nfR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total Dispersive Delay at ", fC['value'][0], fC['unit'], " for 1.0 air mass: ",\
      at.getDispersiveWetPathLength()['value'][0] /  w['value'][0], " meters per mm of water vapor"
print "(",100*(at.getDispersiveWetPathLength()['value'][0] /  w['value'][0])/(at.getNonDispersiveWetPathLength()['value'][0] / w['value'][0]),\
      "% of the Non-dispersive one )"
getDispersiveWetPhaseDelay(nc=-1, spwid=0)[source]

Function to retrievethe the integrated Atmospheric Phase Delay (Dispersive part) along the atmospheric path corresponding to the 1st guess water column.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getUserWH2O()
numSpw = at.getNumSpectralWindows()
for spwid in range(numSpw):
        numCh = at.getNumChan(spwid)
        print "Spectral window ", spwid, " has ", numCh, " frequency channels"
        for n in range(numCh):
                freq = at.getChanFreq(n, spwid)
                print "Total Dispersive Wet Phase Delay at ", freq['value'][0], freq['unit'], " for 1.0 air mass: ",\
                      (at.getDispersiveWetPhaseDelay(n, spwid)['value'][0])/(w['value'][0]), " degrees per mm of water vapor (",\
                      ((100*at.getDispersiveWetPhaseDelay(n, spwid)['value'][0])/(w['value'][0]))/(at.getNonDispersiveWetPhaseDelay(n,spwid)['value'][0]/w['value'][0]),\
                      "% of the Non-dispersive one )"
getDryContOpacity(nc=-1, spwid=0)[source]

Get the integrated Dry Continuum Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total Dry Cont Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getDryContOpacity()
getDryOpacity(nc=-1, spwid=0)[source]

Get the integrated Dry Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total Dry Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getDryOpacity()
getDryOpacitySpec(spwid=0)[source]

Get the integrated Dry opacity along the atmospheric path on each channel in a band.

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

int

Examples

at.getDryOpacitySpec()
# (8, 
#  array([0.12113794420465548, 0.11890122206854335,
#         0.11713584932434795, 0.11572780449702716,
#         0.11459567027114714, 0.11368004975916192,
#         0.11293678422232195,0.11233248854020933]))
getGroundWH2O()[source]

Method to get the zenith column of water vapor. It is computed by simply integrating the H2O profile:

getH2OContOpacity(nc=-1, spwid=0)[source]

Get the integrated zenith H2O Continuum Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total H2O Cont Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getH2OContOpacity()
getH2OLinesOpacity(nc=-1, spwid=0)[source]

Get the integrated zenith H2O Lines Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total H2O Lines Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getH2OLinesOpacity()
getMaxFreq(spwid=0)[source]

Get highest frequency channel for the specified spectral window.

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

print "Frequency range: from ", at.getMinFreq()['value'][0], " to ",\
      at.getMaxFreq()['value'][0], at.getMaxFreq()['unit']
getMinFreq(spwid=0)[source]

Get lowest frequency channel for the specified spectral window.

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

print "Frequency range: from ", at.getMinFreq()['value'][0], " to ",\
      at.getMaxFreq()['value'][0], at.getMinFreq()['unit']
getN2OLinesOpacity(nc=-1, spwid=0)[source]

Get the integrated N2O Lines Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total N2O Lines Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getN2OLinesOpacity()
getN2OLinesPathLength(nc=-1, spwid=0)[source]

Retrieve the integrated Atmospheric Path length (due to N2O Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

getNonDispersiveDryPathLength(nc=-1, spwid=0)[source]

Retrieve the integrated dry Atmospheric Path length (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getGroundWH2O()
nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
nfR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total Dispersive Delay at ", fC['value'][0], fC['unit'], " for 1.0 air mass: ",\
      at.getDispersiveDryPathLength()['value'][0] /  w['value'][0], " meters per mm of water vapor"
print "(",100*(at.getDispersiveDryPathLength()['value'][0] /  w['value'][0])/(at.getNonDispersiveDryPathLength()['value'][0] / w['value'][0]),\
      "% of the Non-dispersive one )"
getNonDispersiveDryPhaseDelay(nc=-1, spwid=0)[source]

Function to retrieve the integrated dry Atmospheric Phase Delay (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getUserWH2O()
numSpw = at.getNumSpectralWindows()
for spwid in range(numSpw):
        numCh = at.getNumChan(spwid)
        print "Spectral window ", spwid, " has ", numCh, " frequency channels"
        for n in range(numCh):
                freq = at.getChanFreq(n, spwid)
                print "Total Dispersive Dry Phase Delay at ", freq['value'][0], freq['unit'], " for 1.0 air mass: ",\
                      (at.getDispersiveDryPhaseDelay(n,spwid)['value'][0])/(w['value'][0])," degrees per mm of water vapor (",\
                      ((100*at.getDispersiveDryPhaseDelay(n,spwid)['value'][0])/(w['value'][0]))/(at.getNonDispersiveDryPhaseDelay(n,spwid)['value'][0]/w['value'][0]),\
                      "% of the Non-dispersive one )"
getNonDispersivePathLength(nc=-1, spwid=0)[source]

Get the integrated zenith H2O Atmospheric Path length (Non-Dispersive part) for the current conditions, for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getUserWH2O()
nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
nfR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total Dispersive Delay at ", fC['value'][0], fC['unit'], " for 1.0 air mass: ",\
      at.getDispersivePathLength()['value'][0] /  w['value'][0], " meters per mm of water vapor"
print "(",100*(at.getDispersivePathLength()['value'][0] /  w['value'][0])/(at.getNonDispersivePathLength()['value'][0] / w['value'][0]),\
      "% of the Non-dispersive one )"
getNonDispersivePhaseDelay(nc=-1, spwid=0)[source]

Get the integrated zenith H2O Atmospheric Phase Delay (Non-Dispersive part) for the current conditions, for channel number nc of spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getUserWH2O()
numSpw = at.getNumSpectralWindows()
for spwid in range(numSpw):
        numCh = at.getNumChan(spwid)
        print "Spectral window ", spwid, " has ", numCh, " frequency channels"
        for n in range(numCh):
                freq = at.getChanFreq(n, spwid)
                print "Total Dispersive Phase Delay at ", freq['value'][0], freq['unit'], " for 1.0 air mass: ",\
                      (at.getDispersivePhaseDelay(n,spwid)['value'][0])/(w['value'][0])," degrees per mm of water vapor (",\
                      ((100*at.getDispersivePhaseDelay(n,spwid)['value'][0])/(w['value'][0]))/(at.getNonDispersivePhaseDelay(n,spwid)['value'][0]/w['value'][0]),\
                      "% of the Non-dispersive one )"
getNonDispersiveWetPathLength(nc=-1, spwid=0)[source]

Retrieve the integrated wet Atmospheric Path length (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getGroundWH2O()
nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
nfR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total Dispersive Delay at ", fC['value'][0], fC['unit'], " for 1.0 air mass: ",\
      at.getDispersiveWetPathLength()['value'][0] /  w['value'][0], " meters per mm of water vapor"
print "(",100*(at.getDispersiveWetPathLength()['value'][0] /  w['value'][0])/(at.getNonDispersiveWetPathLength()['value'][0] / w['value'][0]),\
      "% of the Non-dispersive one )"
getNonDispersiveWetPhaseDelay(nc=-1, spwid=0)[source]

Function to retrieve the integrated wet Atmospheric Phase Delay (NonDispersive part) along the atmospheric path corresponding to the 1st guess water column.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

w = at.getUserWH2O()
numSpw = at.getNumSpectralWindows()
for spwid in range(numSpw):
        numCh = at.getNumChan(spwid)
        print "Spectral window ", spwid, " has ", numCh, " frequency channels"
        for n in range(numCh):
                freq = at.getChanFreq(n, spwid)
                print "Total Dispersive Wet Phase Delay at ", freq['value'][0], freq['unit'], " for 1.0 air mass: ",\
                      (at.getDispersiveWetPhaseDelay(n, spwid)['value'][0])/(w['value'][0]), " degrees per mm of water vapor (",\
                      ((100*at.getDispersiveWetPhaseDelay(n, spwid)['value'][0])/(w['value'][0]))/(at.getNonDispersiveWetPhaseDelay(n,spwid)['value'][0]/w['value'][0]),\
                      "% of the Non-dispersive one )"
getNumChan(spwid=0)[source]

Return the number of channels of ith band ( passes in as parameter ).

Parameters

  • spwid (int=0) - Int standing for identifier of bands (0-based). The value must be >= 0.

Returns

int

Examples

for spwid in range(at.getNumSpectralWindows()):
        numCh = at.getNumChan(spwid)
        print "Spectral window ", spwid, " has ", numCh, " frequency channels"
getNumLayers()[source]

Returns the number of layers in the atmospheric profile.

getNumSpectralWindows()[source]

Get number of spectral windows

getO2LinesOpacity(nc=-1, spwid=0)[source]

Get the integrated O2 Lines Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total O2 Lines Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getO2LinesOpacity()
getO2LinesPathLength(nc=-1, spwid=0)[source]

Retrieve the integrated Atmospheric Path length (due to O2 Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

getO3LinesOpacity(nc=-1, spwid=0)[source]

Get the integrated O3 Lines Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

double

Examples

nb = 1
fC = qa.quantity([850.0], 'GHz')
fW = qa.quantity([0.5], 'GHz')
fR = qa.quantity([0.5], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
print "Total O3 Lines Opacity at ", fC['value'][0], fC['unit'],\
      " for 1.0 air mass: ", at.getO3LinesOpacity()
getO3LinesPathLength(nc=-1, spwid=0)[source]

Retrieve the integrated Atmospheric Path length (due to O3 Lines) along the atmospheric path corresponding to the 1st guess water column for channel nc in spectral window spwid.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

getProfile()[source]

Get the atmospheric profile.

getRefChan(spwid=0)[source]

Return the reference channel of the given spectral window

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

int

Examples

rc = at.getRefChan()
print "Reference channel retrieved: ", rc
getRefFreq(spwid=0)[source]

Return the reference frequency of the given spectral window

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

rf = at.getRefFreq()
print "Reference frequency retrieved: ", rf['value'][0], rf['unit']
getSkyBackgroundTemperature()[source]

Get the sky background temperature

getSpectralWindow(spwid=0)[source]

Return the spectral grid for the specified spectral window.

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

print at.getSpectralWindow()['value'],at.getSpectralWindow()['unit']

sg = at.getSpectralWindow()
for i in range(len(sg['value'])):
        print sg['value'][i], sg['unit']
getTebbSky(nc=-1, spwid=0, wh2o=-1)[source]

Gets the Equivalent Blackbody Temperature in spectral window spwid and channel nc, for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

Parameters

  • nc (int=-1) - Channel number (0-based) - defaults to reference channel

  • spwid (int=0) - Spectral window (0-based). The value must be >= 0.

  • wh2o (double=-1) - User specified water column length in mm. Default is not to use wh2o.

Returns

Quantity

Examples

for s in range(at.getNumSpectralWindows()):
        for i in range(at.getNumChan(s)):
                print "Band", s, " channel ", i, "TebbSky = ", at.getTebbSky(i,s)['value'][0], at.getTebbSky()['unit']
getTebbSkySpec(spwid=0, wh2o=-1)[source]

Gets the Equivalent Blackbody Temperatures in a spectral window spwid for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

Parameters

  • spwid (int=0) - Spectral window (0-based). The value must be >= 0.

  • wh2o (double=-1) - User specified water column length in mm. Default is not to use wh2o.

Returns

int

Examples

sw=at.getWetOpacitySpec()
# returns a tuple of
# 0 - The number of channels, and
# 1 - the Equivalent Blackbody Temperatures in a band
sw[1]['value']
# [34.687910103670511,
#  35.496193465331679,
#  36.460355664151791,
#  37.419146813713745,
#  37.9452005127634,
#  38.722631196093729,
#  39.593561594172662,
#  40.528694048924017]

sw[0]
# 8

Another example:
for s in range(at.getNumSpectralWindows()):
        print "band", s
        tebbspec = at.getTebbSkySpec(spwid=s)
        for i in range(at.getNumChan(s)):
                print " - TebbSky %f [%s] " % (tebbspec[1]['value'][i],tebbspec[1]['unit'])
getTrjSky(nc=-1, spwid=0, wh2o=-1)[source]

Gets the Rayleigh-Jeans Temperature in spectral window spwid and channel nc, for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

Parameters

  • nc (int=-1) - Channel number (0-based) - defaults to reference channel

  • spwid (int=0) - Spectral window (0-based). The value must be >= 0.

  • wh2o (double=-1) - User specified water column length in mm. Default is not to use wh2o.

Returns

Quantity

Examples

for s in range(at.getNumSpectralWindows()):
        for i in range(at.getNumChan(s)):
                print "Band", s, " channel ", i, "TrjSky = ", at.getTrjSky(i,s)['value'][0], at.getTrjSky()['unit']
getTrjSkySpec(spwid=0, wh2o=-1)[source]

Gets the Rayleigh-Jeans Temperatures in a spectral window spwid for the current (user) Water Vapor Column wh2o, the current Air Mass, and perfect Sky Coupling to the sky.

Parameters

  • spwid (int=0) - Spectral window (0-based). The value must be >= 0.

  • wh2o (double=-1) - User specified water column length in mm. Default is not to use wh2o.

Returns

int

Examples

sw=at.getWetOpacitySpec()
# returns a tuple of
# 0 - The number of channels, and
# 1 - the Equivalent Blackbody Temperatures in a band
sw[1]['value']
# [34.687910103670511,
#  35.496193465331679,
#  36.460355664151791,
#  37.419146813713745,
#  37.9452005127634,
#  38.722631196093729,
#  39.593561594172662,
#  40.528694048924017]

sw[0]
# 8

Another example:
for s in range(at.getNumSpectralWindows()):
        print "band", s
        trjspec = at.getTrjSkySpec(spwid=s)
        for i in range(at.getNumChan(s)):
                print " - TrjSky %f [%s] " % (trjspec[1]['value'][i],trjspec[1]['unit'])
getUserWH2O()[source]

Get user zenith water vapor column for forward radiative transfer calculations.

getWetOpacity(nc=-1, spwid=0)[source]

Get the integrated zenith Wet Opacity for one channel in a band.

Parameters

  • nc (int=-1) - Channel number (0-based; defaults to reference channel)

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

Quantity

Examples

for i in range(at.getNumSpectralWindows()):
        for j in range(at.getNumChan(i)):
                print "Frequency: ", at.getChanFreq(j, i)['value'][0], at.getChanFreq(j, i)['unit']
                print "Wet opacity:", at.getWetOpacity(j, i)['value'][0], at.getWetOpacity(j, i)['unit'],\
                      " for ", at.getUserWH2O()['value'][0], at.getUserWH2O()['unit'], " H2O"
getWetOpacitySpec(spwid=0)[source]

Getthe integrated zenith Wet Opacity along the atmospheric path on each channel in a band.

Parameters

  • spwid (int=0) - Int standing for spectral window id (0-based). The value must be >= 0.

Returns

int

Examples

sw=at.getWetOpacitySpec()
# returns a tuple of
# 0 - The number of channels and
# 1 - an quantity array of wet opacity for each channel in band
sw[1]['value']
# array([1.7225454913767393, 1.7204246078103735,
#        1.7188614166349163, 1.7179243635081174,
#        1.7177278069990962, 1.7184525049248152,
#        1.7204244157129918, 1.7242351137518073])

sw[0]
# 8

Another example:
for s in range(at.getNumSpectralWindows()):
        print "band", s
        for i in range(at.getNumChan(0)):
                print " - dryOpacity ", at.getDryOpacitySpec(spwid=s)[1][i], " wet Opacity/mm ",\
                      at.getWetOpacitySpec(spwid=s)[1]['value'][i]
initAtmProfile(altitude=5000.0, temperature=270.0, pressure=560.0, maxAltitude=48.0, humidity=20.0, dTem_dh=-5.6, dP=10.0, dPm=1.2, h0=2.0, atmType=1, layerBoundaries='', layerTemperature='')[source]

An atmospheric profile is composed of 4 quantities as a function of altitude z:

* the layer thickness * the pressure P * the temperature T and * the gas densities for H2O, O3, CO and N2O.

This method is needed for computing the absorption and phase coefficients, as well as for performing radiative transfer calculations (only layer thickness/T are needed).

This method builds an atmospheric profile that can be used to calculate absorption and phase coefficients, as well as to perform forward and/or retrieval radiative transfer calculations. It is composed of a set of parameters needed to build a layer thickness/P/T/gas densities densities profile from simple parameters currently available at observatories (from weather stations for example) using functions from the ATM library. The set of input parameters consists of the pressure P, the temperature T and the relative humidity at the ground, the altitude of the site, the tropospheric temperature lapse rate,… The profile is built as: thickness of the considered atmospheric layers above the site, and mean P,T,H2O,O3,CO,N2O in them. The total number of atmospheric layers in the particular profile is also available (a negative value indicates an error). The zenith column of water vapor can be calculated by simply integrating the H2O profile.

Parameters

  • altitude (double=5000.) - Site altitude - Quantity with units of altitude, meter

  • temperature (double=270.0) - Ambient Temperature - Quantity with units of temperature, K

  • pressure (double=560.0) - Ambient pressure - Quantity with units of pressure, mbar

  • maxAltitude (double=48.0) - altitude of the top pf the modelled atmosphere - Quantity with dimension of length, and units of kilometer

  • humidity (double=20.0) - used to guess water (0-100)

  • dTem_dh (double=-5.6) - the derivative of temperature with respect to height - Quantity with units of K/km

  • dP (double=10.0) - initial pressure step - Quantity with the units of pressure, mb

  • dPm (double=1.2) - pressure multiplicative factor for steps

  • h0 (double=2.0) - scale height for water( exp distribution ) - Quantity with the dimension of length, and units of kilometer

  • atmType (int=1) - atmospheric type 1(tropical),2(mid latitude summer),3(mid latitude winter), 4(subarctic summer),5(subarctic winter), dimensionless

  • layerBoundaries (doubleVec='') - Altitude of user-defined temperature profile, a double array in unit of meter

  • layerTemperature (doubleVec='') - User-defined temperature profile, a double array in unit of Kelvin

Returns

string

Examples

tmp = qa.quantity(270.0, 'K')
pre = qa.quantity(560.0, 'mbar')
hum = 20.0
alt = qa.quantity(5000, 'm')
h0  = qa.quantity(2.0, 'km')
wvl = qa.quantity(-5.6, 'K/km')
mxA = qa.quantity(48, 'km')
dpr = qa.quantity(10.0, 'mbar')
dpm = 1.2
att = 1
myatm = at.initAtmProfile(alt, tmp, pre, mxA, hum, wvl, dpr, dpm, h0, att)
print myatm
# BASIC ATMOSPHERIC PARAMETERS TO GENERATE REFERENCE ATMOSPHERIC PROFILE
#  
# Ground temperature T:         270 K
# Ground pressure P:            560 mb
# Relative humidity rh:         20 %
# Scale height h0:              2 km
# Pressure step dp:             10 mb
# Altitude alti:                5000 m
# Attitude top atm profile:     48 km
# Pressure step factor:         1.2 
# Tropospheric lapse rate:      -5.6 K/km
# Atmospheric type:             TROPICAL
# User-defined temperature profile: OFF
#
# Built atmospheric profile with 19 layers.

User-defined temperature profile
myalt = [ 5071.72200397, 6792.36546384, 15727.0776121, 42464.18192672 ] #meter
mytemp = [ 270., 264., 258., 252. ] #Kelvin
newatm = at.initAtmProfile(alt, tmp, pre, mxA, hum, wvl, dpr, dpm, h0, att, myalt, mytemp)
print newatm
# BASIC ATMOSPHERIC PARAMETERS TO GENERATE REFERENCE ATMOSPHERIC PROFILE
#  
# Ground temperature T:         270 K
# Ground pressure P:            560 mb
# Relative humidity rh:         20 %
# Scale height h0:              2 km
# Pressure step dp:             10 mb
# Altitude alti:                5000 m
# Attitude top atm profile:     48 km
# Pressure step factor:         1.2 
# Tropospheric lapse rate:      -5.6 K/km
# Atmospheric type:             TROPICAL
# User-defined temperature profile: ON
#
# Built atmospheric profile with 19 layers.
initSpectralWindow(nbands=1, fCenter=90, fWidth=0.64, fRes=0.0)[source]

function that defines a spectral window, computes absorption and emmision coefficients for this window, using the atmospheric model profile.

NOTE: This method should be invoked after setting atmospheric profile model by initAtmProfile.

Parameters

  • nbands (int=1) - number of spectral windows/bands. The value must be > 0.

  • fCenter (double=90) - center frequencies - Quantum with a vector value and unit of frequency, GHz

  • fWidth (double=0.64) - frequency width of band - Quantum with a vector value and unit of frequency, GHz

  • fRes (double=0.0) - resolution inside band - Quantum with a vector value and unit frequency, GHz. Default is for a single frequency.

Returns

int

Examples

nb = 1
fC = qa.quantity(88., 'GHz')
fW = qa.quantity(0.5, 'GHz')
fR = qa.quantity(0.5, 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)

nb = 2
fC = qa.quantity([88., 90.], 'GHz')
fW = qa.quantity([0.5, 0.5], 'GHz')
fR = qa.quantity([0.125, 0.125], 'GHz')
at.initSpectralWindow(nb, fC, fW, fR)
listAtmosphereTypes()[source]

Returns a list of index numbers and corresponding atmosphere types used by the ATM library.

setAirMass(airmass='')[source]

Setter for air mass in SkyStatus without performing water vapor retrieval.

Parameters

  • airmass (double='') - Air Mass

Returns

bool

Examples

at.setAirMass(1.51)
setSkyBackgroundTemperature(tbgr=2.73)[source]

Set sky background temperature in SkyStatus without performing water vapor retrieval

Parameters

  • tbgr (double=2.73) - sky background temperature

Returns

bool

Examples

at.setSkyBackgroundTemperature(qa.quantity(2.73,'K'))
setUserWH2O(wh2o=0.0)[source]

Set user zenith water vapor column for forward radiative transfer calculations.

Parameters

  • wh2o (double=0.0) - User water vapor column

Returns

bool

Examples

wh2o=qa.quantity(0.8,"mm")
at.setUserWH2O(wh2o)
updateAtmProfile(altitude=5000.0, temperature=270.0, pressure=560.0, humidity=20.0, dTem_dh=-5.6, h0=2.0)[source]

This is used to update the atmosphere tool when basic atmospheric parameters.change.

Parameters

  • altitude (double=5000.) - Site altitude - Quantity with units of altitude, meter

  • temperature (double=270.0) - Ambient ground temperature - Quantity with units of temperature, K

  • pressure (double=560.0) - Ambient ground pressure - Quantity with units of pressure, mbar

  • humidity (double=20.0) - Relative humidy used to guess water (0-100)

  • dTem_dh (double=-5.6) - Tropospheric Lapse Rate - the derivative of temperature with respect to height - Quantity with units of K/km

  • h0 (double=2.0) - scale height for water( exp distribution ) - Quantity with the dimension of length, and units of kilometer

Returns

string

Examples

new_tmp = qa.quantity(275.0, 'K')
print at.updateAtmProfile(alt, new_tmp, pre, hum, wvl, h0)
# UPDATED BASIC ATMOSPHERIC PARAMETERS TO GENERATE REFERENCE ATMOSPHERIC PROFILE
#  
# Ground temperature T:         275 K
# Ground pressure P:            560 mb
# Relative humidity rh:         20 %
# Scale height h0:              2 km
# Altitude alti:                5000 m
# Tropospheric lapse rate:      -5.6 K/km