GEOS-Chem column code

From Geos-chem
Jump to: navigation, search

Obsolete.jpg

NOTE: the GEOS-Chem Column Code project has now been superseded by the GEOS-Chem HP project. Therefore, the information listed below is now obsolete. But much of the work that was done for the GEOS-Chem Column Code was critical to the success of the GCHP.

Overview

We are building a column (1-D) version of GEOS_Chem. This consists of all the GEOS-Chem operations except for tracer advection, namely:

  • PBL mixing
  • Cloud Convection
  • Dry Deposition
  • Emissions
  • Chemistry
  • Wet Deposition

The GEOS-Chem column model is being built in pure Fortran. This will allow it to be interfaced directly into NASA's GEOS-5 GCM. In this configuration, the GEOS-5 GCM would generate the meteorology and do the tracer advection, but call the GEOS-Chem column code to perform the chemistry and related operations.

We envision that the GEOS-Chem column model will form the core of a new "standalone" GEOS-Chem that would be Earth System Model Framework (ESMF) compliant. This will allow us to also take advantage of Message Passing Interface parallelization via ESMF.

Guidelines for columnizing GEOS-Chem routines

At present, the primary challenge in developing the GEOS-Chem column model is to clean up the existing legacy code that is present in GEOS-Chem. We shall use the following guidelines:

  1. All data shall be passed into/out of subroutines and functions via the argument list.
    • Functions shall declare a return value with the RESULT() statement.
    • Variables from other modules shall no longer be referenced by USE statements.
    • However, subroutine and functions from other modules may still be referenced by USE statements.
    • Some historical common blocks (i.e. in FAST-J, SMVGEAR) are OK for backwards compatibility, as long as all variables are threadprivate.
    • The #include statement may also be used to inline header files with PARAMETER declarations.
  2. There shall be no references to longitude and latitude indices (I,J) from within columnized routines.
    • Data shall be passed down as column vectors or scalars (or derived type objects, where feasible).
  3. Columnized routines shall not terminate execution if an error occurs.
    • An error return code shall be passed back up to the main driver routine.
    • The main driver routine can then decide to stop the simulation if the error is serious enough.
  4. I/O shall be separated from places where computations are done.
    • Emissions and other pertinent data shall be read at the start of the simulation.
    • Global emissions and other data shall be stored in an "internal state".
    • Columns of data from the "internal state" shall be passed to the columnized routines.
  5. Automatic documentation with ProTeX shall be mandatory
    • Each include file, module, subroutine, and function shall carry the appropriate ProTeX documentation header.
    • Makefiles shall have a make doc option, which shall create documentation files in *.pdf and *.ps formats.

As you can see from the lists below, we have made significant progress but the work is ongoing.

Task List

Task Person Status
Columnize chemistry routines and get simulation to run w/ 43 and 54 tracers Bob Yantosca Done 6/8/09
Parallelize main chemistry DO loop with OpenMP Bob Yantosca Done 6/8/09
Columnize dust emission & chemistry routines Philippe Le Sager Done 6/1/09
Columnize carbon aerosol chemistry routines; split off carbon aerosol emission routines into a separate module Philippe Le Sager and
Bob Yantosca
Done 6/8/09
Columnize sulfate aerosol chemistry routines; split off sulfate aerosol emission routines into a separate module Philippe Le Sager Done 7/1/09
Removed dependencies between dry deposition and emissions code Bob Yantosca Done 6/22/09
Columnize dry deposition routines Bob Yantosca Done 7/1/09
Columnize planetary boundary layer (PBL) mixing routines Bob Yantosca Done 7/8/09
Columnize wet depostion routines Bob Yantosca Done 7/15/09
Columnize cloud convection routines Bob Yantosca Done 7/20/09
Columnized soil NOx emissions Bob Yantosca Done 11/6/09
Testing the GEOS-Chem column code interface with the ESMF environment of GEOS-5 Bob Yantosca and Arlindo da Silva Ongoing
Creating emissions reader component and emissions column-processor component Bob Yantosca Ongoing

--Bob Y. 16:46, 6 November 2009 (EST)

Routines that have been columnized

Here is a complete listing of GEOS-Chem routines that have been "columnized". This means that all references to longitude and latitude dependent quantities have been removed from within these routines. Also, inputs & outputs to routines are passed down via argument lists rather than via USE statements or common blocks. This simplifies the structure of the code immensely, while making the code more amenable to parallelization with Message Passing Interface (MPI).

