Latest: TABHDR v2.0 (16DEC19) [Download]



Part of the RFM handling of
Look-Up Tables (LUTs)

TABHDR is a Fortran90 program to extract axis and profile information from RFM look-up tables of pre-tabulated absorption coefficient (.tab files, created using the TAB option).

For example, this could be useful for generating subsequent LUTs with similar axes to a given LUT (assuming the rfm.drv file used to generate the original LUT no longer exists).

General Comments

  1. This program can be run on any .tab file, in either ASCII or binary format.
  2. As well as a summary printed to the terminal, up to 5 files will be created containing axis and profile information:
    Pressure axis values [hPa], in .dat file format, suitable as PFILE input in the *DIM section of the rfm.drv file.
    Temperature axis values [K], suitable as TFILE input
    tab.vmr (only generated if more than 1 q-axis point in .tab file)
    VMR-scaling axis values [%], as QFILE input.
    Pressure axis and embedded Temperature and VMR profiles in .atm file format, suitable as FILATM input in the *ATM section of the rfm.drv file.
    tab.grd (only generated for irregular spectral grid)
    Spectral grid values in .grd file format, suitable as FILGRD input in the *GRD section of the rfm.drv file.
    These filenames are fixed, set by fairly obvious PARAMETER statements near the top of the source code.

Installing tabhdr

Download the program source [tabhdr.f90] and the auxiliary modules [tabaux.f90]

Compile with any generic FORTRAN compiler, eg

gfortran tabaux.f90 tabhdr.f90 -o tabhdr

(although, if using binary .tab files, use the same compiler as for the RFM which created the original files — see Overview).

Running tabhdr

To run the program, type tabhdr and respond to the prompts.

A typical run might be (user responses in bold)

tabhdr R-TABHDR: Running TABHDR v2.0 Input file: tab_co.asc MolecID: 5 co Summary: NPts <---- Range ----> p-axis: 51 1.017E+03 1.955E-05 T-axis: 13 180. 300. q-axis: 1 100. 100. v-axis: 39758 2000.0000 2250.0000 Writing p-axis values to file: tab.pre Writing T-axis values to file: tab.tem Writing profile values to file: tab.atm Writing irregular spectral grid to file: tab.grd R-TABHDR: Succesful completion Shows version of program being run User supplies name of .tab file Molecule identified as CO, with HITRAN ID=5 Summary of the tabulation axes p-axis in hPa T-axis in K q-axis as % of embedded profile v-axis in cm-1 List of output files being created No q-axis since just single value Embedded T, VMR profiles Irreg grid so .grd file created Successful completion message

The program takes a few seconds to run with an irregular grid (since every record has to be read) but is instantaneous with regularly gridded data (since only the file header is read).

Error Messages

The only error messages expected are associated with reading/writing files.

Version History

v2.0 (16DEC19)
Recoded in Fortran 90
v1.31 (05AUG15)
Change '$' in WRITE statements to avoid gfortran warnings
v1.3 (16APR15)
Correction: add local function MOLIDX
v1.2 (24FEB15)
Improve auto-detection of input file-type
v1.1 (17DEC14)
Allow for extra format identifier record in .tab file header
v1.00 (05NOV14)
Original code