NAME:
  chfun
 PURPOSE:   (one line only)
  Compute various approximations of the Chandrasekhar H scattering function
 DESCRIPTION:
  This function provide support for computing the Chandrasekhar H-function
    for isotropic scatterers.  The approximations here are taken from
    Hapke's book, Theory of Reflectance and Emittance Spectroscopy,
      second edition.  In the keyword list, the equation and page number is
      listed.
 CATEGORY:
 CALLING SEQUENCE:
  result=chfun(x)
 INPUTS:
  x = Input value, usually cos(i) or cos(e), valid range from [0,1]
  w = single scattering albedo, valid range from [0,1]
 OPTIONAL INPUT PARAMETERS:
 KEYWORD INPUT PARAMETERS:
  Select which treatment of H(x) you want by setting one of these flags
  SUPP - You can eliminate extraneous computations by providing an
           anonymous structure.  The required tags depend on the
           approximation being used.  You can provide more tags than
           needed.  Only those needed are used.
  TWOS - Two stream approximation (eq 8.53, p203)
              supp.gamma 
  H93  - approximation from Hapke 1993
              supp.gamma, supp.r0
  H12  - (default) approximation from Hapke 2012 (ea 8.56, p204)
              supp.r0
           this keyword can be specified if you wish but leaving it
           off
 OUTPUTS:
  return value is the function evaluation
 KEYWORD OUTPUT PARAMETERS:
 CONFIGURATION:
 COMMON BLOCKS:
 SIDE EFFECTS:
 RESTRICTIONS:
  Very little parameter validation is done inside this routine to keep
    it as fast as possible.  The inputs should be either float or double.
    The type and rank should be preserved but it will be according to
    default language behaviors.
  Don't ever specify two approximation types.  No checking is done for
    this and you'll get something that is unpredictable in the long run.
 PROCEDURE:
 MODIFICATION HISTORY:
  Written by Marc W. Buie, Southwest Research Insitute, 2023/08/02