For a complete description of each routine, please see our GEOS-Chem column code reference document.

NOTES:

  1. A few common blocks had to be preserved for backwards-compatibility with the FAST-J and SMVGEAR packages. However these common blocks are now THREADPRIVATE, i.e., they only refer to quantities within a single column.
  2. The emissions reader routines and emissions internal-state routines have not been listed here, as they are still under development. For more information about these routines, please see our GEOS-Chem column code reference document.
  3. For compatibility with the GEOS-5 GCM, files have been renamed from *_loop.f to *.F.

Header files

Source File Description Last Update
cmn_fj_loop.h Header file containing parameters and common blocks used to interface between Harvard chemistry and UC-Irvine Fast-J photolysis programs. 3/24/09
comode_loop.h Header file COMODE contains common blocks and variables for the SMVGEAR II chemistry package. 3/17/09
drydep_info.h Contains parameters and arrays for the GEOS-Chem dry deposition routines. These were taken from the input files drydep.coef and drydep.table. 6/24/09
jv_cmn_loop.h Common blocks for FAST-J code 3/24/09
jv_mie.h Common blocks for FAST-J code; used in Mie scattering algorithms 3/24/09
lai_land_info.h Contains the various dimensions for the leaf-area-index and Olson land type data. 3/24/09
sea_salt_info.h Containsthe min and max radii for the accumulation mode and coarse mode size bins for sea salt aerosols. 6/24/09
smv_dimension.h This include file contains the various placeholder parameters that are required to replace references to GEOS-Chem grid parameters. This is necessary because several quantities in the FAST-J and SMVGEAR codes are contained in common blocks, and we need to have these parameters for sizing those arrays properly. 3/24/09
smv_errcode.h This include file contains the various success or failure parameters for the GEOS-Chem column chemistry code. 12/14/09
smv_physconst.h Contains physical constants for the GEOS-Chem column chemistry code. 12/14/09

--Bob Y. 11:05, 15 December 2009 (EST)

General chemistry routines

Interface between column chemistry and GEOS-Chem code

Routine name Source File Description Last Update
GC_INTERFACE gc_interface_mod.F Interface between the current GEOS-Chem model and the GEOS-Chem column chemistry driver routine CHEMDR_COL. 6/30/09
READ_SST gc_interface_mod.F Reads monthly mean sea surface temperatures from disk. 6/30/09
GET_O3_COLUMN gc_interface_mod.F Returns a resultant total overhead O3 column from the TOMS data for a given day of the month. 10/20/09
ERROR_TRAP gc_interface_mod.F This routine stops the run and prints the name of the offending routine if an error condition is returned. 12/14/09
INIT_CSPEC_FULL gc_interface_mod.F Initializes the CSPEC_FULL array, which is the internal state array that holds the chemical concentrations from the previous timestep. The initial values come from the globchem.dat file. 11/6/09
PRINT_MEAN_OH gc_interface_mod.F Prints the average mass-weighted OH concentration at the end of a simulation. 4/3/09
GERM_INIT_IMPORT_STATE gc_interface_mod.F Initializes the import state object (which contains information about the size, name, units, and file names) for the 3-D quantities that comprise the emissions internal-state. The import-state object is passed as input to routine GC_EMISSIONS_READ_INIT. 11/13/09

--Bob Y. 12:07, 15 December 2009 (EST)

GEOS-Chem column chemistry: driver module

Routine name Source File Description Last Update
GC_COLUMN_INIT gc_column_mod.F Calls the various initialization routines that read the setup files for the column chemistry module. Also, ID flags for both chemical species and advected tracers are defined. 6/30/09
GC_COLUMN_RUN gc_column_mod.F Driver for the following operations:
  • Planetary boundary layer mixing (not yet implemented)
  • Dry deposition
  • Emissions (not yet implemented)
  • Chemistry
  • Wet Depostion (not yet implemented)
6/30/09
GC_COLUMN_FINAL gc_column_mod.F Deallocates pointers & arrays used in the column chemistry routines. 6/30/09
ITS_TIME gc_column_mod.F Determines if it is time to do dynamics or chemistry 6/30/09
CONVERT_UNITS gc_column_mod.F Converts the tracer concentration array from [kg] to [mol/mol] mixing ratio, or vice versa. 12/15/09

--Bob Y. 10:26, 15 December 2009 (EST)

Chemical solver routines

