RFM v4 Bugs

Report any bugs to dudhia@atm.ox.ac.uk

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

  1. Victoria Jay (8)
  2. Jolyon Reburn (6)
  3. Luis Millan-Valle (3)
  4. Alison Waterfall (3)
  5. Alastair Burgess (3)
  6. Miguel Lopez-Valverde (2)
  7. Chiara Piccolo (2)
  8. Vivienne Payne (2)
  9. Igor Ptashnik (2)
  10. Richard Siddans (2)
  11. Steve Bass (2)
  12. Niels Bormann (2)
  13. Javier Martin-Torres (2)
  14. Alan Vance (1)
  15. Damien Lafont (1)
  16. Sam Illingworth (1)
  17. Elisa Carboni (1)
  18. Harjinder Sembhi (1)
  19. Claire Waymark (1)
  20. Owen Embury (1)
  21. Damien Weidmann (1)
  22. Aleks Milyakov (1)
  23. Randall Skelton (1)
  24. Tim Nightingale (1)
  25. Clive Rodgers (1)
  26. James Watts (1)
  27. Joanna Haigh (1)
  28. Bob Wells (1)

Bug#80
Reported: 04-AUG-11 (Miguel Lopez-Valverde, IAA)
Affects: Versions all versions to date
Symptom: Possible run-time check failure (depending on compiler) due to using uninitialised variable NSEG2 in rfmpth.for when PTH Flag is enabled. nomenclature
Reason: NSEG2 is unitialised under certain conditions.
Fix: v4.29

Bug#79
Reported: 26-APR-11
Affects: Versions v4.25- v4.28-
Symptom: Isotopic mixing ratio profiles output using PRF Flag have misleading nomenclature
Reason: Error in distinguishing 'default' profile (ie for unspecified isotopes) from others, eg correct profiles might be produced for '*H2O(1)' and '*H2O(4)' but the default profile for other isotopes could be listed as '*H2O(2)' rather than just '*H2O'
Fix: v4.29

Bug#78
Reported: 19-MAR-11 (Alan Vance, UKMO)
Affects: Versions v4.25- v4.28-
Symptom: Aerosol extinction profile output using PRF Flag a factor 1E6 too small.
Reason: Internal conversion of 1E6 applied to all profiles (aerosol as well as VMR) from .atm files on input to convert from ppmv to ppv - the factor wasn't included when writing out aerosol profiles (although was with VMR).
Fix: v4.29

Bug#77
Reported: 07-JAN-11 (Damien Lafont, JPL)
Affects: All versions
Symptom: Warning message during run, eg.
W-QTFCT: Extrap.beyond 70-1500K limits, T= -297.1875
when running in with plane parallel modes (
NAD, ZEN, or FLX flags) and with thin (~1 metre) atmospheric layers
Reason: Analytic expressions for Curtis-Godson equivalent temperature and pressure in subroutine rfmnad.for are numerically unstable for very small pressure differences across a layer, which may result in a negative CG Temperature for path segment, prompting above warning message from subroutine calculating partition functions.
Fix: v4.29

