Basic Atmospheric SetupΒΆ

An example of how to setup a simple 1 dimensional (varies only in height) atmosphere that includes a background climatology from MSIS90, the labow ozone climatology, and the pratmo NO2 climatology. This utilizes some of the python libraries including the classes Atmosphere, and ozone. This atmosphere can then be used in a radiative transfer calculation, as shown in Basic Radiative Transfer Calculation.

from radtran.atmosphere import Atmosphere
from radtran.climatologies import background, ozone, no2, aerosol

def setup_atmosphere():
    #create an atmosphere - we will add species to this, then give it to the
    #radiative transfer model
    atmo = Atmosphere()

    #create a background climatology from msis90 and add it to the atmosphere
    clim, optprop, guid = background.msis()
    atmo.add_species( clim, optprop, guid )

    #set this at the background climatology, other species will use the pressure
    #and temperature from the background to determine cross sections
    atmo.backgroundclim = clim

    #add ozone, no2 and aerosol to the model
    clim, optprop, guid = ozone.labow()
    atmo.add_species(clim, optprop, guid)

    clim, optprop, guid = no2.pratmo()
    atmo.add_species(clim, optprop, guid)

    clim, optprop, guid = aerosol.apriori()
    atmo.add_species(clim,optprop, guid)

    return atmo