Routine name Source File Description Last Update
ARSL1K arsl1k.F Calculates the 1st-order loss rate of species on wet aerosol surface. 12/3/09
BACKSUB backsub.F Subroutine BACKSUB does the back-substitution on the decomposed matrix. Called from SMVGEAR. 3/23/09
CALCRATE calcrate.F Computes reaction rates before passing them to the SMVGEAR solver. 12/9/09
N2O5 calcrate.F Computes the GAMMA factor for N2O5 hydrolysis. 3/25/09
CHEMDR_COL chemdr.F This column chemistry driver routine, which is called from DO_CHEMISTRY. All quantities are passed in/out as vertical columns or scalars. 6/22/09
RDUST chemdr.F Calculates dust optical depth at each level for the FAST-J routine set_prof.f. (NOTE: Split off from aerosol_mod.f.) 10/21/09
RDAER chemdr.F Calculates optical depth at each level for set_prof.f. Also calculates surface area for heterogeneous chemistry. It uses aerosol parameters in FAST-J input file jv_spec.dat for these calculations. (NOTE: Split off from aerosol_mod.f.) 4/3/09
DECOMP decomp.F Subroutine DECOMP decomposes the sparse matrix for the SMVGEAR II solver. Called from SMVGEAR. 3/23/09
FYRNO3 fyrno3.F Returns organic nitrate yields YN = RKA/(RKA+RKB) from RO2+NO reactions as a function of the number N of carbon atoms. 12/8/09
GASCONC gasconc.F Initializes gas concentrations for SMVGEAR II. (NOTE: The code to initialize the CSPEC_FULL array was removed from here and inserted into INIT_CSPEC_FULL in chemistry_mod_loop.f. 9/28/09
GET_GLOBAL_CH4 get_global_ch4.F Computes the latitudinal gradient in CH4 corresponding to year. 12/9/09
JSPARSE jsparse.F Subroutine JSPARSE sets up the sparse-matrix arrays for SMVGEAR II. 4/3/09
KSPARSE ksparse.F Subroutine KSPARSE sets up the sparse-matrix arrays, and also arrays for day and night chemistry for SMVGEAR II. 4/3/09
LUMP lump.F Subroutine LUMP takes individual chemistry species and "lumps" them back into tracers after each SMVGEAR chemistry timestep. 9/28/09
PARTITION partition.F Separates GEOS-CHEM tracers into its individual constituent chemistry species before each SMVGEAR chemistry timestep. 9/28/09
PDERIV pderiv.F Subroutine PDERIV places the partial differential equations into a matrix for SMVGEAR II. Called from SMVGEAR. 3/23/09
PHYSPROC physproc.F Driver for SMVGEAR II chemistry. It calls both CALCRATE to compute the rxn rates and the SMVGEAR solver routine. 5/21/09
READCHEM readchem.F Subroutine READCHEM reads species names, chemical rxns, and photolysis reactions from the globchem.dat chemistry mechanism file for SMVGEAR II. Called from routine GC_COLUMN_INIT in gc_column_mod.f. 4/3/09
READER reader.F Subroutine READER reads on/off switches and other settings from for SMVGEAR II from the mglob.dat file. 4/3/09
SCHEM schem_mod.F This module contains routines and data objects for the GEOS-Chem simple stratospheric chemistry loss mechanism. NOTE: This is deprecated, and is slated to be replaced by Linoz in the near future. 4/20/09
SETEMDEP setemdep.F Subroutine SETEMDEP stores SMVGEAR reaction numbers (listed in globchem.dat) corresponding to GEOS-CHEM tracers which emit and dry deposit into the NTEMIS and NTDEP index arrays. 3/24/09
SETEMIS setemis.F Places emissions computed from GEOS-Chem subroutines into arrays for SMVGEAR II chemistry. Converts from units of [molec tracer/box/s] to units of [molec chemical species/cm3/s], and stores in the REMIS array. For hydrocarbons that are carried through the GEOS-CHEM model as [molec C], these are converted back to [molec hydrocarbon], and then stored in REMIS. 11/5/09
SMVGEAR smvgear.F Subroutine SMVGEAR solves ODE's for chemical reactions using a GEAR-type method. 11/16/09
SUBFUN subfun.F Subroutine SUBFUN evaluates the first derivative of each ODE for SMVGEAR II. Called from SMVGEAR. 3/23/09
UPDATE update.F Subroutine UPDATE updates rxn rates for each timestep for SMVGEAR II. Called from SMVGEAR. 3/23/09

--Bob Y. 10:53, 15 December 2009 (EST)

Carbon aerosol routines

Chemistry

Routine name Source File Description Last Update
CHEM_BCPI carbon_chem_mod.F Calculates dry deposition of hydrophilic BC. 6/4/09
CHEM_BCPO carbon_chem_mod.F Converts hydrophobic BC to hydrophilic BC and calculates the dry deposition of hydrophobic BC. 6/4/09
CHEMCARBON carbon_chem_mod.F Subroutine CHEMCARBON is the interface between the GEOS-Chem main program and the carbon aerosol chemistry routines that calculates dry deposition, chemical conversion between hydrophilic and hydrophobic, and SOA production. 6/4/09
CHEM_NVOC carbon_chem_mod.F Computes the oxidation of Hydrocarbon by O3, OH, and NO3. 6/4/09
CHEM_OCPI carbon_chem_mod.F Calculates dry deposition of hydrophilic OC. 6/4/09
CHEM_OCPO carbon_chem_mod.F Converts hydrophobic OC to hydrophilic OC and calculates the dry deposition of hydrophobic OC. 6/4/09
GET_DOH_COL carbon_chem_mod.F Returns the amount of isoprene [kg] that has reacted with OH during the last chemistry time step. 6/4/09
SOA_CHEMISTRY carbon_chem_mod.F Performs SOA formation. 12/15/09
SOA_DEPO carbon_chem_mod.F Computes dry-deposition of a particular SOA species. 6/4/09
SOA_EQUIL carbon_chem_mod.F Solves SOAeqn=0 to determine Mnew(= mass) See Eqn (27) on page 70 of notes. 12/15/09
SOA_PARA carbon_chem_mod.F Gives mass-based stoichiometric coefficientsfor semi-volatile products from the oxidation of hydrocarbons. It calculates secondary organic aerosol yield parameters. Temperature effects are included. 12/15/09
SOA_PARTITION carbon_chem_mod.F Partitions the mass of gas and aerosol tracers according to five Hydrocarbon species and three oxidants. 6/4/09
SOA_LUMP carbon_chem_mod.F Returns the organic gas and aerosol back to the tracer array. 6/4/09
ZEROIN carbon_chem_mod.F Root finder for the function SOA_EQUIL. 12/15/09

Acknowledgments

  • Chemistry routines for BC/OC were written by Rokjin Park
  • Secondary organic aerosol (SOA) chemistry routines are from the Caltech group (J. Seinfeld, H. Liao, S. Chung)

--Bob Y. 12:17, 15 December 2009 (EST)

Emissions

NOTE: The carbon aerosol emissions routines have not yet been extracted from GEOS-Chem.

Dust aerosol routines

Chemistry

NOTE: Dust "chemistry" is not chemistry per se, but rather removal by gravitational settling and dry deposition.

Routine name Source File Description Last Update
CHEMDUST dust_mod.F Interface between the GEOS-Chem main program and the DUST routines that applies removal of dust by gravitational settling and dry deposition. 6/11/09
DRY_DEPOSITION dust_mod.F Subroutine DRY_DEPOSITION computes the loss of dust due to dry deposition at the surface using an implicit method. 4/28/09
DRY_SETTLING dust_mod.F Subroutine DRY_SETTLING computes the dry settling of dust tracers. 12/14/09

Acknowledgments

  • Original code written by T. Duncan Fairlie

--Bob Y. 11:17, 15 December 2009 (EST)

Emissions

Routine name Source File Description Last Update
EMISSDUST_BOX dust_mod.F Driver routine for the dust emission module. It is designed to use either the GINOUX or the DEAD dust source function. (However, as of 6/11/09, only the GINOUX source function has been implemented.) 6/11/09
SRC_DUST_GINOUX_BOX dust_mod.F Paul GINOUX dust source function. This subroutine updates the surface mixing ratio of dust aerosols for NDSTBIN size bins. The uplifting of dust depends in space on the source function, and in time and space on the soil moisture and surface wind speed (10 meters). Dust is uplifted if the wind speed is greater than a threshold velocity which is calculated with the formula of Marticorena et al. (JGR, v.102, p 23277-23287, 1997). 12/15/09

Acknowledgments

  • Dust source function code from Paul Ginoux, and implented into GEOS-Chem by T. Duncan Fairlie

--Bob Y. 11:21, 15 December 2009 (EST)

Sea salt aerosol routines

Chemistry

NOTE: Sea salt "chemistry" is not chemistry per se, but rather removal by gravitational settling and dry deposition.

Routine name Source File Description Last Update
CHEMSEASALT seasalt_chem_mod.F Interface between the GEOS-Chem main program and the seasalt chemistry routines that mostly calculates seasalt dry deposition. 6/12/09
DRY_DEPOSITION seasalt_chem_mod.F Computes the loss of sea salt by dry deposition at the surface, using an implicit method. 6/12/09
WET_SETTLING seasalt_chem_mod.F Performs wet settling of sea salt aerosol tracers. 12/14/09

Acknowledgments

  • Original code written by Becky Alexander

--Bob Y. 11:07, 15 December 2009 (EST)

Emissions

NOTE: The sea salt aerosol emissions routines have not been extracted from GEOS-Chem at this time.

Sulfate aerosol routines

Chemistry

Routine name Source File Description Last Update
AQCHEM_SO2 sulfate_chem_mod.F Computes the reaction rates for aqueous SO2 chemistry. 12/15/09
CHEM_MSA sulfate_chem_mod.F This is the SO4 chemistry subroutine from Mian Chin's GOCART model, modified for the GEOS-Chem model. 12/14/09
CHEM_NH3 sulfate_chem_mod.F Removes NH3 from the surface via dry deposition. 12/15/09
CHEM_NH4 sulfate_chem_mod.F Removes NH4 from the surface via dry deposition. 6/24/09
CHEM_NIT sulfate_chem_mod.F Subroutine CHEM\_NIT removes SULFUR NITRATES (NIT) from the surface via dry deposition. 6/24/09
CHEM_SO2 sulfate_chem_mod.F This is the SO2 chemistry subroutine. 6/24/09
CHEM_SO4 sulfate_chem_mod.F This is the SO4 chemistry subroutine from Mian Chin's GOCART model, modified for the GEOS-CHEM model. Now also modified to account for production of crystalline & aqueous sulfur tracers. 12/15/09
CHEMSULFATE sulfate_chem_mod.F Interface between the GEOS-Chem main program and the sulfate chemistry routines. The user has the option of running a coupled chemistry-aerosols simulation or an offline aerosol simulation. 10/2/09
GET_LWC sulfate_chem_mod.F Returns the cloud liquid water content at a GEOS-Chem grid box as a function of temperature. 6/24/09
GET_O3 sulfate_chem_mod.F Returns O3 for sulfate aerosol simulations. 6/24/09
GET_VCLDF sulfate_chem_mod.F Computes the volume cloud fraction for SO2 chemistry 6/24/09
GRAV_SETTLING sulfate_chem_mod.F Performs gravitational settling of sulfate and nitrate in coarse sea salt (SO4S and NITS). 12/14/09
SEASALT_CHEM sulfate_chem_mod.F Computes SO4 formed from S(IV) + O3 on seasalt aerosols as a function of seasalt alkalinity in one box 6/24/09

Acknowledgments

  • Original code taken from Mian Chin's GOCART model and modified accordingly.

--Bob Y. 13:15, 15 December 2009 (EST)

Emissions

Routine name Source File Description Last Update
EMISSDUST_BOX dust_mod.F Driver routine for the dust emission module. It is designed to use either the GINOUX or the DEAD dust source function. (However, as of 6/11/09, only the GINOUX source function has been implemented.) 6/11/09
SRC_DUST_GINOUX_BOX dust_mod.F Paul GINOUX dust source function. This subroutine updates the surface mixing ratio of dust aerosols for NDSTBIN size bins. The uplifting of dust depends in space on the source function, and in time and space on the soil moisture and surface wind speed (10 meters). Dust is uplifted if the wind speed is greater than a threshold velocity which is calculated with the formula of Marticorena et al. (JGR, v.102, p 23277-23287, 1997). 12/15/09

Acknowledgments

  • Dust source function code from Paul Ginoux, and implented into GEOS-Chem by T. Duncan Fairlie

--Bob Y. 13:15, 15 December 2009 (EST)

Dry deposition routines

Routine name Source File Description Last Update
AERO_SFCRSII drydep_mod.F Computes the aerodynamic resistance of seasalt aerosol tracers according to Zhang et al 2001. We account for hygroscopic growth of the seasalt aerosol particles. 6/30/09
BIO_FIT drydep_mod.F Adjust stomatal resistances for solar insolation, as described in Wang et al [1998]. 11/5/09
DEPVEL drydep_mod.F Computes the dry deposition velocities (Vd) using a resistance-in-series model. 6/30/09
DO_DRYDEP drydep_mod.F Driver for the GEOS-CHEM dry deposition scheme. Calls DEPVEL to compute deposition velocities [m/s], which are then converted to [cm/s]. Drydep frequencies are also computed. 6/30/09
DIAG_DRYDEP_FLUX drydep_mod.F Computes dry deposition fluxes for dry-depositing species which are part of the GEOS-Chem chemical mechanism. 6/30/09
DIFFG drydep_mod.F Function DIFFG calculates the molecular diffusivity [m2/s] in air for a gas X of molecular weight XM [kg] at temperature TK [K] and pressure PRESS [Pa]. 6/30/09
DUST_SFCRSII drydep_mod.F Computes the aerodynamic resistance of dust aerosol tracers according to Zhang et al 2001. We do not consider the hygroscopic growth of the aerosol particles. 6/30/09a
DVZ_MINVAL drydep_mod.F Sets minimum values for drydep velocities for sulfate aerosols, according to Mian Chin's GOCART model. 6/30/09
INIT_DRYDEP drydep_mod.F Initializes the DRYD_INFO object, which contains the parameters for each dry deposition species for passing to subroutine DEPVEL. 6/30/09
SUN_PARAM drydep_mod.F Called by BIO_FIT to adjust the LAI, cosine of solar zenith angle, and cloud fraction fields, according to Wang et al [1998]. 12/15/09

--Bob Y. 11:28, 15 December 2009 (EST)

FAST-J photolysis routines

Routine name Source File Description Last Update
BLKSLV BLKSLV.F Solves the block tri-diagonal system: A(I)*X(I-1) + B(I)*X(I) + C(I)*X(I+1) = H(I) 12/8/09
CLDSRF CLDSRF.F Routine to set cloud and surface properties for the FAST-J photolysis scheme. 12/8/09
EFOLD EFOLD.F Calculates the e-fold between two boundaries, given the value at both boundaries F0(x=0) = top, F1(x=1) = bottom. Used in the FAST-J photolysis scheme. 12/8/09
FAST_J fast_j.F Calls PHOTOJ to compute J-Values for each column at every chemistry time-step. 3/24/09
FJFUNC fjfunc.F Now a stub routine 3/24/09
GAUSSP GAUSSP.F Loads in pre-set Gauss points for 4 angles from 0 to +1 in cos(theta)=mu. Used by the FAST-J photolysis scheme. 12/8/09
GEN GEN.F Generates coefficient matrices for the block tri-diagonal system: A(I)*X(I-1) + B(I)*X(I) + C(I)*X(I+1) = H(I). Used by the FAST-J photolysis scheme. 12/8/09
INPHOT inphot.F Initializes quantities for FAST-J photolysis,including JPL spectral data (e.g. cross sections, quantum yields), standard O3 and T profiles, and the translation indices between GEOS-Chem and FAST-J species names. Called from INIT_COLUMN_CHEMISTRY in chemistry_mod_loop.f. 3/20/09
JRATET JRATET.F Calculate and print J-values. 10/21/09
JVALUE JVALUE.F Calculates the actinic flux at each level for the current solar zenith angle (SZA) value. Quit when SZA > 98.0 deg (= tangent height of 63km). 10/21/09
JV_INDEX jv_index.F Subroutine JV_INDEX computes the mapping between the CTM indices (from "globchem.dat") for J-values to the FAST-J indices (from "ratj.d") for J-values. 12/8/09
LEGND0 LEGND0.F Calculates ORDINARY LEGENDRE fns of X (real), from P[0] = PL(1) = 1, P[1] = X, .... P[N-1] = PL(N). Used in the FAST-J photolysis scheme. 12/8/09
MATIN4 MATIN4.F Invert 4x4 matrix A(4,4) in place with L-U decomposition. Used in the FAST-J photolysis scheme. 12/8/09
MIESCT MIESCT.F This is an adaption of the Prather radiative transfer code, used in the FAST-J photolysis scheme. 12/8/09
NOABS NOABS.F Zero out absorption terms to check scattering code. Leave a little Rayleigh to provide a minimal optical depth, and set surface albedo to unity. Used in the FAST-J photolysis scheme. 12/8/09
OPMIE OPMIE.F New Mie code for J's, only uses 8-term expansion, 4-Gauss pts. Currently allow up to NP aerosol phase functions (at all altitudes) to be associated with optical depth AER(1:NC) = aerosol opt.depth @ 1000 nm 10/21/09
PHOTOJ photoj.F Subroutine PHOTOJ is the driver routine for the FAST-J photolysis package. 3/24/09
RD_TJPL RD_TJPL.F Reads in wavelength bins, solar fluxes, Rayleigh parameters, temperature-dependent cross sections and Rayleigh/aerosol scattering phase functions with temperature dependences. Current data originates from JPL'97 10/21/09
RD_JS rd_js.F Reread the ratj.d file to map photolysis rate to reaction. Read in quantum yield 'jfacta' and fastj label 'jlabel'. Used in the FAST-J photolysis scheme. 12/8/09
RD_PROF rd_prof.F Routine to input T and O3 reference profiles. Used by the FAST-J photolysis scheme. 12/8/09
SET_PROF set_prof.F Sets up atmospheric profiles required by FAST-J using a doubled version of the level scheme used in the CTM. First pressure and z* altitude are defined, then O3 and T are taken from the supplied climatology and integrated to the CTM levels (may be overwritten with values directly from the CTM, if desired) and then black carbon and aerosol profiles are constructed. 3/24/09
SPHERE SPHERE.F Calculation of spherical geometry; derive tangent heights, slant path lengths and air mass factor for each layer. Not called when SZA > 98 degrees. Beyond 90 degrees, include treatment of emergent beam (where tangent height is below altitude J-value desired at). 10/21/09
XSEC1D XSEC1D.F Function XSEC1D returns quantum yields for O3 --> O2 + O(1D) interpolated across 3 temperatures. 10/21/09
XSECO2 XSECO2.F Function XSECO2 returns cross-sections for O2 interpolated across 3 temperatures; No S_R Bands yet! 10/21/09
XSECO3 XSECO3.F Function XSECO3 computes cross-sections for O3 for all processes interpolated across 3 temperatures. 10/21/09

--Bob Y. 12:40, 15 December 2009 (EST)

Dynamics routines

Planetary Boundary Layer Mixing

Routine name Source File Description Last Update
COMPUTE_PBL pbl_mixing_mod.F Computes the PBL height and other related quantities. 7/8/09
DO_PBL_MIXING pbl_mixing_mod.F Executes the GEOS-Chem boundary layer mixing algorithm. Original subroutine by Dale Allen, Univ of MD. 7/8/09

Cloud Convection

Routine name Source File Description Last Update
DO_GEOS5_CONVECTION cloud_convection_mod.F This is S-J Lin's cumulus transport module for 3D GSFC-CTM, modified for the GEOS-Chem model. 7/20/09

--Bob Y. 14:56, 20 July 2009 (EDT)

Wet Deposition

Routine name Source File Description Last Update
COMPUTE_L2G wetdep_mod.F Computes the ratio L2G = Cliq / Cgas, which is the mixing ratio of tracer in the liquid phase, divided by the mixing ratio of tracer in the gas phase. 7/15/09
COMPUTE_UPDRAFT_FSOL wetdep_mod.F Computes the fraction of soluble tracer lost by scavenging in convective cloud updrafts. 7/15/09
CONV_F_PRIME wetdep_mod.F Computes F', the fraction of the grid box that is precipitating during convective precipitation. 7/15/09
E_ICE wetdep_mod.F Computes Eice(T), the saturation vapor pressure of ice at a given temperature. 7/15/09
GET_RAINFRAC wetdep_mod.F Computes the fraction of tracer lost to rainout according to Jacob et al 2000. 7/15/09
INIT_WETDEP_FIELDS wetdep_mod.F Initializes updraft velocity, cloud liquid water content, cloud ice content, and mixing ratio of water fields, which are used in the wet scavenging routines. 7/15/09
INIT_WETDEP wetdep_mod.F Initializes the WETD\_INFO object, which contains the parameters for each wet deposition species for passing to subroutine WETDEP. 7/15/09
LS_F_PRIME wetdep_mod.F Computes F', the fraction of the grid box that is precipitating during large scale (a.k.a. stratiform) precipitation. 7/15/09
LS_K_RAIN wetdep_mod.F Computes K_RAIN, the first order rainout rate constant for large-scale (a.k.a. stratiform) precipitation. 7/15/09
MAKE_QQ wetdep_mod.F Computes the large-scale or convective precipitation fields for use with subroutine WETDEP. These are stored in the PDOWN and QQ fields of the module-private WETD_INFO object. 7/15/09
RAINOUT wetdep_mod.F Computes RAINFRAC, the fraction of soluble tracer lost to rainout events in precipitation. 7/15/09
SAFETY wetdep_mod.F Prints the values of several variables when an error condition is encountered in routine WETDEP. 7/15/09
WASHFRAC_AEROSOL wetdep_mod.F Returns the fraction of soluble aerosol tracer lost to washout. 7/15/09
WASHFRAC_LIQ_GAS wetdep_mod.F Returns the fraction of soluble liquid/gas phase tracer lost to washout. 7/15/09
WASHOUT wetdep_mod.F Computes WASHFRAC, the fraction of soluble tracer lost to washout events in precipitation. 7/15/09
WETDEP wetdep_mod.F Computes the downward mass flux of tracer due to washout and rainout of aerosols and soluble tracers in a column. 7/15/09

--Bob Y. 12:55, 15 December 2009 (EST)

Routines modified to keep backwards compatibility in GEOS-Chem

Source File Notes Last Update
acetone_mod.F
  • Split off routines which read I/O from disk into acetone_input_mod.f
4/28/09
aerosol_mod.F
  • Moved RDUST and RDAER into module chemdr_loop.f
  • Also made some routines that were not needed anymore into stubs
3/20/09
canopy_nox_mod.F
  • Contains routines for computing the bulk surface resistance of the canopy to NOx. This quantity is needed by GEOS-Chem soil emissions routine soilcrf.f. This computation was originally done in legacy routine DEPVEL (located in drydep_mod.f), and the bulk surface resistance was stored in common block array CANOPYNOX (in commsoil.h).
  • However, the legacy code caused an ugly dependency. Drydep routine DEPVEL had to be called BEFORE the soil NOx emissions routines. Routine GET_CANOPY_NOX in this module performs the same computation of NOx from tree canopies independent of drydep_mod.f, thus allowing for a totally clean separation between dry deposition routines and emisisons routines.
6/22/09
cleanup.F
  • Comment out calls to some module cleanup routines (which are now called elsewhere)
  • Also now do not reference any routines from offline simulations
6/19/09
diag3.F
  • Comment out various diagnostics to avoid conflicts
6/12/09
diag48_mod.F
  • References smv_dimension.h
  • References comode_loop.h
6/12/09
diag49_mod.F
  • References smv_dimension.h
  • References comode_loop.h
6/12/09
diag50_mod.F
  • References smv_dimension.h
  • References comode_loop.h
6/12/09
diag51_mod.F
  • References smv_dimension.h
  • References comode_loop.h
6/12/09
diag_pl_mod.F
  • Turned into stub routines
6/12/09
diagoh.F
  • Routine DO_DIAG_OH now takes inputs via the argument list
6/12/09
emissdr.F
  • Moved calls to MEGAN routines to chemistry_mod_loop.f
  • Also now references CMN_O3_loop.
6/12/09
emissions_mod.F
  • Commented out references to code for offline simulations
6/12/09
input_mod.F
  • Commented out references to code for offline simulations
  • Also moved call to INIT_DIAG_OH to <routine INIT_COLUMN_CHEMISTRY in chemistry_mod_loop.f
6/12/09
main.F
  • Call to DO_DRYDEP commented out, this is now done from chemistry_mod_loop.f
  • Calls to the various offline simulations have been commented out, to avoid conflicts
6/24/09
ohsave.F
  • Now a stub routine
6/12/09
planeflight_mod.F
  • Now made into stub routines
6/12/09
ruralbox.F
  • Now a stub routine
6/12/09
seasalt_mod.F
  • Now only contains the sea salt aerosols emissions routines, as they were in the original GEOS-Chem code. Split routines WET_SETTLING and DRY_DEPOSITION into seasalt_chem_mod_loop.f.
6/12/09
setmodel.F
  • Now a stub routine
3/20/09
tracerid_mod.F
  • Subroutine TRACERID now references smv_dimension.h and comode_loop.h
  • Subroutine SETTRACE is now a stub routine
6/12/09
tropopause_mod.F
  • Subroutines COPY_FULL_TROP and SAVE_FULL_TROP are now stub routines
6/12/09

--Bob Y. 12:57, 15 December 2009 (EST)