Bug#76
Reported: 03-SEP-09 (Javier Martin-Torres, JPL)
Affects: v4.20 onwards
Symptom: HDO lines may be ignored if 'HDO' specified in *GAS section of the driver table rather than 'H2O(4)'
Reason: Attempting to treat HDO internally as a separate gas with internal ID=39 proves to be a bit of a can of worms! Suggest just using the standard H2O(4) nomenclature until new RFM v4.3 is released (which will have a much simpler, and hopefully more robust, interpretation of 'HDO' (and 'CH3D')
Fix: v4.3

Bug#75
Reported: 08-JUL-09 (Sam Illingworth, U.Leicester)
Affects: v4.28 onwards
Symptom: Program crashes if unexpected fields added to records in the *JAC section (although depends on compiler)
Reason: Overflows 80 characters when trying to write error message explaining that there are unexpected extra fields (this particular bug is a consequence of the fix of Bug#64)
Fix: v4.29

Bug#74
Reported: 08-JUL-09
Affects: all versions
Symptom: JAC flag: aerosol Jacobians could give unpredictable results
Reason: Subroutine PTBATM did not initialise or save aerosol extinction profile between calls.
Fix: v4.29

Bug#73
Reported: 17-MAR-09
Affects: all versions
Symptom: JAC flag: perturbations not associated with a particular altitude (ie column, SFCTEM, SFCEMS) have random text in header of output file
Reason: Subroutine JACNAM attempts to read altitude from non-existent array element when constructing header.
Fix: v4.29

Bug#72
Reported: 25-SEP-08 (Javier Martin-Torres, JPL)
Affects: all versions
Symptom: COO flag (Cooling rates): Unpredictable results (eg "segmentation fault")
Reason: Arrays ITNATM, WGTATM in subroutine rfmflx.for associated with COO are initialised for first wavenumber interval but not explicitly SAVEd between calls, so different machines/compilers can end up replacing original values with random numbers.
Basically same problem as Bug#67 but with variables specific to Cooling Rate calculations.
Fix: v4.29

Bug#71
Reported: 25-SEP-08 (Elisa Carboni)
Affects: all versions
Symptom: JAC flag: Unpredictable results (eg unexpected filenames) or array bound error for particular number of Jacobian spectra
Reason: Logic in subroutine jacchk.for to check if array dimension MAXJAC is exceed was out by 1, so if MAXJAC +1 jacobian outputs are required no error message was generated and array bounds would have been exceeded (however MAXJAC+2 or more would have been correctly detected).
Fix: v4.29

Bug#70
Reported: 01-APR-08 (Jolyon Reburn, RAL)
Affects: all versions
Symptom: May produce fatal error message when trying to specify spectral ranges in *SPC section with a file rather than explicit numbers
Reason: In subroutine inpspc.for the record containing the filename is passed directly to the opnfil.for subroutine to be opened. If there are leading spaces this can cause a fatal error. New version strips off any leading/trailing spaces before opening.
Fix: v4.29

Bug#69
Reported: 12-DEC-07 (Jolyon Reburn, RAL)
Affects: all versions
Symptom: Produces output filenames with a blank space when dealing with tangent heights/elevations represented by small negative values
Reason: In subroutine tanchk.for the user-supplied set of tangent heights/angles are rounded to an integer value and converted to a C*6 character string. For small negative values this comes out as ' 00000' with an empty space instead of a minus sign as the first character.
Fix: v4.28

Bug#68
Reported: 11-DEC-07 (Jolyon Reburn, RAL)
Affects: all versions
Symptom: Stops with unreadable fatal error message while reading *OBS section of driver table when observer above top of atmosphere
Reason: Subroutine obschk.for was incorrectly returning a fatal error condition with no error message defined.
Fix: v4.28

Bug#67
Reported: 21-NOV-07 (Miguel Lopez-Valverde, IAA Granada)
Affects: all versions
Symptom: Unreliable results when using FLX flag for ranges spanning more than one wavenumber interval.
Reason: Some variables in subroutine rfmflx.for are evaluated on the first call (for first 1cm-1 interval) but not saved between calls, so outcome depends on what machine does to unsaved variables.
Fix: v4.28

Bug#66
Reported: 15-NOV-07 (Harjinder Sembhi, U.Leicester)
Affects: all versions
Symptom: Fails to spot some fatal errors in entries in *JAC section
Reason: A number of fatal error checks in subroutine jacchk.for cause a RETURN to be executed but the FAIL flag is set FALSE, so the external routine ignores it.
Fix: v4.28

Bug#65
Reported: 05-JUL-07 (and several times previously)
Affects: all versions
Symptom: Obscure fatal error message about duplicate driver table sections, eg
F-INPILS: Duplicate *ILS section in Driver Table
where driver table (
rfm.drv) file is not properly terminated with *END<CR> record (usually because the <CR> has been omitted)
Reason: No special handling for 'end-of-file' when reading driver table section headers, so the record containing the last valid section header (*ILS in the example above) is effectively read again. (New versions of the RFM will simply print a warning message to the rfm.runlog file, then assume that the driver file is now terminated and carry on as normal)
Fix: v4.28

Bug#64
Reported: 25-JUN-07 (Luis Millan-Valle)
Affects: v4.26-v.27
Symptom: Fatal error message
F-JACIGQ: Unable to parse IGQSTR: (...
when calculating vibrational temperature Jacobians where combined '(gas)(i)(v)' string in
*JAC section exceeds 8 characters.
Reason: Subroutine inpjac.for truncates all Jacobian targets to C*8, failing to allow for additional characters '(v)' to identify VT level.
Fix: v4.28

Bug#63
Reported: 20-JUN-07 (Claire Waymark)
Affects: v4.25-v.27
Symptom: Combining PRF Flag with cross-section molecules (ID 50 or higher) results in fatal error message:
F-RFMPRF: Logical error
Reason: Subroutine rfmprf.for fails to check for cross-section molecules before checking for isotopic profiles
Fix: v4.28

Bug#62
Reported: 28-MAR-07 (Luis Millan-Valle)
Affects: All versions up to and including v4.27
Symptom: Fails to skip empty record in *JAC section of driver table (and probably other sections as well) - resulting in a fatal error message
Reason: Under Linux, subroutine nxtrec.for, which should skip blank records, interprets <CR> as a non-blank character, hence assumes that there is something readable in the record
Fix: v4.28

Bug#61
Reported: 03-APR-06 (Owen Embury, Edinburgh)
Affects: Versions v4.25 & v4.26
Symptom: Unpredictable results when using LEV flag with F77 compilations which do not automatically save variables inside subroutines.
Reason: Variables IJAC1, IJAC2 in subroutine levupd.for sometimes assume previous values are saved.
Fix: v4.27

Bug#60
Reported: 12-OCT-05 (Damien Weidmann, RAL)
Affects: All versions up to and including v4.25
Symptom: Incorrect Brightness Temperature Jacobians (combination of BBT and JAC flags.
Reason: RFM was calculating brightness temperature of difference in radiance between perturbed and unperturbed atmospheres, instead of the difference in the brightness temperatures.
Fix: v4.26

Bug#59
Reported: 19-JUL-05 (Alison Waterfall, RAL)
Affects: All versions up to and including v4.25
Symptom: Unpredictable results in regions of line-mixing when using MIX flag and gases in addition to CO2.
Reason: Line-mixing lineshape routine (MIXSHP) called for all gases although one of the line-mixing parameters (YMXADJ) is only set for CO2, so other gases inherit last set value of YMXADJ instead of 0.
Fix: v4.26

Bug#58
Reported: 10-JUN-05 (Alison Waterfall, RAL)
Affects: All versions up to and including v4.25
Symptom: Failure to read ASCII LUT files created with TAB option where number of wavenumber points is GE 1E6.
Reason: Format field in output (opntab.for) only allows I6 so, when read free-format on input, field becomes indistinguishable from previous field (which is "0").
Fix: v4.26

Bug#57
Reported: 05-MAY-05 (Alastair Burgess)
Affects: All versions up to and including v4.25
Symptom: Use of wildcard "*" in *GAS section produces no absorbers
Reason: Variable IMIN in subroutine GASALL not SAVEd (this is the threshold level for deciding which absorbers to use which should be 0 by default).
Fix: v4.26

Bug#56
Reported: 03-MAY-05 (Alastair Burgess)
Affects: All versions up to and including v4.25
Symptom: Fails with "Segmentation Fault" when using heavy molecule cross-section (.xsc) files
Reason: Variable NTRI in subroutine TRIANG not SAVEd (this is the triangulation of the cross-section data in (p,T) coordinates).
Fix: v4.26

Bug#55
Reported: 08-MAR-05
Affects: All versions up to and including v4.25
Symptom: `Not a Number' or similar error message
Reason: Ray tracing for cases where tangent point is very close to the top of a layer can occasionally result in a negative absorber amount
Fix: v4.26

Bug#54
Reported: 04-FEB-05
Affects: RFM v4.23-v4.25
Symptom: Occasional failure in ray-tracing with `floating point invalid' type message (taking square root of negative number) during Jacobian calculations (JAC flag) for temperature or pressure.
Reason: density scale height was being calculated from refractivity scale height before refractivity profile was updated (subroutine atmaux.for)
Fix: v4.26

Bug#53
Reported: 11-JAN-05
Affects: All versions of the RFM up to and including v4.25
Symptom: MIX (line mixing) flag has no effect when using special versions of HITRAN-format file developed for MIPAS.
Reason: Additional rotational quantum numbers inserted into the HITRAN records where blank characters are expected (subroutine ymix.for searches for matches of these fields with its list of transitions for which line mixing effects are included).
Fix: v4.26

Bug#52
Reported: 01-JUN-04
Affects: RFM v4.22-v4.24
Symptom: occasionally incorrect spectral calculations when using combination of ILS and GRD flags.
Reason: The direct interpolation from irregular grid to ILS-convolved output grid introduced in v4.22 can lead to uninitialised array elements being included in the summation.
Fix: v4.25

Bug#51
Reported: 22-MAR-04
Affects: RFM v4.23, v4.24
Symptom: rfm.runlog file contains incorrect spectral range information in message
I-SPCCHK: Label= ...
and may lead to array bound error.
Reason: Incorrect spectral range index (true value - 1) used in constructing message text
Fix: v4.25

Bug#50
Reported: 12-MAR-04 (Vivienne Payne)
Affects: All versions of the RFM using combination of CTM flag and different H2O isotopic profiles
Symptom: Incorrect handling of subtraction of 25cm-1 offset for combination with continuum for isotopic profiles
Reason: Variable isotopes handled as separate species but continuum flag only set for default profile
Fix: v4.25

Bug#49
Reported: 25-OCT-03 (Anu Dudhia)
Affects: All versions of the RFM using combination of OBS and JAC flags
Symptom: Jacobians incorrect if *JAC section specified in driver table before the *OBS AND the observer altitude is not an internal profile level AND jacobians are defined for levels at or above the observer height
Reason: Subroutine OBSATM which inserts extra atmospheric level for the observer height does not allow for change in level numbering in definition of perturbed levels for Jacobians.
Fix: v4.24

Bug#48
Reported: 21-OCT-03 (Vivienne Payne, Oxford)
Affects: RFM v4.22,4.23 using combination of OBS and JAC flags
Symptom: Jacobians sometimes incorrect
Reason: Ray-tracing RFMRAY contains a short cut to prevent repeated calculations for Jacobians through atmospheric layers which are unchanged, but this short cut is only valid for observervations outside the atmosphere.
Fix: v4.24

Bug#47
Reported: 30-APR-03 (Aleks Milyakov, Russia)
Affects: All versions of the RFM
Symptom: Lines falling exactly on upper boundary of widemesh interval N are counted twice in interval N-2:N-1 (eg a line exactly at 1000cm-1 is counted as two lines in the interval 998-999cm-1).
Reason: Test on lines in finemesh calculation uses .LE. instead of .LT. when deciding whether the upper boundary should be included
Fix: v4.23

Bug#46
Reported: 30-APR-03 (Chiara Piccolo, Oxford)
Affects: All versions of the RFM using some Linux systems
Symptom: Carriage return character appears at end of 2nd header record of output spectra (the user-supplied comment record entered in the *HDR section of the driver table)
Reason: Carriage Return characters handled differently in Linux and Unix (see also Bug#40)
Fix: v4.23

Bug#45
Reported: 28-APR-03 (Anu Dudhia)
Affects: RFM v4.10 onwards using PTH flag (path diagnostics) plus OBS flag (observer within atmosphere) plus
Symptom: Extra atmospheric layer included in path diagnostics
Reason: Starting integration at layer above observer
Fix: v4.23

Bug#44
Reported: 10-MAR-03 (Anu Dudhia)
Affects: RFM v4.12 onwards using FLX flag, flux calculations.
Symptom: floating zero divide in second widemesh interval
Reason: Resetting pi factor=0.0 in rfmflx.for after first widemesh interval - should be either be 3.14...etc or 1.0 (using VRT flag)
Fix: v4.22

Bug#43
Reported: 20-FEB-03 (Niels Bormann, ECMWF)
Affects: RFM using a combination of GRD and TAB flags, generating direct look-up tables on an irregular grid
Symptom: generated grid files displaced by one or two spectral points
Reason: Not allowing for RFM adding internal grid points at wide mesh boundaries
Fix: v4.22

Bug#42
Reported: 13-FEB-03 (Niels Bormann, ECMWF)
Affects: RFM using a combination of GRA and JAC flags, ie creating Jacobians from a two-dimensional atmosphere
Symptom: Program stops with error message printed to terminal
STOP F-RFMPTB: Logical Error#3
Reason: Unforeseen error when deciding which Jacobian path segments can be derived from simple mass-scaling of other path segments.
Fix: v4.22

Bug#41
Reported: 18-JAN-03 (Anu Dudhia)
Affects: All versions of the RFM using a combination of spectral ranges some with valid LUTs and some without
Symptom: no fine mesh calculation for spectral ranges without LUTs
Reason: When a spectral range is calculated using a Look-Up Table this flags the HITRAN database reading routine REACYC as having reached the end of the database file, so subsequent spectral ranges which may require HITRAN data if no LUT data available do not read any line information.
Fix: v4.22

Bug#40
Reported: 13-JAN-03 (Anu Dudhia)
Affects: All versions of the RFM using some Linux systems
Symptom: Garbled rfm.runlog files and occasionally unable to read driver table entries
Reason: Carriage Return character not handled properly
Fix: v4.22

Bug#39
Reported: 13-JAN-03 (Anu Dudhia)
Affects: All versions of the RFM using GRD flag but with no valid files in the *GRD section
Symptom: Fatal error message:
 F-FINCHK: fine mesh resolution inconsistent with irregular grid resolution
Reason: FINCHK checks that the internal fine mesh resolution (e.g. 0.0005cm-1) is compatible with the resolution of the irregular grid data supplied in the *GRD section, however if no valid GRD files have been found (ie not overlapping any required output spectral range) the grid file resolution is not set (so, for example, may be zero), so the two numbers being compared will not agree.
Fix: v4.22

Bug#38
Reported: 01-DEC-02 (Anu Dudhia)
Affects: v4.21 using molecules with HITRAN index > 14 at wavenumbers near zero
Symptom: Fatal error message:
 F-INIHFL: Failed to read HITRAN file, rec#:          0. IOSTAT=         25
(number 25 is machine dependent)
Reason: failing to set forward pointers for molecules ID#15 onwards when winding back from initial wavenumber if within 25cm-1 of start of HITRAN file so attempts to access record#0 of the HITRAN file instead.
Fix: v4.22

Bug#37
Reported: 18-JUL-02 (Randall Skelton, Oxford)
Affects: v3.90 onwards using LUN flag (re-use LUNs for output spectra) with different types of spectra, e.g. output both radiance (RAD flag) and transmittance (TRA flag) spectra.
Symptom: All files correctly opened but all types of spectra written to only one type of file.
Reason: Incorrect logic in subroutine opnout.for/wrtout.for
Fix: v4.21

Bug#36
Reported: 29-MAY-02 (Anu Dudhia)
Affects: v4.10 onwards using PTH flag (path diagnostics) plus GRA flag (2D atmosphere) with more than one absorber
Symptom: Only writes path diagnostics for upward path for second and subsequent absorbers
Reason: Incorrect logic in subroutine rfmpth.for
Fix: v4.21

Bug#35
Reported: 23-JAN-02 (Tim Nightingale, RAL)
Affects: v4.10 onwards using COO flag (cooling rates)
Symptom: Cooling rates too high by a factor of about 1000
Reason: Incorrect value of molar heat capacity of air CPMOL in phycon.inc (1005/28.964 was used, should have been 1005*28.964).
Fix: v4.12

Bug#34
Reported: 04-JAN-02 (Victoria Jay, RAL)
Affects: v4.10 onwards using JAC flag (Jacobians)
Symptom: Occasional array bound error, or incorrect Jacobian element
Reason: When looking for similar CG paths to save additional computations for Jacobian elements, RFMPTB fail to account for the (rare) situation when the similar path used is itself scaled to another similar path (don't worry - I understand what that means).
Fix: v4.12

Bug#33
Reported: 17-DEC-01 (Anu Dudhia)
Affects: v4.10 onwards using combination of TAB + GRD (creating look-up tables with irregularly spaced wavenumber axes) for more than one absorber.
Symptom: Irregular grid data only written into table of the last absorber
Reason: Failure to write irregular grid data to all absorber tables.
Fix: v4.12

Bug#32
Reported: 13-DEC-01 (Anu Dudhia)
Affects: all previous versions calculating Pressure and Temperature Jacobians
Symptom: Small discrepancy between independently differenced spectra
Reason: Failure to allow for perturbed refractive index when perturbing pressure or temperature.
Fix: v4.12

Bug#31
Reported: 13-DEC-01 (Victoria Jay, Oxford/RAL)
Affects: all previous versions calculating Pressure and Temperature Jacobians with non-zero aerosol extinction
Symptom: Discrepancy between independently differenced spectra
Reason: Code kept original value of (extinction/density) when multiplying by perturbed density, effectively treating extinction/density as the conserved quantity. Correct approach is to maintain extinction constant so that for pure aerosol absorption, density variations have no Jacobian signal.
Fix: v4.12

Bug#29
Reported: 12-DEC-01 (Anu Dudhia)
Affects: all previous versions run under certain compilers (eg Linux g77)
Symptom: Various discrepancies in results
Reason: Failure to save variables in subroutines (With most compilers all subroutine variables are automatically saved between calls, but not with g77). NB: there are probably several more bugs of this type which haven't yet been iedentified - users of the g77 compiler be warned
Fix: v4.12

Bug#28
Reported: 04-DEC-01 (Clive Rodgers, Oxford)
Affects: all previous versions run under certain compilers (eg Linux g77) when using spectral convolutions (either the ILS or AVG flags)
Symptom: Output spectra severely distorted
Reason: Failure to save variable IDXBUF in subroutine RFMILS.FOR (With most compilers all subroutine variables are automatically saved between calls, but not with g77).
Fix: v4.12

Bug#27
Reported: 28-NOV-01 (Alison Waterfall, Oxford)
Affects: all previous versions when using line-mixing (MIX flag)
Symptom: Output spectra sometimes displaced by 1 or 2 complete wavenumbers
Reason: When including line mixing it is necessary to include complete CO2 bands within the +/-25cm margins for the widemesh calculation. Where the -25cm-1 lower limit intersected a band (12 bands, 2-3cm-1 wide - see SPCWID.FOR), instead of just stretching the margins for the widemesh calculation the RFM was also adding a 1 or 2cm-1 offset to the output spectrum.
Fix: v4.12

Bug#26
Reported: 28-NOV-01 (Igor Ptashnik, Reading)
Affects: all previous versions when using limb viewing paths
Symptom: Floating zero divide (or large error)
Reason: When performing the ray-tracing each atmospheric layer is subdivided into 10 or more path segments for the Curtis-Godson integrations. There is a small probability that the final segment within a layer is large enough to be non-zero but too small to evaluate the Curtis-Godson integrations reliably.
Fix: v4.12

Bug#25
Reported: 04-NOV-01 (Anu Dudhia)
Affects: v4.10 and v4.11 when using FLX flags without ZEN flag or SFC flag
Symptom: If SFC flag not enabled, the surface treated as zero emission/reflection in flux calculations
Reason: No check that the user has enabled SFC flag if FLX is enabled without ZEN flag.
Fix: v4.12

Bug#24
Reported: 31-OCT-01 (Igor Ptashnik, Reading)
Affects: All previous versions using ZEN flag
Symptom: Slow calculation compared to using limb-type calculations with elevation angle (*ELE) set to 90deg.
Reason: Line-by-line calculations performed for entire atmosphere not just layers above the observer
Fix: v4.12

Bug#23
Reported: 31-OCT-01 (Anu Dudhia)
Affects: v4.10 and v4.11 when using FLX flag (flux calculations) with NAD flag (downward-looking hemisphere only) above a reflecting surface
Symptom: Incorrect radiance fluxes and cooling rates
Reason: Downward path contribution to net flux is not removed (so NAD flag has no effect)
Fix: v4.12

Bug#22
Reported: 15-AUG-01 (Anu Dudhia)
Affects: All versions when using LIN flag (Linear interpolation of VMR with height) with anything other than limb-viewing.
Symptom: Identical to LIN flag disabled (ie log(VMR) interpolation)
Reason: No special treatment for linear interpolation when calculating Curtis-Godson parameters for plane parallel atmosphere
Fix: v4.11

Bug#21
Reported: 23-MAY-01 (James Watts, Oxford)
Affects: v4.10 onwards when using GRA flag (Horizontal gradients) with psi angles less than minimum value used for profiles (ie raypaths extending beyond specified profiles on the side away from the observer)
Symptom: Incorrect atmospheric paths
Reason: Atmosphere beyond low-psi limit is being extrapolated from last two specified profiles rather than assumed constant (as for the high-psi case)
Fix: v4.11

Bug#20
Reported: 04-MAY-01 (Victoria Jay, Oxford)
Affects: v3.82 onwards when using JAC flag (Jacobians) in combination with GRD (irregular grids).
Symptom: Incorrect Jacobians calculated with irregular grids.
Reason: Interpolation from irregular to fine grid only looping over nominal tangent paths, not additional paths required for Jacobians.
Fix: v4.11

Bug#19
Reported: 22-MAR-01 (Jolyon Reburn, RAL)
Affects: v4.10 when using GRA flag (horizontal gradients).
Symptom: Program sometimes hangs during ray-tracing (after driver table read in, but before start of line-by-line calculations)
Reason: 2D ray-tracing numerical integration doesn't converge in situations where zero path length is required
Fix: v4.11

Bug#18
Reported: 20-MAR-01 (Anu Dudhia)
Affects: versions v3.50-v4.10 when using an Irregular Grid (GRD flag) which is not on the same resolution as the fine mesh calculation.
Symptom: Incorrect fine grid interpolation
Reason: Irregular grids can only be used for one particular fine grid spacing, no checks were performed to ensure this was the case.
Fix: v4.11

Bug#17
Reported: 20-MAR-01 (Victoria Jay, Oxford)
Affects: all versions up to v4.10 using combination of different spectral ranges (multiple records in the *SPC section) plus range-specific ILS functions (ILS flag) where one of the ranges has no defined ILS function plus no default ILS function (bit of an obscure combination, really).
Symptom: Unpredictable.
Reason: RFM checks that each spectral range has a defined ILS function, but fails to exit and report error in the case when it doesn't.
Fix: v4.11

Bug#16
Reported: 16-MAR-01 (Richard Siddans, RAL)
Affects: all versions up to v4.10 when using combination of CRV flag and FOV or geometric tangent heights (specified using *GEO or *ELE marker for the *TAN section).
Symptom: User-specified radius of curvature not used in calculating refracted (actual) tangent heights.
Reason: Refracted tangent heights are calculated with the default radius of curvature (REARTH in phycon.inc), but ray-tracing, using these tangent heights is performed with the user-specified radius.
Fix: v4.11

Bug#15
Reported: 26-FEB-01 (Jolyon Reburn, RAL)
Affects: all versions up to v4.10 when `unusual` spectral resolutions are specified in the *SPC section (e.g., '0.0001999999' )
Symptom: Discrepancy between number of spectral points indicated in header of output spectra and number of points actually written
Reason: Algorithm for calculating number of widemesh intervals occasionally underestimates number required to cover full output spectrum due to truncation errors.
Fix: v4.11

Bug#14
Reported: 26-JAN-01 (Jolyon Reburn, RAL)
Affects: all versions up to v4.10 when no gases are specified in the *GAS section (e.g. by using *(20) with the wild-card parameter set too high)
Symptom: Floating zero divide
Reason: Diagnostic message produced by RFMSCA.FOR doesn't allow for zero paths when calculating fraction of paths that will be scaled.
Fix: v4.11

Bug#13
Reported: 26-JAN-01 (Richard Siddans, RAL)
Affects: v4.10 using both GRA and GEO flags together.
Symptom: Floating zero divide
Reason: Setting Refractive Index=0 rather than 1 in subroutine GRADVS.FOR when performing 2-dimensional ray-trace with refraction switched off.
Fix: v4.11

Bug#12
Reported: 26-JAN-01 (Victoria Jay, Oxford)
Affects: all versions up to v4.10 with ILS or AVG flags and at an output resolution finer than 0.0005 cm-1.
Symptom: Floating zero divide
Reason: ILS/AVG convolutions had assumed that the output resolution would always be coarser than the default internal fine grid (0.0005cm-1).
Fix: v4.11

Bug#11
Reported: 20-DEC-00 (Steve Bass, Oxford)
Affects: all versions up to v4.09 with HOM flag and at least two files describing homogeneous path in the *ATM section, and with a replacement pressure value in the second or subsequent file
Symptom: Floating overflow
Reason: Replacement pressure profiles are usually extrapolated (as log(pressure)) to fit original altitude grid, but with only one "altitude", the extrapolation routine breaks down. Other species, and temperature, are not extrapolated so should be OK anyway.
Fix: v4.10

Bug#10
Reported: 07-NOV-00 (Anu Dudhia)
Affects: v4.04 - v4.09 with SFC flag and reflective surfaces
Symptom: Floating overflow or logarithm of 0
Reason: At surface, transmittance is scaled by surface reflectivity r as tau*r, and optical depth is reevaluated as -log(tau). However, if the atmospheric transmittance is already zero at the surface, this leads to an error. Solution is to evaluate increase in optical depth directly as -ln(r).
Fix: v4.10

Bug#9
Reported: 20-SEP-00 (Victoria Jay, Oxford)
Affects: All previous versions with FOV plus CLC flags both enabled and multiple tangent paths.
Symptom: Slight variations in radiance according to number of different tangent heights calculated in single run
Reason: CLC flag only forced separate paths to be used for each tangent ray constituting the FOV, but did not prevent closely spaced tangent paths from overlapping FOVs to be regarded as the same if the spearation was less than 10% of the FOV spacing. This tolerance has now been reduced to 1%, and 0% if CLC flag is enabled.
Fix: v4.10

Bug#8
Reported: 06-AUG-00 (Steve Bass, Oxford)
Affects: v3.82 onwards with JAC plus HOM flags both enabled.
Symptom: Creates zero Jacobian spectra for homogeneous path case
Reason: HOMPTH resetting number of paths so perturbed paths are ignored
Fix: v4.10

Bug#7
Reported: 26-APR-00 (Anu Dudhia)
Affects: All versions up to v4.04 using wavenumbers near 0.0
Symptom: Program crashes with floating overflow in subroutine VOISHP
Reason: VOISHP doesn't allow for v.small Doppler widths associated with O2 line at 1e-5 cm-1.
Fix: v4.10

Bug#6
Reported: 14-APR-00 (Joanna Haigh, Imperial)
Affects: v3.82 - v4.03 using SFC flag AND surface emissivities < 1.
Symptom: Incorrect reflected radiance contribution.
Reason: Transmittance term for contributions of reflected ray failed to allow for reduction in transmittance upon surface reflection, so reflected atmospheric contribution to radiances is overestimated.
Fix: v4.04

Bug#5
Reported: 13-APR-00 (Anu Dudhia)
Affects: All versions up to and including v4.03 when using WID flag (widemesh diagnostics) AND more than one spectral range in *SPC section.
Symptom: Incorrect line counts for second and subsequent spectral ranges in widemesh diagnostic output.
Reason: Failing to reinitialise line counts at start of each new spectral range.
Fix: v4.04

Bug#4
Reported: 08-DEC-99 (Victoria Jay, Oxford)
Affects: All versions up to and including v4.02 when compiled with the Fujitsu Linux compiler with switch -Xf7 (and probably some other compilers too).
Symptom: Slightly random output filenames (confusing, but not fatal).
Reason: Filenames were constructed from templates by inserting tangent height etc information using a non-standard FORTRAN77 construction of the typical form
FILNAM = FILNAM(1:10)//TANHGT(1:5)//FILNAM(11:20)
On most machines this is interpreted as intended, i.e., with the TANHGT substring inserted at character positions 11 in FILNAM, and the remaining FILNAM characters appended. However, the Fujitsu compiler appears to assign TANHGT to FILNAM(11:15) before determining FILNAM(11:20). In `correct' FORTRAN77 usage the same part of a character string should not appear on both the left and right sides of an assignment statement, as it does above. (NB The above assignment is valid under FORTRAN 95).
Fix: v4.03

Bug#3
Reported: 04-NOV-99 (Bob Wells, Oxford)
Affects: v3.43 onwards, when using CTM flag and NOCTM qualifier with H2O
Symptom: Incorrectly calculated H2O lines
Reason: CTM flag should switch on continuum calculations for all species (ie CO2, H2O, O2 and N2), but NOCTM qualifier after species name should switch it off again for a particular species. However, for water vapour, the NOCTM only switched off part of the continuum calculation: the application of the continuum itself, it did not switch off the truncation of the H2O lines at their +/- 25cm-1 values.
Fix: v4.02

Bug#2
Reported: 04-NOV-99 (Victoria Jay, Oxford)
Affects: v3.7 onwards, when tangent heights (*TAN section) are expressed as ELEvation angles or GEOmetric heights
Symptom: Very occasionally, a fatal error condition arises with the message: F-TANCNV: Failed to converge
Reason: For a given geometric tangent height, the actual refracted tangent height is determined by an iterative procedure which usually converges to 1m accuracy within 3 iterations. However, occasionally the solution appears to oscillate, in which case the maximum allowed number of iterations (10) was exceeded and a fatal error condition was set. Now when this happens, it is assumed that the refracted tangent height can be taken as the mean of the last two iterative values, although a warning message is still printed to the terminal: W-TANCNV: Failed to converge
Fix: v4.02

Bug#1
Reported: 12-OCT-99 (Anu Dudhia)
Affects: SFC Flag used with limb-viewing
Symptom: If SFC flag is switched on, all limb viewing tangent heights are treated as intersecting the surface, even if the tangent height is above the surface.
Reason: Routine RFMRAD.FOR only checked status of SFC before deciding whether or not to insert the surface calculation at the lowest point on the ray path, it didn't check to see if ray actually intersected the surface
Fix: v4.01