Latest: TABINS v1.21 (05AUG15)




Part of the RFM handling of
Look-Up Tables.

tabins.f is a FORTRAN77 program to insert (in the spectral domain) one .tab file into another. These are RFM-generated look-up tables of pre-tabulated absorption coefficient created using the TAB option.

This allows part of the spectral range of an original file to be replaced without requiring the entire spectral range to be recalculated.

General Comments

  1. This program can only be used to combine files with the same molecule/isotope ID and with identical p,T,q axes and embedded profiles of Temperature and VMR. Therefore you should create the individual .tab files using the same RFM driver tables changing only the spectral range, and you should not run the tabcmp_x program on the component files before merging (since this changes the p,T,q tabulation axes).
  2. The program can be run on either ASCII or binary versions of the .tab file, and the output can be either binary or ASCII.
  3. The program asks for an original file, and another file to be inserted. The values from the inserted file are used to overwrite those in the original file within the spectral range of the inserted file.
  4. There must be some spectral overlap between the two files, so that some of the original file is always replaced (use program tabmrg if you want to combine files with different spectral ranges).
  5. It is also possible for the entire original file to be replaced if the inserted file covers a wider spectral range. This is effectively just renaming the file, and unlikely to be what you intended, so a warning accompanies this.

Installing tabins

First download the source code: [tabins.f]

Then compile with any FORTRAN77 compiler, eg

f77 tabins.f -o tabins

NB: if using binary .tab files use the same compiler as for the RFM - see Binary Files.

Running tabins

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

A typical run might be (user responses in bold)

tabins R-TABINS: Running TABINS v1.0 List of input files, terminated with <CR> Original file: tab_sf6.asc Inserted file: tab_sf6_940_950.asc Output file: tab_sf6_new.asc R-TABINS: Successful completion

The program should take a few seconds at most, essentially just copying records from the input files to the output file


  1. The first line tells you which version (1.0) of the program is being executed.
  2. The second line asks you for the name of the original file, part of which is to be replaced.
  3. The third line asks you for the file to be inserted
  4. The fourth line asks you for the name of the new output file.
  5. The processing finishes with a 'Successful Completion' message.

Error Messages

When running the program, after responding to the prompt for the input file, the program may halt with a message printed to the terminal

F-RWAXIS: No.p*T*q-axis pts > MAXX'

This is because the total number of Np × NT × Nq axis points exceeds the local array size 10000. To fix this, edit the source code and set PARAMETER MAXX to be ≥ Np × NT × Nq. Similarly for other array size error messages.

Version History

v1.21 (05AUG15)
Change '$' in WRITE statements to avoid gfortran warnings
v1.2 (24FEB15)
Improve auto-detection of input file-type
v1.1 (18DEC14)
Allow for extra format identifier record in .tab file header
v1.00 (01NOV14)
Original code