RFM v5 Bugs

This is a list of bugs detected for the new RFM v5.0. See separate page for RFM v4 bugs]

Report any bugs to anu.dudhia@physics.ox.ac.uk

v5 Bug-Finder Hall of Fame (excluding myself since I have an unfair advantage)

  1. Zongxm (IAP, China) (5)
  2. Xiaoying Li (RADI, China) (4)
  3. Olivier Auriacombe (RAL) (1)
  4. Lucy Ventress (AOPP, Oxford) (1)

Where the bug can be corrected by simply downloading a modified subroutine (or subroutines) and recompiling, the necessary modules are listed as Patch.

Reported: 12MAR19
Affects: v5.00–v5.02
Symptom: Using *PHY section to adjust GRAVTY or WGTAIR not having the desired effect
Reason: Profiles of density and refractivity are established (using GRAVTY and WGTAIR) immediately after the *ATM section contents are read (using subroutine atmaux_sub.f90) and not subsequently recalculated when these parameters are modified by the later *PHY section.
Patch: drvphy_sub.f90
Fix: RFM v5.03

Reported: 27FEB19 (Zongxm, IAP, China)
Affects: v5.00--v5.02 up to 10FEB19
Symptom: Fatal array bound error in subroutine spcgrd_sub when using sparse irregular output spectral grid.
Reason: For an irregular output grid, for each widemesh (1cm-1) interval the RFM determines the lower and upper spectral grid points within the interval. However, for a sparse grid, it is possible that there are no points within the interval, so the interval should be skipped. The RFM did not allow for this.
Patch: rfmspc_sub.f90, spcgrd_sub.f90,
Fix: RFM v5.03

Reported: 06FEB19 (Zongxm, IAP, China)
Affects: v5.00, v5.01 and v5.02 pre-release versions up to 04FEB19
Symptom: Anomalous results using cross-section molecules (eg CFC-12)
Reason: The RFM uses triangulation in the (p,T) domain to perform the interpolation of .xsc data to path conditions. However there was an error in limiting the number of triangles created, so that the interpolation was unreliable (the difference only really shows up in calculation Jacobian spectra).
Patch: xsccom_dat.f90, reaxsc_sub.f90, triang_sub.f90, triint_sub.f90, spcxsc_sub.f90
Fix: RFM v5.03

Reported: 30JAN19 (Zongxm, IAP, China)
Affects: v5.02 pre-release versions from 02NOV18
Symptom: Unpredictable results using H2O continuum
Reason: Implementation of new MT_CKD v3.2 subroutine leads to incorrect indexing of internal path segments
Patch: ctmh2o_sub.f90
Fix: RFM v5.02

Reported: 30JAN19 (Zongxm, IAP, China)
Affects: v5.00, v5.01, v5.02 pre-release versions
Symptom: Creating (incorrect) 'off-diagonal' Jacobian spectral files even when JTP Flag enabled.
Reason: Output routine continues to assume all Jacobian combinations are used
Patch: spcout_sub.f90
Fix: RFM v5.02

Reported: 13JAN19 (Zongxm, IAP, China)
Affects: v5.00, v5.01,
Symptom: Fatal error indexing array in intrinsic MATMUL function if using LOS Flag with 3 or more tangent heights.
Reason: Error assigning array indices to highest/lowest tangent heights when determining gradients from quadratic fit.
Patch: spclos_sub.f90
Fix: RFM v5.02

Reported: 30NOV18
Affects: v5.00, v5.01,
Symptom: RFM produces irregular-style output (ie two column format) when combining irregular grid (GRD Flag) with convolution (ILS or AVG Flags).
Reason: Internal spectral grid flagged as irregular for calculations but, after convolution, should then have been reset to regular before output.
Patch: spcils_sub.f90
Fix: RFM v5.02

Reported: 21NOV18
Affects: v5.00, v5.01,
Symptom: Error reading .grd irregular grid file when using combination of GRD and ILS flags AND the *GRD section is specified before the *ILS section in the driver table.
Reason: Until the width of the ILS function is known, the RFM assumes a ±1 cm-1 margin for the ILS convolution when test-loading the irregular grid data. However if the actual grid data is smaller than this, it attempts to read beyond the end of the irregular grid file.
Patch: reagrd_sub.f90
Fix: RFM v5.02

Reported: 12OCT18
Affects: v5.00, v5.01,
Symptom: Overflow characters in output filenames where viewing geometry information should be inserted, eg
Reason: Mismatch between 5 character format field and 6 characters required to hold negative numbers, eg elevation angle -80.0, which becomes '-80000'
Patch: hgtstr_fnc.f90,
Fix: RFM v5.02

Reported: 28JUN18 (Olivier Auriacombe, RAL)
Affects: v5.00, v5.01,
Symptom: Fatal error message
F-ATMPRF: Atmospheric profile levels not yet established
If using HOM flag in combination with atmospheric parameters in *ATM specified by PARAM=VALUE pairs rather than by .atm files.
Reason: Code branch for PARAM=VALUE inputs missed the profile initialisation step used for the file inputs. Now added
Patch: atmpar_sub.f90, atmcom_dat.f90
Fix: RFM v5.02

Reported: 23MAY18 (Lucy Ventress, AOPP, Oxford)
Affects: v5.00
Symptom: Fatal error message
F-SHPGAS: Two different line shapes specified for gas= co2
If using MIX flag in combination with CHI shape specified for CO2 in *SHP section (although OK if CHI shape specified by CHI flag, which is the simpler/recommended method)
Reason: Code for handling different lineshapes assumes CO2 lineshapes already specified by MIX (line-mixing) flag so regards Chi-factor as a conflict. In fact the Chi-shape can be used with or without line-mixing.
Patch: shpgas_sub.f90
Fix: RFM v5.01

Reported: 23MAY18 (Xiaoying Li, RADI, China)
Affects: v5.00
Symptom: Array bound error if using FOV + JAC flag, and tangent paths above the perturbed region
Reason: Coding error in handling assignment of tangent rays with FOV and Jacobian combination. Requires a bit of a rewrite of several modules.
Patch: [none]
Fix: RFM v5.01

Reported: 05MAY18
Affects: v5.00
Symptom: Array bound error if using spectral upper range 980cm-1 with O3 as an absorber
Reason: There is an ozone line in HITRAN2012 (and 2016) at exactly 1006cm-1 which the RFM attempts to include within the ±25cm-1 range of the upper limit of 980cm-1 (which means any line within the 1005–1006cm-1 interval) , which causes the array bound error. Subroutine SPCWID now altered so that any line exactly at the upper limit is not included in the interval.
Patch: spcwid_sub.f90

Reported: 04MAY18 (Xiaoying Li, RADI, China)
Affects: v5.00
Symptom: Array bound error reading HITRAN .par file directly (as opposed to reading converted binary version)
Reason: HITRAN uses '0' in the isotope field to indicated isotope#10, but the subroutine REAPAR was reading this as 0, which then translates to an invalid array element in the list of isotopic weights.
Patch: reapar_sub.f90

Reported: 04MAY18 (Xiaoying Li, RADI, China)
Affects: v5.00
Symptom: Error with FOV flag if the RFM is compiled with
ifort -traceback -check all
Reason: The function FOVFIL reads in the FOV altitudes directly into part of a structure (=derived data type) FOV%ALT. I assume this is not strictly allowed, and reading the data into a local array first seems to fix the problem (no other compilers, switches seem to register this as problematic). I assume there will be other similar occurrences elsewhere in the code if this particular compilation option is used ...
Patch: fovfil_sub.f90

Reported: 03MAY18 (Xiaoying Li, RADI, China)
Affects: v5.00
Symptom: Either crashes or multiple warnings in log file when running with HITRAN2016 data.
Reason: The function VALISO tries issue warning of an unrecognised isotope but local array noting previous warnings (to avoid repetition) was not SAVEd between calls. (This also highlights an additional problem that the RFM is not yet up-to-date with all the new molecules & isotopologues introduced with HITRAN 2016)
Patch: valiso_fnc.f90

Reported: 02MAY18
Affects: v5.00
Symptom: Incorrect calculation for plane-parallel atmospheres (NAD or ZEN flag) with viewing direction specified by elevation angle *ELE section)
Reason: The subroutine VRTPTH assumed all scaling for plane-parallel atmospheres was using sec(zenith) ( *SEC section)
Patch: vrtpth_sub.f90

Reported: 02MAY18
Affects: v5.00
Symptom: Array bound errors when calculating more than one spectral range with FOV flag
Reason: The subroutine SPCFOV, which performs the FOV convolution, re-sizes the data structures used to contain tangent paths required to store FOV paths so they cannot be reused for subsequent spectral ranges
Patch: jacpth_sub.f90, jacfov_sub.f90, spcfov_sub.f90
(jacfov_sub.f90 is a new module so you will need to compile it first before running the v5.00 makefile)
Fix: RFM v5.01