GAL_FLAT $SSW/gen/idl_libs/astron/astro/gal_flat.pro
[Previous] [Next]
 NAME:
	GAL_FLAT

 PURPOSE:
	Transforms the image of a galaxy so that the galaxy appears face-on
 EXPLANATION:
	Either a nearest-neighbor approximations or a bilinear interpolation 
	may  be used.

 CALLING SEQUENCE:
	RESULT = GAL_FLAT( image, ang, inc, [, cen, /INTERP ] )  

 INPUTS:   
	IMAGE  - Image to be transformed
	ANG  - Angle of major axis, counterclockwise from Y-axis, degrees
		For an image in standard orientation (North up, East left)
		this is the Position Angle
	INC - Angle of inclination of galaxy, degrees

 OPTIONAL INPUTS:
	CEN - Two element vector giving the X and Y position of galaxy center
		If not supplied, then the galaxy center is assumed to coincide
		 with the image center

 INPUT KEYWORDS:
	INTERP - If present, and non-zero, then bilinear interpolation will be
		performed.  Otherwise a nearest neighbor approximation  is used.

 OUTPUTS:
	RESULT - the transformed image, same dimensions and type as IMAGE

 METHOD:
	A set of 4 equal spaced control points are corrected for inclination
	using the procedure POLYWARP.   These control points are used by 
	POLY_2D to correct the whole image.

 REVISION HISTORY:
	Written by R. S. Hill, SASC Technologies Inc., 4 December 1985
	Code cleaned up a bit    W. Landsman      December 1992
	Converted to IDL V5.0   W. Landsman   September 1997
 CALLS:


GAL_UVW $SSW/gen/idl_libs/astron/astro/gal_uvw.pro
[Previous] [Next]
 NAME:
     GAL_UVW
 PURPOSE:
     Calculate the Galactic space velocity (U,V,W) of star  
 EXPLANATION:
     Calculates the Galactic space velocity U, V, W of star given its 
     (1) coordinates, (2) proper motion, (3) distance (or parallax), and 
     (4) radial velocity.
 CALLING SEQUENCE:
     GAL_UVW, U, V, W, [/LSR, RA=, DEC=, PMRA= ,PMDEC=, VRAD= , DISTANCE= 
              PLX= ]
 OUTPUT PARAMETERS:
      U - Velocity (km/s) positive toward the Galactic *anti*center
      V - Velocity (km/s) positive in the direction of Galactic rotation
      W - Velocity (km/s) positive toward the North Galactic Pole 
 REQUIRED INPUT KEYWORDS:
      User must supply a position, proper motion,radial velocity and distance
      (or parallax).    Either scalars or vectors can be supplied.
     (1) Position:
      RA - Right Ascension in *Degrees*
      Dec - Declination in *Degrees*
     (2) Proper Motion
      PMRA = Proper motion in RA in arc units (typically milli-arcseconds/yr)
      PMDEC = Proper motion in Declination (typically mas/yr)
     (3) Radial Velocity
      VRAD = radial velocity in km/s
     (4) Distance or Parallax
      DISTANCE - distance in parsecs 
                 or
      PLX - parallax with same distance units as proper motion measurements
            typically milliarcseconds (mas)

 OPTIONAL INPUT KEYWORD:
      /LSR - If this keyword is set, then the output velocities will be 
             corrected for the solar motion (U,V,W)_Sun = (-9,+12,+7)  
             (Mihalas & Binney, 1981) to the local standard of rest
  EXAMPLE:
      (1) Compute the U,V,W coordinates for the halo star HD 6755.  
          Use values from Hipparcos catalog, and correct to the LSR
      ra = ten(1,9,42.3)*15.    & dec = ten(61,32,49.5)
      pmra = 627.89  &  pmdec = 77.84         ;mas/yr
      dis = 144    &  vrad = -321.4
      gal_uvw,u,v,w,ra=ra,dec=dec,pmra=pmra,pmdec=pmdec,vrad=vrad,dis=dis,/lsr
          ===>  u=154  v = -493  w = 97        ;km/s

      (2) Use the Hipparcos Input and Output Catalog IDL databases (see 
      http://idlastro.gsfc.nasa.gov/ftp/zdbase/ )to obtain space velocities
      for all stars within 10 pc with radial velocities > 10 km/s

      dbopen,'hipparcos,hic'      ;Need Hipparcos output and input catalogs
      list = dbfind('plx>100,vrad>10')      ;Plx > 100 mas, Vrad > 10 km/s
      dbext,list,'pmra,pmdec,vrad,ra,dec,plx',pmra,pmdec,vrad,ra,dec,plx
      ra = ra*15.                 ;Need right ascension in degrees
      GAL_UVW,u,v,w,ra=ra,dec=dec,pmra=pmra,pmdec=pmdec,vrad=vrad,plx = plx 
      forprint,u,v,w              ;Display results
 METHOD:
      Follows the general outline of Johnson & Soderblom (1987, AJ, 93,864)
      except that U is positive outward toward the Galactic *anti*center, and 
      the J2000 transformation matrix to Galactic coordinates is taken from  
      the introduction to the Hipparcos catalog.   
 REVISION HISTORY:
      Written, W. Landsman                       December   2000


GALAGE $SSW/gen/idl_libs/astron/astro/galage.pro
[Previous] [Next]
 NAME: 
   GALAGE

 PURPOSE:
   Determine the age of a galaxy given its redshift and a formation redshift.

 CALLING SEQUENCE:
   age = galage(z, [zform,  H0 =, k=, lambda0 =, Omega_m= , q0 =, /SILENT])' 

 INPUTS:
    z - positive numeric vector or scalar of measured redshifts 
    zform - redshift of galaxy formation (> z), numeric positive scalar 
        To determine the age of the universe at a given redshift, set zform
        to a large number (e.g. ~1000).

 OPTIONAL KEYWORD INPUTS: 
    H0 - Hubble constant in km/s/Mpc, positive scalar, default is 70
    /SILENT - If set, then the adopted cosmological parameters are not 
         displayed at the terminal.

        No more than two of the following four parameters should be
        specified.   None of them need be specified -- the adopted defaults
        are given. 
    k - curvature constant, normalized to the closure density.   Default is
        0, (indicating a flat universe)
    Omega_m -  Matter density, normalized to the closure density, default
        is 0.3.   Must be non-negative
    Lambda0 - Cosmological constant, normalized to the closure density,
        default is 0.7
    q0 - Deceleration parameter, numeric scalar = -R*(R'')/(R')^2, default
        is -0.5
       
 OUTPUTS:
    age -  age of galaxy in years, will have the same number of elements
           as the input Z vector

 CALLS: ***
	COSMO_PARAM, DTDZ, QSIMP
 EXAMPLE:
    (1) Determine the age of a galaxy observed at z = 1.5 in a cosmology with
    Omega_matter = 0.3 and Lambda = 0.0.    Assume the formation redshift was
    at z = 25, and use the default Hubble constant (=70 km/s/Mpc)

    IDL> print,galage(1.5,25,Omega_m=0.3, Lambda = 0)
             ===> 3.35 Gyr
     
    (2) Plot the age of a galaxy in Gyr out to a redshift of z = 5, assuming 
        the default cosmology (omega_m=0.3, lambda=0.7), and zform = 100

    IDL> z = findgen(50)/10.
    IDL> plot,z,galage(z,100)/1e9,xtit='z',ytit = 'Age (Gyr)'

 PROCEDURE:
    For a given formation time zform and a measured z, integrate dt/dz from 
    zform to z. Analytic formula of dt/dz in Gardner, PASP 110:291-305, 1998 
    March  (eq. 7)
 
 COMMENTS:
    (1) Integrates using the IDL Astronomy Library procedure QSIMP.    (The 
    intrinsic IDL QSIMP() function is not called because of its ridiculous
    restriction that only scalar arguments can be passed to the integrating
    function.)    The function 'dtdz' is defined at the beginning of the 
    routine (so it can compile first).
    
    (2) Should probably be fixed to use a different integrator from QSIMP when
    computing age from an "infinite" redshift of formation.    But using a 
    large value of zform seems to work adequately.

     (3) An alternative set of IDL procedures for computing cosmological
    parameters is available at 
            http://cerebus.as.arizona.edu/~ioannis/research/red/
 PROCEDURES CALLED:
    COSMO_PARAM, QSIMP
 HISTORY: 
     STIS version by P. Plait (ACC)                  June 1999
     IDL Astro Version   W. Landsman (Raytheon ITSS)      April 2000
     Avoid integer overflow for more than 32767 redshifts  July 2001


GAMINC [1] $SSW/gen/idl/spectra/gaminc.pro
[Previous] [Next]
 NAME:
   GAMINC
 PURPOSE:
   Compute the function = exp(X) / X^P * Int[exp(-X)*X^(P-1)dx]
                                       (Int = Integrate from X to Infinity)
 CALLING SEQUENCE:
   Result = gaminc(P,X)                ; X>0

 INPUTS:
   X and P     See expression above for details
 RETURNS:
       Expression returned is a vector the same length as X.
 CALLS: ***
	GAMMA, igamma2 [1], igamma2 [2]
 CALLED BY:
	collexc [1], collexc [2]
 HISTORY:
    1-sep-93, J.R. Lemen (LPARL), Converted from a very old SMM Fortran program
   14-Mar-94, Zarro (ARC) substituted routines from Numerical Recipes


GAMINC [2] $SSW/gen/idl_fix/soft/old350/gaminc.pro
[Previous] [Next]
 NAME:
   GAMINC
 PURPOSE:
   Compute the function = exp(X) / X^P * Int[exp(-X)*X^(P-1)dx]
                                       (Int = Integrate from X to Infinity)
 CALLING SEQUENCE:
   Result = gaminc(P,X)		; X>0

 INPUTS:
   X and P	See expression above for details
		X and P must be a scalars
 RETURNS:
	Expression returned is a vector the same length as X.
 CALLS: ***
	GAMMA, igamma2 [1], igamma2 [2]
 CALLED BY:
	collexc [1], collexc [2]
 HISTORY:
    1-sep-93, J.R. Lemen (LPARL), Converted from a very old SMM Fortran program
		            Not optimized for IDL, but eliminated "go to" stmts.


GAUSS_FIT $SSW/gen/idl/fitting/gauss_fit.pro
[Previous] [Next]
 Project     :  YOHKOH-BCS

 Name	      :  GAUSS_FIT

 Purpose     : Gaussian function fit to line profile
;
 Category    : fitting

 Syntax      : g=gauss_fit(x,y,a,sigmaa)

 Inputs      : y = data to fit
               x = bin or wavelength

 Outputs     : background=a(0)+a(1)*x+a(2)*x^2
               a(3) = peak intensity
               a(4) = center
               a(5) = doppler width
               a(6) = peak intensity (2nd cmpt)
               a(7) = center (2nd cmpt)
               a(8) = doppler width (2nd cmpt)

 Opt. Outputs: sigmaa = sigma errors

 Keywords    : weights = data weights
               nfree  = number of free parameters
               chi2   = chi^2
               last   = set to use input 'a' values as starting values
               fixp   = indicies of parameters to fix
               status = 1/0 converged/not converged
               broad  = 1 for broadened GAUSSIAN (CDS-NIS only)
               no_back = do not fit background
               double  = try double gauss fit
               last    = use last fitted parameters as starting guess
               err= 0 for success, 1 for fail
 CALLS: ***
	BGAUSS, DPRINT, EXIST, FUNCT_FIT, GUESS_FIT_PAR
 CALLED BY:
	FIT_CDS_QL, FIT_SPEC, OSCSLOPE, VOIGT_FIT
 Restrictions: 
               The peak or minimum of the Gaussian must be the largest
	        or smallest point in the Y vector.

 History     : Version 1,  17-July-1993,  D M Zarro.  Written
               Version 2,  14-Sept-1999, Zarro (SM&A) - incorporated
                          broadened gaussian function
               11-June-2000, Zarro (EIT/GSFC) - added /double

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GAUSS_FUNCT2 [1] $SSW/gen/idl/fitting/gauss_funct2.pro
[Previous] [Next]
 PROJECT:
       SOHO - CDS

 NAME:
	GAUSS_FUNCT2

 PURPOSE:
	Evaluate the sum of a gaussian and a 2nd order polynomial.

 EXPLANATION:
	This routine evaluate the sum of a gaussian and a 2nd order polynomial
	and optionally return the value of it's partial derivatives.
	normally, this function is used by CURVEFIT to fit the
	sum of a line and a varying background to actual data.

 CATEGORY:
	E2 - CURVE AND SURFACE FITTING.

 CALLING SEQUENCE:
	GAUSS_FUNCT2,X,A,F,PDER

 INPUTS:
	X = VALUES OF INDEPENDENT VARIABLE.
	A = PARAMETERS OF EQUATION DESCRIBED BELOW.

 OUTPUTS:
	F = VALUE OF FUNCTION AT EACH X(I).

 OPTIONAL OUTPUT PARAMETERS:
	PDER = (N_ELEMENTS(X),6) ARRAY CONTAINING THE
		PARTIAL DERIVATIVES.  P(I,J) = DERIVATIVE
		AT ITH POINT W/RESPECT TO JTH PARAMETER.

 CALLED BY:
	FIND_LIMB, FIND_LIMB2, GAUSSFIT [1], GAUSSFIT2, fit_gcross
 COMMON BLOCKS:
	NONE.

 SIDE EFFECTS:
	NONE.

 RESTRICTIONS:
	NONE.

 PROCEDURE:
	F = A(0)*EXP(-Z^2/2) + A(3) + A(4)*X + A(5)*X^2
	Z = (X-A(1))/A(2)

 MODIFICATION HISTORY:
	WRITTEN, DMS, RSI, SEPT, 1982.
	Modified, DMS, Oct 1990.  Avoids divide by 0 if A(2) is 0.
	Modified, JRL, LPARL, Nov, 1988  - If n_elements(A) is 4 or 5,
					   then a constant or linear
					   background term is calculated.
	Modified, JRL, LPARL, Aug, 1990	 - Allow for no background term
	Modified, SLF, ISAS,  4-Sep-92   - Split gaussfit2/gauss_funct2
       Liyun Wang, NASA/GSFC, October 7, 1994, incoporated into CDS library
         


GAUSS_INTG $SSW/gen/idl/util/gauss_intg.pro
[Previous] [Next]
 PROJECT:
       SDAC
 	
 NAME:
	GAUSS_INTG

 PURPOSE:
	This procedure sums a Gaussian and 2nd order polynomial.
	AND OPTIONALLY RETURN THE VALUE OF IT'S PARTIAL DERIVATIVES.
	THIS GAUSSIAN IS EVALUATED BY INTEGRATING A GAUSSIAN OVER
	AN INTERVAL AND DIVIDING BY THE INTERVAL WIDTH.
	IT USES THE FUNCTION GAUSSINT TO INTEGRATE THE GAUSSIAN.
      

 CATEGORY:
	FITTING, MATH, UTILITY, NUMERICAL ANALYSIS - CURVE AND SURFACE FITTING.
 CALLS: ***
	CHECKVAR [1], F_DIV, checkvar [2], edge_products, f_pder [1], f_pder [2]
 CALLING SEQUENCE:
	GAUSS_INTG,X,A,F,PDER
 CALLED BY:
	F_GAUSS_INTG [1], F_GAUSS_INTG [2]
 EXAMPLE:
       gauss_intg, x, a, f
 INPUTS:
	X = VALUES OF INDEPENDENT VARIABLE, 2 X N, LO AND HI EDGES
	A = PARAMETERS OF EQUATION DESCRIBED BELOW.

 INPUT KEYWORDS:
       SIGTHRESH - number of sigmas defining region of integration
                   for gaussian.  Only regions whose limits are
                   within +/- sigthresh will be evaluated.

 OUTPUTS:
	F = VALUE OF FUNCTION AT EACH X(I).

 OPTIONAL OUTPUT PARAMETERS:
	PDER = (N_ELEMENTS(X),6) ARRAY CONTAINING THE
		PARTIAL DERIVATIVES.  P(I,J) = DERIVATIVE
		AT ITH POINT W/RESPECT TO JTH PARAMETER.
 COMMON BLOCKS:
	NONE.
 SIDE EFFECTS:
	NONE.
 RESTRICTIONS:
	NONE.
 PROCEDURE:
	This procedure sums a Gaussian and 2nd order polynomial.
	AND OPTIONALLY RETURN THE VALUE OF IT'S PARTIAL DERIVATIVES.
	THIS GAUSSIAN IS EVALUATED BY INTEGRATING A GAUSSIAN OVER
	AN INTERVAL AND DIVIDING BY THE INTERVAL WIDTH.
	IT USES THE FUNCTION GAUSSINT TO INTEGRATE THE GAUSSIAN.
	F = A(0)*EXP(-Z^2/2) + A(3) + A(4)*X + A(5)*X^2
	Z = (X-A(1))/A(2)
	F IS INTEGRATED FROM X_LO TO X_HI 
 MODIFICATION HISTORY:
	changed gaussian to integrating gaussian over an interval
	RAS, 21-MAR-95
 CONTACT:
	richard.schwartz@gsfc.nasa.gov


GAUSS_PUT $SSW/gen/idl/util/gauss_put.pro
[Previous] [Next]
 Project     : SOHO - CDS     
                   
 Name        : GAUSS_PUT()
               
 Purpose     : Load a 1-d or 2-d Gaussian into an array.
               
 Explanation : Creates an array or image with a Gaussian profile in it.
               
 Use         : IDL>  array = gauss_put(nx,ny,ht,xcen,sigx [,ycen,sigy,back])
    
 Inputs      : nx, ny  -  size of output array. NY must be set to zero
                          to obtain a 1-d array
               ht      -  central intensity of gaussian
               xcen    -  x location of centre of profile
               sigx    -  standard deviation in x direction
      
               
 Opt. Inputs : ycen    -  y location of centre of profile
               sigy    -  standard deviation in y direction
               
 Outputs     : Function returns vector or array 
               
 Opt. Outputs: None
               
 Keywords    : BACKGROUND    -  background level to be added

 Calls       : None
 CALLED BY:
	CDS_GAUSS, CDS_GFUNCT, GHOST_PLOT_SAMPLE, GIS_DUMMY, MAKE_CHIANTI_SPEC
 Common      : None
               
 Restrictions: None
               
 Side effects: None
               
 Category    : Utility, numerical
               
 Prev. Hist. : I presume everyone has one!

 Written     : C D Pike, RAL, 3-Jul-95
               
 Modified    : Fix 1-d bug (no background).  CDP, 07-Sep-95

 Version     : Version 2, 07-Sep-95


GAUSSIAN $SSW/gen/idl_libs/astron/math/gaussian.pro
[Previous] [Next]
 NAME:
       GAUSSIAN
 PURPOSE:
       Compute the 1-d Gaussian function and optionally the derivative
 EXPLANATION:
       Compute the 1-D Gaussian function and optionally the derivative 
       at an array of points.

 CALLING SEQUENCE:
       y = gaussian( xi, parms,[ pderiv ])

 INPUTS:
       xi = array, independent variable of Gaussian function.

       parms = parameters of Gaussian, 2, 3 or 4 element array:
               parms[0] = maximum value (factor) of Gaussian,
               parms[1] = mean value (center) of Gaussian,
               parms[2] = standard deviation (sigma) of Gaussian.
               (if parms has only 2 elements then sigma taken from previous
               call to gaussian(), which is stored in a  common block).
               parms[3] = optional, constant offset added to Gaussian.
 OUTPUT:
       y -  Function returns array of Gaussian evaluated at xi.    Values will
            be floating pt. (even if xi is double) unless the /DOUBLE keyword
            is set.

 OPTIONAL INPUT:
       /DOUBLE - set this keyword to return double precision for both
             the function values and (optionally) the partial derivatives.
 OPTIONAL OUTPUT:
       pderiv = [N,3] or [N,4] output array of partial derivatives,
               computed only if parameter is present in call.

               pderiv[*,i] = partial derivative at all xi absisca values
               with respect to parms[i], i=0,1,2,[3].


 CALLED BY:
	DECOMPOSE_BATSE_DRM, F_NLINE, HSI_GSMOOTH, PSF_GAUSSIAN [1]
 EXAMPLE:
       Evaulate a Gaussian centered at x=0, with sigma=1, and a peak value
       of 10 at the points 0.5 and 1.5.   Also compute the derivative

       IDL> f = gaussian( [0.5,1.5], [10,0,1], DERIV )
       ==> f= [8.825,3.25].   DERIV will be a 2 x 3 array containing the
       numerical derivative at the two points with respect to the 3 parameters.
 
 COMMON BLOCKS:
       None
 HISTORY:
       Written, Frank Varosi NASA/GSFC 1992.
       Converted to IDL V5.0   W. Landsman   September 1997
       Use machar() for machine precision, added /DOUBLE keyword,
       add optional constant 4th parameter    W. Landsman   November 2001


GAUSSJ $SSW/gen/idl/util/gaussj.pro
[Previous] [Next]
 PROJECT:
       SOHO - CDS

 NAME:
       GAUSSJ

 PURPOSE:
       Linear equation solution by Gauss-Jordan elimination

 EXPLANATION:
       This is a routine translated from a Fortran subroutine of the
       Numerical Recipes.

 CALLING SEQUENCE:
       GAUSSJ, aa, bb

 INPUTS:
       AA -- Coefficient matrix with N x N elements
       BB -- Constant matrix of N x M elements, containing the M right-hand
             side vectors

 CALLED BY:
	NL_MRQMIN
       Note: N is number of unknown variabled to be solved, and therefore is
             number of linear equations; M is number of vectors (each with N
             elements) on the right-hand side of equations.

 OPTIONAL INPUTS:
       None.

 OUTPUTS:
       SOLUTION -- Corresponding set of solution vectors

 OPTIONAL OUTPUTS:
       INVERTED -- Inversed matrix of input matrix AA

 KEYWORD PARAMETERS:
       None.

 CALLS:
	None.
 COMMON BLOCKS:
       None.

 RESTRICTIONS:
       None.

 SIDE EFFECTS:
       None.

 CATEGORY:
       Ulitities, numerical

 EXAMPLE:
       To solve for the following linear equation:
          
         | 1 -1  1 |     | -4  |
         | 5 -4  3 | X = | -12 |
         | 2  1  1 |	  | 11  |

       The matrix AA and BB should be: 
          aa = [[1,5,2],[-1,-4,1],[1,3,1]]
          bb = [[-4,-12,11],[15,56,13]]
       and the result will be: 
          bb = [[3,6,-1],[4,-3,8]]

 PREVIOUS HISTORY:
       Written November 10, 1994, by Liyun Wang, GSFC/ARC

 MODIFICATION HISTORY:

 VERSION:
       Version 1, November 10, 1994


GBO_STRUCT [1] $SSW/gen/idl/fund_lib/yohkoh/gbo_struct.pro
[Previous] [Next]
       NAME:
               GBO_STRUCT
       PURPOSE:
               Define the following ground Based Observing database structures
                       * GEV_Data_Rec
                       * GXR_Data_Rec
                       * GDR_Data_Rec
                       * NAV_Data_Rec
                       * GBO_Version_Rec
                       * GSN_ObsHeader_rec
                       * GSN_ObsImage_rec
                       * GBO_Obs_rec
                       * BATSE_Event_Rec
                       * BATSE_LCur_Rec
                       * Nob_Event_Rec
                       * Nob_TimSer_Rec
                       * Uly_FEM_Rec

       CALLING SEQUENCE:
               GBO_STRUCT
 CALLED BY:
	GOES__DEFINE, last_lc, mk_gbl, mk_gev [1], mk_gev [2], mk_gx, mk_nar [1], mk_nar [2]
	mk_week1_file, mk_week_file [1], mk_week_file [2], rd_gbe_raw, rd_gbl_raw [1]
	rd_gbl_raw [2], rd_goes3sec [1], rd_goes3sec [2], rd_goes_fits, rd_guf_ascii
	rd_selsis, rd_week_file [1], rd_week_file [2], rd_week_file [3]
	rd_week_file [4], weekid [2], ydb_exist [2]
       HISTORY:
               written by Mons Morrison, Jun-92
               slf, 23-sep-92, added GXR_Data_Rec, modified GBO_Version_Rec
               slf, 10-oct-92, changed number pad bytes, GXR_Data_Rec


GCIRC $SSW/gen/idl_libs/astron/astro/gcirc.pro
[Previous] [Next]
 NAME:
     GCIRC
 PURPOSE:
     Computes rigorous great circle arc distances.  
 EXPLANATION:
     Input position can either be either radians, sexigesimal RA, Dec or
     degrees.   All computations are double precision. 

 CALLING SEQUENCE:
      GCIRC, U, RA1, DC1, RA2, DC2, DIS

 INPUTS:
      U    -- integer = 0,1, or 2: Describes units of inputs and output:
              0:  everything radians
              1:  RAx in decimal hours, DCx in decimal
                       degrees, DIS in arc seconds 
              2:  RAx and DCx in degrees, DIS in arc seconds
      RA1  -- Right ascension or longitude of point 1
      DC1  -- Declination or latitude of point 1
      RA2  -- Right ascension or longitude of point 2
      DC2  -- Declination or latitude of point 2

 OUTPUTS:
      DIS  -- Angular distance on the sky between points 1 and 2
              See U above for units;  double precision  

 CALLED BY:
	DBCIRCLE [1], DBCIRCLE [2], SRCOR
 PROCEDURE:
      "Cosine formula" (p. 7 of Smart's Spherical Astronomy or
      p. 12 of Green's Spherical Astronomy)

 NOTES:
       (1) If RA1,DC1 are scalars, and RA2,DC2 are vectors, then DIS is a
       vector giving the distance of each element of RA2,DC2 to RA1,DC1.
       Similarly, if RA1,DC1 are vectors, and RA2, DC2 are scalars, then DIS
       is a vector giving the distance of each element of RA1, DC1 to 
       RA2, DC2.    If both RA1,DC1 and RA2,DC2 are vectors then DIS is a
       vector giving the distance of each element of RA1,DC1 to the 
       corresponding element of RA2,DC2.    If the input vectors are not the 
       same length, then excess elements of the longer ones will be ignored.

       (2) Coordinates closer together than a few milliarcsec cannot
       be distinguished.  If you are in this realm, you should be
       using special-purpose algorithms.

       (3) The function SPHDIST provides an alternate method of computing
        a spherical distance.

 PROCEDURE CALLS:
      None

   MODIFICATION HISTORY:
      Written in Fortran by R. Hill -- SASC Technologies -- January 3, 1986
      Translated from FORTRAN to IDL, RSH, STX, 2/6/87
      Vector arguments allowed    W. Landsman    April 1989
      Prints result if last argument not given.  RSH, RSTX, 3 Apr. 1998
      Remove ISARRAY(), V5.1 version        W. Landsman   August 2000
      Added option U=2                      W. Landsman   October 2006


GCNTRD $SSW/gen/idl_libs/astron/idlphot/gcntrd.pro
[Previous] [Next]
  NAME: 
       GCNTRD
  PURPOSE:
       Compute the stellar centroid by Gaussian fits to marginal X,Y, sums 
 EXPLANATION:
       GCNTRD uses the DAOPHOT "FIND" centroid algorithm by fitting Gaussians
       to the marginal X,Y distributions.     User can specify bad pixels 
       (either by using the MAXGOOD keyword or setting them to NaN) to be
       ignored in the fit.    Pixel values are weighted toward the center to
       avoid contamination by neighboring stars. 

  CALLING SEQUENCE: 
       GCNTRD, img, x, y, xcen, ycen, [ fwhm , /SILENT, /DEBUG, MAXGOOD = ,
                            /KEEPCENTER ]

  INPUTS:     
       IMG - Two dimensional image array
       X,Y - Scalar or vector integers giving approximate stellar center

  OPTIONAL INPUT:
       FWHM - floating scalar; Centroid is computed using a box of half
               width equal to 1.5 sigma = 0.637* FWHM.  GCNTRD will prompt
               for FWHM if not supplied

  OUTPUTS:   
       XCEN - the computed X centroid position, same number of points as X
       YCEN - computed Y centroid position, same number of points as Y

       Values for XCEN and YCEN will not be computed if the computed
       centroid falls outside of the box, or if there are too many bad pixels,
       or if the best-fit Gaussian has a negative height.   If the centroid 
       cannot be computed, then a  message is displayed (unless /SILENT is 
       set) and XCEN and YCEN are set to -1.

  OPTIONAL OUTPUT KEYWORDS:
       MAXGOOD=  Only pixels with values less than MAXGOOD are used to in
               Gaussian fits to determine the centroid.    For non-integer
               data, one can also flag bad pixels using NaN values.
       /SILENT - Normally GCNTRD prints an error message if it is unable
               to compute the centroid.   Set /SILENT to suppress this.
       /DEBUG - If this keyword is set, then GCNTRD will display the subarray
               it is using to compute the centroid.
       /KeepCenter  By default, GCNTRD finds the maximum pixel in a box 
              centered on the input X,Y coordinates, and then extracts a new
              box about this maximum pixel.   Set the /KeepCenter keyword  
              to skip the step of finding the maximum pixel, and instead use
              a box centered on the input X,Y coordinates.                          
  PROCEDURE: 
       Maximum pixel within distance from input pixel X, Y  determined 
       from FHWM is found and used as the center of a square, within 
       which the centroid is computed as the Gaussian least-squares fit
       to the  marginal sums in the X and Y directions. 

 CALLS: ***
	IMLIST
  EXAMPLE:
       Find the centroid of a star in an image im, with approximate center
       631, 48.    Assume that bad (saturated) pixels have a value of 4096 or
       or higher, and that the approximate FWHM is 3 pixels.

       IDL> GCNTRD, IM, 631, 48, XCEN, YCEN, 3, MAXGOOD = 4096       
  MODIFICATION HISTORY:
       Written June 2004, W. Landsman  following algorithm used by P. Stetson 
             in DAOPHOT2.


GEN__DEFINE $SSW/gen/idl/objects/gen__define.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GEN__DEFINE

 Purpose     : Define a GENeric object

 Category    : objects

 Explanation : This CLASS definition really only contains general methods
               that can be inherited by other objects

 Inputs      : None

 Outputs     : Generic object with COPY and EXTRACT methods

 CALLS: ***
	ADD_TAG [1], ADD_TAG [2], BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3]
	DATATYPE [1], DATATYPE [2], DATATYPE [3], DELVARX [1], DELVARX [2], DELVARX [3]
	DELVARX [4], EXIST, FILE_BREAK, GEN::CHECK_AND_SET, GEN::CLEANUP, GEN::EXTRACT2
	GEN::FBREAK, GEN::GETPROP, GEN::INIT, GEN::METHODS, GEN::PRIVATE, GET_DEBUG
	HAVE_TAG, IPRINT, OBJ_METHODS, REM_TAG [1], REM_TAG [2], REP_TAG_VALUE
	SAME_DATA [1], SAME_DATA [2], SINCE_VERSION [1], SINCE_VERSION [2], TRIM, TRIM2
	break_file [4], delvarx [5]
 History     : Written 14 Oct 1999, D. Zarro, SM&A/GSFC

 Contact     : dzarro@solar.stanford.edu


GEN_STRUCT [1] $SSW/gen/idl/fund_lib/yohkoh/gen_struct.pro
[Previous] [Next]
       NAME:
               GEN_STRUCT
       PURPOSE:
               Define the following general database structures
                       * Pointer_Rec              
                       * File_Header_Rec          
                       * QS_General1_Rec          
                       * GEN_Index_rec            
                       * GEN2_Index_rec            
                       * MO_Disk_Map_Rec
                       * MO_Disk_Log_Rec

       CALLING SEQUENCE:
               GEN_STRUCT
 CALLED BY:
	GET_SDA, MK_BSC_STR [1], MK_BSC_STR [2], Rd_Pointer [1], Rd_Pointer [2]
	Rd_fHeader [1], Rd_fHeader [2], Rd_fHeader [3], kluge_att, mk_att [1], mk_att [2]
	mk_evn [1], mk_evn [2], mk_fem_file [1], mk_fem_file [2], mk_gbl, mk_gev [1]
	mk_gev [2], mk_gsn_obs, mk_gx, mk_mo_log, mk_nar [1], mk_nar [2], mk_orb_file, mk_pnt
	mk_sd2, mk_sdl, mk_sl [1], mk_sl [2], mk_sot, mk_ssl, mk_sxc, mk_sxl, mk_week1_file
	mk_week_file [1], mk_week_file [2], pnt2atr, rd_obs, rd_old_obs, rd_roadmap [1]
	sav_bda, sav_bsc, sav_hxi, sav_sda [1], sav_sda [2], sav_sda [3], wrtsxtmap
       HISTORY:
               written by Mons Morrison, Fall 90.
                9-Mar-95 (MDM) - Added documentation comments 
                               - (Compression of the data section)


genx2html [1] $SSW/gen/idl/http/genx2html.pro
[Previous] [Next]
   Name: genx2html

   Purpose: convert a 'genx' file to an html file in a 'standard' format

   Calling Sequence:
      genx2html,genxfile [,outfile=outfile, httpdir=httpdir, thumbfact=N,/thumb]

   Input Parameters:
      genxfiles - one or more genx files to convert

   Keyword Parameters:
      outfiles -  if set, output filenames (default derived from genx name)
      thumbnail - if set, make thumbnail and link
      thumbfact - if set, scale factor for thumbnail
      maxthumb  - if set, scale thumbnail to this size (largest dimension)
      addlinks  - if set, filename to add a link to this image (uniq)

 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], CONGRID [1], CONGRID [2], CONGRID [3], FILE_EXIST [2], WRITE_GIF
	break_file [4], concat_dir [4], data_chk [1], data_chk [2], file_append [1]
	file_append [2], file_exist [1], file_exist [3], file_size [1], file_size [2]
	get_logenv [1], get_logenv [2], rd_tfile [1], rd_tfile [2], restgen [1]
	restgen [2], str2html [1], str2html [2], str2html [3], str_replace [1]
	str_replace [2], ut_time [1], ut_time [2]
 CALLED BY:
	mk_pix [1], mk_pix [2]
   Restrictions:
       must define the parameters (pass keyword in or via environmental)
          top_http  -  top http path known to outside world
          path_http -  top http local disk name (for writing)
       optionally define subdirectories (may be relative)
          image_http - path to images (gif) created by this routine
          html_http  - path to html files created by this routines

	optionally, the address written at the end of the html file can
	be changed from the default (sxtwww@...) by setting the enviroment 
       variable "address_http" to the required string.
      
   History:
      3-Feb-1995 (SLF) - Written to convert show_pix images to gif/html
      6-Feb-1995 (SLF) - Added auto-scaling for thumbnail, ADDLINK keyword
			  and function (update a linked list)
      8-Feb-1995 (SLF) - Add text about full image file size
     13-Feb-1995 (SLF) - parameterized (site independent)
     29-mar-1995 (SLF) - remove <br>x around text
     29-mar-1995 (SLF) - break text formatting into str2html.pro
      7-jun-1995 (SLF) - increase min_col to str2html
     12-Jul-1995 (RDB) - added address_http changing of "address"
     31-aug-1995 (SLF) - add HEADER and TRAILER keywords
     19-dec-1995 (SLF) - fix ADDLINK bug
     22-apr-1996 (SLF) - add NOUPDATE switch
     13-Aug-2003, William Thompson, Use SSW_WRITE_GIF instead of WRITE_GIF


genx_head [1] $SSW/gen/idl/genutil/genx_head.pro
[Previous] [Next]
   Name: genx_head

   Purpose: define version dependent genx file header structures

   Input Parameters:
      version - genx file version number

   Output:
      function returns version dependent gen-file header structure

 CALLS: ***
	MAKE_STR [1], MAKE_STR [2]
 CALLED BY:
	WRT_GENX [1], WRT_GENX [2]
 History:
     ?? written
	RDB  21-Apr-95  modified version=2 so specific to IDLV3 !version


genx_newver [1] $SSW/gen/idl/genutil/genx_newver.pro
[Previous] [Next]
   Name: genx_newver

   Purpose: create new version of genx file - only updates genx header
	     and (optionally) text sections - original data is preserved

   Input Paramters:
      filename - file to convert (assume genx)
      newname  - name for new file (defaults to filename , ie replace orig)

   Keyword Paramters:
      newtext - optional string / strarray to append to existing text section
      verbose - if set, print some informational information

   Calling Sequence:
      genx_newver,filename		; replace existing file 
      genx_newver,filename, newname    ; make new file

   History - slf, 29-jan-1993		; 
 CALLS:


GEO2ECI $SSW/gen/idl_libs/astron/astro/geo2eci.pro
[Previous] [Next]
 NAME:
     GEO2ECI

 PURPOSE:
     Convert geographic spherical coordinates to Earth-centered inertial coords

 EXPLANATION:
     Converts from geographic spherical coordinates [latitude, longitude, 
     altitude] to ECI (Earth-Centered Inertial) [X,Y,Z] rectangular 
     coordinates.    JD time is also needed.

     Geographic coordinates are in degrees/degrees/km
     Geographic coordinates assume the Earth is a perfect sphere, with radius 
       equal to its equatorial radius.
     ECI coordinates are in km from Earth center.

 CALLING SEQUENCE:
       ECIcoord=geo2eci(gcoord,JDtime)

 INPUT:
       gcoord: geographic [latitude,longitude,altitude], or a an array [3,n] 
                of n such coordinates
       JDtime: Julian Day time, double precision. Can be a 1-D array of n 
               such times.

 KEYWORD INPUTS:
       None

 OUTPUT:
       a 3-element array of ECI [X,Y,Z] coordinates, or an array [3,n] of 
                n such coordinates, double precision   
       
 CALLS: ***
	CT2LST
 CALLED BY:
	GEOGRAPHIC2ECI
 COMMON BLOCKS:
       None

 PROCEDURES USED:
       CT2LST - Convert Local Civil Time to Local Mean Sidereal Time

 EXAMPLES:

       IDL> ECIcoord=geo2eci([0,0,0], 2452343.38982663D)
       IDL> print,ECIcoord
      -3902.9606       5044.5548       0.0000000

       (The above is the ECI coordinates of the intersection of the equator and
       Greenwich's meridian on 2002/03/09 21:21:21.021)

 MODIFICATION HISTORY:
       Written by Pascal Saint-Hilaire (shilaire@astro.phys.ethz.ch) 
             on 2002/05/14
               


GEO2GEODETIC $SSW/gen/idl_libs/astron/astro/geo2geodetic.pro
[Previous] [Next]
 NAME:
       GEO2GEODETIC

 PURPOSE:
       Convert from geographic/planetographic to geodetic coordinates
 EXPLANATION:
       Converts from geographic (latitude, longitude, altitude) to geodetic
       (latitude, longitude, altitude).  In geographic coordinates, the 
           Earth is assumed a perfect sphere with a radius equal to its equatorial 
               radius. The geodetic (or ellipsoidal) coordinate system takes into 
               account the Earth's oblateness.

       Geographic and geodetic longitudes are identical.
               Geodetic latitude is the angle between local zenith and the equatorial plane.
               Geographic and geodetic altitudes are both the closest distance between 
               the satellite and the ground.

       The PLANET keyword allows a similar transformation for the other 
       planets  (planetographic to planetodetic coordinates). 

       The EQUATORIAL_RADIUS and POLAR_RADIUS keywords allow the 
       transformation for any ellipsoid.

       Latitudes and longitudes are expressed in degrees, altitudes in km.

       REF: Stephen P.  Keeler and Yves Nievergelt, "Computing geodetic
       coordinates", SIAM Rev. Vol. 40, No. 2, pp. 300-309, June 1998

       Planterary constants from "Allen's Astrophysical Quantities", 
       Fourth Ed., (2000)

 CALLING SEQUENCE:
       ecoord=geo2geodetic(gcoord,[ PLANET=,EQUATORIAL_RADIUS=, POLAR_RADIUS=])

 INPUT:
       gcoord = a 3-element array of geographic [latitude,longitude,altitude],
                or an array [3,n] of n such coordinates.


 OPTIONAL KEYWORD INPUT:
       PLANET = keyword specifying planet (default is Earth).   The planet
                may be specified either as an integer (1-9) or as one of the
                (case-independent) strings 'mercury','venus','earth','mars',
                'jupiter','saturn','uranus','neptune', or 'pluto'
               
       EQUATORIAL_RADIUS : Self-explanatory. In km. If not set, PLANET's 
                value is used.
       POLAR_RADIUS : Self-explanatory. In km. If not set, PLANET's value is 
                used.

 OUTPUT:
      a 3-element array of geodetic/planetodetic [latitude,longitude,altitude],
        or an array [3,n] of n such coordinates, double precision.

 COMMON BLOCKS:
       None

 RESTRICTIONS:

       Whereas the conversion from geodetic to geographic coordinates is given
       by an exact, analytical formula, the conversion from geographic to
       geodetic isn't. Approximative iterations (as used here) exist, but tend 
       to become less good with increasing eccentricity and altitude.
       The formula used in this routine should give correct results within
       six digits for all spatial locations, for an ellipsoid (planet) with
       an eccentricity similar to or less than Earth's.
       More accurate results can be obtained via calculus, needing a 
       non-determined amount of iterations.
       In any case, 
          IDL> PRINT,geodetic2geo(geo2geodetic(gcoord)) - gcoord
       is a pretty good way to evaluate the accuracy of geo2geodetic.pro.

 EXAMPLES:

       Locate the geographic North pole, altitude 0., in geodetic coordinates
       IDL> geo=[90.d0,0.d0,0.d0]  
       IDL> geod=geo2geodetic(geo); convert to equivalent geodetic coordinates
       IDL> PRINT,geod
       90.000000       0.0000000       21.385000

       As above, but for the case of Mars
       IDL> geod=geo2geodetic(geo,PLANET='Mars')
       IDL> PRINT,geod
       90.000000       0.0000000       18.235500

 MODIFICATION HISTORY:
       Written by Pascal Saint-Hilaire (shilaire@astro.phys.ethz.ch), May 2002
       Generalized for all solar system planets by Robert L. Marcialis
               (umpire@lpl.arizona.edu), May 2002
       Modified 2002/05/18, PSH: added keywords EQUATORIAL_RADIUS and 
               POLAR_RADIUS


GEO2MAG $SSW/gen/idl_libs/astron/astro/geo2mag.pro
[Previous] [Next]
 NAME:
       GEO2MAG()

 PURPOSE:
       Convert from geographic to geomagnetic coordinates
 EXPLANATION:
       Converts from GEOGRAPHIC (latitude,longitude) to GEOMAGNETIC (latitude, 
       longitude).   (Altitude remains the same)

       Latitudes and longitudes are expressed in degrees.

 CALLING SEQUENCE:
       mcoord=geo2mag(gcoord)

 INPUT:
       gcoord = a 2-element array of geographic [latitude,longitude], or an 
                array [2,n] of n such coordinates.

 KEYWORD INPUTS:
       None

 OUTPUT:
       a 2-element array of magnetic [latitude,longitude], or an array [2,n] 
         of n such coordinates                     

 COMMON BLOCKS:
       None

 EXAMPLES:
       geographic coordinates of magnetic south pole

       IDL> mcoord=geo2mag([79.3,288.59])      
       IDL> print,mcoord
       89.999992      -173.02325

 MODIFICATION HISTORY:
       Written by Pascal Saint-Hilaire (Saint-Hilaire@astro.phys.ethz.ch), 
            May 2002
               


GEODETIC2GEO $SSW/gen/idl_libs/astron/astro/geodetic2geo.pro
[Previous] [Next]
 NAME:
       GEODETIC2GEO

 PURPOSE:
       Convert from geodetic (or planetodetic) to geographic coordinates
 EXPLANATION:
       Converts from geodetic (latitude, longitude, altitude) to geographic
       (latitude, longitude, altitude).  In geographic coordinates, the 
       Earth is assumed a perfect sphere with a radius equal to its equatorial 
       radius. The geodetic (or ellipsoidal) coordinate system takes into 
       account the Earth's oblateness.

       Geographic and geodetic longitudes are identical.
       Geodetic latitude is the angle between local zenith and the equatorial 
       plane.   Geographic and geodetic altitudes are both the closest distance
       between the satellite and the ground.

       The PLANET keyword allows a similar transformation for the other 
       planets  (planetodetic to planetographic coordinates). 

       The EQUATORIAL_RADIUS and POLAR_RADIUS keywords allow the 
       transformation for any ellipsoid.

       Latitudes and longitudes are expressed in degrees, altitudes in km.

       REF: Stephen P.  Keeler and Yves Nievergelt, "Computing geodetic
       coordinates", SIAM Rev. Vol. 40, No. 2, pp. 300-309, June 1998
       Planetary constants from "Allen's Astrophysical Quantities", 
       Fourth Ed., (2000)

 CALLING SEQUENCE:
       gcoord = geodetic2geo(ecoord, [ PLANET= ] )

 INPUT:
       ecoord = a 3-element array of geodetic [latitude,longitude,altitude],
                or an array [3,n] of n such coordinates.

 OPTIONAL KEYWORD INPUT:
       PLANET = keyword specifying planet (default is Earth).   The planet
                may be specified either as an integer (1-9) or as one of the
                (case-independent) strings 'mercury','venus','earth','mars',
                'jupiter','saturn','uranus','neptune', or 'pluto'

       EQUATORIAL_RADIUS : Self-explanatory. In km. If not set, PLANET's value
                is used.   Numeric scalar
       POLAR_RADIUS : Self-explanatory. In km. If not set, PLANET's value is 
                 used.   Numeric scalar

 OUTPUT:
       a 3-element array of geographic [latitude,longitude,altitude], or an
         array [3,n] of n such coordinates, double precision

       The geographic and geodetic longitudes will be identical.
 COMMON BLOCKS:
       None

 EXAMPLES:

       IDL> geod=[90,0,0]  ; North pole, altitude 0., in geodetic coordinates
       IDL> geo=geodetic2geo(geod)
       IDL> PRINT,geo
       90.000000       0.0000000      -21.385000

       As above, but the equivalent planetographic coordinates for Mars
       IDL> geod=geodetic2geo(geod,PLANET='Mars'); 
       IDL> PRINT,geod
       90.000000       0.0000000      -18.235500

 MODIFICATION HISTORY:
       Written by Pascal Saint-Hilaire (shilaire@astro.phys.ethz.ch),
                  May 2002

       Generalized for all solar system planets by Robert L. Marcialis
               (umpire@lpl.arizona.edu), May 2002

       Modified 2002/05/18, PSH: added keywords EQUATORIAL_RADIUS and 
                POLAR_RADIUS


GEOGRAPHIC2ECI $SSW/gen/idl/solar/geographic2eci.pro
[Previous] [Next]
 NAME:
       GEOGRAPHIC2ECI

 PURPOSE:
	Wrapper for the geo2eci.pro routine, for SSW users of the ANYTIM time format.

       Converts from geographic spherical coordinates [latitude, longitude, altitude]
	to ECI (Earth-Centered Inertial) [X,Y,Z] rectangular coordinates.
	A time is also needed.

	ECI coordinates are in km from Earth center.
	Geographic coordinates are in degrees/degrees/km
	Geographic coordinates assume the Earth is a perfect sphere, with radius equal to its equatorial radius.

 CALLING SEQUENCE:
       ECIcoord=geographic2eci(gcoord,time)

 INPUT:
	gcoord : the geographic coordinates [latitude,longitude,altitude], can be an array [3,n] of n such coordinates.
	time: in any ANYTIM format, can be a 1-D array of n such times.

 KEYWORD INPUTS:
	None

 OUTPUT:
	a 3-element array of ECI [X,Y,Z] (in km), or an array [3,n] of n such coordinates	

 CALLS: ***
	GEO2ECI, anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
 COMMON BLOCKS:
	None

 RESTRICTIONS:
       None

 EXAMPLE:

	IDL> ECIcoord=geographic2eci([0,0,0], '2002/03/09 21:21:21.021')
	IDL> print,ECIcoord
	-3902.9606       5044.5547       0.0000000

	(The above is the ECI coordinates of the intersection of the equator and Greenwitch's 
	meridien on 2002/03/09 21:21:21.021)


 MODIFICATION HISTORY:
	Written by Pascal Saint-Hilaire (Saint-Hilaire@astro.phys.ethz.ch) on 2001/05/14
		


get1doc [1] $SSW/gen/idl/genutil/get1doc.pro
[Previous] [Next]
 	NAME: get1doc 

	PURPOSE: extract subset of idl header info for display/verification  
		 this is a check of a two line purpose
		 third purpose line

	CALLING SEQUENCE: doc=get1doc(infile)

       Input Parameters:
          infile - file to extract - assume idl .pro file

       Optional Keyword Parameters:
          keep_key - if set, keywords from file are retained in the
		      tag value - default is to eliminate since the 
		      tag name contains relavent info. 
	   debug - if set, some programmer info is printed

	Output: 
	   function returns structure containing documentation info 
	   all fields are string type - null fields imply a particular
	   field is missing from the documentation header 

 CALLED BY:
	add_pro [1], add_pro [2], get_doc [1], get_doc [2], get_doc [3]
	Restrictions: unix only x 

	Category: gen, swmaint, unix_only

 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], FILE_EXIST [2], MAKE_STR [1], MAKE_STR [2], STR_LASTPOS [1]
	break_file [4], concat_dir [4], curdir [1], curdir [2], file_exist [1]
	file_exist [3], str_lastpos [2], strposarr [1], strposarr [2]
	Common Blocks: get_doc_private, doc_strt

	Modification History: slf, 18-July-1992 
			      (derived from sw_head.pro)
			      slf,  9-Aug-1992	added print option
	12-Jun-97 (MDM) - Added "EXPL" (Explanation) to the list of
			  section separators


get_acedata $SSW/gen/idl/solar/get_acedata.pro
[Previous] [Next]
   Name: get_acedata

   Purpose: read/return ACE data for desired time range & cadence

   Input Paramters:
      time0, time1 - time range desired , any SSW format

   Output:
      function returns ACE data, utplot-ready time tags

   Keyword Parameters:
      /swepam, /epam, /mag, /sis - ACE instrument to read/return
      (default is /SWEPAM)

      daily - if set, use daily files (cadence one or five minutes)
      monthly - if set, use monthly files, cadence = 1 hour
      missing - if set, include missing sample points (def removes these)
      _extra - ACE data type (see current restrictions) - default=SWEPAM
      status - return status, =1 if ANY data in time range, 0 if NONE
      bad_data - include data flagged as missing/bad by ACE
                 (default only returns "perfect" data)
      keep_quality - if set, returned structures include the quality
                     flag (or flags) - this is default if /BAD_DATA is set
      /SWEPAM, /EPAM, /SIS, /MAG - which ACE instrument to read/return
      (historical default is SWEPAM)

   Calling Examples:
           get last 24 hours of data (cadence = 1 minute)
      IDL> acedata=get_acedata(reltime(/yest),reltime(/now),/daily,/swepam)

           long term data (cadence = 1 hour)
      IDL> acedata=get_acedata('1-jan-2001','1-mar-2001',/monthly,/epam)

 CALLED BY:
	plot_ace, ssw_getdst
   History:
      6-Sep-2001 - S.L.Freeland - for eit/sxt comparative studies, LWS
     26-Sep-2001 - S.L.Freeland - remove SWEPAM only restriction
                                  add /BAD_DATA switch and function

   Calls: ***
	BOX_MESSAGE, READ_ACE, ace_files, anytim [1], anytim [2], anytim [3], anytim [4]
	anytim [5], data_chk [1], data_chk [2], sel_timrange [1], sel_timrange [2]


GET_ANGLE $SSW/gen/idl/fund_lib/sdac/get_angle.pro
[Previous] [Next]
 Project     : SDAC   
                   
 Name        : GET_ANGLE
               
 Purpose     : This function returns the angle (degrees) between two vectors
		specified in spherical coordinates of an azimuthal angle
		and declination, usually right ascension and declination
               
 Category    : GEN, Coordinate Manipulations
               
 Explanation : The vectors are computed to Cartesian coordinates, their
		inner product taken, then the inverse cosine is used to 
		return the angle.
               
 Use         : Angle = GET_ANGLE( Radec1, Radec2 )
    
 Inputs      : Radec1 - Vector 1 right ascension and declination in degrees 
		Radec1 may be an array of vectors, dimensioned 2xN_elements
             : Radec2 - Vector 2 right ascension and declination in degrees 
               
 Opt. Inputs : None
               
 Outputs     : Returns the angle in degrees.

 Opt. Outputs: None
               
 Keywords    : 

 Calls       : ***
	SPHCART
 Common      : None
               
 Restrictions: 
               
 Side effects: None.
               
 Prev. Hist  : This was originally written as angle.pro in 1987 by RAS.

 Modified    : Version 1, RAS, 26-Dec-1996


GET_ARR_CENTER $SSW/gen/idl/mapping/get_arr_center.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_ARR_CENTER

 Purpose     : compute center of input coordinates array

 Category    : imaging

 Syntax      : center=get_arr_center(array)

 Inputs      : ARRAY = 1 or 2d coordinate array

 Outputs     : CENTER = center coordinate value

 Keywords    : ERR = error string
               DX, DY = mean pixel spacing in x and y directions

 CALLS: ***
	EXIST, PR_SYNTAX
 CALLED BY:
	DROT_RASTER, GET_MAP_SPACE [1], GET_MAP_SPACE [2], GRID_MAP, MAKE_MAP, MK_CDS_IMAP
	MK_CDS_SMAP, MK_NEW_MAP, REPACK_MAP
 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_ASPECT $SSW/gen/idl/display/get_aspect.pro
[Previous] [Next]
 NAME:
	GET_ASPECT

 PURPOSE:
	This function calculates and returns the normalized position
	coordinates necessary to put a plot with a specified aspect ratio
	into the currently active graphics window. It works on the display
	output window as well as in a PostScript output window.

 CATEGORY:
	Graphics

 CALLING SEQUENCE:

	position = GET_ASPECT(aspectRatio)

 INPUTS:
	aspectRatio: A floating point value that is the desired aspect
	ratio (ratio of heigth to width) of the plot in the current 
	graphics output window. If this parameter is missing, an aspect
	ratio of 1.0 (a square plot) is assumed.

 KEYWORD PARAMETERS:
	MARGIN:	The margin around the edges of the plot. The value must be
	a floating point value between 0.0 and 0.5. It is expressed in
	normalized coordinate units. The default margin is 0.15

       XRANGE,YRANGE: optional range of data coordinates. Must be
       two-element vectors.

 OUTPUTS:
	position: A four-element floating array of normalized coordinates.
	The order of the elements is [x0, y0, x1, y1], similar to the
	!P.POSITION system variable or the POSITION keyword on any IDL
	graphic command.

 CALLED BY:
	PLOT_MAP, PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support
 EXAMPLE:
	To create a plot with an aspect ratio of 1:2 and a margin of
	0.10 around the edge of the output window, do this:

	   plotPosition = ASPECT(0.5, Margin=0.10)
	   PLOT, Findgen(11), POSITION=plotPosition
	
	Notice this can be done in a single IDL command, like this:
	
	   PLOT, Findgen(11), POSITION=ASPECT(0.5, Margin=0.10)

 MODIFICATION HISTORY:
 	Written by:	David Fanning, November 1996.
       Added better error checking, 18 Feb 97, DWF.
       Added XRANGE/YRANGE keywords to allow for skewed data ranges
        - Zarro (EIT/GSFC), 28 Jun 00


get_atomic [1] $SSW/gen/idl/spectra/get_atomic.pro
[Previous] [Next]
  NAME:
    get_atomic
  PURPOSE:
    Return a data structure with atomic data parameters 
    for requested BCS channel.
  CALLING SEQUENCE:
    ato_data = get_atomic(Chan)

    w_wave   = get_atomic(Chan,/w_wave)		; Return wavelength of w-line
    w_wave   = get_atomic(Chan,/z_wave)		; Return wavelength of z-line

  INPUTS:
    Chan	= BCS Channel Number or structure (Must be a scalar)
  OPTIONAL INPUT KEYWORDS:
    w_wave	= If set, only return the wavelength of the w line
		  Also, x_wave, y_wave, z_wave, q_wave, j_wave, k_wave
    atocal	= Def=Max value present.  Specifies alternative atomic calculation.
		  If atomic data file has already been read, and atocal is
		  NOT specified, then previously read data will be returned.

		  atocal=5 and chan=4 will cause susec5.dat to be read.
		  atocal=4 and chan=4 will cause susec4.dat to be read, etc.

    new	= If /new is set, forces a read of the file even if it has been
		  previously read.
  OUTPUTS:
    The functional result is structure containing the atomic data parameters
  METHOD:
    Reads ascii data files contained in $DIR_GEN_SPECTRA
    The files have the following names: susec3.dat, casec3.dat, fesec3.dat, f26sec3.dat

 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], GT_BSC_CHAN [1], GT_BSC_CHAN [2], STR2ARR [1], STR2ARR [2]
	break_file [4], concat_dir [4], rd_atodat [1], rd_atodat [2], str_replace [1]
	str_replace [2]
 CALLED BY:
	bcs_broad [1], bcs_broad [2], bcs_funct, bcs_line, bcs_velres, bsc_bin2w, cal_bsc
  MODIFICATION HISTORY:
     7-oct-93, J. R. Lemen (LPARL), Written
     8-feb-94, JRL,  Changed the way the file name is specified via the atocal parameter
    11-mar-94, JRL,  Added x_wave,y_wave,z_wave,q_wave switches
    15-Mar-94, DMZ,  changed to avoid file search each time
    15-mar-94, JRL,  Additional changes to avoid file search
    23-mar-94, JRL,  Fix bug introduced by concat_dir for VMS
     2-jan-96, JRL,  Added the /new keyword.  Used for debugging purposes.


GET_CALLDETAILS $SSW/gen/idl/system/get_calldetails.pro
[Previous] [Next]
 Project     : SOHO - CDS     
                   
 Name        : GET_CALLDETAILS()
               
 Purpose     : Return details of calling program (at any stack depth)
               
 Explanation : The HELP,CALLS=CALLS utility is nice, but it's often a bit
               awkward to extract information.  This routine returns the
               information in a more edible form, as a structure:

               {GET_CALLDETAILS_STC,
                TEXT   : The full text of CALLS(DEPTH)
                MODULE : The procedure or function name of CALLS(DEPTH)
                FILE   : The source file for the procedure 
                LINENO : The line number of the calling statement
                DEPTH  : The depth used (default 2)
                TOTALDEPTH : The maximum possible depth allowed in this call} 
               
                Depth=0 means *this* program (GET_CALLDETAILS) 
                      1 means the caller of GET_CALLDETAILS
                      2 means the caller of the program calling 
                        GET_CALLDETAILS (DEFAULT)
                      3 means the caller of the caller of the program calling
                        GET_CALLDETAILS ... etc

 Use         : STC = GET_CALLDETAILS( [ DEPTH ] )
 
 Inputs      : None required

 Opt. Inputs : DEPTH : See Explanation

 Outputs     : Returns information structure.
               
 Opt. Outputs: None.
               
 Keywords    : None.

 Calls       : None.
 CALLED BY:
	INLINE_TEXT
 Common      : None.
               
 Restrictions: None.
               
 Side effects: None.
               
 Category    : General.
               
 Prev. Hist. : None.

 Written     : S.V.H.Haugan, UiO, 6 May 1998
               
 Modified    : Not yet.

 Version     : 1, 6 May 1998


GET_CALLER $SSW/gen/idl/system/get_caller.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_CALLER

 Purpose     : Get name of caller routine

 Category    : Utility

 Explanation : Uses HELP,CALLS=CALLS to get name of routine calling
               current program.

 Syntax      : IDL> caller=get_caller(status)

 Inputs      : None.

 Opt. Inputs : None.

 Outputs     : CALLER = name of caller.

 Opt. Outputs: STATUS= 1 if one of the following conditions are met:
               -- caller routine is XMANAGER
               -- caller routine is calling itself recursively
               -- caller routine is an event handler of itself
               -- caller is blank

 Keywords    : PREV_CALLER = previous caller before caller
                             (confusing isn't it?)

 CALLS: ***
	DPRINT, TRIM
 CALLED BY:
	CHECK_KAP, CW_ANIMATE2, GET_POINTER, GE_WINDOW_SIM, IMAGE_TOOL, MAKE_POINTER
	MK_PLAN, MK_PLAN_CUSTOM, MK_PLAN_RECOVER, MK_SOHO_CUSTOM, MK_STUDY, PARSE_TIME
	PR_SYNTAX, RSTN__DEFINE, SITE__DEFINE, SPEX_GEN__DEFINE, XACK, XANSWER, XCALENDAR
	XCAMP, XCAT, XCDS_BOOK, XCHOICE, XCPT, XDOC, XIAP, XINPUT, XLIST, XMANAGER_RESET, XPORT
	XPROGRAM, XREPORT, XSEL_LIST [1], XSEL_LIST [2], XSET_VALUE, XSHOW_RASTER, XSTRUCT
	XSTUDY, XTEXT, XZOOM_PLAN, db_gbo, ethz_XCHOICE, get_history, ihy_db, update_history
 Common      : None.

 Restrictions: None.

 Side effects: None.

 History     : Version 1,  20-Aug-1996,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_CENT_OFF $SSW/gen/idl/widgets/get_cent_off.pro
[Previous] [Next]
 Project     : SDAC

 Name        : GET_CENT_OFF

 Purpose     : determine pixel offsets for centering widget bases

 Use         : OFFSETS=GET_CENT_OFF(WBASE)

 Inputs      : WBASE = widget base id

 Opt. Inputs : GROUP = ID of group widget relative to which the
                       offset values are calculated

 Outputs     : OFFSETS=[XOFF,YOFF]

 Opt. Outputs: None.

 Keywords    : VALID = 1 if valid offsets found, 0 otherwise
               WSIZE = [xsize,ysize] of WBASE
               SCREEN = center relative to main screen

 Explanation :
               Useful for centering pop up text widgets.
               For example:
               if group base is defined as w1, then
               widget_control,w2,/realize,tlb_set_xoff=xoff,tlb_set_yoff=yoff
               will center w2 within w1.

 CALLS: ***
	XALIVE
 CALLED BY:
	GE_WINDOW_SIM, MK_SOHO_EDP, XGET_SYNOPTIC, XGET_UTC, XMESSAGE, XREALIZE, XSET_COLOR
	XSTRUCT
 Restrictions: WBASE must be valid otherwise [-1,-1] is returned

 Category    : Widgets

 Written     : Zarro (ARC/GSFC) 17 April 1995
 Modified    : Sandhia Bansal 05-Aug-2004.  Added a new 'nomap' keyword to delay
               the display of widget until later.
 Modified    : Zarro (L-3Com/GSFC) 13 August 2005 - Added CATCH


GET_COORDS $SSW/gen/idl_libs/astron/astro/get_coords.pro
[Previous] [Next]
 NAME:
       GET_COORDS

 PURPOSE:
       Converts a string with angular coordinates  to floating point values.  
 EXPLANATION:
       Although called by ASTRO.PRO, this is a general purpose routine.
       The user may input as floating point or sexigesimal.  If user inputs 
       calling procedure's job to convert hours to degrees if needed.
       Since the input string is parsed character-by-character, ANY character
       that is not a digit, minus sign or decimal point may be used as a 
       delimiter, i.e. acceptable examples of user input are:

       1:03:55 -10:15:31
       1 3 55.0 -10 15 31
       1*3 55              -10abcd15efghij31
       1.065278  hello   -10.25861

 CALLING SEQUENCE:
       GET_COORDS, Coords, [ PromptString, NumVals, INSTRING =, /QUIET ]

 OPTIONAL INPUT:
       PromptString - A string to inform the user what data are to be entered

 CALLED BY:
	ASTRO, PUTAST
 OPTIONAL KEYWORD INPUT:
       InString - a keyword that, if set, is assumed to already contain the
               input data string to be parsed.  If this keyword is set, then
               the user is not prompted for any input.
       /Quiet - if set the program won't printout any error messages, but bad
               input is still flagged by Coords=[-999,-999].

 OUTPUT:
       Coords - a 2 element floating array containing the coordinates.  The
               vector [-999,-999] is returned if there has been an error.

 OPTIONAL OUTPUT:
       NumVals - the number of separate values entered by the user:  2 if the
               user entered the coordinates as floating point numbers, 6 if 
               the user entered the coordinates as sexigesimal numbers.  Some
               calling procedures might find this information useful (e.g., to
               to print some output in the same format as the user's input).

 REVISION HISTORY:
       Written by Joel Parker, 5 MAR 90
       Included InString and Quiet keywords.  Cleaned up some of the code and
       comments.  JWmP,  16 Jun 94

*******************************************************************************
       Converted to IDL V5.0   W. Landsman   September 1997


get_correl_offsets $SSW/gen/idl/image/get_correl_offsets.pro
[Previous] [Next]
   Name: get_correl_offsets

   Purpose: calculate rigid displacement via cross-correlation 

   Input Paramters:
      data - image cube 

   Keyword Parameters:
      reference - image number of reference image (default is 1st = 0 )

 CALLED BY:
	align_cube_correl
   History:
      15-October-1998 - S.L.Freeland - Directly 'tr_get_disp' by Ted Tarbell
                        (using algorithm derived from B.Lin)
      Review/Distillation of SSW cross correlation techniques
      [One of several cross correl methods under SSW  - others include 
               'get_off.pro  G.L.Slater  
               'korrel.pro   J.P.Wuelser
               'cross_correl T. Berger 

 CALLS: ***
	HANNING, IS_IN_RANGE, data_chk [1], data_chk [2]
   Restrictions:
      Under review during review of 'best' cross corr methods
      Need to add CORR_FOV (permit user specified subfields)

   Category:
      2D , 3D, Image, Alignment , Cross Correlation, Cube
   


GET_DATE [1] $SSW/gen/idl/fits/get_date.pro
[Previous] [Next]
 NAME:
       GET_DATE
 PURPOSE:
       Return the (current) UTC date in CCYY-MM-DD format for FITS headers
 EXPLANATION:
       This is the format required by the DATE and DATE-OBS keywords in a 
       FITS header.

 CALLING SEQUENCE:
       GET_DATE, FITS_date, [ in_date, /OLD, /TIMETAG, LOCAL_DIFF=]
 OPTIONAL INPUTS:
       in_date - string (scalar or vector) containing dates in IDL
            systime() format (e.g. 'Tue Sep 25 14:56:14 2001')
 OUTPUTS:
       FITS_date = A scalar character string giving the current date.    Actual
               appearance of dte depends on which keywords are supplied.
       
       No Keywords supplied - dte is a 10 character string with the format
               CCYY-MM-DD where <CCYY> represents a calendar year, <MM> the
               ordinal number of a calendar month within the calendar year, 
               and <DD> the ordinal number of a day within the calendar month.
       /TIMETAG set - dte is a 19 character string with the format
               CCYY-MM-DDThh:mm:ss where <hh> represents the hour in the day,
                <mm> the minutes, <ss> the seconds, and the literal 'T' the 
               ISO 8601 time designator
       /OLD set - dte is an 8 character string in DD/MM/YY format

 INPUT KEYWORDS:
       /TIMETAG - Specify the time to the nearest second in the DATE format
       /OLD - Return the DATE format formerly (pre-1997) recommended for FITS
               Note that this format is now deprecated because it uses only
               a 2 digit representation of the year. 
       LOCAL_DIFF - numeric scalar giving the difference between local time
               and Greenwich Mean Time (GMT) in hours.   This keyword is only
               needed for non-Unix users prior to V5.4.  Unix users should not 
               use this keyword because under Unix (or since V5.4 with any OS),
               SYSTIME(1) returns the UTC (=GMT) time directly.
               Users on other machines must either supply a LOCAL_DIFF keyword,
               or use the TIME_CONV environment variable discussed below.    
               For example, a user on U.S. Eastern Standard Time should set 
               LOCAL_DIFF = -5
 CALLS: ***
	DAYCNV [1], DAYCNV [2], DAYCNV [3], MONTH_CNV
 CALLED BY:
	FITS_ADD_CHECKSUM, FXBHMAKE [1], FXBHMAKE [2], FXHMAKE [1], FXHMAKE [2]
	FXREAD [1], FXREAD [2], FXWRITE [1], FXWRITE [2], MKHDR [1], MKHDR [2], SXHMAKE
	SXMAKE
 EXAMPLE:
       Add the current date to the DATE keyword in a FITS header,h
     
       IDL> GET_DATE,dte
       IDL> sxaddpar, h, 'DATE', dte, 'Date header was created'
 ENVIRONMENT VARIABLE:
       An alternate method of inputing the difference between local and GMT 
       time for non-Unix machines is to specify this information in a file 
       named local_diff.dat in a directory specified with the environment 
       variable TIME_CONV.       For example, a user in EST should write -5 
       on this first (and only) line of this file.

 NOTES:
       (1) A discussion of the DATExxx syntax in FITS headers can be found in
       ftp://fits.cv.nrao.edu/fits/data/samples/year-2000/year2000.txt

       (2) Those who wish to use need further flexibility in their date 
       formats (e.g. to use TAI time) should look at Bill Thompson's time
       routines in http://sohowww.nascom.nasa.gov/solarsoft/gen/idl/time

 PROCEDURES USED:
       DAYCNV - Convert Julian date to Gregorian calendar date
 REVISION HISTORY:
       Written      W. Landsman          March 1991
       Major rewrite to write new DATExxx syntax  W. Landsman  August 1997
       Converted to IDL V5.0   W. Landsman   September 1997
       Work after year 2000 even with /OLD keyword W. Landsman January 2000
       Don't need to worry about TIME_DIFF since V5.4 W. Landsman July 2001


GET_DATE [2] $SSW/gen/idl_libs/astron/astro/get_date.pro
[Previous] [Next]
 NAME:
       GET_DATE
 PURPOSE:
       Return the (current) UTC date in CCYY-MM-DD format for FITS headers
 EXPLANATION:
       This is the format required by the DATE and DATE-OBS keywords in a 
       FITS header.  

 CALLING SEQUENCE:
       GET_DATE, FITS_date, [ in_date, /OLD, /TIMETAG ]
 OPTIONAL INPUTS:
       in_date - string (scalar or vector) containing dates in IDL
            systime() format (e.g. 'Tue Sep 25 14:56:14 2001')
 OUTPUTS:
       FITS_date = A scalar character string giving the current date.    Actual
               appearance of dte depends on which keywords are supplied.
       
       No Keywords supplied - dte is a 10 character string with the format
               CCYY-MM-DD where <CCYY> represents a calendar year, <MM> the
               ordinal number of a calendar month within the calendar year, 
               and <DD> the ordinal number of a day within the calendar month.
       /TIMETAG set - dte is a 19 character string with the format
               CCYY-MM-DDThh:mm:ss where <hh> represents the hour in the day,
                <mm> the minutes, <ss> the seconds, and the literal 'T' the 
               ISO 8601 time designator
       /OLD set - dte is an 8 character string in DD/MM/YY format

 INPUT KEYWORDS:
       /TIMETAG - Specify the time to the nearest second in the DATE format
       /OLD - Return the DATE format formerly (pre-1997) recommended for FITS
               Note that this format is now deprecated because it uses only
               a 2 digit representation of the year. 
 CALLS: ***
	DAYCNV [1], DAYCNV [2], DAYCNV [3], MONTH_CNV
 CALLED BY:
	FITS_ADD_CHECKSUM, FXBHMAKE [1], FXBHMAKE [2], FXHMAKE [1], FXHMAKE [2]
	FXREAD [1], FXREAD [2], FXWRITE [1], FXWRITE [2], MKHDR [1], MKHDR [2], SXHMAKE
	SXMAKE
 EXAMPLE:
       Add the current date to the DATE keyword in a FITS header,h
     
       IDL> GET_DATE,dte
       IDL> sxaddpar, h, 'DATE', dte, 'Date header was created'

 NOTES:
       (1) A discussion of the DATExxx syntax in FITS headers can be found in
       http://www.cv.nrao.edu/fits/documents/standards/year2000.txt

       (2) Those who wish to use need further flexibility in their date 
       formats (e.g. to use TAI time) should look at Bill Thompson's time
       routines in http://sohowww.nascom.nasa.gov/solarsoft/gen/idl/time

 PROCEDURES USED:
       DAYCNV - Convert Julian date to Gregorian calendar date
 REVISION HISTORY:
       Written      W. Landsman          March 1991
       Major rewrite to write new DATExxx syntax  W. Landsman  August 1997
       Converted to IDL V5.0   W. Landsman   September 1997
       Work after year 2000 even with /OLD keyword W. Landsman January 2000
       Don't need to worry about TIME_DIFF since V5.4 W. Landsman July 2001
       Assume since V5.4, remove LOCAL_DIFF keyword  W. Landsman April 2006


GET_DEF_PRINTER $SSW/gen/idl/system/get_def_printer.pro
[Previous] [Next]
 Name        : GET_DEF_PRINTER

 Purpose     : Get default printer from available printers

 Category    : system

 Explanation : 

 Syntax      : IDL> get_def_printer,printer

 Inputs      : None

 Opt. Inputs : None

 Outputs     : PRINTER = default printer name

 Opt. Outputs: None

 Keywords    : DEFAULT = default printer name
               DESC = description of printer
               SET  = set input printer to be last selected printer

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], LIST_PRINTER, TRIM
 CALLED BY:
	XPS_SETUP, XSEL_PRINTER
 Common      : GET_DEF_PRINTER = last selected printer

 Restrictions: None

 Side effects: None

 History     : Version 1,  28 Feb 1997,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


get_def_times $SSW/gen/idl/time/get_def_times.pro
[Previous] [Next]
 Project     : HESSI

 Name        : get_def_times

 Purpose     : return default times

 Category    : HESSI, GBO, utility, time

 Explanation : If TSTART/TEND are not specified correctly, then
               return current time and end of current day
               as useful defaults

 Syntax      : IDL> dstart=get_def_times(tstart,tend,dend=dend)

 Opt. Inputs : TSTART = start time
               TEND   = end time

 Outputs     : DSTART = TSTART or current time if invalid TSTART (TAI format)

 Opt. Outputs: None

 Keywords    : DEND = TEND or end of current day if invalid TEND
               Inherits ANYTIM keywords
               ROUND_TIMES = round start/end to start/end of day
               NO_NEXT = don't include next day

 CALLS: ***
	ANYTIM2TAI, ANYTIM2UTC [1], ANYTIM2UTC [2], GET_UTC, TRIM, is_struct, vso_format
 CALLED BY:
	BBSO__DEFINE, CDS_ASRUN_POINT, CDS_PLAN_POINT, EIT_COPY, EIT__DEFINE, LAROBS_COPY
	PLOT_CDS_POINT [1], PLOT_CDS_POINT [2], RD_CDS_POINT, RD_GOES, TRACE_COPY
 History     : 14-Nov-1999,  D.M. Zarro (SM&A/GSFC),  Written
               22-Mar-2004, Zarro (L-3Com/GSFC) - added check for tend < tstart
               7-Apr-2004, Zarro (L-3Com/GSFC) - fixed bug that returned
                structure time instead of TAI (Sorry, Luis)
               12-Nov-2005, Zarro (L-3Com/GSFC) - added VSO output:
                yyyymmddhhmmss

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_DFONT [1] $SSW/gen/idl/system/get_dfont.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        :
	GET_DFONT()
 Purpose     :
       Return widget font with size compatible with current device
 Explanation :
	Useful for selecting fonts to fit into  widgets
 Use         :
	Result = GET_DFONT(UFONT)
 Inputs      :
       UFONT = user's optional input fonts (string array)
 Opt. Inputs :
	None.
 Outputs     :
            DFONT = returned fonts (string array)
 Prev. Hist. :
       Written Elaine Einfalt (HSTX) May 1992.
 Modified    :
       Version 1, Dominic Zarro, GSFC, 1 August 1994.
               Corrected some bugs
	Version 2, 23-Oct-1997, William Thompson, GSFC,
		Only select X device if on Unix or VMS.
		Call SELECT_WINDOWS
       Modified, 18-Jun-01, Zarro (EITI/GSFC) - added call to IS_WOPEN
       Modified, 10-Jul-02, Kim Tolbert - added branches for Windows

 CALLS:
 CALLED BY
	CHIANTI_NE, CHIANTI_TE, EIT_CATRD [1], EIT_DISPLAY, General_Menu [1]
	HESSI PARAMETER SELECTION TOOL [1], HESSI Spectrum [2], HESSI Spectrum [4]
	IMAGE_TOOL, ITOOL_PKFILE_BS, ITOOL_PTOOL, MDisp, MK_DFONT, MK_POINT_BASE, MK_RASTER
	MK_SOHO, MK_SOHO_CUSTOM, MK_SOHO_EDP, MK_SOHO_SBASE [1], MK_SOHO_SBASE [2]
	Move_Image, PICKFITS, POPUP_MSG, ROUTINE_NAME [4], ROUTINE_NAME [7]
	Radio Astronomy Group View RAG View [1]
	Radio Astronomy Group View RAG View [2], SCANPATH, SET_CURSOR_SHAPE
	SUMER_SEARCH, SUMER_TOOL, WIDG_HELP, XGET_SYNOPTIC, XGET_UTC, XMATRIX, XMESSAGE
	XTEXTEDIT, ch_ss, emiss_select, get_font


get_doc [1] $SSW/gen/idl/genutil/get_doc.pro
[Previous] [Next]
   Name: get_doc

   Purpose: retrieve a subset of idl header info. in a standard structure

   Input Parameters:
  	modules -  string or string array of idl module names

   Output Paramters:
     	function returns a vector of documentation structures
   
   Optional Keyword Parameters:
       quiet - if set, no output (just return documentation structures)
       summ  - if set, brief output (fmt_doc(doc_str)) - default
       full  - if set, full header is printed


   Method:
	calls get1doc for each element of modules

   Calling Sequence: docstrs=get_doc(modules)

 CALLS:


GET_DROT_DUR $SSW/gen/idl/mapping/get_drot_dur.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_DROT_DUR

 Purpose     : compute durations (in seconds) to solar rotate a map

 Category    : imaging

 Explanation : cater for different types of inputs 

 Syntax      : dur=get_drot_dur(map,duration,time=time)

 Inputs      : MAP = time or map structure
               DURATION = amount to rotate by [def=hours units]

 Outputs     : DUR = duration in seconds

 Keywords    : TIME = time to rotate to (ignored if duration is input)
               DAYS = input duration units in days
             : SECONDS = input duration units in seconds
  
 CALLS: ***
	ANYTIM2TAI, EXIST, GET_MAP_TIME, PR_SYNTAX, VALID_MAP, anytim [1], anytim [2]
	anytim [3], anytim [4], anytim [5], is_struct
 CALLED BY:
	DROT_MAP, DROT_MAP_FAST, PLOT_MAP
	PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support
 History     : Written 5 June 1998, D. Zarro, SAC/GSFC
               10 Jan 2005, Zarro (L-3Com/GSFC) - permitted zero duration

 Contact     : dzarro@solar.stanford.edu


get_edge_products $SSW/gen/idl/spectra/get_edge_products.pro
[Previous] [Next]
 Name: get_edge_products

 Purpose:  Wrapper around EDGE_PRODUCTS procedure to turn it into a function

 Category:  GEN  SPECTRA
 Method:
 GET_EDGE_PRODUCTS has the same arguments as EDGE_PRODUCTS, except that it
 treats the choices of different output types as boolean keywords, and just returns
 the one selected.
 See EDGE_PRODUCTS documentation for meaning of keyword arguments.

 CALLS: ***
	edge_products
 CALLED BY:
	HESSI MULTI IMAGE CLASS DEFINITION [1]
	HESSI MULTI IMAGE CLASS DEFINITION [2], PROFILES2, SPEX_GEN__DEFINE
	SPEX__DEFINE, XYPLOT__DEFINE, axis_get_edges, axis_get_limits, binning__define
	cw_energy_range, find_pixel_intersects, hsi_compute_image_axis, hsi_ui_ql
	spex_data__define
 Example:  To return the [low,high] boundaries for contiguous channels in array:
    result = get_edge_products(array, /edges_2)

 Written:  Kim Tolbert 26-Oct-2002


GET_EDGES $SSW/gen/idl/spectra/get_edges.pro
[Previous] [Next]
 Name: GET_EDGES

 Purpose: From a vector of contiguous channel boundaries return the
	commonly used quantities for plotting and scaling.

 Calling Sequence
	contiguous_edges = get_edges( [random_values], /contiguous )
	returns and ordered and vector with unique elements.
 Category:
	GEN, UTIL, SPECTRA

 Input: Edges -if 1d, contiguous channel boundaries, n+1 values for n channels
               if 2d, 2xn, [lo(i),hi(i)], etc., assumed contiguous for
		calculating edges_1

 Output:
	Mean - arithmetic mean of boundaries
       Gmean - geometric mean
	width - absolute difference between upper and lower edges
	edges_2 - 2xn array of edges [lo(i), hi(i)], etc.
       edges_1 - array of n+1 edges of n contiguous channels
	Keyword Inputs
	EPSILON - If the absolute relative difference is less than epsilon
	then two numbers are considered to be equal and a new bin is not required under
   the contiguous requirement.  If epsilon isn't passed but CONTIGOUS is set it
	attempts to construct an epsilon based on the average relative difference between
	adjacent bins, it takes that value and multiplies it by 1e-5 and limits that to
	1e-6
   CONTIGUOUS - force all edges to be contiguous, including edges_1

 Mod. History:

 8-dec-2001, richard.schwartz@gsfc.nasa.gov, made a function
	based on edge_products
 25-aug-2006, ras, added epsilon and default epsilon as test
	to differentiate real numbers. If the absolute relative difference is less than epsilon
	then two numbers are considered to be equal and a new bin is not required under
   the contiguous requirement
 CALLS:
 CALLED BY
	Energy_res [2], F_VTH, HESSI BINNED EVENTLIST CLASS DEFINITION
	HESSI FRAMEWORK TEMPLATE CLASS [2], HESSI FRAMEWORK TEMPLATE CLASS [3]
	HSI_DECIM_CORRECTION [1], HSI_DECIM_CORRECTION [2], HSI_DRM_MOD CLASS
	HSI_DRM_MOD_CONTROL__DEFINE, HSI_SPECTROGRAMACCBIN [5]
	HSI_SPECTROGRAMCHAN_OVERLAP_FIX, HSI_SPECTROGRAM_DECIM_CORRECT
	HSI_SPECTROGRAM_DECIM_TABLE, HSI_SPECTRUM__DEFINE, HSI_SRM_EXTEND_PH_ENERGY
	MK_CONTIGUOUS, Pileup_countrate_Build_Piler, Pileup_countrate_PULSE_CONVOLVE
	SOXS_CZT_DRM, SOXS_DRM, SPECTROGRAM CLASS DEFINITION
	SPECTRUM CLASS DEFINITION, SPEX_DRM__DEFINE, SPEX_GEN__DEFINE
	energy_res class, hsi_obs_summary__define [1], hsi_obs_summary__define [2]
	hsi_spectrogramACCBIN [2], hsi_spectrogram__define [1]
	hsi_spectrogram__define [2], hsi_spectrogram__define [3]
	hsi_spectrogram__get_obs [1], hsi_spectrogram__livetime [1], plotman
	read_hessi_4_ospex, read_hessi_4_spex [1], read_hessi_4_spex [2]
	read_hessi_fits_4_spex [1], read_hessi_fits_4_spex [2], read_soxs_4_ospex
	read_xsm_4_ospex, soxs_readfile, spex_bk__define, spex_data_strategy__define
	spex_nontherm_energy, spex_xsm_fits2drm


get_elemabun [1] $SSW/gen/idl/spectra/get_elemabun.pro
[Previous] [Next]
 NAME:
   get_elemabun
 PURPOSE:
   Return elemental abundances.  H = 1, He = (approx) .2, etc.
 CALLING SEQUENCE:
   abun = get_elemabun()		; Return default
   abun = get_elemabun(Num,info=info)	; info is an information string

 INPUTS:
   Num		= Number of the abundance values to use.  See data statements
		  below for the descriptions.
 OPTIONAL INTPUT KEYWORDS:
   verbose	= Give some information while running
 OPTIONAL OUTPUT KEYWORDS:
   Info	= Information string
    7-Oct-93, J. R. Lemen (LPARL), Written
 CALLS:
 CALLED BY
	bcs_line


GET_ENVIRON $SSW/gen/idl/system/get_environ.pro
[Previous] [Next]
 Project     :	SOHO - CDS

 Name        :	GET_ENVIRON()

 Purpose     :	Get environment variables.

 Category    :	

 Explanation :	In VMS, logical names can be either single valued or
		multi-valued.  This routine will use TRNLOG,/FULL to get the
		full translation of a logical name in VMS.  In other operating
		systems, GETENV is used instead.

 Syntax      :	Result = GET_ENVIRON( EVAR )

 CALLED BY:
	FIND_ZDBASE, FIX_ZDBASE, GOES_TF, GOES_TF_COEFF, MK_STUDY, SHOW_EVARS, XREPORT
	make_goes_chianti_response [1], make_goes_chianti_response [2]
	make_goes_chianti_response [3], make_goes_chianti_response [4]
 Examples    :	ZDBASE = GET_ENVIRON('ZDBASE')

 Inputs      :	EVAR	= The name of the environment variable.  It can start
			  with a $ to signal that it is a logical name, but
			  that isn't necessary.

 Opt. Inputs :	None.

 Outputs     :	The result of the function is the value of the environment
		variable.

 Opt. Outputs:	None.

 Keywords    :	PATH	= If set, then the value of the environment variable is
			  returned as a single delimited string, even if the
			  environment variable is multi-valued.  Ignored in
			  operating systems other than VMS.

 Calls       : ***
	OS_FAMILY
 Common      :	None.

 Restrictions:	None.

 Side effects:	None.

 Prev. Hist. :	None.

 History     :	Version 1, William Thompson, GSFC, 7 August 1996

 Contact     :	WTHOMPSON


GET_EQUINOX $SSW/gen/idl_libs/astron/astrom/get_equinox.pro
[Previous] [Next]
 NAME:
       GET_EQUINOX
 PURPOSE:
       Return the equinox value from a FITS header.  
 EXPLANATION:
       Checks for 4 possibilities:

       (1)  If the EQUINOX keyword is found and has a numeric value, then this
               value is returned
       (2)  If the EQUINOX keyword has the values 'J2000' or 'B1950', then
               either 2000. or 1950. is returned.
       (3)  If the EQUINOX keyword is not found, then GET_EQUINOX will return
               the EPOCH keyword value.   This usage of EPOCH is disparaged.
       (4)  If neither EQUINOX no EPOCH is found, then the RADECSYS keyword
               is checked.   If the value is 'ICRS' or 'FK5' then 2000 is
               is returned, if it is 'FK4' then 1950 is returned.

       According Calabretta & Greisen (2002, A&A, 395, 1077) the EQUINOX should
       be written as a numeric value, as in format (1).   However, in older 
       FITS headers, the EQUINOX might have been written using formats (2) or 
       (3).      
 CALLING SEQUENCE:
       Year = GET_EQUINOX( Hdr, [ Code ] )   

 INPUTS:
       Hdr - FITS Header, string array, will be searched for the EQUINOX
               (or EPOCH) keyword.

 OUTPUT:
       Year - Year of equinox in FITS header, numeric scalar
 OPTIONAL OUTPUT:
       Code - Result of header search, scalar
               -1 - EQUINOX, EPOCH or RADECSYS keyword not found in header
               0 - EQUINOX found as a numeric value
               1 - EPOCH keyword used for equinox (not recommended)
               2 - EQUINOX found as  'B1950'
               3 - EQUINOX found as  'J2000'
               4 - EQUINOX derived from value of RADECSYS keyword
                   'ICRS', 'FK5' ==> 2000,  'FK4' ==> 1950

 PROCEDURES USED:
       ZPARCHECK, SXPAR()
 REVISION HISTORY:                                               
       Written  W. Landsman        STX              March, 1991
       Converted to IDL V5.0   W. Landsman   September 1997
       Don't use !ERR          W. Landsman   February 2000
       N = 1 for check of EPOCH keyword, not 0 S. Ott July 2000
 CALLS:
 CALLED BY
	ATV, HASTROM, HPRECESS, IMDBASE, PUTAST, XYXY


GET_FID $SSW/gen/idl/time/get_fid.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_FID

 Purpose     : determine YYMMDD names based on date/time 

 Category    : utility io 

 Syntax      : rdir=get_fid(tstart,tend)

 Inputs      : TSTART/TEND = start/end times to base search
               e.g. TSTART = 10-may-99 -> 990510
                    TEND   = 20-dec-99 -> 991220

 Outputs     : Array directory names 

 Keywords    : NO_DAY = exclude day from output
               FULL= include full year in output
               YEAR_ONLY = include year only
               DELIM = delimiter between year, month, & day

 CALLS: ***
	ANYTIM2TAI, ANYTIM2UTC [1], ANYTIM2UTC [2], APPEND_ARR, GET_UTC, TIME2FID
	VALID_TIME
 CALLED BY:
	HFITS__DEFINE, HSI_SOCK_FIND, HSI_SOCK_LIST, SITE__DEFINE, SOCK_FILES
 History     : Written 6 Jan 1999, D. Zarro (SM&A/GSFC)

 Contact     : dzarro@solar.stanford.edu


GET_FITS_CDELT $SSW/gen/idl/fits/get_fits_cdelt.pro
[Previous] [Next]
 Project     : SOHO, YOHKOH

 Name        : GET_FITS_CDELT

 Purpose     : Get FITS CDELT values from header

 Category    : imaging, FITS

 Explanation : Try to determine FITS scaling info

 Syntax      : get_fits_time,stc,time

 Inputs      : STC - FITS header in structure format (such as from HEAD2STC)

 Outputs     : CDELT1, CDELT2 - image pixel scaling

 Keywords    : TIME - optional image time (if already determined)
               ERR  - error message

 CALLS: ***
	ANYTIM2UTC [1], ANYTIM2UTC [2], GET_FITS_TIME, PB0R, PR_SYNTAX, REP_TAG_NAME
	gt_tagval [1], gt_tagval [2], is_struct
 CALLED BY:
	GET_FITS_CEN
 History     : Written, 15 November 1998, D.M. Zarro (SM&A)

 Contact     : dzarro@solar.stanford.edu


GET_FITS_CEN $SSW/gen/idl/fits/get_fits_cen.pro
[Previous] [Next]
 Project     : SOHO, YOHKOH

 Name        : GET_FITS_CEN

 Purpose     : Return XCEN and/or YCEN from FITS-like stucture

 Category    : imaging, FITS

 Explanation : 

 Syntax      : get_fits_cen,struct,xcen,ycen,dx,dy

 Inputs      : struct - FITS-like structure

 Opt. Inputs : None

 Outputs     : XCEN, (and/or YCEN) - center of FOV in data units

 Keywords    : TIME - optional time

 CALLS: ***
	ANYTIM2UTC [1], ANYTIM2UTC [2], APPEND_ARR, COMP_FITS_CEN, DPRINT, EXIST
	GET_FITS_CDELT, GET_FITS_TIME, HAVE_TAG, HEL2ARCMIN [1], HEL2ARCMIN [2], PR_SYNTAX
	gt_tagval [1], gt_tagval [2], is_struct
 History     : Written, 12 November 1998, D.M. Zarro (SM&A)
               Modified, 16 Sept 2001, Zarro (EITI/GSFC)
               -added check for non-zero XCEN/YCEN

 Contact     : dzarro@solar.stanford.edu


get_fits_extno $SSW/gen/idl/fits/get_fits_extno.pro
[Previous] [Next]
 NAME:
       get_fits_extno

 PURPOSE:
       To retrieve extension number(s) for extensions with given name(s).

 CATEGORY:
       I/O, FITS

 CALLING SEQUENCE:
       get_fits_extno, file_or_fcb, extname [, message=message]

 INPUTS:
       file_or_fcb - this parameter can be the FITS Control Block (FCB)
               returned by FITS_OPEN or the file name of the FITS file.
       extname - name of extension (string scalar or array)

 KEYWORD PARAMETERS:
		message = output error message

 CALLS: ***
	FITS_CLOSE, FITS_OPEN, where_arr [1], where_arr [2]
 CALLED BY:
	Energy_res [2], HESSI FRAMEWORK TEMPLATE CLASS [2]
	HESSI FRAMEWORK TEMPLATE CLASS [3], HSI_DRM_MOD CLASS
	HSI_DRM_MOD_CONTROL__DEFINE, HSI_QLOOK_SUMMARY_PAGE__DEFINE
	SPEX_READ_FIT_RESULTS, hsi_break_srm, hsi_filedb_read [1], hsi_filedb_read [2]
	hsi_qlook__define, hsi_test_files, read_hessi_4_ospex_params
 History:
	Written: Kim Tolbert 1-jun-2002


GET_FITS_INSTR $SSW/gen/idl/fits/get_fits_instr.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_FITS_INSTR

 Purpose     : Return source of data (telescop, mission, or instrument) from FITS header

 Category    : FITS

 Explanation :

 Syntax      : instr = get_fits_instr(header)

 Inputs      : header - FITS header

 Opt. Inputs :
   file - Can pass in a file name instead of the header structure.  Ignores header argument
      in this case.  Looks in each extension of file for instrument, telescop or mission.

 Outputs     : String containing instrument (or telescop or mission).  Blank if not found.

 CALLS: ***
	FITS_INFO [1], FITS_INFO [2], FXPAR [1], FXPAR [2], MRDFITS [1], MRDFITS [2], TRIM
 CALLED BY:
	SPEX_DRM__DEFINE, spex_xsm_fits2drm
 History     : Written, Kim Tolbert 23-Apr-2003
  26-Aug-2004, Kim.  Use 'telescop' first, and don't use 'origin'
  19-Nov-2004, Kim.  Added file keyword.  And changed order so instrument is first.
  23-Jun-2005, Kim.  Added check for blank - keep looking if blank


GET_FITS_TIME $SSW/gen/idl/fits/get_fits_time.pro
[Previous] [Next]
 Project     : SOHO, YOHKOH

 Name        : GET_FITS_TIME

 Purpose     : Get FITS observation time from header

 Category    : imaging, FITS

 Explanation : Try to get FITS time from several formats

 Syntax      : get_fits_time,stc,time

 Inputs      : STC - FITS header in structure format (such as from HEAD2STC)

 Outputs     : TIME - time in UTC units

 Keywords    : ERR - error message
               CURRENT - set to default to current time

 CALLS: ***
	ANYTIM2TAI, ANYTIM2UTC [1], ANYTIM2UTC [2], GET_MONTH, GET_UTC, HAVE_TAG, IS_STRING
	PR_SYNTAX, TAG_EXIST [1], TAG_EXIST [2], TRIM, anytim [1], anytim [2], anytim [3]
	anytim [4], anytim [5], is_struct, required_tags
 CALLED BY:
	GET_FITS_CDELT, GET_FITS_CEN, MK_SOHO_MAP_EARTH, lasco_time2file
	return  a solar disk mask using SSW standard keywords
 History     : Written, 15 November 1998, D.M. Zarro (SM&A)
               Modified, 15 Feb 2000, Zarro (SM&A/GSFC) - added
               more checks for different time tag varieties
               Modified, 15 Aug 2000, Zarro (EIT/GSFC) -- fixed
               vector problem
               Modified, 21 Mar 2004, Zarro (L-3Com/GSFC) -- added
               more time format checks

 Contact     : dzarro@solar.stanford.edu


get_font $SSW/gen/idl/genutil/get_font.pro
[Previous] [Next]
 PROJECT:  HESSI

 NAME: get_font

 PURPOSE:  Get fonts suitable for widgets for any platform

 CATEGORY: WIDGETS

 CALLING SEQUENCE:  get_font, font, big_font=big_font, small_font=small_font, huge_font=huge_font

 INPUTS:
	None

 OPTIONAL KEYWORDS:
	big_font - larger font for titles, etc
	small_font
	huge_font

 OUTPUTS:
	font - normal size font

 OPTIONAL OUTPUTS:  None

 Calls: ***
	GET_DFONT [1], GET_DFONT [2]
 COMMON BLOCKS: None

 HISTORY:
	Kim Tolbert, 10-Jul-2005 (extracted from hsi_ui_getfont)



get_from_plot $SSW/gen/idl/display/get_from_plot.pro
[Previous] [Next]
 NAME:
	get_from_plot
 PURPOSE
	To click a box on a plot and return the indices of the data
	points that fall in that box.
 CALLING EXAMPLE
	ss=get_from_plot(xdata,ydata)
 INPUT
	xdata = x-array for making plot.
	ydata = y-array for making plot.
 OUTPUT
	vector of indices of data points falling within the box
 HISTORY
	24-Jul-2001  LWA  Logic cribbed from plot_fov.pro
 CALLS:


GET_GEV $SSW/gen/idl/solar/get_gev.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_GEV

 Purpose     : Wrapper around RD_GEV

 Category    : planning

 Explanation : Get GOES Event listing

 Syntax      : IDL>gev=get_gev(tstart)

 Inputs      : TSTART = start time 

 Opt. Inputs : TEND = end time

 Outputs     : GEV = event listing in structure format

 Keywords    : COUNT = # or entries found
               ERR = error messages
               QUIET = turn off messages
               LIMIT = limiting # of days for time range

 CALLS: ***
	ADD_PATH [1], ADD_PATH [2], ANYTIM2UTC [1], ANYTIM2UTC [2], DATATYPE [1]
	DATATYPE [2], DATATYPE [3], GET_UTC, HAVE_PROC, IS_DIR, NUM2STR, RD_GEV, TRIM
	is_number [1], is_number [2]
 CALLED BY:
	LIST_GEV, NEAREST_GEV, PRINT_GEV, db_gbo, flare_hist
 History     : Version 1,  20-June-1999,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


get_gevloc_data $SSW/gen/idl/http/get_gevloc_data.pro
[Previous] [Next]
   Name: get_gevloc_data

   Purpose: return contents of gev/flare location file (structure vector)

   Input Parameters:
      enames - optional specfic event name pattern to search/return
              (if not supplied, entire contens of gevloc file returned)

   Keyword Parameters:
      path (input) - subdirectory to use (default is current 'last_events')
      gevloc_file - subdirectory used (if gevloc file found)
      force_remote - (switch) - if set, force remote access via sock_copy
 
  Calling Sequence:
     gevloc=get_gevloc_data()       ; return entire 'latest_events' data
     gevloc=get_gevloc_data(enames) ; specific events (using gev_YYYYMMDD_HHMM)
               

 CALLED BY:
	les_archive_info
   History:
      10-Apr-2001 - S.L.Freeland - helper utility for last_events maint
      16-Apr-2001 - S.L.Freeland - use sockets if not local and >+5.4 IDL
      11-Apr-2003 - S.L.Freeland - add /MERGE and /TEMP functions
      14-Jan-2004 - S.L.Freeland - add ARCHIVE_URL keyword&function

 CALLS: ***
	ADD_TAG [1], ADD_TAG [2], BOX_MESSAGE, CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], CONCAT_STRUCT, FILE2TIME, FILE_EXIST [2], GET_TEMP_DIR
	SINCE_VERSION [1], SINCE_VERSION [2], SOCK_COPY, SSW_FILE_DELETE, UNIQ [1]
	UNIQ [2], UNIQ [3], anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
	concat_dir [4], data_chk [1], data_chk [2], file_exist [1], file_exist [3]
	file_list [1], file_list [2], restgenx, str_replace [1], str_replace [2]
	tim2dset [1], tim2dset [2]
   Restrictions:
      for remote access, requires IDL >= 5.4


get_goes_defsat [1] $SSW/gen/idl/goes/get_goes_defsat.pro
[Previous] [Next]
   Name: get_goes_defsat

   Purpose: return time dependent GOES satellite number

   Input Parameters:
       start_time - time or start time of range
       stop_time - optional stop time (if range)

   Output:
      function returns time dependent GOES satellite number ("default")


   Keyword Parameters:
      check_sswdb - (switch) - if set, verify dbase is online
      online (output) - boolean - 1 if dbase is available 
      string_return - (switch) - if set, output is string Sat#
      
 CALLS: ***
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], reltime [1], reltime [2]
	ssw_deltat
 CALLED BY:
	goes_plot [1], goes_plot [2], goes_plot [3], goes_plot [4], goes_plot [5]
	rd_gxd [1], rd_gxd [2], rd_gxd [3]
   History: 
      16-Apr-2003 - S.L.Freeland rd_gxd/plot_goes helper 


get_group $SSW/gen/idl/system/get_group.pro
[Previous] [Next]
  NAME:
      get_group

  SAMPLE CALLING SEQUENCE:
	group = get_group()
	groups = get_group(/all)

  PURPOSE:
      Find out the name of the group of the current process.
      Optionally return the list of all groups it's a member of

  INPUT PARAMETERS:
	None.

  OUTPUT PARAMETERS:
	Returned value is the group name.

 CALLS: ***
	STR2ARR [1], STR2ARR [2]
 CALLED BY:
	ssw_upgrade [1], ssw_upgrade [2], ssw_upgrade_backup, sswdb_upgrade
  PROCEDURE:
	Spawn a child process and pipe the result back.

  HISTORY:
	Written 16-Apr-97 by M.Morrison
       22-Jun-2000 - RDB - return '' except under unix


GET_GZIP $SSW/gen/idl/system/get_gzip.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_GZIP

 Purpose     : find GZIP command on a Windows system

 Category    : system, utility,i/o

 Syntax      : gzip_cmd=get_gzip()

 Inputs      : None
 
 Keywords    : ERR = error string

 CALLS: ***
	CHKLOG [1], CHKLOG [2], DPRINT, ESPAWN, GET_TEMP_DIR, HAVE_PROC, LOC_FILE [1]
	LOC_FILE [2], LOC_FILE [3], OS_FAMILY
 CALLED BY:
	uncompress
 Restrictions: Windows only

 History     : May 20 Apr 2000, D. Zarro (SMA/GSFC)

 Contact     : dzarro@solar.stanford.edu


GET_HANDLER_ID $SSW/gen/idl/widgets/get_handler_id.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_HANDLER_ID

 Purpose     : to get widget ID of base associated with event handler

 Category    : widgets

 Explanation : examines XMANAGER common for registered ID's

 Syntax      : IDL> widget_id = get_handler_id(handler)

 Inputs      : HANDLER = event handler name

 Opt. Inputs : None

 Outputs     : WIDGET_ID = most recent widget ID associated with handler

 Opt. Outputs: None

 Keywords    : GHOSTS = other widget ID's related to handler name
               ALL = return all ID's associated with handler

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], EXIST, TRIM, XMANAGER_COM
 CALLED BY:
	EIS_CAT [1], EIS_CAT [2], MK_CDS_PLAN, MK_STUDY, SCANPATH, SHOW_SYNOP, XACK, XALIVE
	XCAMP, XCAT, XGHOST, XKILL, XSHOW, XSTUDY, XTEXT
 Common      : None

 Restrictions: None

 Side effects: None

 History     : Version 1,  22-Aug-1996,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_HANDLER_NAME $SSW/gen/idl/widgets/get_handler_name.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_HANDLER_NAME

 Purpose     : to get name of event handler for widget ID.

 Category    : widgets

 Explanation : examines XMANAGER common for registered ID's

 Syntax      : IDL> handler = get_handler_name(widget_id)

 Inputs      : WIDGET_ID = widget id 

 Opt. Inputs : None

 Outputs     : HANDLER = event handler name for WIDGET_ID 
               (blank string if undefined)

 Opt. Outputs: None

 Keywords    : GHOSTS = other widget ID's related to handler name

 CALLS: ***
	XALIVE, XMANAGER_COM
 CALLED BY:
	XGHOST, XMANAGER_RESET
 Common      : None

 Restrictions: WIDGET_ID should be a main base

 Side effects: None

 History     : Version 1,  22-Aug-1996,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_HEAP_INDEX $SSW/gen/idl/objects/get_heap_index.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_HEAP_INDEX

 Purpose     : Function to return the heap index of a pointer or object as a string.  If variable is not a
	pointer or object, returns an empty string.

 Category    : utility objects

 Explanation : Parses output of help,var,output=output to find heap index.  Will not work if RSI changes
	format of help output.

 Syntax      : IDL> index = get_heap_index(var)

 Examples    : if  get_heap_index(a) eq get_heap_index(b) then print,'a and b are the same object'

 Inputs      :		var - object or pointer to get heap index of

 Opt. Inputs : None

 Outputs     : string containing heap index, or empty string if not a heap variable.

 Opt. Outputs: None

 Keywords    : None

 Restrictions: Uses output of help,var so if RSI changes the format of the help output,
		this won't work.

 Side effects: None

 History     : Written 17 Aug 2000, Kim Tolbert

 Contact     : kim.tolbert@gsfc.nasa.gov


get_history $SSW/gen/idl/struct/get_history.pro
[Previous] [Next]
   Name: get_history

   Purpose: get HISTORY from structures or FITS header, optionally match patt

   Input Parameters:
      index - structure array or (less useful) FITS header
      pattern - optional string pattern to match

   Keyword Parameters:
      caller - if set than PATTERN=Calling Routine Name
      version - if set, extract VERSION number (per update_history)
      found (output)  - boolean if specified history/pattern found
  
   Calling Sequence:
      hist=get_history(index [,pattern], [/version] [/routine or routine=xx])

 CALLED BY:
	SSW_HOT_PIX, TRACE_PREP, TR_EXT_SUBIMG, ssw_unspike_cube, trace_make_tma
	trace_sub2point, trace_unspike_time, trace_wave2point
   History:
      3-November-1998 - S.L.Freeland - simplify common sequence
      1-December-1998 - S.L.Freeland - set missing VERSIONs to -1.0
      09-May-2003, William Thompson - Use ssw_strsplit instead of strsplit
  
   Calls: ***
	BOX_MESSAGE, GET_CALLER, data_chk [1], data_chk [2], gt_tagval [1], gt_tagval [2]
	ssw_strsplit, str2number [1], str2number [2], wc_where [1], wc_where [2]


get_host [1] $SSW/gen/idl/system/get_host.pro
[Previous] [Next]
  NAME:
      get_host

  PURPOSE:
      Find out the name of the ultrix system as defined in the system
      variable "hostname"

  INPUT PARAMETERS:
	short	- If set, then only return the node name, not the full
		  address (ie sxt2 instead of sxt2.space.lockheed.com)

  OUTPUT PARAMETERS:
	Returned value is the interpretted `hostname` value.

  PROCEEDURE:
	Spawn a child process and pipe the result back.

 CALLS: ***
	STR2ARR [1], STR2ARR [2]
 CALLED BY:
	ACOPY [1], ACOPY_TEST, CANCEL_PRELIM, LZPLOT, NET_DIR_DIFF, WRITE_IAP
	check_oldprocess [1], check_oldprocess [3], check_process [1]
	check_process [2], color_copy, dbase2disk, def_tapd [1], def_tapd [2]
	def_tapd [3], disk_hog [1], disk_hog [2], diskbench, flares2disk, ftp_copy [1]
	ftp_copy [2], get_tf_rec fname filnum recnum [1], getm1ans, go_batch [1]
	go_batch [2], html_doc, idl_server_command, idl_server_control, is_bestnode [1]
	is_bestnode [2], laser_init, list_tfi, make_mirror, mdifocus2, mk_cd [1], mk_cd [2]
	mk_mdi_iap, mk_rasm_files, mk_tfi, mk_vcr, mk_ydbtab, mk_ydbtape [1], mk_ydbtape [2]
	mo_check, mo_init [1], mo_init [2], mo_job0, mo_job1, mo_patch, momount, mostrip
	nimg_in_tfr fnam [1], pprint OBSOLETE  See SPRINTPRO [1], pprint [1]
	pr_status [1], pr_status [2], rdtfr, rsh, soon_search [1], soon_search [3]
	ssw_install [2], ssw_start_rpcserver, ssw_strfind, synop_link, tfr_decom, timeline
	topsdb [1], topsdb [2], tr_hsm_fix, video_menu, web_seq, wrttcplog
	wwwidl_server_check, wwwidl_watchdog [1], wwwidl_watchdog [2], xset_chain [1]
	xset_chain [2], xsw2tree, xsw2tree_event, xswlist [2], xsxt_prep, ycopy
	ydb_install [1], ydb_install [2], ydump
  HISTORY:
	Written, 30-sep-91, JRL
	12-Mar-92 (MDM) - Changed to work for VMS as well as  Unix.
	24-mar-92 (JRL) - Updated for IRIX operating system
	26-mar-92 (SLF) - Got it working for SUNs (again)
	30-mar-92 (SLF) - Put vms in the case where it belongs
	26-Jul-94 (MDM) - Added /SHORT keyword
        4-oct-94 (SLF) - spawn 'hostname' (avoid shell), protect agains .cshrc
                         minor change in 'short' generation
                         Noted that there are more modifications to this
			  program then lines of code...
	28-Mar-95 (MDM) - Modified 'irix' to use /usr/bsd/hostname with /noshell
			  to make it much faster
	20-Jun-00 (RDB) - reordered unix code; added windows case


GET_IJ $SSW/gen/idl/util/get_ij.pro
[Previous] [Next]
 Project     : SOHO - CDS     
                   
 Name        : GET_IJ()
               
 Purpose     : Determine (i,j) indices from a 1-d index of values   
               
 Explanation : 
               
 Use         : ij=get_ij(v,nx)
    
 Inputs      : v  = index to convert
               nx = first dimension of 2-d array from which v was derived
               
 Opt. Inputs : None
               
 Outputs     : ij = [i,j] ; i,j indices of v. 
               
 Opt. Outputs: None
               
 Keywords    : None

 Calls       : MOD
 CALLED BY:
	FUNCT_FIT, GET_MAP_REGION, GE_WINDOW_SIM, HESSI HSI_PILEUP CLASS
	HSI_DECIM_CORRECTION [1], HSI_DECIM_CORRECTION [2], HSI_MAP2GAUSSIANS
	Modify_Merge_list [1], Modify_Merge_list [2], NEAR_PIN_RESP [1]
	NEAR_PIN_RESP [2], PLOTMAP, POLY_SPEC, XSTRUCT, hsi_pmap2xy
 Common      : None
               
 Restrictions: None
               
 Side effects: None
               
 Category    : Util, numerical
               
 Prev. Hist. : None

 Written     : D M Zarro (ARC) Nov 1992  
               
 Modified    : 

 Version     : Version 1, Nov-92


GET_IM_KEYWORD $SSW/gen/idl/image/get_im_keyword.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : 
	GET_IM_KEYWORD
 Purpose     : 
	Gets the value of a SERTS keyword/flag.
 Explanation : 
	Gets the value of KEYWORD.  For use in SERTS image display routines.
	If IM_KEYWORD is not already set, then !IMAGE.Keyword is checked.

	If KEYWORD is already defined, then no action is taken.  Otherwise, if
	!IMAGE.Keyword.SET is set, then KEYWORD is set equal to the value of
	!IMAGE.Keyword.VALUE.

 Use         : 
	GET_IM_KEYWORD, Keyword, !IMAGE.Keyword
 Inputs      : 
	KEYWORD		= Keyword variable to be checked.
	IMAGE_KEYWORD	= Associated element in the !IMAGE structure variable.
 Opt. Inputs : 
	None.
 Outputs     : 
	KEYWORD		= If not already defined, and !IMAGE.Keyword.SET is
			  true, then this is output as the value of
			  !IMAGE.Keyword.VALUE.  Otherwise it retains its
			  current value.
 Opt. Outputs: 
	None.
 Keywords    : 
	None.
 Calls       : 
	None.
 CALLED BY:
	ADJUST, ASMOOTH, AVG_WO_CR, BLINK_IMAGES, BSCALE, CDS_CLEAN_IMAGE, COLOR_BAR
	CROSS_CORR2, EXPAND_TV, EXPTV, FORM_INT, FORM_VEL, GOOD_PIXELS, HISCAL, INTERP2
	LAPLACIAN, LOADCT, PROF, PUT, SCALE_TV, SIGRANGE [1], TVPROF, WCS_RECTIFY, WDISPLAY
 Common      : 
	None.
 Restrictions: 
	In general, the SERTS image display routines use several non-standard
	system variables.  These system variables are defined in the procedure
	IMAGELIB.  It is suggested that the command IMAGELIB be placed in the
	user's IDL_STARTUP file.

	Some routines also require the SERTS graphics devices software,
	generally found in a parallel directory at the site where this software
	was obtained.  Those routines have their own special system variables.

 Side effects: 
	None.
 Category    : 
	Utilities, Image_display.
 Prev. Hist. : 
	William Thompson, June 1991.
 Written     : 
	William Thompson, GSFC, June 1991.
 Modified    : 
	Version 1, William Thompson, GSFC, 13 May 1993.
		Incorporated into CDS library.
 Version     : 
	Version 1, 13 May 1993.


GET_INDX $SSW/gen/idl/util/get_indx.pro
[Previous] [Next]
 Name:
      GET_INDX
 Purpose:
      Compute set of N indexes for an N-dimensional array given 1-D indexes
 Category:
      Utility
 Calling sequence:
      index_set = GET_INDX(index_array,dimensions)
 Inputs:
      indx_array : 1-D indexes (vector, N elements)
      dimensions : dimensions of the array (array: [d1,d2,...,dn])
 Keyword parameters:
      None
 Output:
      Output : array of array indexes (dimensions: (n,N))
 Common blocks:
      None
 Calls:
	Description:
	From a 1-D set of array indexes (as obtained from functions like
	N) array., None, WHERE etc.) pointing to elements of an n-dimensional array
	an array, input 1-D set
	of n-D indexes is extracted. If N indexes are specified by the
	the output will be a (n
 Side effects:
      None
 Restrictions:
      None
 Modification history:
      V. Andretta, 19/Jun/1998 - Written (Modified from an earlier version)
      V. Andretta,  9/Oct/1999 - Fixed problem with scalar input.
      V. Andretta, 29/Oct/1999 - Changed response to invalid input.
 Contact:
      andretta@na.astro.it


get_infox $SSW/gen/idl/genutil/get_infox.pro
[Previous] [Next]
   Name: get_infox

   Purpose: convert IDL structure info to string summary (1 line/structure)

   Input Parameters:
      index - index structure
      itags - desired list of TAGS to include 
              (string array or comma delimited string)

   Keyword Parameters:
      format -  optional format list as string array or comma delimited string
      delim  -  optional inter-field delimter (default = two blanks)
      /gt_xxx - optional gt_functions to call and include in output
      /display - print results to terminal
      /more    - same as /display with more-like behavior
      /number -  switch, if set, prepend the index subscript to each string
      header - (output) - aligned header string 
      fmt_time  - if switch set and structure contains STANDARD time keywords
      fmt_time  - if STRING, specify desired string format for TIME/DAY
                  (see OUT_STYLE options for anytim.pro)
      day_only  - if set, only return DAY portion of DATE
      time_only - if set, only return TIME portion of DATE
	titles	- The array of column headings for the listing.  Default is
		  the tag names.
	keylab	- If set, then put the column labels with the data

   Calling Sequence:
      outstring=get_infox(structure, 'tag1,tag2,...tagn' , 		$
				       header=header ,  		$
				       /fmt_time, /gt_xxx, /gt_yyy, 	$
                                      /number,				$
				       /display, /more ]
   Calling Examples:
   IDL> info=get_infox(!version, 'OS_FAMILY,RELEASE,ARCH,OS',/more)
    OS_FAM  RELEASE   ARCH   OS
      unix   4.0.1a  alpha  OSF

   In the following, eitstr is a 3 element vector of type eit_struct()
   IDL> more, get_infox(eitstr,'WAVELNTH,FILTER',fmt_tim='ecs',format='a,a')
        1997/03/14 00:11:50.000       304   Clear
        1997/03/14 00:34:49.000       304   Clear
        1997/03/14 00:50:10.000       304   Clear

   IDL> more,get_infox(eitstr,'WAVELNTH,NAXIS1',fmt_tim='ccsds',format='a,a')
        1997-03-14T00:11:50.000Z       304       512
        1997-03-14T00:34:49.000Z       304       512
        1997-03-14T00:50:10.000Z       304       512

 CALLED BY:
	eit_genx_cat, get_eit_info, get_spartan_info [1], get_spartan_info [2]
	img_sumtr2, lasteit, lcur_image, mreadfits_sxig12, show_pix [1], show_pix [2]
	spartan_pb2fits, ssw_build_trace, ssw_findstuff2html, ssw_fov_context
	ssw_start_rpcserver, tr_tab_head, trace_cat2cosmic, trace_make_tsma
	trace_make_vignette, trace_movie_index [1], trace_movie_index [2]
	trace_uniq_movies, write_trace
   History:
      22-March-1996 (S.L.Freeland) - generalize the 'get_info' problem
       3-April-1996 (S.L.Freeland) - added NUMBER keyword & function
      18-march-1997 (S.L.Freeland) - add DAY_ONLY,TIME_ONLY keyword & function
                                     (passed to ANYTIM), add MSECS (def=NO)
      19-Feb-1998   (S.L.Freeland) - merge MDM suggestions
                                   - enhance auto-formating logic  
	19-Feb-1998 (M.D.Morrison)	- Added "titles" input
	24-Feb-1998 (M.D.Morrison)	- Added KEYLAB option
	10-Mar-1998 (M.D.Morrison)	- Changed "string(outtag" to "fstring(outtag"
					  to avoid the "% STRING: Explicitly formated output truncated 
					  at limit of 1024 lines." error
       22-Nov-1999 (S.L.Freeland) - expand auto-fmts a little
      09-May-2003, William Thompson - Use ssw_strsplit instead of strsplit

   Method:
      calls gt_tagval  (to extract the data)
            strjustify (to align columns)
            gt_xxx     (optionally called)
            anytim     (if FMT_TIM, TIME, or DAY switches are set)

 CALLS: ***
	FSTRING, STR2ARR [1], STR2ARR [2], anytim [1], anytim [2], anytim [3], anytim [4]
	anytim [5], data_chk [1], data_chk [2], gt_tagval [1], gt_tagval [2], prstr [1]
	prstr [2], ssw_strsplit, strjustify
   Restrictions:
      if FORMAT is supplied, n_elements(FORMAT) must EQ n_elements(FIELDS)
      if FMT_TIME is supplied, structure must contain SSW standard TIME tags

   TODO - (allow FITs header or FITS file list?? recursive call after str convert??)


get_ionbal [1] $SSW/gen/idl/spectra/get_ionbal.pro
[Previous] [Next]
  NAME:
    get_ionbal
  PURPOSE:
    Return interpolated ionization fractions.
  CALLING SEQUENCE:
    ion_abun = get_ionbal(Z,Te6)
    ion_abun = get_ionbal(Z,Te6,stages,ioncal=ioncal)
    ion_abun = get_ionbal(Z,Te6,Nel=Nel,Elem=Elem,		$
			   stages=stages1,ion_data=ion_data)
  INPUTS:
    Z		= Atomic Number (e.g., 16 for S, 20 for Ca, 26 for Fe)
    Te6	= Vector of electron temperatures in units of 1.e6 K
  OPTIONAL INPUTS:
    Stages	= Vector of ionization stages.  (XVIII = 18, etc.)
  OPTIONAL INPUT KEYWORDS:
    Nel	= Number of electrons.  Can be used instead of Stages.
                 For example, Nel=1 is H-like, Nel=He-like, etc.
    ioncal	= Ionization calculation to use (default is ioncal=0)
  OUTPUTS:
    The functional result is a 2-d array containing the fractional ion 
    abundances:
           ion_abun = fltarr(N_elements(Te6),N_elements(Stages))
  OPTIONAL OUTPUT KEYWORDS:
    Element	= The element (which is obtained from the last word in Head)
    Stages	= The ion stages returned
    Ion_data	= Data structure contain data read from the ascii data
			file with the routine rd_ionbal
  METHOD:
    Reads ascii data files contained in $DIR_GEN_SPECTRA
    The files have the following names: subal1.dat, cabal1.dat, febal1.dat

 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], concat_dir [4], iionbal [1]
	iionbal [2], rd_ionbal [1], rd_ionbal [2]
 CALLED BY:
	bcs_line
  MODIFICATION HISTORY:
     7-oct-93, J. R. Lemen (LPARL), Written


GET_JULDATE $SSW/gen/idl_libs/astron/astro/get_juldate.pro
[Previous] [Next]
 NAME:
    GET_JULDATE
 PURPOSE:
     Return the current Julian Date

 EXPLANATION:
     In V5.4, GET_JULDATE became completely obsolete with the introduction
     of the /UTC keyword to SYSTIME().   So GET_JULDATE,jd is equivalent to
     jd = SYSTIME(/JULIAN,/UTC).

 CALLING SEQUENCE:
       GET_JULDATE,jd

 INPUTS:
       None

 OUTPUTS:
       jd = Current Julian Date, double precision scalar

 EXAMPLE:
       Return the current hour, day, month and year as integers

       IDL> GET_JULDATE, JD                  ;Get current Julian date
       IDL> DAYCNV, JD, YR, MON, DAY, HOURS  ;Convert to hour,day month & year

 METHOD:
       A call is made to SYSTIME(/JULIAN,/UTC).

 REVISION HISTORY:
       Written Wayne Landsman                March, 1991
       Converted to IDL V5.0   W. Landsman   September 1997
       Assume since V5.4 Use /UTC keyword to SYSTIME()  W. Landsman April 2006


get_kbrd [1] $SSW/gen/idl/system/get_kbrd2.pro
[Previous] [Next]
   Name: get_kbrd

   Purpose: same as IDL get_kbrd unless SGI ( mabey future additions)
	     SGI appears to solicit bogus 255 from Xclients

 CALLS:


GET_KEYWORD $SSW/gen/idl/string/get_keyword.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_KEYWORD

 Purpose     : Extract values in a string array that appear after
               keyword construct such as: KEYWORD=VALUE
               (e.g. extract all time values following STARTIME=time_value)

 Category    : Utility

 Syntax      : IDL> values=get_keyword(array)

 Inputs      : ARRAY = array to search
               KEY   = keyword name to extract

 Outputs     : VALUES = keyword values
               INDEX  = index location of keyword

 Keywords    : CASE = set to make search case sensitive

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], TRIM
 CALLED BY:
	FIX_IAP
 History     : Version 1,  25-May-1997,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_LATLON $SSW/gen/idl/solar/get_latlon.pro
[Previous] [Next]
NAME:
     GET_LATLON
PURPOSE:
     Compute latitude and longitude for a data array given the coordinates
     of the center of the array.
CATEGORY:
CALLING SEQUENCE:
     latlon = get_latlon(mag,point=point,date=date)
INPUTS:
OPTIONAL INPUT PARAMETERS:
     mag = magnetic field structure containing at least the B_LONG (used to
           derive the dimension of the array: not required if the nx and ny
           keywords are set) and POINT fields (see below).  B_LONG is
           used to derive the dimension of the array and is not required if 
           the nx and ny keywords are set.  The size and pointing can be
     specified with keywords, in which case mag is not required.
KEYWORD INPUT PARAMETERS
     point = pointing structure: 
                lat(radians) = latitude of center of array, 
                cmd(radians) = cmd of center of array, 
                b0(radians) = solar B0 angle,               
                p(radians) = solar P angle, 
                pix_size(arcseconds) = size of the pixels, 
                                       single number = x & y size
                                       2-element vector = [xsize,ysize]
                radius(arcseconds) = solar radius.

 CALLED BY:
	BFITS, IDEPROJECT, MK_MDI_MAP_EARTH, MK_SOHO_MAP_EARTH, PLOT_HSI, PLOT_HXT
	TRACE_CUBE_POINTING, TRACE_MDI_ALIGN
     Note: The center of the array is defined to be (nx-1)/2.0 and 
     (ny-1)/2.0 in pixel coordinates.

     The pointing parameters can alternatively be specifield seperately 
     with the following keywords:

     lat    = latitude of center of FOV in radians
     cmd    = CMD of center of FOV in radians

     Alternatively, you can specify the pixel coordinates of the center of the
     FOV rather than the lat/lon of the center of the FOV:

     x0,y0 = coordinates of the center of the FOV relative to the center
             of the solar disk in PIXEL units.

     b0     = solar B0 angle in radians
     pangle = solar P angle in radians
     pixsize= Pixel size in arc seconds
     radius = solar radius in arc seconds.  Not required if date is set or if
              radius is set in the point structure.

     date = date of data, e.g. '19-Aug-92 19:00'.  
            Required to compute solar radius if the radius is not set in 
            the radius keyword or in the point structure.
     nx = x size of data array.  Required if no data is passed.
     ny = y size of data array.  Required if no data is passed.
KEYWORD PARAMETERS
     /solar = x,y in array is relative to solar coordinates (so the p-angle
              should be forced to zero).  Default is to assume that
              x,y are relative to terrestrial coordinates.
     /add = Add the latitude and longitude arrays to the magnetic field
            structure (mag).
     /quiet = work quietly.
OUTPUTS:
     latlon = structure with two field: latitude and cmd (arrays, same size
              as the input array) giving the latitude and central meridian
              distance in DEGREES.
 CALLS: ***
	LONLAT2XY, add2str [1], add2str [2], anytim2ints [1], anytim2ints [2]
	get_rb0p [1], get_rb0p [2], tag_index [1], tag_index [2]
COMMON BLOCKS:
SIDE EFFECTS:
EXAMPLES:

     j is a magnetic field structure

     ll = get_latlon(j)
     ll = get_latlon(point=j.point,nx=60,ny=45)

RESTRICTIONS:
     o Projects points off the limb back to the limb.
     o Assumes pixels are uniformly spaced.
     o Assumes the pixel grid is aligned so that the y axis is to the north
       and the x axis is to the west (terrestrial or solar depending on the
       state of the "solar" keyword).  This could be corrected by adjusting
       the p angle as necessary.
PROCEDURE:
     Straightforward spherical trig.
MODIFICATION HISTORY:
     T. Metcalf 25-Apr-1994
     1996-02-15  Allow pixel size to be a 2-element vector.
     1996-09-04  Changed "keyword_set" to "n_elements() EQ 1" for the 
                 various keywords so that they can be equal to 0.
     1996-10-11  Added the x0 and y0 keywords.
     1996-10-15  Fixed minor bug with undefined qdull_disk when x0,y0 not
                 set.
     20-feb-1997 S.L.Freeland - use <get_rb0p> instead of "old" pb0r
     17-oct-2001 T. metcalf Use double precision.
     18-Oct-2001 T. Metcalf Use atan to find longitude
     11-Mar-2005 T. Metcalf Use lonlat2xy to get xy when a mag structure
                            is passed in.  Not a very significant change.


GET_LEAP_SEC $SSW/gen/idl/time/get_leap_sec.pro
[Previous] [Next]
 Project     : HINODE/EIS

 Name        : GET_LEAP_SEC

 Purpose     : Returns the Modified Julian Day number of all known
               leap seconds.  

 Inputs      : None

 Outputs     : MJD = An array containing the Modified Julian Day
                     numbers for all dates on which a leap second 
                     was inserted, starting with 31 December 1971.

 Keywords    : ERRMSG = string error message

 Version     : Written 15-Nov-2006, Zarro (ADNET/GSFC)
               - based on original GET_LEAP_SEC by Bill Thompson.

 Contact     : dzarro@solar.stanford.edu
 CALLS:
 CALLED BY
	CHECK_INT_TIME, HSI_ANY2SCTIME, HSI_SCTIME2ANY, TAI2UTC, UTC2TAI


GET_LEAP_SEC2 $SSW/gen/idl/time/get_leap_sec2.pro
[Previous] [Next]
 Project     : HINODE/EIS

 Name        : GET_LEAP_SEC2

 Purpose     : Returns the Modified Julian Day number of all known
               leap seconds.  

 Inputs      : None

 Outputs     : MJD = An array containing the Modified Julian Day
                     numbers for all dates on which a leap second 
                     was inserted, starting with 31 December 1971.

 Keywords    : ERRMSG = string error message

 Version     : Written 15-Nov-2006, Zarro (ADNET/GSFC)
               - based on original GET_LEAP_SEC by Bill Thompson.

 Contact     : dzarro@solar.stanford.edu
 CALLS:


GET_LIB $SSW/gen/idl/help/get_lib.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : 
	GET_LIB()
 Purpose     : 
	Place elements of !PATH into a string array..
 Explanation : 
	Place library and directory elements of !PATH into a string array.
	Used by SCANPATH.
 Use         : 
	Result = GET_LIB()
	Result = GET_LIB( PATH )
 Inputs      : 
	None required.
 Opt. Inputs : 
       PATH = Path name (default is !path).
 Outputs     : 
	Function result is a string array of path elements.
 Opt. Outputs: 
	None.
 Keywords    : 
	NO_CURRENT - don't include current directory
 Calls       : ***
	GETTOK [1], GETTOK [2], GETTOK [3], GETTOK [4], OS_FAMILY, TRIM, curdir [1]
	curdir [2]
 CALLED BY:
	CHECK_DUP, CHKARG, CLEAN_PATH, FINDFILE_LIST, LIST_PATH, SCANPATH, ST_SUMER, XACK
	gextal, rdbda_smm
 Common      : 
	None.
 Restrictions: 
	None.
 Side effects: 
	None.
 Category    : 
	Documentation, Online_help.
 Prev. Hist. : 
       Written DMZ (ARC) April 1991
	William Thompson, Dec 1991, modified to be compatible with UNIX, and
				    with VMS logical names.  Also, to be
				    compatible with changes in SCANPATH
 Written     : 
	D. Zarro, GSFC/SDAC, April 1991.
 Modified    : 
	Version 1, William Thompson, GSFC, 23 April 1993.
		Incorporated into CDS library.
	Version 2, William Thompson, GSFC, 7 May 1993.
		Added IDL for Windows compatibility.
	Version 3, William Thompson, GSFC, 24 September 1993.
		Changed EXPAND_PATH to PATH_EXPAND.
       Version 3.1, Dominic Zarro, GSFC, 1 August 1994.
               Added check for current directory in path.
	Version 4, 23-Oct-1997, William Thompson, GSFC
		Use OS_FAMILY() instead of !VERSION.OS
 Version     : 
	Version 4, 23-Oct-1997


get_logenv [1] $SSW/gen/idl/system/get_logenv.pro
[Previous] [Next]
   Name: get_logenv

   Purpose: provide system independent front end to get_env and trn_log

   Input Parameters:
      logenvs - string or string array of vms logicals or unix environments
		 (may contain wild cards)
      
   Output Parameters:
	function returns equivilence string/string array

   Optional Keyword Parameters:
      outenv - actual environmentals (output) - may differ from logenvs
		if wild cards were used (null if associated env not defined)

   Calling Sequence:
      envs=get_logenv(logenvs [,count=count, outenv=outenv, 

   Calling Examples:
      sfddirs=get_logenv('DIR_SFD*')		  ; sfd directories
      gendirs=get_logenv('dir_gen*',/case_ignor) ; all DIR_GENxxxxx
      home   =get_logenv(/home)		  ; home directory
      curdir =get_logenv(/curdirq)		  ; current [same as curdir()]
      ysenvs =get_logenv('ys_*',/environ)	  ; environmentals form ys_...
      ysflags=get_logenv('ys_*')		  ; same, only translated value

   Optional Keyword Parameters
	count  (output) - number of non-null elements returned
 	status (output) - boolean success vector (1:match, 0:nomatch)
       outenv (output) - string array - actual environmentals found
	environ(input)  - switch - return logical/environ, not translation
			  (could be useful if logenvs contains wild card)
	home   (input)  - switch, if set, return home directory translation
       curdir (input)  - if set, return current directory
	case_ignore (input) if set, case INsensitive (only functional in unix)
     
 CALLED BY:
	ANAL_BCS_PHA, ANAL_STIMS, ANDRIL_SXT, AUTOCAL, CHECK_DIST, DSK_LOCG, EIT_CATRD [1]
	EIT_MKMOVIE, EIT_PREP, FIRST_LIGHT [1], FIRST_LIGHT [2], FLAGOOL, HESSI
	HSI_ASPECT_MODEL, HSI_CHK_DUPLICATE, Hsi_contact2fits [1]
	Hsi_contact2fits [2], JSMOVIE, QUICKDARK [2], SPEX_COMMONS [2], SPEX_COMMONS [4]
	SPEX_PROC [1], SPEX_PROC [2], STEPPER [3], STEPPER [4], STEPPER2_s1 [1]
	STEPPER2_s1 [2], UPDATE_LINE_TEMPLATES, ace_files, bcs_path, cdrom_files [2]
	check_log [1], check_log [2], chk_batse_env [1], chk_batse_env [2]
	configure_http, daily_forecast [2], data_compress [1], data_compress [2]
	data_compress [3], dbase2disk, disk_hog [1], disk_hog [2], disk_monitor [1]
	disk_monitor [2], drm_4_spex [1], drm_4_spex [2], eit_file2path, eit_files
	eit_fulldiskdb, eit_genx_cat, eit_mirror, eit_proton_summary, event_movie [1]
	extract_val, file_path [1], file_path [2], file_purge_sizes, files_since [1]
	files_since [2], fitstap2tap [1], fitstap2tap [2], fl_goesplot [1]
	fl_goesplot [2], fl_goesplot [3], fl_mktext, fl_suntoday [1], fl_suntoday [2]
	fl_suntoday [3], fl_sxtobsnar [1], fl_sxtobsnar [2], ftp_copy [1], ftp_copy [2]
	ftp_copy2sites, ftp_defprompt, genx2html [1], genx2html [2], get_daily [1]
	get_daily [2], get_epoch_sfcs [1], get_epoch_sfcs [2], get_mk3 [1], get_mk3 [2]
	get_selsis, get_sirius [1], get_sirius [2], get_solar_indices
	go_lasdisk golaserdisk, go_lasdisk2 golaserdisk, go_yo_prod_batch
	goes3sec_copy, goes_plot [1], goes_plot [2], goes_plot [3], goes_plot [4]
	goes_plot [5], hardcopy [1], hardcopy [2], hessi_version, hsi_1orbit_allpak
	hsi_clk_delta_calc, hsi_mult_filedb_inp filedb_dir  filedb_dir
	hsi_params_write_pro, html_basics, html_doc, http_names, image2movie
	is_bestnode [1], is_bestnode [2], lapalma_cat, lapalma_files, leak_sub [1]
	leak_sub [2], leak_sub [3], les_archive_info, mail [1], mail [2], make_ssw_mirror
	map_env2dir, mdi_cat, mdi_files, mdi_write_genxcat, mk_gsn_obs, mk_lasteit_movie
	mk_pix [1], mk_pix [2], mk_pubydb, mk_sdcs, mk_sfc [1], mk_sfc [2], mk_ssc [1]
	mk_ssc [2], mk_ssc_batch [1], mk_ssc_batch [2], mk_sxh, mk_syn_sfc [1]
	mk_syn_sfc [2], mk_synsfc_coeff [1], mk_synsfc_coeff [2], mk_ydb_list, mk_ydbtab
	mk_ydbtape [1], mk_ydbtape [2], mo_filelist, mo_patch, monitor_scratch [1]
	monitor_scratch [2], mreadfits_sxig12, msok_copy_jpg, msok_poi_copy [1]
	msok_poi_copy [2], multi_hda2hxi, newsfd, nobeyama_update
	ospex_params_write_pro, pprint OBSOLETE  See SPRINTPRO [1], pprint [1]
	pr_logenv, pref_super, rapp_get_spectrogram, rd_fdss, rd_goesp_ascii
	rd_goesx_ascii, rd_sxg, rd_ydbtap, read_genxcat, read_lapalma, read_msok_jpg
	rep_logenv, restenv [1], restenv [2], save_idl_routines, saveenv [1], saveenv [2]
	search_obs, secchi_time2files, selsis_copy [1], selsis_copy [2], set_logwindows
	setssw_windows, setup_spex [1], setup_spex [2], sfc_check, sft2sfc, show_contacts
	show_pix [1], show_pix [2], show_pix_event [1], show_pix_event [2]
	show_pix_event [3], show_pixf, soon_search_www, sooncat_cadence
	spex_preview [1], spex_preview [2], ssc_files [1], ssc_files [2], ssc_files [3]
	ssw_addmm_gen, ssw_bin, ssw_check_contrib, ssw_colors, ssw_conflicts
	ssw_contrib_monitor, ssw_ct2rgb, ssw_findstuff2html, ssw_fov_context
	ssw_getapplet, ssw_install [1], ssw_install [2], ssw_instr_info, ssw_instruments
	ssw_packages, ssw_path, ssw_required_path, ssw_set_chianti, ssw_set_instr
	ssw_setsswdb_gen, ssw_setup_windows, ssw_start_rpcserver, ssw_upgrade [1]
	ssw_upgrade [2], ssw_upgrade_backup, sswdb_info, sswdb_install, sswdb_upgrade
	sswloc, struct_where, sun_today [1], sun_today [2], sun_today [3], sxt2file
	sxt2mpeg, sxt_cen [1], sxt_cen [2], sxt_deleak [1], sxt_deleak [2], sxt_files
	sxt_html, sxt_patch_att, sxt_prep [1], sxt_prep [2], sxt_prep [3], sxt_ssc2sss
	sxt_uvf_info [1], sxt_uvf_info [3], sxt_where, term_times, tim2dbase, tim2tfss
	trace_cat, trace_decode_idl PLEASE USE trace_jpeg_decomp
	trace_do_data_requests, trace_dph2struct [1], trace_file2path, trace_files
	trace_get1www_image, trace_jpeg_decomp, trace_last_movie [1]
	trace_last_movie [2], trace_last_movie [3], trace_last_movie_queue
	trace_make_tma, trace_make_tmr [1], trace_make_tmr [2], trace_movie_context
	trace_movie_index [1], trace_movie_index [2], trace_movies_prioritize [1]
	trace_movies_prioritize [2], trace_special_movie [1]
	trace_special_movie [2], trace_special_movie [3], trace_special_movie2
	trace_submit_request, trace_success_file, trace_where, trace_write_genxcat
	ucon_path, url_decode, write_trace, wwwidl_watchdog [1], wwwidl_watchdog [2]
	xcheckip, xso_search, ycopy, ydb_install [1], ydb_install [2], ydb_pre2dir [1]
	ydb_pre2dir [2], ydump, yo_index2path, yo_mkos1_dbase, yo_xda2legacy, yohkoh_files
	yohkoh_legacy_files [1], yohkoh_legacy_files [2]
   History:
      slf - 5-apr-1993
      SLF - 13-Jan-1993 (use /noshell on printenv for speed)
      SLF - 16-Jan-1993 (work around for multiple line envs)
      SLF - 30-Mar-1994 fix VMS bug
      DMZ - 20-May-1994 added check for '$' in first character
      SLF - 21-May-1994 added a semicolon to comment (4 man-months effort)
      SLF -  2-Jun-1994 fix (define allenv if wild cards used)
      JSN - 03-Jun-1998 changed loops to long integer

 CALLS: ***
	wc_where [1], wc_where [2]
   Restrictions:
      if logenvs is an array with one or more elements containg a wild
      card AND more than one env/log satisfies the wildcard, then only
      one match is returned (maintains 1 to 1 correspond between 
      input <logenvs> and <output>  
      Does not yet handle multiple line environmentals (1st line returned)


GET_MAP_DRANGE $SSW/gen/idl/mapping/get_map_drange.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_DRANGE

 Purpose     : extract min/max data of map

 Category    : imaging

 Syntax      : drange=get_map_drange(map)

 Inputs      : MAP = image map

 Opt. Inputs : None

 Outputs     : DRANGE = [dmin,dmax]

 Opt. Outputs: None

 Keywords    : ERR = error string
               XRANGE/YRANGE = coordinate ranges within to compute DRANGE

 CALLS: ***
	GET_MAP_SUB, VALID_MAP
 CALLED BY:
	PATCH_MAP, PLOT_MAP
 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_FOV $SSW/gen/idl/mapping/get_map_fov.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_FOV

 Purpose     : compute map FOV 

 Category    : imaging

 Explanation : 

 Syntax      : fov=get_map_fov(map)

 CALLED BY:
	PLOT_MAP, PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support
 Examples    :

 Inputs      : MAP = image map

 Opt. Inputs : None

 Outputs     : FOV = [fovx,fovy] = arcsec fov in X and Y directions

 Opt. Outputs: None

 Keywords    : ERR = error string
               ARCMIN = return in arcmin units
               ROUND = round to nearest integer

 CALLS: ***
	GET_MAP_PROP, NINT [1], NINT [2], PR_SYNTAX, VALID_MAP
 Common      : None

 Restrictions: None

 Side effects: None

 History     : Written 26 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_PROP $SSW/gen/idl/mapping/get_map_prop.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_PROP

 Purpose     : extract map properties

 Category    : imaging

 Syntax      : prop=get_map_prop(map,/prop_name)

 Inputs      : MAP = image map

 Opt. Inputs : PROP = prop name can optionally be entered as argument

 Outputs     : PROP = extracted property
               (e.g. xc=get_map_prop(map,/xc) to extract map center

 Keywords    : ERR = error string
               FOUND = 1/0 if found/not found
               INDEX = index location of property
               DEF = def property value to return

 CALLS: ***
	EXIST, GET_MAP_CENTER, GET_MAP_SPACE [1], GET_MAP_SPACE [2], GET_MAP_XP
	GET_MAP_XRANGE, GET_MAP_YP, GET_MAP_YRANGE, GREP, PR_SYNTAX, TAG_EXIST [1]
	TAG_EXIST [2], TRIM, VALID_MAP, data_chk [1], data_chk [2]
 CALLED BY:
	BREAK_MAP, DROT_MAP, DROT_MAP_FAST, DROT_RASTER, FLIP_MAP, GET_MAP_FOV, ITOOL2MAP
	MAP2L1, MK_OLD_MAP, PLOT_MAP
	PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support, REDUCE_MAP
	REP_PROP, ROT_MAP, SHIFT_MAP, SUB_MAP, UNPACK_MAP
 History     : Written 16 April 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_REGION $SSW/gen/idl/mapping/get_map_region.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_REGION

 Purpose     : compute pixel indicies of region [xmin,xmax,ymin,ymax]

 Category    : imaging

 Explanation : 

 Syntax      : indicies=get_map_region(xp,yp,region)

 CALLED BY:
	MAKE_MAP
 Examples    :

 Inputs      : XP,YP = 2-d X- and Y- coordinate arrays
               REGION = coordinate region to window = [xmin,max,ymin,ymax]

 Opt. Inputs : None

 Outputs     : [imin,imax,jmin,jmax] = x and y indicies or region, as in,
               (imin:imax,jmin:jmax)

 Opt. Outputs: None

 Keywords    : ERR = error string
               COUNT = # of points in subregion

 CALLS: ***
	DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4], EXIST, GET_IJ, PR_SYNTAX
	delvarx [5]
 Common      : None

 Restrictions: None

 Side effects: None

 History     : Written 20 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_SPACE [1] $SSW/gen/idl/mapping/get_map_center.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_SPACE

 Purpose     : extract xc,yc center from map

 Category    : imaging

 Explanation : 

 Syntax      : center=get_map_center(map)

 CALLED BY:
	GET_MAP_PROP
 Examples    :

 Inputs      : MAP = image map

 Opt. Inputs : None

 Outputs     : CENTER = [xc,yc]

 Opt. Outputs: None

 Keywords    : ERR = error string

 CALLS: ***
	BOOST_ARRAY [1], BOOST_ARRAY [2], BOOST_ARRAY [3], GET_ARR_CENTER
	GET_MAP_CENTER, VALID_MAP
 Common      : None

 Restrictions: None

 Side effects: None

 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_SPACE [2] $SSW/gen/idl/mapping/get_map_space.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_SPACE

 Purpose     : extract dx,dy spacings from map

 Category    : imaging

 Syntax      : space=get_map_space(map)

 Inputs      : MAP = image map

 Outputs     : SPACE = [dx,dy]

 Keywords    : ERR = error string

 CALLS: ***
	BOOST_ARRAY [1], BOOST_ARRAY [2], BOOST_ARRAY [3], GET_ARR_CENTER, VALID_MAP
 CALLED BY:
	GET_MAP_PROP
 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_SUB $SSW/gen/idl/mapping/get_map_sub.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_SUB

 Purpose     : extract sub-field from a map

 Category    : imaging

 Explanation : 

 Syntax      : sub=get_map_sub(map,xrange=xrange,yrange=yrange)

 Inputs      : MAP = image map

 Outputs     : SUB = extracted 2d-sub-field array

 Keywords    : XRANGE  = x-coord range to extract (e.g. [100,200])
               YRANGE  = y-coord range to extract (e.g. [300,400])
               ARANGE  = actual coordinates ranges [xstart,xend,ystart,yend]
               IRANGE  = indicies of extracted coords [istart,iend,jstart,jend]
               COUNT   = # of points extracted
               VERBOSE = echo messages
               ERR     = error string ('' if all ok)
               TAG_ID  = tag to extract (def = .data)
               XP,YP   = optional coordinate arrays to base extraction on
                        (if other than what is in MAP)
               NO_OVERLAP = don't include overlapping pixel outside xrange/yrange

 CALLS: ***
	EXIST, GET_MAP_XP, GET_MAP_XRANGE, GET_MAP_YP, GET_MAP_YRANGE, GET_TAG_INDEX
	PR_SYNTAX, VALID_MAP, data_chk [1], data_chk [2]
 CALLED BY:
	GET_MAP_DRANGE, PLOT_MAP
	PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support, SUB_MAP
 History     : Written 16 Feb 1999, D. Zarro, SM&A/GSFC
               Modified 18 Feb 2000, Zarro (SM&A/GSFC) - added /NO_OVERLAP

 Contact     : dzarro@solar.stanford.edu


GET_MAP_TIME $SSW/gen/idl/mapping/get_map_time.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_TIME

 Purpose     : extract map time

 Category    : imaging

 Syntax      : time=get_map_time(map)

 Inputs      : MAP = image map

 Outputs     : TIME = map time in UTC units

 Keywords    : ERR = error string
               TAI = set for TAI format
               ORIGINAL = set to always return original time (not rotated)

 CALLS: ***
	ANYTIM2TAI, ANYTIM2UTC [1], ANYTIM2UTC [2], PR_SYNTAX, TAG_EXIST [1]
	TAG_EXIST [2], VALID_MAP
 CALLED BY:
	DIFF_MAP, DROT_MAP, DROT_MAP_FAST, GET_DROT_DUR, MEAN_MAP, MOVIE_MAP, PLOT_MAP
	PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support
	REM_MAP_LIMB
 History     : Written 16 Aug 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_XP $SSW/gen/idl/mapping/get_map_xp.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_XP

 Purpose     : extract X-coordinate arrays of map

 Category    : imaging

 Syntax      : xp=get_map_xp(map)

 Inputs      : MAP = image map

 Opt. Inputs : None

 Outputs     : XP = 2d X-coordinate array

 Opt. Outputs: None

 Keywords    : ERR = error string
               DX  = X-pixel spacing
               XC  = X-pixel center coordinate
               ONED = extract coordinate as 1-D

 CALLS: ***
	MK_MAP_XP, VALID_MAP
 CALLED BY:
	DROT_COORD, DROT_MAP, DROT_RASTER, GET_MAP_PROP, GET_MAP_SUB, GRID_MAP, INTER_MAP
	PLOT_MAP, REM_MAP_LIMB, ROT_MAP, UNPACK_MAP
 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_XRANGE $SSW/gen/idl/mapping/get_map_xrange.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_XRANGE

 Purpose     : extract min/max X-coordinate of map

 Category    : imaging

 Syntax      : xrange=get_map_xrange(map)

 Inputs      : MAP = image map

 Opt. Inputs : None

 Outputs     : XRANGE = [xmin,xmax]

 Keywords    : ERR = error string

 CALLS: ***
	VALID_MAP
 CALLED BY:
	DROT_RASTER, GET_MAP_PROP, GET_MAP_SUB, PATCH_MAP, PLOT_MAP
 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_YP $SSW/gen/idl/mapping/get_map_yp.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_YP

 Purpose     : extract Y-coordinate arrays of map

 Category    : imaging

 Syntax      : yp=get_map_yp(map)

 Inputs      : MAP = image map

 Outputs     : YP = 2d X-coordinate array

 Keywords    : ERR = error string
               DY  = y-pixel spacing
               YC  = y-pixel center coordinate
               ONED = extract as 1-d

 CALLS: ***
	MK_MAP_YP, VALID_MAP
 CALLED BY:
	DROT_COORD, DROT_MAP, DROT_RASTER, GET_MAP_PROP, GET_MAP_SUB, GRID_MAP, INTER_MAP
	PLOT_MAP, REM_MAP_LIMB, ROT_MAP
 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAP_YRANGE $SSW/gen/idl/mapping/get_map_yrange.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_MAP_YRANGE

 Purpose     : extract min/max Y-coordinate of map

 Category    : imaging

 Syntax      : yrange=get_map_yrange(map)

 Inputs      : MAP = image map

 Opt. Inputs : None

 Outputs     : YRANGE = [ymin,ymax]

 Opt. Outputs: None

 Keywords    : ERR = error string

 CALLS: ***
	VALID_MAP
 CALLED BY:
	DROT_RASTER, GET_MAP_PROP, GET_MAP_SUB, PATCH_MAP, PLOT_MAP
 History     : Written 16 Feb 1998, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MAX_TAG $SSW/gen/idl/struct/get_max_tag.pro
[Previous] [Next]
 Project     :	SOHO - CDS

 Name        :	GET_MAX_TAG

 Purpose     :	find max dimension of a tag in a structure

 Use         : MAX=GET_MAX_TAG(STRUCT)

 Inputs      :	STRUCT = input structure

 Opt. Inputs :	None.

 Outputs     :	MAX = max dimension of tags

 Opt. Outputs:	None.

 Keywords    :	NEST = check nested structure dimensions only

 Category    :	Structure handling

 CALLS: ***
	is_struct
 CALLED BY:
	CONCAT_STRUCT
 History     :	22 May 1995, Zarro (ARC) - written
               22 April 2006, Zarro (L-3Com/GSFC) - modified to use
                                                    IS_STRUCT
 Contact     :	dzarro@solar.stanford.edu


GET_METHODS $SSW/gen/idl/objects/get_methods.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_METHODS

 Purpose     : return all methods of a class or object

 Category    : utility objects

 Explanation : checks output of help,/rout for CLASS::METHOD

 Syntax      : IDL> methods=get_methods(class)

 Inputs      : CLASS = scalar string class or object name 

 Outputs     : METHODS = string array of method names

 CALLS: ***
	APPEND_ARR, EXIST, TRIM, VALID_CLASS
 History     : Written 13 Nov 2000, D. Zarro, EIT/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_MOD $SSW/gen/idl/help/get_mod.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        :
	GET_MOD()
 Purpose     :
	Extract list of procedure modules.
 Explanation :
	Extract list of procedure modules from a library or directory.  Used by
	SCANPATH.
 Use         :
	Result = GET_MOD(LIB)
 Inputs      :
	LIB  = Library or directory name.
 Opt. Inputs :

 Outputs     :
	Result of function is a string array with each module name.
 Opt. Outputs:
	None.
 Keywords    :
	None.
 Calls       : ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], CHKLOG [1], CHKLOG [2]
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], ESPAWN, LOC_FILE [1], LOC_FILE [2]
	LOC_FILE [3], break_file [4], concat_dir [4]
 CALLED BY:
	CHKARG, FINDFILE_LIST, PEEK, SCANPATH, WHICH
 Common      :
	None.
 Restrictions:
	None.
 Side effects:
	None.
 Category    :
	Documentation, Online_help.
 Prev. Hist. :
       Written DMZ (ARC) May 1991
	William Thompson, Dec 1991, modified to be compatible with UNIX.
       DMZ (DEC'92), fixed bug in FINDFILE with long argument lists.
 Written     :
	D. Zarro, GSFC/SDAC, May 1991.
 Modified    :
	Version 1, William Thompson, GSFC, 23 April 1993.
		Incorporated into CDS library.
	Version 2, William Thompson, GSFC, 16 June 1993.
		Changed strategy used for text libraries--more robust.
		Added IDL for Windows compatibility.
       Version 3, Dominic Zarro, GSFC, 1 August 1994.
               Changed something, but can't remember what it was
       Version 3.1, Dominic Zarro, GSFC, 1 August 1994.
               Replace spawning of 'ls' by call to LOC_FILE
	Version 3.2, richard.schwartz@gsfc, 5 June 1998.
		Sort modules explictly alphabetically to help windows.
 Version     :
	Version 3.2, 5 June 1998.


GET_MONTH $SSW/gen/idl/time/get_month.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_MONTH

 Purpose     : get month name 

 Category    : utility date time 

 Syntax      : month=get_month(id)

 Inputs      : ID = month number (0 for Jan, 1 for Feb, etc)
                or  month name (Jan, Feb, etc)

 Outputs     : MONTH = string month corresponding to ID
                 or  month number corresponding to month

 Keywords    : TRUNCATE = truncate to 3 characters

 CALLS: ***
	ERR_STATE, EXIST
 CALLED BY:
	FID2TIME, FID__DEFINE, FIX_DATE, GET_FITS_TIME, RSTN__DEFINE
	eis_dr_obj__DEFINE [1], eis_dr_obj__DEFINE [2]
 History     : Written 6 Jan 1999, D. Zarro (SM&A/GSFC)

 Contact     : dzarro@solar.stanford.edu


GET_NAR $SSW/gen/idl/solar/get_nar.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_NAR

 Purpose     : Wrapper around RD_NAR

 Category    : planning

 Explanation : Get NOAA AR pointing from $DIR_GEN_NAR files

 Syntax      : IDL>nar=get_nar(tstart)

 Inputs      : TSTART = start time 

 Opt. Inputs : TEND = end time

 Outputs     : NAR = structure array with NOAA info

 Opt. Outputs: None

 Keywords    : COUNT = # or entries found
               ERR = error messages
               QUIET = turn off messages
               NO_HELIO = don't do heliographic conversion
               LIMIT=limiting no of days in time range
               UNIQUE = return unique NOAA names

 CALLS: ***
	ADD_PATH [1], ADD_PATH [2], ADD_TAG [1], ADD_TAG [2], ANYTIM2UTC [1]
	ANYTIM2UTC [2], CHKLOG [1], CHKLOG [2], CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], DATATYPE [1], DATATYPE [2], DATATYPE [3], DELVARX [1], DELVARX [2]
	DELVARX [3], DELVARX [4], GET_UTC, HAVE_PROC, HEL2ARCMIN [1], HEL2ARCMIN [2], IS_DIR
	MERGE_STRUCT, MKLOG, NUM2STR, RD_NAR, UNIQ [1], UNIQ [2], UNIQ [3], anytim [1]
	anytim [2], anytim [3], anytim [4], anytim [5], concat_dir [4], delvarx [5]
	is_number [1], is_number [2]
 CALLED BY:
	LIST_NAR, OPLOT_NAR [1], PRINT_NAR, hsi_flare_list2ar, ssw_fov_context
 History     : 20-Jun-1998, Zarro (EITI/GSFC) - written
               20-Nov-2001, Zarro - added extra checks for DB's
               24-Nov-2004, Zarro - fixed sort problem

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_OBS_DATE $SSW/gen/idl/image_tool/get_obs_date.pro
[Previous] [Next]
 PROJECT:
       SOHO - CDS

 NAME:
       GET_OBS_DATE()

 PURPOSE:
       Get date and time of obs. from FTIS header in CCSDS format.

 EXPLANATION:
       Make effort trying to extract date and time of observation from the
       header of FITS image file. It searches for the following keywords
       in the FITS header:

          DATE_OBS -- in CCSDS format (a keywork proposed for the SOHO
                      project)
          DATE-OBS -- in DD/MM/YY format. If not present, current date will
                      be returned, and a warning message is issued.
          TIME-OBS -- in hh:mm:ss format. If not present, current time will
                      be returned, and a warning message is issued.
          UTSTOP  -- in seconds from 01/01/70 00:00
          UTSTART  -- in seconds from 01/01/70 00:00
          ENDTIME  -- in seconds from 01/01/70 00:00
          STARTIME -- in seconds from 01/01/70 00:00
          YEAR     -- Year number
          MONTH    -- Month of year
          DAY      -- Day of month
          HOUR     -- Hour of day
          MINUTE   -- Minute of hour
          SECOND   -- Second of minute

 CALLING SEQUENCE:
       GET_OBS_DATE, header, utc

 INPUTS:
       HEADER -- Header of a FITS file

 OPTIONAL INPUTS:
       None.

 OUTPUTS:
       UTC -- String of date and time of observation in CCSDS format

 OPTIONAL OUTPUTS:
       None.

 KEYWORD PARAMETERS:
       QUIET -- Suppress any error message if set.

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], DMY2YMD, FIND_WITH_DEF [1]
	FIND_WITH_DEF [2], FIND_WITH_DEF [3], FXKVALUE, FXPAR [1], FXPAR [2], GET_UTC
	LEAPSEC_1972, NUM2STR, REPCHAR, SEC2TAI, STR_SEP, TAI2UTC
 CALLED BY:
	RD_IMAGE_FITS
 COMMON BLOCKS:
       None.

 RESTRICTIONS:
       None.

 SIDE EFFECTS:
       None.

 CATEGORY:
       Science planning

 PREVIOUS HISTORY:
       Written September 21, 1994, by Liyun Wang, GSFC/ARC

 MODIFICATION HISTORY:
      Liyun Wang, GSFC/ARC, September 27, 1994
         Added keyword QUIET.
      Liyun Wang, GSFC/ARC, October 7, 1994
         Added checkings for image files from Mees SO
      Version 2, Liyun Wang, GSFC/ARC, December 21, 1994
         Made it work with data from Mt. Wilson
      Version 3, Liyun Wang, GSFC/ARC, April 19, 1995
         Made it capable of dealing with time format of HH.MM.SS    

 VERSION:
       Version 3, April 19, 1995


GET_PID $SSW/gen/idl/system/get_pid.pro
[Previous] [Next]
 Project     : SOHO - CDS     
                   
 Name        : GET_PID
               
 Purpose     : return user PID and TTY for given process
               
 Category    : utility
               
 Syntax      : IDL> pid=get_pid(process)
    
 CALLS: ***
	ESPAWN, GREP, IS_BATCH, IS_BLANK, OS_FAMILY, TRIM2
 CALLED BY:
	APPLY_LOCK, CHECK_LOCK
 Examples    : pid=get_pid('/idl')

 Inputs      : PROCESS = string process name (e.g. 'idl')
               
 Outputs     : PID = user PID from PS

 Opt. Outputs: None
               
 Keywords    : TTY = terminal at which process was initiated
               ERR = error string
               COUNT = # of PID's associated with PROCESS
               ALL = get PID's for all terminals

 History     : Version 1,  17-Aug-1996,  D M Zarro.  Written
             : 26-Mar-2002, Zarro (EER/GSFC) - sped up with caching

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_POINTER $SSW/gen/idl/objects/get_pointer.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_POINTER()

 Purpose     : to get a pointer value from a pointer variable

 Category    : Help

 Explanation : retrieves a pointer value from a pointer variable.

 Syntax      : IDL> value = get_pointer(pointer)

 Inputs      : POINTER = pointer variable

 Opt. Inputs : None

 Outputs     : Value associated with POINTER

 Opt. Outputs: None

 Keywords    : NOCOPY   -  do not make internal copy of value
             : UNDEFINED - 0/1 if returned value is defined/undefined

 CALLS: ***
	DPRINT, EXIST, GET_CALLER, VALID_POINTER
 CALLED BY:
	CACHE_DATA, CDS_STACK, COPY_VAR, EIS_IMAGE_TOOL_EVENT [1]
	EIS_IMAGE_TOOL_EVENT [2], GET_CDS_STUDY, IMAGE_TOOL_EVENT, ITOOL_OVERLAYER
	MK_PLAN_CUSTOM, MK_SOHO_CUSTOM, XANSWER, XCALENDAR, XCAMP, XCAT, XCHOICE, XCLONE_PLAN
	XGET_UTC, XIAP, XINPUT, XLIST, XMATRIX, XPROGRAM, XPROGRAM_ADD, XPS_SETUP, XREPORT
	XREPORT_EDIT, XSEL_ITEM, XSEL_LIST [1], XSEL_LIST [2], XSET_COLOR, XSET_VALUE, XTEXT
	XZOOM_PLAN, ethz_XCHOICE, plotman
 Common      : None

 Restrictions: POINTER must be defined via MAKE_POINTER

 Side effects: memory value of POINTER is removed when /NO_COPY set

 History     : Version 1,  1-Sep-1995,  D.M. Zarro.  Written
               Version 2,  17-July-1997,  D.M. Zarro. Modified
                -- Updated to version 5 pointers
               Version 3,  17-Nov-1999,  D.M. Zarro. Modified
                -- Added check for allocated heap variable in pointer
               24-Jan-2007, Zarro (ADNET/GSFC)
                 - removed EXECUTE
    
 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_PROC $SSW/gen/idl/help/get_proc.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : 
	GET_PROC()
 Purpose     : 
	Extract procedure from a library or directory.  
 Explanation : 
	This procedure is used by the SCANPATH routine to extract a procedure
	from a VMS text library, or from a directory.
 Use         : 
	Result = GET_PROC(LIB,NAME,TEXT=TEXT, 
			/SEARCH,/LINOS,/BUFFER)
 Inputs      : 
	LIB	= Library name.
	NAME	= Procedure name.
 Opt. Inputs : 
	None.
 Outputs     : 
	The output of the function is a string array with each element being a
	line of code.
 Opt. Outputs: 
	None.
 Keywords    : 
	TEXT 	= Search string.
	SEARCH  = Logical switch to decide whether to search for string in
       RELOAD  = do not recall procedure from memory, but reload it
       KEEP    = number of files to keep in buffer [def=20]
 UNUSABLE KEYWORDS -- code is in place but modifications to DOC.PRO
		       are needed to pass /LINOS or BUFFER=[n1,n2]
       LINOS   = added line number option
	BUFFER  = 2 element vector indicating display n1 lines before search 
		  string and n2 lines after search string. Only valid if
		  /SEARCH is set
 Calls       : ***
	BOOST_ARRAY [1], BOOST_ARRAY [2], BOOST_ARRAY [3], BREAK_FILE [1]
	BREAK_FILE [2], BREAK_FILE [3], CHKLOG [1], CHKLOG [2], CONCAT_DIR [1]
	CONCAT_DIR [2], CONCAT_DIR [3], DATATYPE [1], DATATYPE [2], DATATYPE [3], ESPAWN
	EXIST, LOC_FILE [1], LOC_FILE [2], LOC_FILE [3], OS_FAMILY, RD_ASCII [1]
	RD_ASCII [2], REVERSE, TRIM2, break_file [4], concat_dir [4]
 CALLED BY:
	CHKARG, SCANPATH
 Common      : 
	None.
 Restrictions: 
	None.
 Side effects: 
	None.
 Category    : 
	Documentation, Online_help.
 Prev. Hist. : 
       Written DMZ (ARC) May 1991.
	Modified WTT (ARC) Dec 1991, to support UNIX.
       Modified DMZ (ARC) Jul 1992, to speed reading and add extract keyword
       Modified EEE (HSTX) Oct 1992, 1) to find all occurrences of ;+/;_
       			      2) to search for input string
       			      3) to allow BUFFER keyword 
 Written     : 
	D. Zarro, GSFC/SDAC, May 1991.
 Modified    : 
	Version 1, William Thompson, GSFC, 23 April 1993.
		Incorporated into CDS library.
	Version 2, William Thompson, GSFC, 16 June 1993.
		Added IDL for Windows compatibility.
		Modified to avoid conflict with SERTS function named FIND.
       Version 3, Dominic Zarro, GSFC, 1 August 1994.
               Corrected bug in reading from common block 
       Version 3.1, Dominic Zarro (GSFC) 22 August 1994.
               Removed spawning and replace by call to RD_ASCII
       Version 4, Dominic Zarro (GSFC) 22 September 1994.
               Removed lower/upper case forcing if filenames
               (who put that there? - not me)
 Version     : 
	Version 4, 22 September 1994.


get_rb0p [1] $SSW/gen/idl/solar/get_rb0p.pro
[Previous] [Next]
NAME:
	get_rb0p
PURPOSE:
	Determine the solar radius, b0 angle, and p angle for a set of times
CALLING SEQUENCE:
	rb0p    = get_rb0p(time)
	r       = get_rb0p(index, /radius)
	b0angle = get_rb0p(roadmap, /b0angle, /deg)
	pangle  = get_rb0p('1-jun-93', /pangle)
INPUT:
	item	- A structure or scalar.  It can be an array.
 CALLS: ***
	GET_SUN [1], GET_SUN [2], anytim2ints [1], anytim2ints [2]
 CALLED BY:
	ALIGN1BIGGRAM, ARC2LEN, BUILD_SSX, CONV_A2H [1], CONV_A2H [2], CONV_H2A [1]
	CONV_H2A [2], EARTH, EARTH_CURSOR, GBO_HEL, GET_LATLON, GET_POINT_STR, GET_SSX_SLICE
	GET_TRACUBE, GRID_CURSOR, G_H, HELIOCENTRIC, HELIO_FOOT, HXA2HXAXY [1]
	HXA2HXAXY [2], HXASCAN2HXAXY, HXA_SUNCENTER, LAY1GKM, LIMB2DISK, LONLAT2XY
	LOUGHHEAD, MAP_CARRINGTON, MK_SOHO_MAP_EARTH, MK_SSX, NEAR_CONJ, NORH_BEAM [1]
	NORH_BEAM [2], NORH_GRID [1], NORH_GRID [2], NORH_P2H [1], NORH_P2H [2]
	NOV93_ECLIPSE, NOV_ECLIPSE, PLOT_CLON, PLOT_HSI, PLOT_HXT, POLAR_GRID, PP_MWLT2SXT
	PP_SXT2ANY, PP_SXT2VLA, PROM_ON_DISK, Ruler, SXT_ECLIPSE, SXT_EXPOSURE_MAP
	SXT_GRID [1], SXT_GRID [2], SXT_GRID [3], SXT_RPAXY, TANGENT_HEIGHT, TERM_QUICK
	THERMAL_KEV, TRACE_CUBE_POINTING, TRACE_MDI_ALIGN, TRACE_SSWHERE [1], TV_SSX
	TV_SYNOP, WITH_INT, agl2cut, atr2hxa_dbase, azimuth_teem [1], azimuth_teem [2]
	conv_a2ap, conv_a2p [1], conv_a2p [2], conv_p2a [1], conv_p2a [2], fit_limb
	fl_suntoday [1], fl_suntoday [2], fl_suntoday [3], foreshort, gbo_obs_coord
	gbo_pfi, get_gbo_pfi, gt_pix_size, hxt_images2ps, mk_gsn_obs_s1, mk_mdi_fits
	mk_strip_file, mk_sun_mosaic, mk_sxh, mk_sxl, mplot_nar, plot_ar_pfi, plot_fov [1]
	plot_nar [1], plot_nar [2], plot_ssw_fov, rot_pix2, rt_nkr, scale_gbo, sda2fits
	show_hxafid, sleazy_rot, sol_rot [2], sun_grid, sun_today [1], sun_today [2]
	sun_today [3], sxi_arcs2pix, sxi_hel2arcs, sxi_parv2pix, sxi_pix2arcs, sxi_pix2hel
	sxipng_arcs2pix, sxipng_hel2arcs, sxipng_parv2pix, sxipng_pix2helstr
	sxt_deleak [1], sxt_deleak [2], sxt_plot_fov, sxt_xsaa, trace_sswhere [2]
	trace_sswhere [3], trace_sswhere [4], xy2lonlat, xy_lwa
OPTIONAL KEYWORD INPUT:
	radius	- If set, just return the radius
	b0angle	- If set, just return the b0 angle
	pangle	- If set, just return the p angle
	pb0r	- If set, return a 3xN array of [p, b0, r]
		  This option is available so that the old routine PB0R can
		  be replaced.
	deg	- If set, then return angles in degrees (default is radians)
OUTPUT:
	rb0p	- Returns a 3xN vector containing the following parameters
		  when /RADIUS, /B0ANGLE, or /PANGLE are not set:
       	P  = Position angle of the northern extremity of the axis
                    of the sun's rotation, measured eastward from the
                    geographic north point of the solar disk. 
       	B0 = Heliographic latitude of the central point of the
                    solar disk
       	R  = Solar radius measured outside earth's atmosphere in
		     arcseconds
HISTORY:
	Written 22-Nov-91 by G. Slater using Morrison style parameters
	18-Jul-93 (MDM) - Added /RADIUS, /B0ANGLE, and /PANGLE 
			- Deleted "header" option (was not implemented)
			- Changed the time conversion code somewhat
			- Added /PB0R option
	18-Jan-94 (GLS) - Made GET_RB0P front end to GET_SUN, which
			  calculates a variety of solar ephemeris data,
			  and was derived from SUN, a Johns Hopkins U.
			  routine
	15-Feb-94 (GLS)	- Checked for 1 element OUT


GET_RECENT_EIT $SSW/gen/idl/image_tool/get_recent_eit.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_RECENT_EIT

 Purpose     : get recent EIT images 

 Category    : planning

 Explanation : check SOHO PRIVATE & SUMMARY data locations

 Syntax      : file=get_recent_eit(date)

 CALLED BY:
	LOCATE_FFCAL, PLOT_CDS_POINT [1], PLOT_CDS_POINT [2]
 Examples    :

 Inputs      : None

 Opt. Inputs : DATE = date to retrieve [def=current day]

 Outputs     : 

 Opt. Outputs: FILES= most recent EIT file

 Keywords    : WAVE = EIT wavelength to select [def=304]
               PATH = path to EIT directories 
                      [used to override PRIVATE/SUMMARY locations]
               ERR = error string
               COUNT = no of files found
               BACK= # of days backward to look [def=2]
               QUIET = no output messages
               FULL_DISK = select full-disk images only
               NEAREST = get image nearest in time to DATE

 CALLS: ***
	ANYTIM2TAI, ANYTIM2UTC [1], ANYTIM2UTC [2], CHK_DIR [1], CHK_DIR [2]
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], DATATYPE [1], DATATYPE [2]
	DATATYPE [3], DATE_CODE, DPRINT, EXIST, FILE2TIME, GET_UTC, LOC_FILE [1], LOC_FILE [2]
	LOC_FILE [3], TRIM, concat_dir [4]
 Common      : None

 Restrictions: None

 Side effects: None

 History     : Written 14 May 1998 D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GET_RECENT_FILE $SSW/gen/idl/system/get_recent_file.pro
[Previous] [Next]

 NAME: 
	GET_RECENT_FILE
	
 PURPOSE:
	This function returns the name of the most recent file
	from a list of files with dates encoded in their names.

 CATEGORY:
	SYSTEM

 CALLING SEQUENCE:
	Most_recent_file = Get_recent_file( Filelist [,DATE=DATE, ALLSORTED=ALLSORTED] )

 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], FILE2TIME, REVERSE, break_file [4]
	uniqo [1], uniqo [2]
 INPUTS:
       none explicit, only through commons;

 OPTIONAL INPUTS:

 OUTPUTS:
       none explicit, only through commons;

 KEYWORD INPUTS:

 KEYWORD OUTPUTS:
	DATE - time in sec from 1-jan-1979 for file(s) encoded in file name.
	ALLSORTED - If set, return array of files sorted by date
 CALLED BY:
	HSI_LOC_FILE
 COMMON BLOCKS:
	none

 SIDE EFFECTS:
	none

 RESTRICTIONS:
	none

 PROCEDURE:
	Use file2time to parse and interpret time.

 MODIFICATION HISTORY:
	Version 1, richard.schwartz@gsfc.nasa.gov, 27-mar-2001.


GET_RECON $SSW/gen/idl/fund_lib/sdac/get_recno.pro
[Previous] [Next]

 NAME: 
	GET_RECON

 PURPOSE:
 	This function returns the number of lines in an ASCII FILE


 CATEGORY:
	GEN

 CALLING SEQUENCE:
	recno = get_recno( file )

 CALLS: ***
	GET_RECNO
 INPUTS:
       file - file name

 OPTIONAL INPUTS:
	none

 OUTPUTS:
       none explicit, only through commons;

 OPTIONAL OUTPUTS:
	none

 KEYWORDS:
	none
 COMMON BLOCKS:
	none

 SIDE EFFECTS:
	none

 RESTRICTIONS:
	none

 PROCEDURE:
 Uses FSTAT in a loop

 MODIFICATION HISTORY:
	DOC. RAS JUNE 1996


GET_RID $SSW/gen/idl/util/get_rid.pro
[Previous] [Next]
 Project     : HESSI
                  
 Name        : GET_RID
               
 Purpose     : return a random ID 
                             
 Category    : system utility
               
 Explanation : uses combination of current time and random function
               
 Syntax      : IDL> id=get_rid()
    
 Inputs      : None
               
 Outputs     : ID = random id
               
 Keywords    : /TIME = include a time part
               /ULONG = convert to Unsigned long
             
 CALLS: ***
	NINT [1], NINT [2]
 CALLED BY:
	CLONE_VAR, MK_TEMP_DIR, MK_TEMP_FILE, REP_TAG_NAME, REP_TAG_VALUE, TEST_OPEN2
	UNIX_SPAWN, WIN_SPAWN
 History     : 29-Nov-1999, Zarro (SM&A/GSFC), written

 Contact     : dzarro@solar.stanford.edu


GET_SCREEN [1] $SSW/gen/idl/widgets/get_screen.pro
[Previous] [Next]
 Project     :	SOHO - CDS

 Name        :	GET_SCREEN

 Purpose     : 
	return screen scaling parameters for controlling widget
       sizing
 Explanation :

 Use         : GET_SCREEN, space,xpad,ypad,scx,scy

 Inputs      : None.

 Opt. Inputs : None.

 Outputs     : 
       space = pixel spacing between children bases
       xpad,ypad = horizontal and vertical pixel spacing being children 
                   bases and edges of parent base.
       scx,scy = pixel scale factors to rescale screen size in 
                 X- and Y-directions
 Opt. Outputs: None.

 Keywords    : None.

 Procedure   :
       The returned values were derived empirically by
       experimenting with sizing widgets on a 1280 x 1024 pixel screen.
       They can be used as keywords in WIDGET_CONTROL  to produce
       "nice fitting" widgets. IDL can (and will likely) ignore them.
   
 Calls       : None.
 Common      : None.

 Restrictions: None.

 Side effects: None.

 Category    :

 Prev. Hist. : None.

 Written     :	DMZ (ARC) Oct 1993

 Modified    :

 Version     :


GET_SID $SSW/gen/idl/objects/get_sid.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_SID

 Purpose     : Return a session ID (SID) for tracking users CGI forms

 Category    : HTML
                   
 Inputs      : None

 Outputs     : SID = unique session ID string

 Keywords    : EXPIRED = if SID already exists in memory, and it is older
               than EXPIRED minutes [def=10], then return it instead of creating
               a new one.
               RESET = set to clear out SID_POOL and release memory

 CALLS: ***
	ANYTIM2TAI, ARR2STR [1], Arr2Str [2], DATATYPE [1], DATATYPE [2], DATATYPE [3]
	DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4], EXIST, FREE_POINTER, GET_UTC
	MERGE_STRUCT, NINT [1], NINT [2], TRIM, anytim2ex [1], anytim2ex [2], delvarx [5]
 CALLED BY:
	EIS_LIST_EXPER [1], EIS_LIST_EXPER [2], SID__DEFINE
 Common      : GET_SID,SID_POOL = saved array of SID structures
                {sid, sid:sid, born:born, ptr:ptr} 
                BORN = time when SID was created (TAI format)
                PTR  = pointer in which FORM data relating to SID is stored 

 History     : 13-Sept-1999,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


get_solar_indices $SSW/gen/idl/solar/get_solar_indices.pro
[Previous] [Next]
   Name: get_solar_indices

   Purpose: return selected solar/geomag indices for time range

   Input Parameters:
      time0, time1 - time range of interest

   Output - function returns selected indices (structure or selected)

   Keyword Parameters:
      apkp_3hour - switch - return higher cadence structure including
                   kp and ap @ 3 hour cadence (time:0l,mjd:0l,ap:0,kp:0}
      apmean,kpmean,sunspot,f10_7 - switch selects desired output 
         (@default cadence = one sample per day)
      kp - backward compat synonym for kpmean
      struct (output) - the complete dbase structure between t0/t1
      interpolate - if set and only one input time, interpolate value

   Calling Seqence:
      indices=get_solar_indices(time0 time1 [,/SUNSPOT] [/F10_7] [/KPmean] $
                                                [/APmean])
      kpap3hr=get_solar_indices(time0, time1 ,/apkp_3hour)

   Calling Examples:
      IDL> struct=get_solar_indices('1-jan-1960','1-jan-2000')
      IDL> help,struct,/str

      IDL> spots=get_solar_indices('1-jan-1960','1-jan-2000',/sunspot,struct=struct)
      IDL> help,sunspots

   Method:
     setup and call 'read_genxcat' for $SSW_SOLAR_INDICES/ssw_indices*.genx
     [ genx catalog files via ngdc_make_genxcat & ngdc_kpap2struct ]

   History:
      13-March-2000 - S.L.Freeland (originally for atmospheric absorption)
       4-April-2000 - S.L.Freeland - rationalize input time(s)
      12-Dec-2001   - S.L.Freeland - check $SSWDB/ngdc/indices/genx if
                         $SSW_SOLAR_INDICES not defined
       8-Mar-2005 - S.L.Freeland - add /APKP_3HOUR keyword + function

 CALLS: ***
	BOX_MESSAGE, CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], FILE_EXIST [2]
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], concat_dir [4]
	data_chk [1], data_chk [2], file_exist [1], file_exist [3], get_logenv [1]
	get_logenv [2], gt_tagval [1], gt_tagval [2], read_genxcat, tim2dset [1]
	tim2dset [2], time_window, timegrid
   Restrictions:
      Assumes $SSWDB  set $SSW_SOLAR_INDICES is installed locally
      /interpolate not yet implemented - just a reminder of possible 'todo'...

   Method:
      Inidices from NGDC are stored as a 'genx' catalog 
      (see read_genxcat / write_genxcat )


GET_SOURCE_STC $SSW/gen/idl/image_tool/get_source_stc.pro
[Previous] [Next]
 PROJECT:
       SOHO - CDS/SUMER

 NAME:
       GET_SOURCE_STC()

 PURPOSE: 
       Get a source structure based on the datatype. 

 CATEGORY:
       Planning, Image_tool
 
 EXPLANATION:
       This routine returns a structure that refelct the image
       sources of the solar image FITS files

 SYNTAX: 
       Result = get_source_stc()

 INPUTS:
       None.

 OPTIONAL INPUTS: 
       None.

 OUTPUTS:
       RESULT - A structure that contains the following tag names:
          NAME    - Name of image sources to be shown
          DIRNAME - the actual directory name for the image sources
                    under the SYNOP_DATA or SUMMARY_DATA direcotry

          By default, RESUTL is a source structure for synoptic data
          unless the keyword SUMMARY is set.

 OPTIONAL OUTPUTS:
       None.

 KEYWORDS: 
       DATASOURCE - SOHO data source: 1 (default): synoptic data; 2:
                    summary data; 3: private data

 CALLS: ***
	TRIM
 CALLED BY:
	ITOOL_PICKFILE, XGET_SYNOPTIC
 COMMON:
       None.

 RESTRICTIONS: 
       None.

 SIDE EFFECTS:
       None.

 HISTORY:
       Version 1, August 16, 1995, Liyun Wang, NASA/GSFC. Written
       Version 2, June 17, 1996, Liyun Wang, NASA/GSFC
          Added Pic du Midi Observatory
       Version 3, July 30, 1996, Liyun Wang, NASA/GSFC
          Added Kiepenheuer Institute for Solar Physics
       Version 4, February 1998, Zarro (SAC/GSFC)
          Added TRACE
	Version 5, Nov 3, 1998, Bentley (MSSL/UCL)
          Checks env. variables and only lists directories that are
          present
       Version 6, Sept 16, 2006, Zarro (ADNET/GSFC)
          Fixed some bad coding on the part of Dr. Bentley

 CONTACT:
       Liyun Wang, NASA/GSFC (Liyun.Wang.1@gsfc.nasa.gov)


GET_SSWDB $SSW/gen/idl/ssw_system/get_sswdb.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_SSWDB

 Purpose     : figure out path to SSWDB from 
               $SSW/site/setup/setup.ssw_paths

 Category    : Utility

 Syntax      : sswdb=get_sswdb()

 Inputs      : None

 Outputs     : SSWDB = directory corresponding to SSWDB (e.g. /sdb)

 CALLS: ***
	IS_DIR, LOC_FILE [1], LOC_FILE [2], LOC_FILE [3], RD_ASCII [1], RD_ASCII [2]
	STR2ARR [1], STR2ARR [2], TRIM, str_replace [1], str_replace [2]
 History     : Written 1 Dec 2001, D. Zarro (EITI/GSFC)

 Contact     : dzarro@solar.stanford.edu


GET_SUB_MAP $SSW/gen/idl/mapping/get_sub_map.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_SUB_MAP

 Purpose     : function wrapper around SUB_MAP

 Category    : imaging

 Syntax      : smap=get_sub_map(map)

 Inputs      : MAP = map structure created by MAKE_MAP

 Outputs     : SMAP = subimage of map

 Keywords    : see SUB_MAP

 CALLS: ***
	SUB_MAP
 CALLED BY:
	region_mark
 History     : Written 8 November 2002, Zarro (EER/GSFC)

 Contact     : dzarro@solar.stanford.edu


GET_SUB_REGION $SSW/gen/idl/mapping/get_sub_region.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_SUB_REGION

 Purpose     : get coordinate range in an image

 Category    : imaging

 Explanation : 

 Syntax      : sub=get_sub_region()

 CALLED BY:
	SUB_MAP
 Examples    :

 Inputs      : None (but a plot must already exist)

 Opt. Inputs : None

 Outputs     : SUB=[xmin,xmax,ymin,ymax] = selected region

 Opt. Outputs: None

 Keywords    : PIXEL = return limits in pixel units
               RUBBER = use rubber band in place of BOX_CURSOR

 CALLS: ***
	BOX_CURSOR2, DRAWBOX
 Common      : None

 Restrictions: None

 Side effects: None

 History     : Written 22 November 1997, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


get_subdirs [1] $SSW/gen/idl/genutil/get_subdirs.pro
[Previous] [Next]
NAME:
	get_subdirs
PURPOSE:
	To return a list of the subdirectories under a given location
CALLING SEQUENCE:
	sdir = get_subdirs('/2p/morrison')
	sdir = get_subdirs('/ys')
	sdir = get_subdirs('ys:[sxt]')
INPUT:
	indir	- The input directory to find all subdirectories under
 CALLS: ***
	str_replace [1], str_replace [2]
 CALLED BY:
	DATA_PATHS, PLOT_RESULTS [2], file_path [1], file_path [2], get_dirtree, his_dirs
	show_pix [1], show_pix [2], sxt2file, timeline, topsdb [1], topsdb [2], web_seq
	xdisp_fits
RESTRICTIONS:
	For VMS system, there has to be a "]" in the input specification
HISTORY:
	Written 19-Oct-92 by M.Morrison
	 5-Jul-94 (MDM) - Modified to add the root directory to the list
			  of subdirectories found
	13-Jan-98 (MDM) - Modified to not use "ls -R" option, rather to use
			  the "find" instruction.
			- Added /ls option to use the old method


GET_SUMER_POINT $SSW/gen/idl/image_tool/get_sumer_point.pro
[Previous] [Next]
 PROJECT:
       SOHO - SUMER

 NAME:
       GET_SUMER_POINT()

 PURPOSE:
       Make a pointing structure for use by IMAGE_TOOL from SUMER study

 EXPLANATION:

 CALLING SEQUENCE:
       Result = get_sumer_point(sumer_study)

 INPUTS:
       SUMER_DETAIL - SUMER detail structure returned from GET_DETAIL.
                      It currently (as of January 26, 1995) has the 
                      following tags: 

          STRUCT_TYPE - The character string 'SUMER-DETAIL'
          PROG_ID     - Program ID, linking one or more studies together
          STUDY_ID    - Number defining the study
          STUDYVAR    - The number 0 (for compatibility with CDS software).
          SCI_OBJ     - Science objective from the daily science meeting
          SCI_SPEC    - Specific science objective from meeting
          CMP_NO      - Campaign number
          OBJECT      - Code for object planned to be observed
          OBJ_ID      - Object identification
          DATE_OBS    - Date/time of beginning of observation, in TAI format
          DATE_END    - Date/time of end of observation, in TAI format
          TIME_TAGGED - True (1) if the start of the study is to be a 
                        time-tagged event.  Otherwise, the study will begin
                        immediately after the previous study.
          N_POINTINGS - Number of pointing areas associated with the study.
          POINTINGS   - A array describing the area for each study to be 
                        used during the study.  If there are no pointings
                        associated with the array, then this tag will have a
                        dummyvalue instead.
          
          The POINTINGS descriptions themselves are structures, of
          type "sumer_plan_pnt", with the following tags:
          
             XCEN    - Center pointing of the study part in the X direction.
             YCEN    - Same in the Y direction.
             WIDTH   - Width to use for the study.
             HEIGHT  - Height to use for the study.
             ZONE_ID - 1-byte integer, the zone ID for the pointing.
             ZONE    - String, the zone description, e.g. "Off Limb"

 OPTIONAL INPUTS:
       None.

 OUTPUTS:
       RESULT - A pointing structure that can be used by IMAGE_TOOL. 
                It has the following tags:

          MESSENGER  - ID of widget in the caller that triggers a
                       timer event in the planning tool to signal the
                       completion of pointing; must be a widget that
                       does not usually generate any event
          INSTRUME   - Code specifying the instrument; e.g., 'C' for CDS
          SCI_SPEC   - Science specification
          STD_ID     - Study ID   
          G_LABEL    - Generic label for the pointing; e.g., 'RASTER'
          X_LABEL    - Label for X coordinate of pointing; e.g., 'INS_X'
          Y_LABEL    - Label for Y coordinate of pointing; e.g., 'INS_Y'
          DATE_OBS   - Date/time of beginning of observation, in TAI format   
          DO_POINTING- An integer of value 0 or 1 indicating whether pointing
                       should be handled at the planning level (i.e., by
                       IMAGE_TOOL)
          N_POINTINGS- Number of pointings to be performed by IMAGE_TOOL
          POINTINGS  - A structure array (with N_POINTINGS elements) of type
                       "DETAIL_POINT" to be handled by IMAGE_TOOL. It has 
                       the following tags: 

                       POINT_ID - A string scalar for pointing ID
                       INS_X    - X coordinate of pointing area center in arcs
                       INS_Y    - Y coordinate of pointing area center in arcs
                       WIDTH    - Area width (E/W extent)  in arcsec
                       HEIGHT   - Area height (N/S extent) in arcsec
                       ZONE     - Description of the zone for pointing
                       OFF_LIMB - An interger with value 1 or 0 indicating 
                                  whether or not the pointing area should
                                  be off limb 

          N_RASTERS  - Number of rasters for each pointing (this is
                       irrelevant to the SUMER)
          RASTERS    - A structure array (N_RASTERS-element) of type
                       "RASTER_POINT" that contains raster size and pointing
                       information (this is irrelevant to the SUMER). It has
                       the following tags: 

                       POINTING - Pointing handling code; valis
                                  values are: 1, 0, and -1
                       INS_X    - Together with INS_Y, the pointing to use
                                  when user-supplied values are not
                                  allowed.  Only valid when POINTING=0
                                  (absolute) or POINTING=-1 (relative to
                                  1st raster).
                       INS_Y    - ...
                       WIDTH    - Width (E/W extent) of the raster, in arcs
                       HEIGHT   - Height (N/S extent) of the raster, in arcs


 OPTIONAL OUTPUTS:
       None.

 KEYWORD PARAMETERS:
       None.

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], DELVARX [1], DELVARX [2], DELVARX [3]
	DELVARX [4], MK_POINT_STC, delvarx [5]
 COMMON BLOCKS:
       None.

 RESTRICTIONS:
       None.

 SIDE EFFECTS:
       None.

 CATEGORY:

 PREVIOUS HISTORY:
       Written January 26, 1995, Liyun Wang, NASA/GSFC

 MODIFICATION HISTORY:
       Version 1, created, Liyun Wang, NASA/GSFC, January 26, 1995
       Version 2, February 18, 1997, Liyun Wang, NASA/GSFC
          Added SCI_SPEC and STD_ID in output structure

 VERSION:
       Version 2, February 18, 1997


GET_SUN [1] $SSW/gen/idl/solar/get_sun.pro
[Previous] [Next]
 NAME:
       GET_SUN
 PURPOSE:
	Provides geocentric physical ephemeris of the sun.
       Front end to routine SUN to provide 'Yohkoh-style' time interface
 CATEGORY:

 CALLING SEQUENCE:
       OUT = GET_SUN(ITEM)
 INPUTS:
       ITEM -	Reference time for ephemeris data.  Interpreted as
	  an ephemeris time (ET).  The difference between ephemeris
	  time and universal time (Delta T = ET - UT) is not
	  completely predictable but is about 1 minute now.  This
	  difference is noticable slightly.  The form can be:
           (1) structure with a .time and .day field,
           (2) standard 7-element external representation, or
	    (3) a string of the format "hh:mm dd-mmm-yy".
         If no date is entered, the current date is used.
         The year is not required, but if entered should be
         of the form "dd-mmm" style.  The date should be entered
         in string style with date first.
 KEYWORD INPUTS:
      /LIST :	Displays values on screen.
 OUTPUTS:
	DATA = Vector of solar ephemeris data:
	  DATA( 0) = Distance (AU).
	  DATA( 1) = Semidiameter of disk (sec).
	  DATA( 2) = True longitude (deg).
	  DATA( 3) = True latitude (0 always).
	  DATA( 4) = Apparent longitude (deg).
	  DATA( 5) = Apparent latitude (0 always).
	  DATA( 6) = True RA (hours).
	  DATA( 7) = True Dec (deg).
	  DATA( 8) = Apparent RA (hours).
	  DATA( 9) = Apparent Dec (deg).
	  DATA(10) = Longitude at center of disk (deg).
	  DATA(11) = Latitude at center of disk (deg).
	  DATA(12) = Position angle of rotation axis (deg).
	  DATA(13) = decimal carrington rotation number.
 KEYWORD OUTPUTS
	DIST 		= Distance in AU.
	SD 		= Semidiameter of disk in arc seconds.
	TRUE_LONG	= True longitude (deg).
	TRUE_LAT 	= 0 always.
	APP_LONG 	= Apparent longitude (deg).
	APP_LAT 	= 0 always.
	TRUE_RA 	= True RA (hours).
	TRUE_DEC 	= True Dec (deg).
	APP_RA 		= Apparent RA (hours).
	APP_DEC 	= Apparent Dec (deg).
	HE_LON 		= Longitude at center of disk (deg).
	HE_LAT 		= Latitude at center of disk (deg).
	PA 		= Position angle of rotation axis (deg).
	CARR		= decimal carrington rotation number.
 CALLS: ***
	RECPOL [1], RECPOL [2], RECPOL [3], TIM2JD [1], TIM2JD [2], fmt_tim [1], fmt_tim [2]
 CALLED BY:
	CARR2EX, COORD_ADDINDEX, COORD_CART_HELIO [1], COORD_CART_HELIO [2]
	COORD_HELIO_SPHERE, STEREO_SIMUL, TIM2CARR, ea_view_angle [2], get_rb0p [1]
	get_rb0p [2], mk_strip_file, mk_syn_sfc [1], mk_syn_sfc [2], mk_synsfc_coeff [1]
	mk_synsfc_coeff [2], read_soon
	return  a solar disk mask using SSW standard keywords
	return solar disk mask constrained by XY limits using SSW standards
	yopos [1], yopos [2]
 COMMON BLOCKS:
 NOTES:
       Notes: based on the book Astronomical Formulae
         for Calculators, by Jean Meeus.
         If no arguments given will prompt and list values.
 MODIFICATION HISTORY:
	Feb, 1994 - GLS - Written to provide 'Yohkoh style' time
	  interface to routine SUN.PRO by R. Sterner, 19 Feb, 1991
       8-Oct-1998 - S.L.Freeland - allow any SSW time (via anytim front end)

 Copyright (C) 1991, Johns Hopkins University/Applied Physics Laboratory
 This software may be used, copied, or redistributed as long as it is not
 sold and this copyright notice is reproduced on each copy made.  This
 routine is provided as is without any express or implied warranties
 whatsoever.  Other limitations apply as described in the file disclaimer.txt.


GET_SYNOPTIC $SSW/gen/idl/image_tool/get_synoptic.pro
[Previous] [Next]
 PROJECT:
       SOHO

 NAME:
       GET_SYNOPTIC()

 PURPOSE:
       Return list of FITS files for given dates and instrument

 CATEGORY:
       Planning

 SYNTAX:
       Result = get_synoptic()

 INPUTS:
       None required.

 OPTIONAL INPUTS:
       None.

 OUTPUTS:
       RESULT - String array or scalar containing requested file
                names; the null string is returned if no files found

 OPTIONAL OUTPUTS:
       None.

 KEYWORDS:
       START    - Starting date from which the files are searched;
                  default to 3 days before STOP if missing
       STOP     - End date for which the files are searched; default to
                  today if missing
       INSTRUME - Name of instrument; can be one of SOHO instruments
                  or 'YOHK' for yohkoh SXT images. To get SOHO files,
                  INSTRUME must be a valid SOHO instrument name (can
                  be in 1-char format recognized by GET_SOHO_INST
                  routine); if PRIVATE keyword is not set, summary
                  data is assumed.
       PRIVATE  - Set this keyword for SOHO private data; only
                  effective when INSTRUME is one for SOHO
       ERROR    - String scalar containing possible error message.
                  The null string is returned if no error occurrs
       COUNT    - Number of files returned

 CALLS: ***
	ANYTIM2UTC [1], ANYTIM2UTC [2], CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3]
	DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4], GET_SOHO_INST, GET_UTC
	ITOOL_GETFILE, concat_dir [4], delvarx [5]
 COMMON:
       None.

 RESTRICTIONS:
       None.

 SIDE EFFECTS:
       None.

 HISTORY:
       Version 1, January 15, 1997, Liyun Wang, NASA/GSFC. Written
       Version 2, January 17, 1997, Liyun Wang, NASA/GSFC
          Added PRIVATE keyword

 CONTACT:
       Liyun Wang, NASA/GSFC (Liyun.Wang.1@gsfc.nasa.gov)


GET_TAG_INDEX $SSW/gen/idl/struct/get_tag_index.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_TAG_INDEX

 Purpose     : Return index of structure tag name

 Category    : Utility

 Explanation : Same as TAG_INDEX, except input can be both name or index
               (If index, then check for validity)


 Syntax      : IDL> index=get_tag_index(stc,tag_name)

 Inputs      : STC = input structure
               TAG_NAME = input tag name 

 Outputs     : INDEX = index location of named tag

 Keywords    : VALID = return only valid indexes
               UNIQUE_VAL = return unique values

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], EXIST, IS_STRING, get_uniq, is_number [1]
	is_number [2], tag_index [1], tag_index [2]
 CALLED BY:
	BOOST_TAG, EIS_GET_HDR_STRUC, FRAME ABSTRACT CLASS DEFINITION, GET_MAP_SUB
	MOVIE_MAP, REM_TAG [2], REP_TAG_NAME, REP_TAG_VALUE, UNPACK_MAP, hsi_do_plotman
	hsi_draw_plotman_image, plot_ace, safe_log10
 History     : 23-Jan-1998,  D.M. Zarro.  Written
               4-Oct-2000, Zarro, vectorized

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_TAG_VALUE $SSW/gen/idl/struct/get_tag_value.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_TAG_VALUE

 Purpose     : get tag values from within a structure

 Category    : Help, structures

 Explanation : 
              Uses keyword inheritance and execute to determine
              if the requested tag exists. Uses recursion
              to search nested structures. The nice thing
              about this method is that the tag names don't
              have to be hardwired into the code. Any tag name
              can be entered and will be stored as a tag name in the
              anonymous structure _EXTRA. The latter is then
              cross-checked against the tags in the input structure STC.

 Syntax      : IDL>  value=get_tag_value(stc,/tag_name)

 Inputs      : STC = any structure

 Opt. Inputs : None

 Outputs     : Requested tag value

 Opt. Outputs: None

 Keywords    : ERR (output) =  1/0 for success/failure
               QUIT (input) = 0/1 to report/not report failure
               TAG_NAME   = tag name to extract
               e.g. to extract time tag from index.time use:
               TIME=GET_TAG_VALUE(INDEX,/TIME)
               MATCH = # of characters to match (e.g. if 3 then first
               3 characters sufficient for match)

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], is_number [1], is_number [2]
 CALLED BY:
	CDS_STACK, MK_CDS_MAP, SPEX_DRM_GENX [1], SPEX_DRM_GENX [2], VALID_QL, XCAT
 History     : Version 1,  1-Sep-1995,  D.M. Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


get_tape $SSW/gen/idl/system/get_tape.pro
[Previous] [Next]
 NAME:   
      get_tape
 PURPOSE:
      get and mount available tape drive unit
 CALLING SEQUENCE:
      get_tape,tunit
 OUTPUTS:
      tunit = tape unit number
 CALLS: ***
	CHKLOG [1], CHKLOG [2], DELLOG, SETLOG
 RESTRICTIONS: 
      VMS only
 MODIFICATION HISTORY:
      written DMZ (ARC Jul'92)


GET_TEMP_DIR $SSW/gen/idl/system/get_temp_dir.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GET_TEMP_DIR

 Purpose     : return system dependent temporary directory

 Category    : system utility

 Syntax      : IDL> temp=get_temp_dir()

 Outputs     : TEMP = temporary directory pertinent to OS

 Keywords    : RESET = do not use last save directory
              

 CALLS: ***
	CHKLOG [1], CHKLOG [2], DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4], EXIST
	TRIM2, WRITE_DIR, curdir [1], curdir [2], delvarx [5]
 CALLED BY:
	ADD_METHOD, ALLOW_GIF, CLONE_VAR, EIS_LIST_EXPER [1], EIS_LIST_EXPER [2]
	EIT__DEFINE, FIND_COMPRESSED, FTP__DEFINE, GET_GZIP, GET_TEMP_FILE, GOES_TEMP_DIR
	HSI_SOCK_FILE, IHY_READ, LATEST_IMAGE, MK_TEMP_FILE, SHOW_SYNOP__DEFINE
	SOCK_DOWNLOAD, SOCK_RUN, SOCK_SSW, SYNOP_DEFINE, TRACE_JSMOVIE, UNIX_SPAWN
	WIN_SPAWN, XDIFF, get_gevloc_data, mreadfits_urls, ssw_get_sources, ssw_jsulr2data
	ssw_url2data
 History     : Version 1,  25-May-1999,  D.M. Zarro (SM&A/GSFC),  Written
               17 April 2000, Zarro (SM&A/GSFC) - added alternative WINXX
               temporary directory choices

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_TEMP_FILE $SSW/gen/idl/system/get_temp_file.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : GET_TEMP_FILE

 Purpose     : Create a temporary filename in a writeable directory

 Category    : Utility

 Syntax      : IDL> file=get_temp_file()

 Inputs      : FILE = file name [def='temp.dat']

 Outputs     : NAME = file name with added path

 Keywords    : RANDOM - prepend a random set of digits to force uniqueness

 CALLS: ***
	GET_TEMP_DIR, MK_TEMP_FILE
 CALLED BY:
	RD_ASCII_BYTE, XMLPARSER__DEFINE
 History     : 13 Nov 2005, Zarro (L-3Com/GSFC) - Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_TV_SCALE $SSW/gen/idl/display/get_tv_scale.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : 
	GET_TV_SCALE
 Purpose     : 
	Retrieves information about displayed images.
 Explanation : 
	Retrieves information about images displayed by EXPTV, PUT, and other
	routines, as stored by STORE_TV_SCALE.
 Use         : 
	GET_TV_SCALE, SX, SY, MX, MY, JX, JY  [, DATA ]
 Inputs      : 
	None.
 Opt. Inputs : 
	None.
 Outputs     : 
	SX, SY	= Image size, in data pixels
	MX, MY	= Image size, in screen pixels
	JX, JY	= Position of lower left-hand corner of displayed
			  image, in screen pixels.
 Opt. Outputs: 
	DATA	= Structure variable containing the parameters needed to
		  convert pixel coordinates into data coordinates.
 Keywords    : 
	DISABLE  = If set, then TVSELECT not used.
 Calls       : ***
	TVSELECT, TVUNSELECT
 CALLED BY:
	CONTV, EIS_IMAGE_TOOL [1], EIS_IMAGE_TOOL [2], IMAGE_TOOL, IM_CONV_COORD
	LABEL_IMAGE, PIXELS_2_DATA, PIXELS_2_DEVICE, POLY_VAL, SETIMAGE, SET_SERTSW, TVAXIS
	TVBOXCRS, TVOUT, TVPLT, TVPOS, TVPROF, TVPROFILE, TVSUBIMAGE, TVVALUE, TVZOOM, TVZOOM2
 Common      : 
	TV_SCALE contains the passed parameters as a function of graphics
	device, window, and SETIMAGE settings.

	IMAGE_AREA contains switch IMAGE_SET and position IX, NX, IY, NY, from
	SETIMAGE.

 Restrictions: 
	In general, the SERTS image display routines use several non-standard
	system variables.  These system variables are defined in the procedure
	IMAGELIB.  It is suggested that the command IMAGELIB be placed in the
	user's IDL_STARTUP file.

	Some routines also require the SERTS graphics devices software,
	generally found in a parallel directory at the site where this software
	was obtained.  Those routines have their own special system variables.

 Side effects: 
	None.
 Category    : 
	Utilities, Image_display.
 Prev. Hist. : 
	William Thompson, May 1992.
 Written     : 
	William Thompson, GSFC, May 1992.
 Modified    : 
	Version 1, William Thompson, GSFC, 13 May 1993.
		Incorporated into CDS library.
       Version 2, Zarro, GSFC, 17 Feb 1997, Added /CONT to MESSAGE
 Version     : 
	Version 2


get_uniq $SSW/gen/idl/util/get_uniq.pro
[Previous] [Next]
 Project     : HESSI

 Name        : get_uniq

 Purpose     : return unique elements of an array

 Category    : utility
;
 Syntax      : IDL> out=get_uniq(in)

 Inputs      : IN = array to search

 Outputs     : OUT = unique elements

 Optional Out: SORDER = sorting index

 Keywords    : NO_CASE: case insensitive ordering on strings
               COUNT: # of uniq values
				EPSILON:  positive number ge 0, for gt 0 the difference between
				two consecutive numbers must be gt epsilon for them to be unique.

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], EXIST, UNIQ [1], UNIQ [2], UNIQ [3]
 CALLED BY:
	ADD_METHOD, Data reader with caching, EIT_COPY, EIT__DEFINE, ESPAWN, FILT_EVENTS
	FRAME ABSTRACT CLASS DEFINITION, FTP__DEFINE, GET_TAG_INDEX, GOES_Y_AVERAGE
	GOES__DEFINE, HAVE_TAG, HESSI BINNED EVENTLIST CLASS DEFINITION
	HESSI_DATA_PATHS [1], HSI_COINCIDENCE_CHECK, HSI_DECIM_CORRECTION [1]
	HSI_DECIM_CORRECTION [2], HSI_EVENTLIST_SELECT_BY_ENERGY
	HSI_SPECTROGRAMACCBIN [5], HSI_SPECTROGRAMCHAN_OVERLAP_FIX
	HSI_SPECTROGRAM_DECIM_CORRECT, HSI_SPECTROGRAM_DECIM_TABLE
	HSI_SPECTRUM__DEFINE, MAP__DEFINE, MK_SUB_DIR, RD_RSTN, REM_TAG [2]
	SHOW_SYNOP__DEFINE, SPECTROGRAM CLASS DEFINITION, SPECTRUM CLASS DEFINITION
	SPEX_DRM__DEFINE, SPEX_FIT__DEFINE, SPEX_GEN__DEFINE, SYNOP_DB__DEFINE
	SYNOP_DEFINE, TRACE_COPY, XYPLOT__DEFINE, db_gbo, edge_products, expand_dirs
	hsi_get_flare_flags, hsi_getflare, hsi_imagefile_2_plotman, hsi_plot_flux
	hsi_show_flags [2], hsi_spectrogramACCBIN [2], hsi_spectrogram__define [1]
	hsi_spectrogram__define [2], hsi_spectrogram__define [3]
	hsi_spectrogram__get_obs [1], hsi_spectrogram__livetime [1]
	hsi_ui_img_doimage [1], hsi_ui_img_doimage [2], ihy_db, plotman_conf_panels
	spex_draw_bars, spex_hessi_image__define, stc_uniq, wc_where_arr
 History     : Written 20 Sept 1999, D. Zarro, SM&A/GSFC
				25-Aug-2006, richard.schwartz@gsfc.nasa.gov;  added an epsilon tolerance
				for determining floats to be the same value

 Contact     : dzarro@solar.stanford.edu


GET_UNIQ_LIST $SSW/gen/idl/util/get_uniq_list.pro
[Previous] [Next]
 PROJECT:
       SOHO - CDS

 NAME:	
       GET_UNIQ_LIST()

 PURPOSE:
       Extract uniq list of string values from a string array

 EXPLANATION:
       This routine examines all elements of a string array, sorts
       these values, gets rid of repeated values and return a new
       string array with uniq values in a sorted order.

 CALLING SEQUENCE: 
       Result = get_uniq_list(str_array)

 INPUTS:
       STR_ARRAY - String array to work with

 OPTIONAL INPUTS: 
       ORIGINAL - Original list

 OUTPUTS:
       RESULT      - Extracted string from STR_ARRAY or from input
       SENSITIVE   - make search case sensitive 
                [e.g. 'TEST' and 'test' will be different]

 OPTIONAL OUTPUTS:
       None.

 KEYWORD PARAMETERS: 
       None.

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], UNIQ [1], UNIQ [2], UNIQ [3]
 CALLED BY:
	MK_CDS_PLAN, MK_SOHO, RD_PLAN
 COMMON BLOCKS:
       None.

 RESTRICTIONS: 
       None.

 SIDE EFFECTS:
       None.

 CATEGORY:
       
 PREVIOUS HISTORY:
       Written May 22, 1995, Liyun Wang, GSFC/ARC

 MODIFICATION HISTORY:
       Version 1, created, Liyun Wang, GSFC/ARC, May 22, 1995
       Version 2, modified, Zarro, ARC, June 6, 1996 --
         added /SENSITIVE and protected input STR_ARRAY

 VERSION:
       Version 1, May 22, 1995


get_uniq_range $SSW/gen/idl/util/get_uniq_range.pro
[Previous] [Next]
 Project     : HESSI

 Name        : get_uniq_range

 Purpose     : return unique pairs of a 2xn array

 Category    : utility

 Syntax      : IDL> out=get_uniq_range(in)

 Inputs      : IN = 2xn array to search

 Outputs     : OUT = unique pairs (dimensioned 2xm) sorted by value in first column

 Optional Out: SORDER = sorting index

 Keywords    : COUNT: # of uniq values

 CALLS: ***
	EXIST, ROWSORT, UNIQ_RANGE
 History     : Extended from get_uniq by Kim Tolbert, 12-Jan-2005
               Originally written 20 Sept 1999, D. Zarro, SM&A/GSFC

 Modifications


get_user [1] $SSW/gen/idl/system/get_user.pro
[Previous] [Next]
  NAME:
      get_user

  PURPOSE:
      Find out the name of the user as defined by the environment
      variable USER

  INPUT PARAMETERS:
	None.

  OUTPUT PARAMETERS:
	Returned value is the interpretted USER value.

  PROCEEDURE:
	Spawn a child process and pipe the result back.

 CALLED BY:
	NET_DIR_DIFF, SET_PS, check_oldprocess [1], check_oldprocess [2]
	check_oldprocess [3], check_oldprocess [4], check_process [1]
	check_process [2], color_copy, diskbench, evt_demo, ftp_copy [1], ftp_copy [2]
	go_batch [1], go_batch [2], go_yo_prod_batch, html_basics, html_doc
	idl_server_control, killold [1], killold [2], laststat [1], laststat [2]
	make_mirror, mk_mdi_iap, mk_sfc [1], mk_sfc [2], mk_ssc_batch [1]
	mk_ssc_batch [2], mo_check, mo_patch, mobad_summ, modvolume_inf [1]
	modvolume_inf [2], pr_status [1], pr_status [2], ref_term [2], save_idl_routines
	search_obs, soon_search [1], soon_search [3], ssw_conflicts, ssw_install [2]
	ssw_start_rpcserver, ssw_upgrade [1], ssw_upgrade [2], ssw_upgrade_backup
	sswdb_upgrade, sxt_html, trace_special_movie [2], trace_special_movie [3]
	write_access [1], write_access [2], xset_chain [1], xset_chain [2], xso_search
	xsw2tree, xsw2tree_event, xswlist [2], xsxt_prep, ydb_install [1], ydb_install [2]
  HISTORY:
	Written, 14-jan-92, JRL
                 4-oct-94, SLF - spawn 'whoami' first, then try the old
				  printenv if USER not defined
                                 (protect against loud .cshrc files)
                20-aug-97, SLF - extend to vms (per D.Zarro, get_user_id)
                22-Jun-00, RDB - if none set, make user "windows" under windows


GET_USER_ID $SSW/gen/idl/system/get_user_id.pro
[Previous] [Next]
 Project     : SOHO - CDS     
                   
 Name        : GET_USER_ID
               
 Purpose     : return user name and host 
               
 Category    : utility
               
 Explanation : 
               
 Syntax      : IDL> user_id=get_user_id()

 Inputs      : None
               
 Outputs     : USER_ID, e.g. zarro@smmdac.nascom.nasa.gov
               
 CALLS: ***
	CHKLOG [1], CHKLOG [2], ESPAWN, EXIST, OS_FAMILY, TRIM
 CALLED BY:
	APPLY_LOCK, CHECK_FTP, CHECK_LOCK, EIT_SYS, FTP_SYNOP, FTP__DEFINE, SMART_FTP
	UPDATE_SOHO_TARGETS
 History     : Version 1,  17-Aug-1996,  D M Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GET_UTAXIS $SSW/gen/idl/utplot/get_utaxis.pro
[Previous] [Next]
 PROJECT:
	SDAC	
 NAME: 
	GET_UTAXIS

 PURPOSE:
	This function returns the system variable axis structures set and hidden
	by UTPLOT (SET_UTPLOT).

 CATEGORY:
	Plotting, UTIL, UTPLOT

 CALLING SEQUENCE:
	axis_structure = get_utaxis() for !x.
	axis_structure = get_utaxis( /XAXIS ) for !x.
	axis_structure = get_utaxis( /YAXIS ) for !y.
	axis_structure = get_utaxis( /ZAXIS ) for !z.
	axis_structure = get_utaxis( /PLOT  ) for !p.

 CALLS:
	none
 INPUTS:
       none explicit, only through commons;

 OPTIONAL INPUTS:
	none

 OUTPUTS:
       none explicit, only through commons;

 OPTIONAL OUTPUTS:
	none

 KEYWORDS:
	XAXIS - if set return, saved !x
	YAXIS
	ZAXIS
	PLOT
 CALLED BY:
	SET_UTAXIS
 COMMON BLOCKS:
	store_plotvar

 SIDE EFFECTS:
	none

 RESTRICTIONS:
	Only 1 structure may be restored at a time, precedence, X, Y, Z, P.

 PROCEDURE:
	none

 MODIFICATION HISTORY:
	Version 1, richard.schwartz@gsfc.nasa.gov, 27-jan-1998, on a suggestion
	from DMZ to better support calls to AXIS.


GET_UTC $SSW/gen/idl/time/get_utc.pro
[Previous] [Next]
 Project     :	SOHO - CDS

 Name        :	GET_UTC

 Purpose     :	Gets the current date/time in UTC.

 Explanation :	This procedure uses the IDL SYSTIME() function to calculate
		the current UTC date/time, and formats it into one of the CDS
		standard UTC time formats.  For notes on various time formats,
		see file aaareadme.txt.

 Use         :	GET_UTC, UTC
		GET_UTC, UTC, /EXTERNAL
		GET_UTC, UTC, /CCSDS
		GET_UTC, UTC, /ECS

 Inputs      :	None.

 Opt. Inputs :	None.

 Outputs     :	UTC  = The UTC current calendar time in one of several formats,
		       depending on the keywords passed.

			Internal:  A structure containing the tags:

				MJD:	The Modified Julian Day number.
				TIME:	The time of day, in milliseconds since
					the beginning of the day.

				   Both are long integers.  This is the default
				   format.

			External:  A structure containing the integer tags
	"18-JAN-1988 17:20:43.12", "18-JAN-1988 17:20:43.123"
	"1988-01-18T17:20:43.123Z", "1988/01/18 17:20:43.123"
	CCSDS:	   An ASCII string containing the UTC time to, DAY
	ECS:	   Similar to CCSDS, HOUR, MILLISECOND., MINUTE, MONTH, SECOND
	STIME:	   The date and time has the format
	See UTC2STR for more information, VMS:	   The date and time has the format
	YEAR, and, e.g., except that the date has, for Space Data Systems (ISO 8601)
	millisecond accuracy in the format
	recommended by the Consultative Committee, the format:
 Opt. Outputs:	None.

 Keywords    :	EXTERNAL = If set, then the output is in external format, as
			   explained above.

		CCSDS	 = If set, then the output is in CCSDS format, as
			   explained above.

		ECS	 = If set, then the output is in ECS format, as
			   explained above.

		VMS	  = If set, then the output will be in VMS format, as
			    described above.

		STIME	  = If set, then the output will be in STIME format, as
			    described above.

		The following keywords are only valid if one of the string
		formats is selected.

		TRUNCATE  = If set, then the time will be truncated to 1 second
			    accuracy.  Note that this is not the same thing as
			    rounding off to the nearest second, but is a
			    rounding down.

		DATE_ONLY = If set, then only the date part of the string is
			    returned.

		TIME_ONLY = If set, then only the time part of the string is
			    returned.

		UPPERCASE = If set, then the month field in either the VMS or
			    STIME format is returned as uppercase.

		NOZ	  = When set, the "Z" delimiter (which denotes UTC
			    time) is left off the end of the CCSDS/ISO-8601
			    string format.  It was decided by the FITS
			    committee to not append the "Z" in standard FITS
			    keywords.

		The following keyword is always valid.

		ERRMSG   = If defined and passed, then any error messages will
			   be returned to the user in this parameter rather
			   than using the IDL MESSAGE utility.  If no errors
			   are encountered, then a null string is returned.
			   In order to use this feature, the string ERRMSG
			   must be defined first, e.g., 

				ERRMSG = ''
				GET_UTC, UTC, ERRMSG=ERRMSG
				IF ERRMSG NE '' THEN ...


 Calls       : ***
	FIND_WITH_DEF [1], FIND_WITH_DEF [2], FIND_WITH_DEF [3], INT2UTC
 CALLED BY:
	ADD_CDS_POINT, ADD_EFFICIENCY, ADD_EFF_AREA, ADD_EXPER, ADD_EXP_COMM, ADD_MAIN
	ADD_MIRSHIFT, ADD_TILTCAL, ADD_WAVECAL, ADD_WAVE_EFF, ANYTIM2UTC [1]
	ANYTIM2UTC [2], ARCMIN2HEL, ARCMIN2HEL2, BBSO__DEFINE, CALC_RAS_DUR, CDS_FILES
	CDS_SLIT6_BURNIN, CHECK_EXP_FACTOR_DUPS, CHECK_KAP, CHECK_LOCK
	CHECK_OBESUMERROR, CHECK_PRO_NAMES, CHIANTI_NE, CHIANTI_TE, CH_LINE_LIST
	CNVRT_MSPTIME, COMB_FULL_EQ, CONGRID [1], CONGRID [2], DAYS2LAUNCH
	DISPLAY_CDS_BURNIN, DOY2UTC, DROT_COORD, DROT_RASTER, EIS_CAT [1], EIS_CAT [2]
	EIS_CPT_NOW [1], EIS_CPT_NOW [2], EIS_FITS_DATAID [1], EIS_FITS_DATAID [2]
	EIS_FOV [1], EIS_FOV [2], EIS_IMAGE_TOOL [1], EIS_IMAGE_TOOL [2]
	EIS_IMAGE_TOOL_EVENT [1], EIS_IMAGE_TOOL_EVENT [2], EIS_MKFITS [1]
	EIS_MKFITS [2], EIT_SUBFIELD, EXPORT_PLAN, EXPORT_STUDY, FAKE_POINT_STC
	FILE_DATE_MOD, FIND_DURATION, FIND_FID, FIX2IMGS, FIX_IAP, FTP_BBSO, FTP_KISF
	FTP_MLSO_IMAGES, FTP_MWSO, FTP_NOBE, FTP_SYNOP, GET_EXP_FACTOR [1]
	GET_EXP_FACTOR [2], GET_FID, GET_FITS_TIME, GET_GEV, GET_LATEST_IAP, GET_NAR
	GET_NOAA, GET_OBS_DATE, GET_RECENT_EIT, GET_SC_POINT, GET_SID, GET_SOHO_ROLL
	GET_SUMER_FILES, GET_SYNOPTIC, GET_WAVECAL, GOES__DEFINE, HASTA__DEFINE, HC_SINCE
	HEL2ARCMIN [1], HEL2ARCMIN [2], HFITS__DEFINE, HTML_SPLAN, HXRS__DEFINE
	IMAGE_TOOL, IMAGE_TOOL_EVENT, ITOOL_DIFF_ROT, ITOOL_GET_TIME, ITOOL_NEW_CSI
	ITOOL_PICKFILE, ITOOL_RD_GIF, KANZ__DEFINE, KDATE, KISF__DEFINE, LAT2Y, LATEST_IMAGE
	LIST_DURATION, LOAD_TP_STRUCT, LOAD_WAVECAL, LOCATE_FFCAL, MAKE_DAILY_IMAGE
	MAKE_MAP, MEUDON__DEFINE, MK_ALL_MIN, MK_CDS_PLAN, MK_DAILY_C1_MED, MK_DAILY_MED
	MK_DAILY_MIN, MK_HEAD_CAT, MK_PLAN_HTML, MK_PLAN_PRIV, MK_PLAN_RECAL, MK_POINT_STC
	MK_RASTER, MK_SOHO, MK_SOHO_TARGET, MK_SUMMARY, MK_WAVECAL, MOD_EXPER, MOD_MAIN
	MONITOR_EXP, MONITOR_EXP_IMG, NANCAY__DEFINE, NOBE__DEFINE, OBS__DEFINE
	OVSA_LTC_DEFINE, PB0R, PLOT_EXP_FACTOR, PLOT_HELIO [1], PLOT_HELIO [2], PLOT_HKLZ
	PLOT_SPLAN, PRED_PROG_NUM, QCALIB, QTILT, RASTER_DUR, RD_IMAGE_GIF, READCDSFITS
	READ_MERGED_DSN, READ_MSP_FILE, REDUCE_IMAGE, REDUCE_LEVEL_05, REDUCE_LEVEL_1
	REDUCE_MAIN, REDUCE_TRANSFER, ROT_XY, RSTN__DEFINE, RTMOVIE, RTMVI [1], SCAN_SC_HDR
	SHOW_CDHS, SHOW_PLAN, SHOW_SYNOP__DEFINE, SOHO_ITEMS_HTML, SPLIT_QKL, ST_SUMER
	SUBFIELD_EV, SYNOP_PATH, SYNSCAN, TP_WRT_IEF, UNPACK_ALL_SCIENCE
	UNPACK_LZ_SCIENCE, UNPACK_REDUCE_MAIN, UPDATE_CAMPAIGN, UPDATE_CDS_TARGETS
	UPDATE_IAP, UPDATE_KAP, UPDATE_MM, UPDATE_MPG, UPDATE_SOHO_TARGETS, VDS_ROTATE
	WHERE_OFF_LIMB, WPLOT_NONOP, WPLOT_SUBHTR [2], WRITE_CAP, WRITE_CIF, WRITE_IAP
	XCALENDAR, XCAMP, XCAT, XCLONE_PLAN, XCPT, XGET_SYNOPTIC, XGET_UTC, XIAP, XPLOT_HT, XPORT
	XREPORT, XREPORT_EDIT, ch_ss
	cmap2gif ftsfile maxdmind ROOTroot CONTROLcontrol, db_gbo
	eis_db_save_gui [1], eis_db_save_gui [2], eis_get_current_time [1]
	eis_get_current_time [2], eis_get_events_filename [2]
	eis_get_events_filename [4], eis_mk_plan_gui [1], eis_mk_plan_gui [2]
	eis_timeline_graphics_axes_default [1]
	eis_timeline_graphics_axes_default [2], get_def_times, get_ovsa_log
	get_survey, hsi_obs_times, laser8ew
	rt_carrmapmaker yymmdd num_r rad limb wlimb hdr disp saveset nextrot
	setup_params [1], setup_params [2], soho_fac, specread__DEFINE, trieste__DEFINE
 Common      :	Uses the internal common block LOCAL_DIFF to store information
		between calls.  This common block is shared with the routine
		LOCAL_DIFF.

 Restrictions:	This routine depends on the behavior of IDL's SYSTIME function.
		Currently, it is believed that this routine will return the
		time in UTC on all properly configured Unix systems.  However,
		the result may be different in other operating systems; e.g. on
		VMS and MacIntosh computers it gives the local time instead.
		It is believed to work correctly in IDL for Windows.

		In order to get around this difficulty, the file
		"local_diff.dat" can be placed in the directory given by the
		environment variable TIME_CONV.  If this file exists, then this
		program will read the value (local-UTC in hours) from this file
		and use it as a correction factor.  For example, for U.S.
		Eastern Standard Time, this file would contain the value -5.
		(See local_diff.pro for more information.)  This means then,
		that this file must contain the correct value, and must be
		updated to reflect changes between standard and daylight
		savings time.

		On the other hand, if the second line in the "local_diff.dat"
		file reads "GMT", then it is assumed that the computer is
		running on GMT instead of local time, and no correction is
		made.

		The file local_diff.dat is only read once.  The contents are
		stored in a common block between calls.  Once a day, the file
		is reread.

		The accuracy of the time returned by this routine depends on
		that of the computer's system clock.

 Side effects:	None.

 Category    :	Utilities, time.

 Prev. Hist. :	None.  However, the concept of "internal" and "external" time
		is based in part on the Yohkoh software by M. Morrison and G.
		Linford, LPARL.

 Written     :	William Thompson, GSFC, 21 September 1993.

 Modified    :	Version 1, William Thompson, GSFC, 21 September 1993.
		Version 2, William Thompson, GSFC, 3 November 1994
			Added test for "local_diff.dat" file.
		Version 3, William Thompson, GSFC, 14 November 1994
			Added test for "GMT" line in "local_diff.dat" file
			Changed .DAY to .MJD
		Version 4, William Thompson, GSFC, 17 November 1994
			Fixed bug introduced in version 3
		Version 5, William Thompson, GSFC, 20 December 1994
			Added keywords TRUNCATE, DATE_ONLY, TIME_ONLY
		Version 6, Donald G. Luttermoser, GSFC/ARC, 20 December 1994
			Added the keyword ERRMSG.
		Version 7, William Thompson, GSFC, 25 January 1995
			Changed to call intrinsic ROUND instead of NINT.  The
			version of NINT in the Astronomy User's Library doesn't
			automatically select between short and long integers as
			the CDS version does.
		Version 8, Donald G. Luttermoser, GSFC/ARC, 30 January 1995
			Added ERRMSG keyword to internally called procedures.
			Made the error handling procedures more robust.
		Version 9, William Thompson, GSFC, 14 March 1995
			Added keywords VMS, STIME, UPPERCASE
		Version 10, William Thompson, GSFC, 15 March 1995
			Changed CDS_TIME to TIME_CONV
		Version 11, William Thompson, GSFC, 2 June 1997
			Store information between calls in common block.
		Version 12, William Thompson, GSFC, 17 September 1997
			Added keyword NOZ.

 Version     :	Version 12, 17-Sep-1997


get_utevent [1] $SSW/gen/idl/utplot/get_utevent.pro
[Previous] [Next]
   Name: get_utevent
  
   Purpose: return time ranges for various Yohkoh events - optionally use
   	     the current utplot range for start and stop
             (from fem, gev, evn, or observing log depending on keyword set)

   Input Parameters:
      starttime, stoptim - [Optional] Time range to search for events

   Keyword Parameters:
      goes  - if set, all goes events
      above - if set, goes events above this level
      ksc,canberra,goldstone,madrid - if set, return contact info (only one)
      flaremode - if set, occurences of Yohkoh flare mode
      visible - if set, return start/stop time of Yohkoh VISIBLE orbits      
      info - (output) - optional text descriptor
      window - if set, search +/- this many hours
      utrange - if set, return current UTPLOT start and stop in p1/p2

   Calling Sequence:
      get_utevent, t0, t1, eventstart, eventstop, $
		[,/ksc, /goes, /day, /night, /saa, /flaremode, /visible, info=info]

      get_utevent, eventstart, eventstop, $
		[,/ksc, /goes, /day, /night, /saa, /flaremode, info=info]
 
      This second form will use current UTPLOT range.

   Calling Examples:
      get_utevent, strs, stps, /ksc	   ; ksc times in current UTPLOT range
      get_utevent, strs, stps, /saa 	   ; saa times ""       ""   ""
      get_utevent, strs, stps, /flare	   ; yohkoh flare modes ""   ""
      get_utevent, strs, stps, /goes	   ; all goes events
      get_utevent, strs, stps, goes='c'	   ; times for goes events >= C level
      get_utevent, strs, stps, /visible   ; visible passes 
      get_utevent, t0, t1, /utrange	   ; return current UTPLOT range -> t0/t1
      get_utevent, ffi, /sxtf		   ; FFI times (from observing log)

   Can be used in conjunction with evt_grid to annotate current utplot
      utplot....			   ; some utplot
      get_utevent, strs, stps, /ksc	   ; get times for KSC
      evt_grid, [strs,stps]		   ; overlay KSC times on current UTPlot
  
 CALLED BY:
	fem_grid [1], fem_grid [2], goes_widget, pfi_dominant, search_obs, show_contacts
	ssw_apkpbar, sxt_adjacent_image
   History:
      22-Sep-1994 (SLF) - evt_grid / utplot annotation assistance
      23-Sep-1994 (SLF) - added DAYS, NIGHTS, SAAS keywords
      26-Sep-1994 (SLF) - change name from get_event to get_utevent
			   (avoid name conflict)
       3-Jan-1995 (SLF) - add observing log keywords (SXTF,SXTP,BCS,HXT,WBS)
      12-Jan-1995 (SLF) - add /quiet to rd_obs calls
      10-apr-1995 (SLF) - allow preexisting window for /init option
      22-oct-1996 (SLF) - add /VISIBLE keyword & function (call get_visible)
       7-feb-1997 (SLF) - protect against alternating string/structure
                          start and stop time entries
      09-May-2003, William Thompson - Use ssw_strsplit instead of strsplit
  
 CALLS: ***
	GETUT [1], GETUT [2], UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5]
	UTPLOT [6], WDEF [1], WDEF [2], anytim [1], anytim [2], anytim [3], anytim [4]
	anytim [5], anytim2ints [1], anytim2ints [2], anytim2weekid [1]
	anytim2weekid [2], contacts [1], contacts [2], data_chk [1], data_chk [2]
	fmt_tim [1], fmt_tim [2], get_visible, gt_dp_mode [1], gt_dp_mode [2], rd_obs
	sel_timrange [1], sel_timrange [2], ssw_strsplit, str2cols [1], str2cols [2]
	tbeep [1], tbeep [2], tbeep [3], timegrid
   Common Blocks:
      get_utevent_blk1, get_utevent_blk2 - avoid repeated calls for same
                                           dbase/time combinations


get_utevent [2] $SSW/gen/idl_fix/soft/old310/get_utevent.pro
[Previous] [Next]
   Name: get_utevent
  
   Purpose: return time ranges for various Yohkoh events - optionally use
   	     the current utplot range for start and stop
             (from fem, gev, evn, or observing log depending on keyword set)

   Input Parameters:
      starttime, stoptim - [Optional] Time range to search for events

   Keyword Parameters:
      goes  - if set, all goes events
      above - if set, goes events above this level
      ksc,canberra,goldstone,madrid - if set, return contact info (only one)
      flaremode - if set, occurences of Yohkoh flare mode
      
      info - (output) - optional text descriptor
      window - if set, search +/- this many hours
      utrange - if set, return current UTPLOT start and stop in p1/p2

   Calling Sequence:
      get_utevent, t0, t1, eventstart, eventstop, $
		[,/ksc, /goes, /day, /night, /saa, /flaremode, info=info]

      get_utevent, eventstart, eventstop, $
		[,/ksc, /goes, /day, /night, /saa, /flaremode, info=info]
 
      This second form will use current UTPLOT range.

   Calling Examples:
      get_utevent, strs, stps, /ksc	   ; ksc times in current UTPLOT range
      get_utevent, strs, stps, /saa 	   ; saa times ""       ""   ""
      get_utevent, strs, stps, /flare	   ; yohkoh flare modes ""   ""
      get_utevent, strs, stps, /goes	   ; all goes events
      get_utevent, strs, stps, goes='c'	   ; times for goes events >= C level
      get_utevent, t0, t1, /utrange	   ; return current UTPLOT range -> t0/t1
      get_utevent, ffi, /sxtf		   ; FFI times (from observing log)

   Can be used in conjunction with evt_grid to annotate current utplot
      utplot....			   ; some utplot
      get_utevent, strs, stps, /ksc	   ; get times for KSC
      evt_grid, [strs,stps]		   ; overlay KSC times on current UTPlot
  
 CALLED BY:
	fem_grid [1], fem_grid [2], goes_widget, pfi_dominant, search_obs, show_contacts
	ssw_apkpbar, sxt_adjacent_image
   History:
      22-Sep-1994 (SLF) - evt_grid / utplot annotation assistance
      23-Sep-1994 (SLF) - added DAYS, NIGHTS, SAAS keywords
      26-Sep-1994 (SLF) - change name from get_event to get_utevent
			   (avoid name conflict)
       3-Jan-1995 (SLF) - add observing log keywords (SXTF,SXTP,BCS,HXT,WBS)
      12-Jan-1995 (SLF) - add /quiet to rd_obs calls
       9-apr-1995 (SLF) - support old IDL (pre keyword inherit)
  
 CALLS: ***
	GETUT [1], GETUT [2], UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5]
	UTPLOT [6], WDEF [1], WDEF [2], anytim [1], anytim [2], anytim [3], anytim [4]
	anytim [5], anytim2ints [1], anytim2ints [2], anytim2weekid [1]
	anytim2weekid [2], contacts [1], contacts [2], data_chk [1], data_chk [2]
	fmt_tim [1], fmt_tim [2], get_visible, gt_dp_mode [1], gt_dp_mode [2], rd_obs
	sel_timrange [1], sel_timrange [2], ssw_strsplit, str2cols [1], str2cols [2]
	tbeep [1], tbeep [2], tbeep [3], timegrid
   Common Blocks:
      get_utevent_blk1, get_utevent_blk2 - avoid repeated calls for same
                                           dbase/time combinations


get_utrange $SSW/gen/idl/time/get_utrange.pro
[Previous] [Next]
 NAME:   
      get_utrange
 PURPOSE:
      get user to enter UT start and end times
 CATEGORY:
      GEN
 CALLING SEQUENCE:
      get_utrange,utbase,dstart,dend
 INPUTS:
      utbase  - UT base time
 OUTPUTS:
      dstart,dend - requested start and end times
 CALLS: ***
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
 CALLED BY:
	RD_EXB, mksort
 RESTRICTIONS:
      input times must be in UT format YY/MM/DD, HHMM:SS.MSEC
      (date is optional, and defaults to UTBASE)
 HISTORY:
      written DMZ (ARC Apr'93)


get_uvxsections $SSW/gen/idl/spectra/get_uvxsections.pro
[Previous] [Next]
   Name: get_uvxsections

   Purpose: return UV/EUV xsections for input lambda, O, N2, and O2

   Input Parameters:
      lambda - desired wavelength(s)
  
   Output Parameters:
      O  - corresponding atomic Oxygen X-section Units: 10^-18/cm^2
      N2 - corresponding Nitrogen X-section       ""      ""
      O2 - corresponding Oxygen   X-section       ""      ""

   Keyword Parameters:

   Calling Seqeunce:
      get_uvxsection, lambda, O, N2, O2
  
 CALLS: ***
	BOX_MESSAGE, CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], FILE_EXIST [2]
	INTERPOL, STRTAB2VECT, concat_dir [4], file_exist [1], file_exist [3]
	rd_tfile [1], rd_tfile [2], str2cols [1], str2cols [2]
   History:
      31-March-2000 - S.L.Freeland

   Method:
      Uses data supplied by Roger Thomas which is contained in
      $SSW/gen/data/spectra/uv_xsections.dat (inc. source info)
      Output (xsections) are interpolated according to that table


GET_VIEWPORT [1] $SSW/gen/idl/display/get_viewport.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : 
	GET_VIEWPORT
 Purpose     : 
	Gets current viewport values, in device coordinates.
 Explanation : 
	Gets the current values of the viewport, in the form of the
	old-fashioned variables !SC1, !SC2, !SC3, and !SC4.  This supports
	those routines that were originally developed for IDL version 1.

	The routine calculates the system variables by generating a dummy plot
	without actually drawing to the screen.

 Use         : 
	GET_VIEWPORT, SC1, SC2, SC3, SC4
 Inputs      : 
	None.
 Opt. Inputs : 
	None.
 Outputs     : 
	SC1, SC2, SC3, SC4 are the device coordinates of the viewport.
 Opt. Outputs: 
	None.
 Keywords    : 
	CHARSIZE = Character size to take into account when calculating plot
		   size.
 Calls       : 
	None.
 CALLED BY:
	SETIMAGE, SETSCALE [1], SETSCALE [2], SET_SERTSW
 Common      : 
	None.
 Restrictions: 
	In general, the SERTS graphics devices routines use the special system
	variables !BCOLOR and !ASPECT.  These system variables are defined in
	the procedure DEVICELIB.  It is suggested that the command DEVICELIB be
	placed in the user's IDL_STARTUP file.

 Side effects: 
	None.
 Category    : 
	Utilities, Devices.
 Prev. Hist. : 
	William Thompson, November 1992.
	William Thompson, November 1992, modified to get parameters by
		generating a dummy plot rather than calculating directly, so as
		to be compatible with !P.MULTI.
	William Thompson, December 1992, corrected bug where certain system
		variables were being changed by this routine.
 Written     : 
	William Thompson, GSFC, November 1992.
 Modified    : 
	Version 1, William Thompson, GSFC, 27 April 1993.
		Incorporated into CDS library.
	Version 2, William Thompson, GSFC, 12 January 1994.
		Modified to avoid problems that may arise when !X.STYLE or
		!Y.STYLE is not zero.
	Version 3, William Thompson, GSFC, 8 October 1996
		Added keyword CHARSIZE
	Version 4, 14-May-2001, William Thompson, GSFC
		Use modern system variables.
 Version     : 
	Version 4, 14-May-2001


get_wtype [1] $SSW/gen/idl/widgets/get_wtype.pro
[Previous] [Next]
 NAME:
	get_wtype
 PURPOSE:
       get widget type
 CALLING SEQUENCE:
	wtype=get_wtype(event)
 INPUTS:
       event = widget event number
 OUTPUTS:
       wtype=type of widget (base, button, slider, etc)
 PROCEDURE
       examines tag names in event and widget_id structures
 CALLS: ***
	WIDG_TYPE
 HISTORY:
       Zarro (ARC) - written Oct'93


get_xfont [1] $SSW/gen/idl/genutil/get_xfont.pro
[Previous] [Next]
   Name: get_xfont

   Purpose: return font (front end filter to device,get_font=)

   Input Parameters: 
      pattern - font pattern to match

   Keyword Parameters:
      only_one - return one match as a scaler string 
      fixed    - if set, only fixed sized fonts (example: for table output)
      closest  - if set, font size (select closest size to this if mulitple)

 CALLS: ***
	str2number [1], str2number [2], str_replace [1], str_replace [2], strsplit
 CALLED BY:
	CHOOSE_FL, disp_gen [1], disp_gen [2], favviewer, set_font, show_pix [1]
	show_pix [2], verify_gui, xanal_emi, xcheckip, xdate [1], xdate [2], xdisp_fits
	xdisp_sci5k, xdisp_tfr, xdisp_trace [1], xdisp_trace2, xdisp_trace3, xgen_widget
	xhkplot, xread_hist, xsearch_obs, xset_chain [1], xset_chain [2], xspr [1], xspr [2]
	xwrite_hist
   History:
       25-mar-95 (SLF) 
	10-Apr-95 (MDM) - Fixed a typo "xfont" versus "xfonts"
        2-May-95 (SLF) - font format protections (call str2number)
      09-May-2003, William Thompson - Use ssw_strsplit instead of strsplit


GET_XWIN [1] $SSW/gen/idl/display/get_xwin.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GET_XWIN

 Purpose     : get a free X-window

 Category    : imaging

 Explanation : 

 Syntax      : get_xwin,index

 Inputs      : INDEX - window index to get
               If input window INDEX is available then corresponding window
               will become active, otherwise a new window is opened

 Keywords    : XSIZE,YSIZE = window size [def = 512,512]
               RETAIN = retain backing store [def = 2]
               XPOS,YPOS = window position [def = 0,0]
               TITLE = window title [def = '']
               FREE  = get next free window
               NOSHOW = don't call WSHOW
               NEW = get new window with specified INDEX
               NORESIZE = if set, resized windows are treated as new windows

 CALLS: ***
	ALLOW_WINDOWS, DATATYPE [1], DATATYPE [2], DATATYPE [3], DPRINT, EXIST, WSHOW2
	is_number [1], is_number [2]
 CALLED BY:
	MK_PLAN_PLOT, PLOT_MAP
	PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support
	hsi_vis2pmap
 History     : Written 22 October 1996, D. Zarro, ARC/GSFC
               Modified, 20 May 2000, Zarro (EIT/GSFC) 
               Modified, 13 Dec 2001, Zarro (EITI/GSFC) - added ALLOW_WINDOWS call

 Contact     : dzarro@solar.stanford.edu


get_xwin [2] $SSW/gen/idl/display/get_xwin.pro
[Previous] [Next]

pro get_xwin,index,xsize=xsize,ysize=ysize,free=free,err=err,$
             ypos=ypos,xpos=xpos,retain=retain,title=title,draw=draw,$
             noshow=noshow,new=new,_extra=extra,noresize=noresize

err=''
do_windows=(!d.name ne 'Z') and (!d.name ne 'PS')
if not do_windows then begin
 if not exist(index) then index=-1 & return
endif

if not allow_windows() then begin
 err='Unable to open window'
 if not exist(index) then index=-1
 return
endif

if n_elements(retain) eq 0 then retain=2
if n_elements(xpos) eq 0 then xpos=0
if n_elements(ypos) eq 0 then ypos=0
if datatype(title) ne 'STR' then title=' '

case 1 of
 exist(xsize) and (not exist(ysize)): begin
  dxsize=xsize(0) & dysize=xsize(0)
 end
 (not exist(xsize)) and exist(ysize): begin
  dxsize=ysize(0) & dysize=ysize(0)
 end
 exist(ysize) and exist(xsize) : begin
  dxsize=xsize(0) & dysize=ysize(0)
 end
 else: begin
  dxsize=512 & dysize=512
 end
endcase

if keyword_set(free) then begin
 dwin=-1 & goto,done
endif

 CALLS:
 CALLED BY
	MK_PLAN_PLOT, PLOT_MAP
	PLOT_MAP2 WARNINGTEMPORARY FIX ONLY FOR 16 bit ZBuffer support
	hsi_vis2pmap


get_ymd $SSW/gen/idl/time/get_ymd.pro
[Previous] [Next]
 Project     : HESSI

 Name        : get_ymd

 Purpose     : return YYMMDD part from filename

 Category    : utility 

 Syntax      : IDL> get_ymd,file,ymd,hms

 Inputs      : FILE = string array of filenames 
                      (e.g. kpno_fd_20010601_0111.fits)

 Outputs     : YMD = yymmdd string (e.g. 200110601)

 Opt. Outputs: HMS = hhmmss (e.g. 121204)

 Keywords    : FULL = include full year [def is 01 instead of 2001]

 CALLS: ***
	IS_BLANK
 CALLED BY:
	MDI_COPY
 History     : Written 1 Aug 2001, D. Zarro (EITI/GSFC)

 Contact     : dzarro@solar.stanford.edu


GET_ZDBASE $SSW/gen/idl/database/get_zdbase.pro
[Previous] [Next]
 Project     : SOHO - CDS     
                   
 Name        : GET_ZDBASE
               
 Purpose     : set ZDBASE file appropriate CDS/USER/SOHO Database location
               
 Category    : Planning
               
 Explanation : 
               
 Syntax      : IDL> get_zdbase,file
    
 CALLED BY:
	LOCK_ZDBASE, UNLOCK_ZDBASE
 Examples    : 

 Inputs      : DBFILE = string file name to search for (e.g. 'main.dbf')
               
 Opt. Inputs : None
               
 Outputs     : FILE = full path name to DB file

 Opt. Outputs: None
               
 Keywords    : STATUS = 1 if fil DB found, 0 if unsuccessful
               ERR  = any error string
               /CAT = set to look for catalog DB
               /DEF = set to look for study definitions DB [default]
               /DAI = set to look for plan DB
               /RES = set to look for resources (e.g. campaign, etc)

 CALLS: ***
	DATATYPE [1], DATATYPE [2], DATATYPE [3], EXIST, FIND_WITH_DEF [1]
	FIND_WITH_DEF [2], FIND_WITH_DEF [3], TRIM, WHERE_VECTOR
 Common      : None
               
 Restrictions: None
               
 Side effects: None
               
 History     : Version 1,  7-September-1996,  D M Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


get_zenang $SSW/gen/idl/solar/get_zenang.pro
[Previous] [Next]
   Name: get_zenang

   Purpose: Return solar Zenith angle (see ssw_pos2zenith wrapper)

   Input Parameters:
      item - something containing a UT time, any SSW format
      lat,lon - latitude and longitude (westward negative) in degrees

   Output:
      function returns solar zenith angle - degrees is default

   Keyword Parameters:
      radians - if set, function returns angle in radians
      degrees - if set, function returns angle in degrees (DEFAULT)
  
 CALLS: ***
	CT2LST, SUNPOS, TIM2JD [1], TIM2JD [2]
 CALLED BY:
	ssw_pos2zenith
   History:
      16-March-2000 - G.L.Slater, LMSAL
      16-March-2000 - S.L.Freeland, LMSAL some doc, made DEGREES default
       6-April-2000 - incorporate Roger J. Thomas modifications


GETFILES $SSW/gen/idl/system/getfiles.pro
[Previous] [Next]
 NAME:
	GETFILES
 PURPOSE:
	Prompt the user to interactively specify a list of files
 EXPLANATION:
	User can specify a single file per line or a range of files 
	separated by a dash or comma.    Used, for example, by FITSRD to
	return a list of file numbers on tape to read

 CALLING SEQUENCE:
	getfiles, list

 OUTPUT:
	LIST - integer array containing file numbers

 SIDE EFFFECTS:
	User will be prompted to enter a list of file numbers

 REVISION HISTORY
	Written D. Lindler November, 1985
	Converted to Version 2 IDL,  August 1990
	Converted to IDL V5.0   W. Landsman   September 1997
 CALLED BY
	BIGPICKFILE, CDSPICKFILE, FXTAPEREAD, FXTAPEWRITE, PICKFILE


GETLOG [1] $SSW/gen/idl/system/getlog.pro
[Previous] [Next]
 NAME:
     GETLOG
 PURPOSE:
     Formats a logical directory for the given operating system.

 CALLING SEQUENCE:
     result = GETLOG(lname)

 INPUTS:
     lname   - the base name of the logical (without special characters).

 OUTPUTS:
     Returns appropriate string.
     Under VMS the logical is not translated since it may correspond to
     multiple directories.    

 RESTRICTIONS:
     Assumes that the directory logical will have meaning to the host
     operating system.
 PROCEDURE:
       The operating system in !version.os_family is checked. If it equals:

               'vms'           then a ':' is appended.
               'windows'       directory name is translated with GETENV()
                               and a '\' is appended
               'unix'          directory name is translated with GETENV()
                               and a '/' is appended
               'MacOS'         directory name is translated with GETENV()

 EXAMPLE:
       Open the file 'stars.dbh' in the logical directory ZDBASE in an 
       operating system independent way:
               IDL> openr,1,getlog('ZDBASE') + 'stars.dbh'

 MODIFICATION HISTORY:
       Written, JDNeill, May, 1990.
       Modified, JDNeill,Sep, 1990 -- for unix return full path instead of
               just environment variable name.
       Modified, I. Freedman, HSTX April 1994 -- for MacOS return full path
       Bug in CASE statement fixed.    JDO, HSTX, May 2 1994.
       Added Windows compatibility  W. Landsman      September 1995
       Converted to IDL V5.0   W. Landsman   September 1997


GETOPT $SSW/gen/idl_libs/astron/misc/getopt.pro
[Previous] [Next]
 NAME:
	GETOPT
 PURPOSE:
	Convert a string supplied by the user into a valid scalar or vector
 EXPLANATION:
	Distinct elements in the string may be
	separated by either a comma or a space.  The output scalar
	or vector can be specified to be  either  integer or floating
	point.   A null string is converted to a zero.   
 CALLING SEQUENCE:
     option = GETOPT( input, [ type, numopt, COUNT = ])

 INPUTS:
	input   - string that was input by user in response to a prompt
		Arithmetic operations can be included in the string (see
		examples)

 OPTIONAL INPUTS:
	type    - Either an "I" (integer) or an "F" (floating point) specifying 
		the datatype of the output vector.  Default is floating point

	numopt  - number of values expected by calling procedure
		If less than NUMOPT values are supplied the output
		vector will be padded with zeros.  
 OUTPUTS:
	option  - scalar or vector containing the numeric conversion of
		the fields in the string INPUT.  If NUMOPT is not
		supplied, the number of elements in OPTION will 
		equal the number of distinct fields in INPUT.
 OPTIONAL INPUT KEYWORD:
       Count - integer giving the number of values actually returned by
               GETOPT.   If the input is invalid then COUNT is set to -1
 NOTES:
	(1) If an input is invalid, Count is set to -1 and the result is set 
		to 999.
	(2) GETOPT uses the execute function to interpret the user string.   
	 	Therefore GETOPT itself cannot be called with the EXECUTE 
		function.
	(3) GETOPT has a hard limit of 10 tokens in the input string. 

 CALLS: ***
	GETTOK [1], GETTOK [2], GETTOK [3], GETTOK [4]
 CALLED BY:
	ADXY, APER, FIND, HROT, JULDATE, PUTAST, UVBYBETA
 EXAMPLES:
	(1)   a = getopt( '3.4,5*4 ', 'I' )    yields   a = [ 3, 20]
	(2)   a = getopt( '5/2.', 'F', 5)      yields   a = [2.5,0.,0.,0.,0.]
	(3)   a = getopt( '2*3,5,6')           yields   a = [6.,5.,6.]

 REVISON HISTORY:
	written by B. Pfarr, STX, 5/6/87
	change value of !ERR W. Landsman   STX,  6/30/88
	Converted to IDL V5.0   W. Landsman   September 1997


GETPRO $SSW/gen/idl_libs/astron/misc/getpro.pro
[Previous] [Next]
 NAME:
     GETPRO
 PURPOSE:
     Search !PATH for a procedure, and copy into user's working directory
 EXPLANATION:
     Extract a procedure from an IDL Library or directory given in the 
     !PATH  system variable and place it in the current default directory
     (presumably to be edited by the user). 

 CALLING SEQUENCE:
     GETPRO, [ proc_name ]          ;Find PROC_NAME in !PATH and copy

 OPTIONAL INPUT:
     proc_name - Character string giving the name of the IDL procedure or 
               function.  Do not give an extension.   If omitted, 
               the program will prompt for PROC_NAME.   

 OUTPUTS:
     None.

 CALLS: ***
	FDECOMP [1], FDECOMP [2], FDECOMP [3], FILE_WHICH, ZPARCHECK [1], ZPARCHECK [2]
	ZPARCHECK [3]
 SIDE EFFECTS:
      A file with the extension .pro and a name given by PROC_NAME will
      be created on the user's directory.

 PROCEDURE:
      The FILE_WHICH() function is used to locate the procedure in the IDL
      !PATH.     When found, FILE_COPY (if V5.6 or later) or SPAWN is used to 
      copy the procedure into the user's current default directory.    If not 
      found in !PATH, then the ROUTINE_INFO() function is used to determine 
      if it is an intrinsic IDL procedure.  

 EXAMPLE:
       Put a copy of the USER library procedure CURVEFIT on the current
       directory

       IDL> getpro, 'CURVEFIT'

 RESTRICTIONS:
       User will be unable to obain source code for a native IDL function
       or procedure, or for a FORTRAN or C routine added with CALL_EXTERNAL.
       User must have write privilege to the current directory

 PROCEDURE CALLS:
       FDECOMP, ZPARCHECK
 REVISION HISTORY:
      Written W. Landsman, STX Corp.   June 1990
      Now use intrinsic EXPAND_PATH() command  W. Landsman November 1994
      Use ROUTINE_NAMES() to check for intrinsic procs  W. Landsman July 95
      Update for Windows/IDL     W. Landsman      September 95
      Check if procedure is in current directory  W. Landsman  June 1997
      Use ROUTINE_INFO instead of undocumented ROUTINE_NAMES W.L. October 1998
      Use FILE_WHICH() to locate procedure W. Landsman May 2006 
      Assume since V5.5, remove VMS support  W. Landsman Sep 2006


GETPSF $SSW/gen/idl_libs/astron/idlphot/getpsf.pro
[Previous] [Next]
 NAME:
	GETPSF
 PURPOSE:
	To generate a point-spread function (PSF) from observed stars. 
 EXPLANATION:
	The PSF is represented as a 2-dimensional Gaussian
	(integrated over each pixel) and a lookup table of residuals.
	The lookup table and Gaussian parameters are output in a FITS
	image file.   The PSF FITS file created by GETPSF can be
	read with the procedure RDPSF.      Adapted from the 1986 STSDAS 
	version of DAOPHOT

 CALLING SEQUENCE:
	GETPSF, image, xc, yc, apmag, sky, [ronois, phpadu, gauss, psf, 
			idpsf, psfrad, fitrad, psfname, /DEBUG ]

 INPUTS:
	IMAGE  - input image array
	XC     - input vector of x coordinates (from FIND), these should be
		IDL (first pixel is (0,0)) convention.
	YC     - input vector of y coordinates (from FIND)
	APMAG  - vector of magnitudes (from APER), used for initial estimate
		of gaussian intensity.  If APMAG is multidimensional, (more
		than 1 aperture was used in APER) then the first aperture
		is used.
	SKY    - vector of sky values (from APER)                

 OPTIONAL INPUTS:
	The user will be prompted for the following parameters if not supplied.

	RONOIS - readout noise per pixel, (in electrons, or equivalent photons)
	PHPADU - photons per analog digital unit, used to scale the data
		numbers in IMAGE into photon units
	IDPSF  - subscripts of the list of stars created by 
		APER which will be used to define the PSF.   Stars whose
		centroid does not fall within PSFRAD of the edge of the frame,
		or for which a Gaussian fit requires more than 25 iterations,
		will be ignored when creating the final PSF.
	PSFRAD - the scalar radius, in pixels, of the circular area within
		which the PSF will be defined.   This should be slightly larger
		than the radius of the brightest star that one will be
		interested in.
	FITRAD - the scalar radius, in pixels of the circular area used in the
		least-square star fits.  Stetson suggest that FITRAD should
		approximately equal to the FWHM, slightly less for crowded
		fields.  (FITRAD must be smaller than PSFRAD.)
	PSFNAME- Name of the FITS file that will contain the table of residuals,
		and the best-fit Gaussian parameters.    This file is 
		subsequently required for use by NSTAR.  

 OPTIONAL OUTPUTS:
	GAUSS  - 5 element vector giving parameters of gaussian fit to the 
		first PSF star
		GAUSS(0) - height of the gaussian (above sky)
		GAUSS(1) - the offset (in pixels) of the best fitting gaussian
			and the original X centroid
		GAUSS(2) - similiar offset from the Y centroid 
		GAUSS(3) - Gaussian sigma in X
		GAUSS(4) - Gaussian sigma in Y
	PSF    - 2-d array of PSF residuals after a Gaussian fit.

 CALLED BY:
	T_GETPSF
 PROCEDURE:
	GETPSF fits a Gaussian profile to the core of the first PSF star 
	and generates a look-up table of the residuals of the
	actual image data from the Gaussian fit.  If desired, it will then
	fit this PSF to another star (using PKFIT) to determine its precise 
	centroid, scale the same Gaussian to the new star's core, and add the
	differences between the actual data and the scaled Gaussian to the
	table of residuals.   (In other words, the Gaussian fit is performed
	only on the first star.)

 CALLS: ***
	DAOERF, MAKE_2D, MKHDR [1], MKHDR [2], PKFIT [1], PKFIT [2], RINTER [1], RINTER [2]
	STRN [1], STRN [2], STRN [3], STRNUMBER [1], STRNUMBER [2], STRNUMBER [3]
	STRNUMBER [4], SXADDHIST [1], SXADDHIST [2], SXADDPAR [1], SXADDPAR [2]
	SXADDPAR [3], WRITEFITS [1], WRITEFITS [2]
 OPTIONAL KEYWORD INPUT:
	DEBUG - if this keyword is set and non-zero, then the result of each
		fitting iteration will be displayed.

 PROCEDURES CALLED
	DAOERF, MAKE_2D, MKHDR, RINTER(), PKFIT, STRNUMBER(), STRN(), WRITEFITS

 REVISON HISTORY:
	Adapted from the 1986 version of DAOPHOT in STSDAS
	IDL Version 2  W Landsman           November 1988
	Use DEBUG keyword instead of !DEBUG  W. Landsman       May 1996
	Converted to IDL V5.0   W. Landsman   September 1997


GETROT $SSW/gen/idl_libs/astron/astrom/getrot.pro
[Previous] [Next]
 NAME:
    GETROT
 PURPOSE:
     Return the rotation and plate scale of an image from its FITS header
 EXPLANATION:
     Derive the counterclockwise rotation angle, and the X and Y scale
     factors of an image, from a FITS image header.   Input parameter 
     may be either a FITS image header or an astrometry structure (as 
     obtained by EXTAST.PRO)

 CALLING SEQUENCE:
     GETROT, Hdr, [ Rot, CDelt, /SILENT, DEBUG =  ]   
             or 
     GETROT, Astr, Rot, CDelt, /SILENT, DEBUG = ]       

 INPUT PARAMETERS:
     HDR - FITS Image header (string array).  Program will extract the 
             astrometry structure
              or
     ASTR -  ASTROMETRY structure, of the type returned by EXTAST.
             See the documentation for EXTAST.PRO for details.

 OPTIONAL OUTPUT PARAMETERS:
       ROT - Scalar giving the counterclockwise rotation of NORTH in DEGREES 
               from the +Y axis of the image.
       CDELT- 2 element vector giving the scale factors in DEGREES/PIXEL in 
               the X and Y directions.   CDELT[1] is always positive, whereas
               CDELT[0] is negative for a normal left-handed coordinate system,
               and positive for a right-handed system. 

       If no output variables are supplied (or /DEBUG is set), then GETROT 
       will display the rotation and plate scale at the terminal.

 OPTIONAL INPUT KEYWORD
 
       ALT - single character 'A' through 'Z' or ' ' specifying an alternate
             astrometry system present in the FITS header.   See extast.pro
             for more information on the ALT keyword.    Ignored if an
             astrometry structure rather than FITS header is supplied.
       DEBUG - if DEBUG is set, GETROT will print the rotation for both the 
           X and Y axis when these values are unequal.  If DEBUG is set to 2, 
           then the output parameter ROT will contain both X and Y rotations.

       /SILENT - if set, then do not provide a warning about a right-handed
           coordinate system
 CALLS: ***
	EXTAST, GSSS_STDAST, REVERSE
 CALLED BY:
	ARROWS, HASTROM, HPRECESS, IMCONTOUR, TVLASER
 PROCEDURE:
       If the FITS header already contains CDELT (and CD or CROTA) keyword,
       (as suggested by the Calabretta & Greisen (2002, A&A, 395, 1077) FITS 
       standard) then this is used for the scale factor.
       
       If the header contains CD keywords but no CDELT keywords (as in IRAF
       headers) then the scale factor is derived from the CD matrix. 

 PROCEDURES USED:
       EXTAST, GSSS_EXTAST
 REVISION HISTORY:
       Written W. Landsman STX January 1987 
       Convert to IDL V2. M. Greason, STX, May 1990
       Option to return both rotations added.  J. D. Offenberg, STX, Aug 1991
       Use new astrometry structure   W. Landsman  Mar 1994
       Recognize a GSSS header        W. Landsman  June 1994
       Converted to IDL V5.0   W. Landsman   September 1997
       Correct rotation determination with unequal CDELT values WL October 1998
       Consistent conversion between CROTA and CD matrix  WL  October 2000
       Correct CDELT computations for rotations near 90 deg WL November 2002
       Preserve sign in the CDELT output  WL June 2003
       Check if latitude/longitude reversed in CTYPE  WL  February 2004
       Fix problem in latitude check  M.Lombardi/W.Landsman Sep 2004
       Added ALT keyword W. Landsman May 2005


GETTOK [1] $SSW/gen/idl/string/gettok.pro
[Previous] [Next]
 NAME:
	GETTOK                                    
 PURPOSE:
	Retrieve the first part of a (vector) string up to a specified character
 EXPLANATION:
	GET TOKen - Retrieve first part of string until the character char 
	is encountered.   

 CALLING SEQUENCE:
	token = gettok( st, char, [ /EXACT ] )

 INPUT:
	char - character separating tokens, scalar string

 INPUT-OUTPUT:
	st - string to get token from (on output token is removed),
            scalar or vector

 OUTPUT:
	token - extracted string value is returned, same dimensions as st
 OPTIONAL INPUT KEYWORD:
       /EXACT -  The default behaviour of GETTOK is to remove any leading 
              blanks and (if the token is a blank) convert tabs to blanks.    
              Set the /EXACT keyword to skip these steps and leave the 
              input string unchanged before searching for the  character 
              tokens. 

 CALLED BY:
	CMP_ALL_PRO, DATE_CONV, DBCREATE [1], DBCREATE [2], DBCREATE [3], DBFPARSE [1]
	DBFPARSE [2], DBFPARSE [3], DBOPEN [1], DBOPEN [2], DBOPEN [3], DB_ITEM [1]
	DB_ITEM [2], DB_ITEM [3], DOC_MENU, FDECOMP [1], FDECOMP [2], FDECOMP [3], FITSDIR
	FITSHDR2STRUCT, FITS_INFO [1], FITS_INFO [2], FTADDCOL, FXBTDIM [1], FXBTDIM [2]
	FXPAR [1], FXPAR [2], GETOPT, GET_LIB, GET_OBJECT, HESSI SOHDATA CLASS DEFINITION
	IRAFRD, JPLEPHREAD, MRDFITS [1], MRDFITS [2], MRD_STRUCT [1], MRD_STRUCT [2]
	NORH_CREATE_STRUCT [1], NORH_CREATE_STRUCT [2], NORH_FITS_INTERP [1]
	NORH_FITS_INTERP [2], PATH_EXPAND, PIXCOLOR, QUERYVIZIER, READCOL [1], READCOL [2]
	READCOL [3], READFMT, TABLE_CALC, TABLE_EXT, TAB_FORTOSPP, TAB_PRINT, TBPRINT
	fits_interp
 EXAMPLE:
	If ST is ['abc=999','x=3.4234'] then gettok(ST,'=') would return
	['abc','x'] and ST would be left as ['999','3.4234'] 

 PROCEDURE CALLS:
       REPCHR()
 HISTORY
	version 1  by D. Lindler APR,86
	Remove leading blanks    W. Landsman (from JKF)    Aug. 1991
	Converted to IDL V5.0   W. Landsman   September 1997
       V5.3 version, accept vector input   W. Landsman February 2000
       Slightly faster implementation  W. Landsman   February 2001
       Added EXACT keyword  W. Landsman March 2004
       Use COMPLEMENT keyword to WHERE W. Landsman   March 2004


GETTOK [2] $SSW/gen/idl_libs/astron/misc/gettok.pro
[Previous] [Next]
 NAME:
	GETTOK                                    
 PURPOSE:
	Retrieve the first part of a (vector) string up to a specified character
 EXPLANATION:
	GET TOKen - Retrieve first part of string until the character char 
	is encountered.   

 CALLING SEQUENCE:
	token = gettok( st, char, [ /EXACT ] )

 INPUT:
	char - character separating tokens, scalar string

 INPUT-OUTPUT:
	st - string to get token from (on output token is removed),
            scalar or vector

 OUTPUT:
	token - extracted string value is returned, same dimensions as st
 OPTIONAL INPUT KEYWORD:
       /EXACT -  The default behaviour of GETTOK is to remove any leading 
              blanks and (if the token is a blank) convert tabs to blanks.    
              Set the /EXACT keyword to skip these steps and leave the 
              input string unchanged before searching for the  character 
              tokens. 

 CALLED BY:
	CMP_ALL_PRO, DATE_CONV, DBCREATE [1], DBCREATE [2], DBCREATE [3], DBFPARSE [1]
	DBFPARSE [2], DBFPARSE [3], DBOPEN [1], DBOPEN [2], DBOPEN [3], DB_ITEM [1]
	DB_ITEM [2], DB_ITEM [3], DOC_MENU, FDECOMP [1], FDECOMP [2], FDECOMP [3], FITSDIR
	FITSHDR2STRUCT, FITS_INFO [1], FITS_INFO [2], FTADDCOL, FXBTDIM [1], FXBTDIM [2]
	FXPAR [1], FXPAR [2], GETOPT, GET_LIB, GET_OBJECT, HESSI SOHDATA CLASS DEFINITION
	IRAFRD, JPLEPHREAD, MRDFITS [1], MRDFITS [2], MRD_STRUCT [1], MRD_STRUCT [2]
	NORH_CREATE_STRUCT [1], NORH_CREATE_STRUCT [2], NORH_FITS_INTERP [1]
	NORH_FITS_INTERP [2], PATH_EXPAND, PIXCOLOR, QUERYVIZIER, READCOL [1], READCOL [2]
	READCOL [3], READFMT, TABLE_CALC, TABLE_EXT, TAB_FORTOSPP, TAB_PRINT, TBPRINT
	fits_interp
 EXAMPLE:
	If ST is ['abc=999','x=3.4234'] then gettok(ST,'=') would return
	['abc','x'] and ST would be left as ['999','3.4234'] 

 PROCEDURE CALLS:
       REPCHR()
 HISTORY
	version 1  by D. Lindler APR,86
	Remove leading blanks    W. Landsman (from JKF)    Aug. 1991
	Converted to IDL V5.0   W. Landsman   September 1997
       V5.3 version, accept vector input   W. Landsman February 2000
       Slightly faster implementation  W. Landsman   February 2001
       Added EXACT keyword  W. Landsman March 2004
       Assume since V5.4, Use COMPLEMENT keyword to WHERE W. Landsman Apr 2006


GETUT [1] $SSW/gen/idl/utplot/getut.pro
[Previous] [Next]
 NAME:
	GETUT
 PURPOSE:
	Retrieve base, start, or end time from common UTCOMMON.  
 CATEGORY:
 CALLING SEQUENCE:
	GETUT,UTBASE=base,UTSTART=start,UTEND=end ,XSTart = xstart, /STR,/PRI
 INPUTS:
	None.
 INPUT PARAMETERS:
	BASE, START, END, XSTART - keyword parameters select which time(s) to retrieve,
	   times returned are double precision seconds relative to 79/1/1, 0000
	   or string if /STRINGIT is specified
	/STRINGIT - return times in strings with format YY/MM/DD,HHMM:SS.XXX 
	/PRINT - print times on the terminal (prints all three if none are 
	   specified)
 CALLS: ***
	ATIME [1], ATIME [2], CHECKVAR [1], checkvar [2]
 CALLED BY:
	BATSE_ONTIMES, EDITOC, FLISTOC, FSOC, FS_ARCHIVE_RW, FS_SUBTITLE, GETUTBASE [1]
	GETUTBASE [2], POINT [1], QLDISPLAY, QL_DAY_PLOT, RATESDUMPOC, RAWDUMPOC
	SPEX_COMMONS [2], SPEX_COMMONS [4], SPEX_PROC [1], SPEX_PROC [2]
	SPEX_THISTORY [1], SPEX_THISTORY [2], evt_grid, fem_grid [1], fem_grid [2]
	get_utevent [1], get_utevent [2], goes_log, plotman, point [2], t_utplot [1]
	t_utplot [2], utcursor [1], utcursor [2]
 COMMON BLOCKS:
	COMMON UTCOMMON, UTBASE, UTSTART, UTEND, XST = base, start, and 
	   end time for X axis in double precision variables containing
	   seconds since 79/1/1, 00:00.  XST is the fully referenced time
	   of the start of the plot in any supported format.
 SIDE EFFECTS:
	None.
 RESTRICTIONS:
	None.
 PROCEDURE:
	ATIME is called to translate UTXXX to YY/MM/DD, HHMM:SS.XXX string
	UTBASE is epoch day * 86400 + msec/1000 from 79/01/01
 MODIFICATION HISTORY:
	Written by Richard Schwartz for IDL Version 2, Feb. 1991
	RAS, modified for Yohkoh Environment, 1-Nov-1993


GETUTBASE [1] $SSW/gen/idl/utplot/getutbase.pro
[Previous] [Next]
 NAME:
	GETUTBASE
 PURPOSE:
	Function to retrieve value of utbase fromm common UTCOMMON without 
	   having to declare common.  Returns in UTIME format, sec from 79/1/1

 CALLING SEQUENCE:
	RESULT = GETUTBASE()
 INPUTS: 
	None
 CALLS: ***
	GETUT [1], GETUT [2]
 CALLED BY:
	ASCII_RATES, CONT_READ, DATPLOT, DCFSUMMARY, DISCSP_READ, DRAW_FLARE, EVAL_SHERB
	FDBREAD, FSOC, FSPLOT, FS_ARCHIVE_DRAW, FS_ARCHIVE_RW, FS_AUTO_LOG, FS_GEN_ARR
	FS_GRAPH, FS_OVERLAY, GET_PRAT_TCOUN, HXARCHIVE, HXFITS, HXRBS, HXR_DC2FITS
	MAP_DISCLA2CONT, MEMORY_INTRVLS, PLOTBATSE, PLOTBATSE_QL, PLOT_OCC_ONDAY
	READ_DISCLA, RUN_BATSE, SAVE_DCDATA, SC4TREAD, SPEX_BACKGROUND [1]
	SPEX_BACKGROUND [2], SPEX_COMMONS [2], SPEX_COMMONS [4], SPEX_HANDLES [1]
	SPEX_HANDLES [2], SPEX_PROC [1], SPEX_PROC [2], SPEX_SAVE [1], SPEX_SAVE [2]
	SPEX_SAVE_DATA [1], SPEX_SAVE_DATA [2], SPEX_THISTORY [1], SPEX_THISTORY [2]
	UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5], Utime2str [1]
	Utime2str [2], Y_AVERAGE [1], Y_AVERAGE [2], goes_plot [1], goes_plot [2]
	goes_plot [3], goes_plot [4], goes_plot [5], help_merge [1], help_merge [2]
	inv_get_data_spex [2], mark_intervals, plotman, read_batse_4_spex [1]
	read_batse_4_spex [2], spectro_plot2, spex_delete [1], spex_delete [2]
	spex_hold [1], spex_hold [2], spex_merge [1], spex_merge [2], spex_source [1]
	spex_source [2], wbs_response [1], wbs_response [2]
 PROCEDURE:
	GETUT is called to retrieve utbase, See GETUT.PRO description.
 MODIFICATION HISTORY:
	Written by Richard Schwartz for IDL VERSION 2, Feb. 1991
	mod 1-nov-91 to accept all representations of the base time, ras


GETWRD [1] $SSW/gen/idl_libs/astron/jhuapl/getwrd.pro
[Previous] [Next]
 NAME:
       GETWRD
 PURPOSE:
       Return the n'th word from a text string.
 CATEGORY:
 CALLING SEQUENCE:
       wrd = getwrd(txt, n, [m])
 INPUTS:
       txt = text string to extract from.         in
         The first element is used if txt is an array.
       n = word number to get (first = 0 = def).  in
       m = optional last word number to get.      in
 KEYWORD PARAMETERS:
       Keywords:
         LOCATION = l.  Return word n string location.
         DELIMITER = d. Set word delimiter (def = space & tab).
         /LAST means n is offset from last word.  So n=0 gives
           last word, n=-1 gives next to last, ...
           If n=-2 and m=0 then last 3 words are returned.
         /NOTRIM suppresses whitespace trimming on ends.
         NWORDS=n.  Returns number of words in string.
 OUTPUTS:
       wrd = returned word or words.              out
 CALLED BY:
	TIMEAXIS [1], TIMEAXIS [2], TIMEAXIS [3], XPRINT [1], XPRINT [3]
 COMMON BLOCKS:
       getwrd_com
 NOTES:
       Note: If a NULL string is given (txt="") then the last string
             given is used.  This saves finding the words again.
             If m > n wrd will be a string of words from word n to
             word m.  If no m is given wrd will be a single word.
             n<0 returns text starting at word abs(n) to string end
             If n is out of range then a null string is returned.
             See also nwrds.
 MODIFICATION HISTORY:
       Ray Sterner,  6 Jan, 1985.
       R. Sterner, Fall 1989 --- converted to SUN.
       R. Sterner, Jan 1990 --- added delimiter.
       R. Sterner, 18 Mar, 1990 --- added /LAST.
       R. Sterner, 31 Jan, 1991 --- added /NOTRIM.
       R. Sterner, 20 May, 1991 --- Added common and NULL string.
       R. Sterner, 13 Dec, 1992 --- Made tabs equivalent to spaces.
       R. Sterner,  4 Jan, 1993 --- Added NWORDS keyword.
       R. Sterner, 2001 Jan 15 --- Fixed to use first element if not a scalar.
       Johns Hopkins University Applied Physics Laboratory.

 Copyright (C) 1985, Johns Hopkins University/Applied Physics Laboratory
 This software may be used, copied, or redistributed as long as it is not
 sold and this copyright notice is reproduced on each copy made.  This
 routine is provided as is without any express or implied warranties
 whatsoever.  Other limitations apply as described in the file disclaimer.txt.


gfits_ext1 $SSW/gen/idl/goes/gfits_ext1.pro
[Previous] [Next]
 GFITS_EXT1
 GFITS_EXT1 composes the FITS header for the energy edges extension
    for GOES FITS files.

 Kim Tolbert 6/18/93
 CALLS:


gfits_ext2 $SSW/gen/idl/goes/gfits_ext2.pro
[Previous] [Next]
 GFITS_EXT2
 GFITS_EXT2 composes the FITS header for the status word extension
    for GOES FITS files.

 Kim Tolbert 6/18/93
 CALLS:


gfits_files $SSW/gen/idl/goes/gfits_files.pro
[Previous] [Next]
 GFITS_FILES
 Finds GOES FITS files for a specified time interval.
 Based on user start and end times and satellite (GOES), create an 
 array of file names covering that time interval.

 Kim Tolbert 6/93
 CALLS: ***
	ATIME [1], ATIME [2], PARSE_ATIME [1], parse_atime [2]
 CALLED BY:
	GFITS_R
 Modification History:
 Version 2, Amy.Skowronek@gsfc.nasa.gov, modified findfile call
	to get longer than two digit years for y2k


gfits_head $SSW/gen/idl/goes/gfits_head.pro
[Previous] [Next]
 GFITS_HEAD
 GFITS_HEAD composes the primary FITS header for GOES FITS files.
 GFITS_EXT1 and GFITS_EXT2 compose the headers for the energy edge and
 status word extensions.

 Kim Tolbert 5/28/93
 CALLS:


GFITS_R $SSW/gen/idl/goes/gfits_r.pro
[Previous] [Next]
 PROJECT:  SDAC

 NAME:     GFITS_R

 PURPOSE:  This procedure reads GOES three second soft X-ray data from
   either the SDAC or Yohkoh databases.  Default is to use the SDAC
   data base found at GOES_FITS.

 CATEGORY:     GOES

 CALLING SEQUENCE:
   gfits_r, stime=stime, etime=etime,  sat=sat, nosetbase=nosetbase, $
      tarray=tarray, yarray=yarray, edges=edges, $
      base_ascii=base_ascii, base_sec=base_sec, $
      quiet=quiet, sdac=sdac, yohkoh=yohkoh, $
      numstat=numstat, tstat=tstat, stat=stat, headers=headers, $
     error=error, err_msg=err_msg, verbose=verbose

   gfits_r, stim='93/1/1,1200', etim='93/1/1,1400', tarray=t, yarray=y

 CALLS: ***
	ATIME [1], ATIME [2], CHECKVAR [1], DATATYPE [1], DATATYPE [2], DATATYPE [3]
	FXPAR [1], FXPAR [2], LOC_FILE [1], LOC_FILE [2], LOC_FILE [3], MRDFITS [1]
	MRDFITS [2], READFITS [1], READFITS [2], READFITS [3], SETUT [1], SETUT [2]
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], checkvar [2], curdir [1]
	curdir [2], gfits_files, where_arr [1], where_arr [2]
 INPUTS: None.

 KEYWORDS:

  INPUT KEYWORDS:
   STIME:  Mandatory, start time of requested time interval in ASCII
     format yy/mm/dd,hhmm:ss.xxx (or any format recognized by anytim.pro)
   ETIME:  Mandatory, end time of requested time interval in ASCII format
               yy/mm/dd,hhmm:ss.xxx (or any format recognized by anytim.pro)
   SAT:    6, 7 or 8, 9  for GOES 6, GOES 7 or GOES 8 or GOES 9 data
     (default is 7)
   NOSETBASE:  0/1 means don't/do  set the base time in the UTPLOT package
               common (default is 1, i.e. set base time)
   SDAC:   If set search only for data in GOES_FITS location, SDAC style.
   YOHKOH: If set, search only for data using RD_GXD
   QUIET:  If set, suppress error messages
   VERBOSE:    If =0 do not print messages

  OUTPUT KEYWORDS:
   TARRAY: Array of times in seconds since the base time (which will be
               returned in BASE_ASCII and/or BASE_SEC if requested.  Base time
               is normally the beginning of the day that the data is on.)
   YARRAY: Array of flux values for the two GOES channels, yarray (n,0)
               is flux for long wavelength channel, yarray(n,1) is for short.
   EDGES:  Edges of the two channels in Angstroms
   BASE_ASCII: Base time in ASCII string yy/mm/dd,hhmm:ss.xxx for start of day of start of
     TARRAY.  Times in tarray are in seconds relative to this time. (Same time
     as in BASE_SEC.)
   BASE_SEC:   Time in seconds since 1979/1/1,0.0 of starting day.

   NUMSTAT:    Number of status values returned in tstat and stat arrays.
   TSTAT:  Times corresponding the status words in stat array.
   STAT:   Status words for times in TSTAT array.  Only status words that
               indicate an abnormal condition are returned.  There are two
     status words.  Explanation of the status codes is returned
     in the header for the status word extension (HEADERS(3)).
   HEADERS:    HEADERS(0) is the primary header for the FITS file, HEADERS(1)
               is the header for the channel edges extension, HEADERS(2) is
               the header for the flux and HEADERS(3) is the header for the
     status word extension.  Print these headers
               to see useful information about these files.
   ERROR:  0/1 means an error was encountered reading file.  Text of
               error message in ERR_MSG
   ERR_MSG:    Text of error message when ERROR = 1.

 CALLED BY:
	RD_GOES_SDAC
 PROCEDURE :   This procedure merges the GOES find and read functions developed
   independently at the SDAC and for Yohkoh.  The SDAC routine, GFITS_R,
   reads the GOES data archive for a selected time interval and
   selected satellite (6, 7 or 8) and returns an array of times and
   flux values for the two channels. Also returned are the energy edges
   of the channels, the status words, and the header strings.

 MODIFICATION HISTORY:
   Kim Tolbert 7/93
   ras, 13-apr-95, reconciled OVMS and OSF for SDAC,Umbra respectively
   ras, 19-jun-95, file names are now lowercase
   ras, 27-jan-1997, incorporate rd_gxd for Yohkoh environments
   RCJ, 05/06/97, to recognize old and new FITS files, clean up
     documentation
   richard.schwartz@gsfc.nasa.gov, 6-May-1998. Fixed times for multiple days by
   using offset time from TIMEZERO in header instead of terrible, horrible former way based
   on stime. Also sized arrays initially based on length of observing interval, which is the
   correct method.
   richard.schwartz@gsfc.nasa.gov, 15-May-1998. Fixed bug introduced on 6-May-1998, left
   a line in about setting index_array, now removed.
   richard.schwartz@gsfc, 10-nov-1999. changed initial file read to readfits from
   mrdfits.  Otherwise old format of sdac fits fails under windows.
   Kim, 12-apr-2000, include 10 in sat_list.  If sat not passed in or is
     0, then start search at 6, not 0.
   Kim, 18-jun-2000, check that yohkoh software is available before calling routine
     rd_gxd.  Otherwise, crashes.
   ras, 4-apr-2001, explicitly use first element of stime and etime for comparisons.
   Kim, 07-Jul-2003.  If rd_gxd isn't found, set error=1
   ras, 11-aug-2003.  Switched to loc_file from findfile.
   Kim, 14-Nov-2005.  Added /silent in call to readfits.
   Zarro, 23-Nov-2005. Added a few calls to 'temporary' and /NO_RETRY
   Zarro, 17-Jan-2006. Made VERBOSE=0 the default


GFITS_W $SSW/gen/idl/goes/gfits_w.pro
[Previous] [Next]
 PROJECT:
	SDAC
	
 NAME: GFITS_W

 PURPOSE:  
   Write a GOES FITS file for the date and satellite specified.  

 CATEGORY:  GOES

 CALLING SEQUENCE:
	GFITS_W, date, satellite
 CALLS: ***
	ATIME [1], ATIME [2], FLIPDATE, FORM_FILENAME [1], FORM_FILENAME [2], GOES_3HOUR
	LOC_FILE [1], LOC_FILE [2], LOC_FILE [3], SPECTRA2FITS, SYS2UT, TIME2FILE
	YYDOY_2_UT, anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
 INPUTS:
	Date:	date to write FITS file for.  Any format accepted by anytim.
	Satellite:  6, 7, 8, 9, 10
 OPTIONAL KEYWORD INPUTS:
	Y2K - if set the FITS date keywords are written as dd/mm/yyyy instead
	of dd/mm/yy.

 OUTPUTS:
	FITS file written to GOES_FITS:GO*.FITS or $GOES_FITS/go*.fits

 CALLED BY:
	DO_FITSFILES
 PROCEDURE:
       Calls GOES_3HOUR to read the 8 GOES 3-hour files copied from SEL, 
	and accumulates all the data from the 8 files.  Then calls 
	SPECTRA2FITS to write binary FITS table where the primary data 
	unit contains no data, the first extension contains the edges, 
	fluxes are in the second extension, and status words are in the 
	third extension. Routine GFITS_R reads these GOES FITS files. 

 MODIFICATION HISTORY:
 	Written by Kim Tolbert
	Mod. 05/97 by RCJ to write binary FITS table.
	Version 3, richard.schwartz@gsfc.nasa.gov, platform independent (unix and Vms)
	and FITS keywords are y2k compliant with y2k switch set.  Filenames are also
	written with 4 digit strings
       Version 4, amy.skowronek@gsfc.nasa.gov, implemented y2k changes


GIF2PICT $SSW/gen/idl/image/gif2pict.pro
[Previous] [Next]
 Project     :	SDAC

 Name        :	GIF2PICT

 Purpose     :	copy GIF image to PICT format

 Explanation :	

 Use         :	GIF2PICT,IFILE,OFILE
              
 Inputs      :	IFILE = GIF file name
               OFILE = PICT file name [def is to rename ext of IFILE to .PICT)

 Opt. Inputs : None.

 Outputs     :	None.

 Opt. Outputs:	None.

 Keywords    :	LIST = list of input files to convert (overridden by IFILE)
               FRAME = write output PICT files as FRAMEi.*
               OUT_DIR = output directory for PICT files [def = sames as GIF]

 Restrictions:	None.

 CALLS: ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], CONCAT_DIR [1], CONCAT_DIR [2]
	CONCAT_DIR [3], DATATYPE [1], DATATYPE [2], DATATYPE [3], LOC_FILE [1]
	LOC_FILE [2], LOC_FILE [3], RD_ASCII [1], RD_ASCII [2], READ_GIF, TEST_OPEN, TRIM
	VALID_GIF, WRITE_PICT, break_file [4], concat_dir [4]
 Side effects:	None.

 Category    :	Graphics

 Prev. Hist. :	None.

 Written     :	Dominic Zarro (ARC)

 Version     :	Version 1.0, 1 January 1997


GLACTC $SSW/gen/idl_libs/astron/astro/glactc.pro
[Previous] [Next]
 NAME:  
       GLACTC
 PURPOSE:
        Convert between celestial and Galactic (or Supergalactic) coordinates.
 EXPLANATION:
       Program to convert right ascension (ra) and declination (dec) to
       Galactic longitude (gl) and latitude (gb) (j=1) or vice versa (j=2).

 CALLING SEQUENCE: 
       GLACTC, ra, dec, year, gl, gb, j, [ /DEGREE, /FK4, /SuperGalactic ]

 INPUT PARAMETERS: 
       year     equinox of ra and dec, scalar       (input)
       j        direction of conversion     (input)
               1:  ra,dec --> gl,gb
               2:  gl,gb  --> ra,dec

 INPUTS OR OUTPUT PARAMETERS: ( depending on argument J )
       ra       Right ascension, hours (or degrees if /DEGREES is set), 
                         scalar or vector
       dec      Declination, degrees,scalar or vector
       gl       Galactic longitude, degrees, scalar or vector
       gb       Galactic latitude, degrees, scalar or vector

       All results forced double precision floating.

 OPTIONAL INPUT KEYWORD PARAMETERS:
       /DEGREE - If set, then the RA parameter (both input and output) is 
                given in degrees rather than hours. 
       /FK4 - If set, then the celestial (RA, Dec) coordinates are assumed
              to be input/output in the FK4 system.    By default,  coordinates
              are assumed to be in the FK5 system.    For B1950 coordinates,
              set the /FK4 keyword *and* set the year to 1950.
       /SuperGalactic - If set, the GLACTC returns SuperGalactic coordinates
              as defined by deVaucouleurs et al. (1976) to account for the 
              local supercluster. The North pole in SuperGalactic coordinates 
              has Galactic coordinates l = 47.47, b = 6.32, and the origin is 
              at Galactic coordinates l = 137.37, b= 0 
              
 CALLS: ***
	BPRECESS, JPRECESS, PRECESS
 EXAMPLES:
       Find the Galactic coordinates of Altair (RA (J2000): 19 50 47 
       Dec (J2000): 08 52 06)

       IDL> glactc, ten(19,50,47),ten(8,52,6),2000,gl,gb,1
       ==> gl = 47.74, gb = -8.91

 PROCEDURE CALLS:
       BPRECESS, JPRECESS, PRECESS
 HISTORY: 
       FORTRAN subroutine by T. A. Nagy, 21-MAR-78.
       Conversion to IDL, R. S. Hill, STX, 19-OCT-87.
       Modified to handle vector input, E. P. Smith, GSFC, 14-OCT-94
       Converted to IDL V5.0   W. Landsman   September 1997
       Added DEGREE keyword, C. Markwardt, Nov 1999
       Major rewrite, default now FK5 coordinates, added /FK4 keyword
       use external precession routines    W. Landsman   April 2002
       Add /Supergalactic keyword W. Landsman  September 2002
       Fix major bug when year not 2000 and /FK4 not set W. Landsman July 2003


GMT_OFFSEC $SSW/gen/idl/fund_lib/jhuapl/gmt_offsec.pro
[Previous] [Next]
 NAME:
       GMT_OFFSEC
 PURPOSE:
       Return offset in seconds from local time to GMT (UT).
 CATEGORY:
 CALLING SEQUENCE:
       off = gmt_offsec()
 INPUTS:
 KEYWORD PARAMETERS:
 OUTPUTS:
 CALLED BY:
	TIMER
 COMMON BLOCKS:
 NOTES:
       Note: Times are rounded to the nearest 1/4 hour.
         This should handle any time zone, even fractional ones.
 MODIFICATION HISTORY:
       R. Sterner, 2 Dec, 1993

 Copyright (C) 1993, Johns Hopkins University/Applied Physics Laboratory
 This software may be used, copied, or redistributed as long as it is not
 sold and this copyright notice is reproduced on each copy made.  This
 routine is provided as is without any express or implied warranties
 whatsoever.  Other limitations apply as described in the file disclaimer.txt.


go_batch [1] $SSW/gen/idl/genutil/go_batch.pro
[Previous] [Next]
   Name: go_batch

   Purpose: make and idl 'batch' job and 'submit' it (using VMS terminology)
            (puts and end statement on your command list and calls idl_batch)

   Input Parameters:
      command_list - one or more idl statements to execute

   Keyword Parameters:
      nodelist - one or more nodes to submit job on (will choose 'best' node)
      user     - user for remote job (ignored if no nodelist)
      remove   - if set, remove selected node from nodelist (for distribuinting jobs)
      batchdir - directory for job (added to IDL !path) - default = $DIR_SITE_BATCH
      logdir   - if set, directory for log file
      nodelete - if set, do not delete job & log after succesful completion
      defnodes - if set, will use node list specified by $SITE_BATCHNODES
 			  (see is_bestnode documentation)
     caller    - string name of calling routine (passed to pr_status)

   Calling Sequence:
      go_batch, command_list [nodelist=nodelist, user=user, batchdir=batchdir, $
			      [logdir=logdir, logfile=logfile]

   Calling Examples:
      go_batch, 'daily_forecast' , nodelist=['flare13','flare14','flare15']
      (runs the idl command 'daily_forecast' as a background task on the
      (least utiilized machine in the nodelist)
      
 CALLS: ***
	ARR2STR [1], Arr2Str [2], BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3]
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], FILE_EXIST [2], STR2ARR [1]
	STR2ARR [2], break_file [4], concat_dir [4], data_chk [1], data_chk [2]
	ex2fid [1], ex2fid [2], file_append [1], file_append [2], file_exist [1]
	file_exist [3], get_host [1], get_host [2], get_user [1], get_user [2]
	is_bestnode [1], is_bestnode [2], pr_status [1], pr_status [2], rd_tfile [1]
	rd_tfile [2], rsh, ut_time [1], ut_time [2]
 CALLED BY:
	pref_super, xso_search
   Side Effects:
      and idl child process is submitted in the background on the specified
      or best node available.  

   History:
      29-Sep-1994 (SLF) written to facilitated distributed processing
       1-Oct-1994 (SLF) added job file capability 
       2-Oct-1994 (SLF) added CALLER keyword (passed to pr_status)


go_file_purge $SSW/gen/idl/ssw_system/go_file_purge.pro
[Previous] [Next]
   Name: go_file_purge

   Purpose: cron driver for file_purge

   History: 
       09-Aug-1993 (SLF) (keep backup data bases in check)
       23-may-1995 (SLF) add option 3
        2-oct-1995 (SLF) add file filter option (column 4)
        8-Aug-1997 (SLF) adjust for SSW use
        7-Oct-1997 (SLF) appended SITE template file


go_ssw_batch $SSW/gen/idl/ssw_util/go_ssw_batch.pro
[Previous] [Next]
   Name: go_ssw_batch

   Purpose: run sswidl jobs from application or cronjobs

   Input Parameters:
      jobfile - the *.pro to run; main level program format
      logfile - job output (def=$SSW/site/logs/<job>.log

   Keyword Parameters:
      site - (switch) if set, use $SSW/site/bin/ssw_batch
                      (def=$SSW/gen/bin/ssw_batch)
      batch_cmd - explicit command (def= .../ssw_batch )
      nodate - (switch) - if set, dont append date to <logfile>
      background - (switch) - if set, background task
                              (def = in-line/sycncronous)

   Calling Sequence:
      IDL> go_ssw_batch,'program.pro'[,logfile],[/background]

   Application: 
      appliclation generates <job.pro> dynamically - then
      call this to execute it within the application.

   History:
       Circa 1-jan-???? - S.L.Freeland  
       21-Nov-2005 - S.L.Freeland - added doc header,/BACKGROUND

 CALLS: ***
	ARR2STR [1], Arr2Str [2], BOX_MESSAGE, BREAK_FILE [1], BREAK_FILE [2]
	BREAK_FILE [3], CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], FILE_EXIST [2]
	OS_FAMILY, break_file [4], concat_dir [4], data_chk [1], data_chk [2]
	file_exist [1], file_exist [3]
   Restrictions:
      os_family()='unix' only 


go_update_ssw $SSW/gen/idl/ssw_system/go_update_ssw.pro
[Previous] [Next]
   Name:  go_update_ssw

   Purpose: single point routine to maintain SSW system at remote sites

   Motivation:
      Main program which (originally) just calls S.L.Freeland routine
      SSW_UPGRADE.PRO to force an update of the local $SSW tree.
      See SSW_UPGRADE doc header for options/information.
      Generally called via cron job (via $SSW/gen/bin/ssw_batch)

      Extended to functioning as a single point SSW maintenence cron job
      so calls to other routines may be added here without requiring
      user to update the existing cron references.

   History:
	        16-Apr-97 M.D.Morrison - batch front end->SLF SSW_UPGRADE
                2-May-97 S.L.Freeland - document and extend 'scope'
                9-may-97 S.L.Freeland - add call to SSW_CHECK_CONTRIB
               17-sep-97 S.L.Freeland - Allow instrument upgrade specification
                                        ($SSW_INSTR) via configuration file:
                                        $SSW/site/setup/setup.ssw_upgrade
		31-Mar-98 M.D.Morrison - Disabled ssw_check_contrib temporarily
               27-Jan-99 S.L.Freeland - run sswdb_upgrade if
                                        $SSW/site/setup/setup.sswdb_upgrade exists
Restrictions:
   Perl5 must exist on local machine - installed in '/usr/local/bin/perl'
                                       or must have Perl link with that name


GOES $SSW/gen/idl/goes/goes.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GOES

 Purpose     : GOES procedure and function.  Procedure starts GOES GUI interface and
               optionally returns GOES object.
               GOES function creates a new GOES object

 Category    : synoptic objects

 Explanation : Provide a GUI to plot GOES flux, temperature, emission measure,
               select background time intervals, and write a save file.

 Syntax      : IDL> goes  or goes, obj (for procedure)
               IDL> o = goes()  (for function)

 Arguments:  : When called as a procedure:
               obj - returns GOES object reference

 Keywords    : Any keywords to pass into goes object

 CALLS: ***
	OGOES
 CALLED BY:
	SDAC
 History     : Written 17-Nov-2005, Kim Tolbert

 Contact     : kim.tolbert@gsfc.nasa.gov

 Modifications:


GOES2FLUX $SSW/gen/idl/solar/goes2flux.pro
[Previous] [Next]
 Project     : SOHO - CDS     
                   
 Name        : GOES2FLUX()
               
 Purpose     : Convert GOES class to flux.
               
 Explanation : Translates string giving GOES class of a flare to flux
               in watts/sq m.
               
 Use         : IDL> Flux = goes2flux(class)
    
 Inputs      : class  -  (string array) GOES class, 
                          eg 'M3.2' or ['M3.2','C1.4']
               
 Opt. Inputs : None
               
 Outputs     : Function returns flux in watts/sq m.
               
 Opt. Outputs: None
               
 Keywords    : None

 Calls       : None
 Common      : None
               
 Restrictions: None
               
 Side effects: None
               
 Category    : Util
               
 Prev. Hist. : None

 Written     : C D Pike, RAL, 17-oct-94
               
 Modified    : 

 Version     : Version 1, 17-Oct-94


GOES_3HOUR $SSW/gen/idl/goes/goes_3hour.pro
[Previous] [Next]

 NAME:
	GOES_3HOUR

 PURPOSE:
	Read the GOES 3-hour files copied from SEL and return the
	header record, and the data records.

 CATEGORY:
	GOES

 CALLING SEQUENCE:
       GOES_3HOUR, File, Header, Data

 CALLS: ***
	IEEE_TO_HOST [1], IEEE_TO_HOST [2], IEEE_TO_HOST [3], IEEE_TO_HOST [4]
 INPUTS:
       File:	GOES 3-hour file.

 OUTPUTS:
       Header:	Array containing year, day of the year and satellite number.
	Data:   Array containing time in sec from start of observation day
		in 2-3 sec interval, ?, ?, flux (watts/m^2) for range 
		1. - 8. angstroms, and flux (watts/m^2) for range 
		.5 - 4. angstroms. Flux value of -99999.0 means no data.

 CALLED BY:
	GFITS_W
 PROCEDURE:
       Read data from goes_3hour file, perform a longword swap using
	'byteorder', convert data array from IEEE to host representation,
	and return header and remaining data arrays.

 MODIFICATION HISTORY:
	Kim Tolbert 7/93
       Mod. 08/07/96 by RCJ. Use IEEE_TO_HOST instead of CONV_UNIX_VAX.


GOES__DEFINE $SSW/gen/idl/goes/goes__define.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GOES__DEFINE

 Purpose     : Define a GOES lightcurve object

 Category    : synoptic objects

 Explanation : Object to read GOES data, and return or plot the two flux channels or
               the temperature and emission measure.  Reads either the SDAC or the
               YOHKOH archive of GOES data.  Can be used from the command line (via
               set, get, getdata, plot, plotman methods), or from a gui (o->gui).

 Syntax      : IDL> new=obj_new('goes')

 CALLS: ***
	ADD_TAG [1], ADD_TAG [2], ALLOW_SOCKETS, ANYTIM2TAI, ANYTIM2UTC [1]
	ANYTIM2UTC [2], APPEND_ARR, CHECKVAR [1], CLEAN_GOES, DELVARX [1], DELVARX [2]
	DELVARX [3], DELVARX [4], DPRINT, EXIST, FILE_SINCE, FIT_BACKGRND, FORMAT_INTERVALS
	GBO_STRUCT [1], GBO_STRUCT [2], GET_UTC, GOES::ALLOW_GOES, GOES::CALC_BK
	GOES::CLEANUP, GOES::DEF_TIMES, GOES::DISPLAY_MESSAGE, GOES::FIX_KEYWORDS
	GOES::FLUSH, GOES::GET, GOES::GETDATA, GOES::GET_ABUND_NAME, GOES::GET_MODE
	GOES::GET_PLOTMAN, GOES::HAVE_GDATA, GOES::HAVE_GOES_DIR
	GOES::HAVE_PLOTMAN_DIR, GOES::HELP, GOES::INIT, GOES::MK_FILE_ID
	GOES::NEED_UPDATE, GOES::OUTPUT, GOES::PLOT, GOES::PLOTMAN, GOES::PREPARE_PLOT
	GOES::READ, GOES::SAT2INDEX, GOES::SAT_TIMES, GOES::SAVEFILE
	GOES::SELECT_BACKGROUND, GOES::SELECT_INTEGRATION_TIMES, GOES::SET
	GOES::SHOW_BACKGROUND, GOES::SHOW_INTEGRATION_TIMES, GOES::TIMES, GOES::TITLE
	GOES::VALID_BTIMES, GOES_GET_CHIANTI_VERSION, GOES_LX, GOES_SAT, GOES_SERVER
	GOES_TEM, GOES_TEMP_DIR, HAVE_PROC, HAVE_TAG, IS_CLASS, IS_DIR, IS_STRING
	PLOTMAN_DRAW_INT, PTR_EMPTY, PTR_EXIST, RD_GOES, RD_GOES_SDAC, RECOMPILE
	REM_TAG [1], REM_TAG [2], STRUP, TIME2FILE, TRIM, VALID_RANGE, VALID_TIME, XREGISTERED
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], calc_rad_loss
	checkvar [2], curdir [1], curdir [2], delvarx [5], get_uniq, is_number [1]
	is_number [2], is_struct, linecolors [1], linecolors [2], prstr [1], prstr [2]
 History     : Written 31 Dec 2001, D. Zarro (EITI/GSFC)

 Contact     : dzarro@solar.stanford.edu

 Modifications:
   24-Sep-2003, Zarro (GSI/GSFC) - fixed timerange plotting bug
   21-Oct-2003, Zarro (GSI/GSFC) - fixed timeunits bug
   17-Nov-2005, Kim Tolbert, lots of changes to enable the following:
     1. subtracting background
     2. cleaning glitches out of data
     3. using either SDAC or YOHKOH archive of GOES data
     4. calculating temperature and emission measure
     5. adding plotman capability
     6. adding a gui interface (in goes__gui.pro).  Access via o->gui.
   7-Dec-2005, Kim.  In getdata, if timerange is not passed in, use
     timerange=[tstart,tend] in case tstart,tend is a subset of data read in
     last read operation.
   21-Dec-2005, Kim.  Added a /yohkoh switch.  Same as sdac=0.
   23-Dec-2005, Kim.  Speed up getdata. Also use current plot for select_background.
     And made yohkoh the default.
   23-Dec-2005, Zarro. Added a few calls to 'temporary'
   9-Jan-2006, Kim.  Modified display_message to output to widget only when GUI is running
   9-Jan-2006, Kim.  Added bkfunc and bk properties.  Got rid of avback.  Background
     is now computed by fitting an exponential or a polynomial of order 0,1,2,or 3 to
     the data in the background intervals, and is stored as an array vs time, not 2 numbers.
     Also added option to compute and plot the total energy loss in flare, and the integral.
   11-Jan-2006, Kim.  Fix disabling integration times (setting itimes to -1)
   12-Jan-2006, Kim.  Added ps keyword to plot method to generate PostScript file
   17-Jan-2006, Kim.  Changed update checking method.  Instead of setting an update flag
     in set method as params are getting set, check just before new plot or getdata whether we
     need to reread data.  This requires saving 5 params that show what was read in last time,
     and new need_update method.
     Got rid of search, verbose, and update properties.  Replaced get_sat method with sat2index
     method - covers more types of input.
   18-Jan-2006, Zarro, reconciled _ref_extr
   20-Jan-2006, Kim.  Added lx stuff (X-ray energy loss), and added /times keyword to getdata
   20-Jun-2006, Kim.  Times input as seconds are interpreted as UTC/TAI (rel to 1958).  Fixed
     inconsistencies so this is true for btimes and itimes too.  Always use get(/btimes) instead
     of self.btimes (similarly for itimes).  All times are stored in properties as TAI seconds,
     and are converted to vms ascii format by the get method.  Note that internally, in some
     cases, ascii times may be temporarily converted to sec since 1979, e.g.  for
     compatibility with plotman.
    20-Aug-2006, Zarro (ADNET/GSFC) - added check for GOES FITS files
                                     in $GOES_FITS
    8-Sep-2006, Kim.  Added LX (X-ray energy loss rate) to items saved in save file.
    7-Nov-2006, Zarro (ADNET/GSFC) 
     - moved check for valid $GOES_FITS directory to RD_GOES_SDAC
    16-Nov-2006, Zarro (ADNET/GSFC) - removed recursive read call in  ::READ


GOES__GUI $SSW/gen/idl/goes/goes__gui.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GOES__GUI

 Purpose     : Provide a GUI for the GOES object

 Category    : synoptic objects

 Explanation : Provide a GUI to plot GOES flux, temperature, emission measure,
               select background time intervals, and write a save file.

 Syntax      : IDL> o->gui  (where o is a GOES object)

 History     : Written 17-Nov-2005, Kim Tolbert

 Contact     : kim.tolbert@gsfc.nasa.gov

 Modifications:
	9-Jan-2006, Kim.  Added options for background function, plotting bk, multiple
	  plots allowed or not (previously multiple was the only option), plotting energy
	  loss, selecting integration times and plotting integrated energy loss.
	10-Jan-2005, Kim.  Desensitize goes gui when select intervals widgets are started
	11-Jan-2006, Kim.  widget_info(/map) not allowed in 5.4 so added allow_multiple


GOES_CHIANTI_TEM $SSW/gen/idl/goes/goes_chianti_tem.pro
[Previous] [Next]
 Project:
     SDAC
 Name:
     GOES_CHIANTI_TEM

 Usage:
     goes_chianti_tem, fl, fs, temperature, emission_meas, satellite=goes 
                       [, /photospheric, date=date_if_GOES_6 ]

Purpose:
     This procedures computes the temperature and emission measure of the
     solar soft X-ray plasma measured with the GOES ionization chambers
     using CHIANTI spectral models with coronal or photospheric abundances

     Intended as a drop-in replacement for GOES_TEM that uses mewe_spec

Category:
     GOES, SPECTRA

Method:
     From the ratio of the two channels the temperature is computed 
     from a spline fit from a lookup table for 101 temperatures 
     then the emission measure is derived from the temperature and b8.
     All the hard work is done in two other routines containing the 
     coefficients for the responses.
     
Inputs:
     FL - GOES long wavelength flux in Watts/meter^2
     FS - GOES short wavelength flux
     
Keywords:
     satellite  - GOES satellite number, needed to get the correct response
     photospheric - use photospheric abundances rather than the default
              coronal abundnaces
     DATE   - ANYTIM format, eg 91/11/5 or 5-Nov-91, 
              used for GOES6 where the constant used to scale the reported 
              long-wavelength channel flux was changed on 28-Jun-1993 from 
              4.43e-6 to 5.32e-6, all the algorithms assume 5.32 so FL prior 
              to that date must be rescaled as FL = FL*(4.43/5.32)
 
Outputs: 
     Temperature   - Plasma temperature in units of 1e6 Kelvin
     Emission_meas - Emission measure in units of 1e49 cm-3
     
 CALLS: ***
	FCHECK, GOES_GET_CHIANTI_EM, GOES_GET_CHIANTI_TEMP, anytim [1], anytim [2]
	anytim [3], anytim [4], anytim [5]
 CALLED BY:
	GOES_TEM
Common Blocks:
     None.
     
Needed Files:
     goes_get_chianti_temp, goes_get_chianti_em contain the coefficients.
     also calls anytim, fcheck
     
 MODIFICATION HISTORY:
     Stephen White, 04/03/24
     Stephen White, 05/08/15: added the scl89 correction for GOES 8-12
     
 Contact     : Richard.Schwartz@gsfc.nasa.gov
     


GOES_DEGLITCH $SSW/gen/idl/goes/goes_deglitch.pro
[Previous] [Next]
 PROJECT:
	SDAC
 NAME: 
	GOES_DEGLITCH

 PURPOSE:
	This function finds and replaces telemetry spikes in GOES data.

 CATEGORY:
	SMM, HXRBS

 CALLING SEQUENCE:
	new_counts = goes_deglitch( old_flux,  RECUR=RECUR] )

 CALLS: ***
	CHECKVAR [1], F_DIV, INTERPOL, RESISTANT_Mean [3], Resistant_Mean [1]
	Resistant_Mean [2], checkvar [2]
 INPUTS:
	TIME     - Time of observation, a vector, any units, any reference.
		Used to parameterize spline interpolation.	
       OLD_FLUX - Array of 2 chan goes fluxes with possible glitches.
		data may be dimensioned 2 x nbins or nbins x 2

 OPTIONAL INPUTS:
	WIDTH	
 OUTPUTS:
       none explicit, only through commons;

 OPTIONAL OUTPUTS:
	none

 KEYWORD OUTPUTS:
	none
 COMMON BLOCKS:
	none

 SIDE EFFECTS:
	none

 RESTRICTIONS:
	none

 PROCEDURE:
	none

 MODIFICATION HISTORY:
	richard.schwartz@hxrbs.nascom.nasa.gov, 
	based on numerous routines.  24-nov-1997.


GOES_FITS_FILES $SSW/gen/idl/goes/goes_fits_files.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GOES_FITS_FILES

 Purpose     : Return a list of possible SDAC GOES file names for specified times and satellite

 Explanation : The SDAC archive files are daily files, named either:
    goxxyyyymmdd.fits for times >= 19-Jan-1999 (except for 21-Jan-1999)  or
    goxxyymmdd.fits   for times <= 19-Jan-1999 (and for 21-Jan-1999)
  where xx is the 2-digit satellite number, and yy, yyyy is a 2- or 4-digit year,
  mm is the month, and dd is the day of month.
  This routine returns the list of names constructed for each satellite for
  each day requested.  It's called by rd_goes_sdac which will determine which
  files actually exist.

  We want to return the file names in the following order: all days requested for
  the satellite requested, followed by all days requested for each of the remaining
  satellites.

 Category    : synoptic gbo

 Syntax      : IDL> files=goes_fits_files(stime,etime,sat=sat,_extra=extra)

 Inputs      : STIME, ETIME = start/end times to search

 Outputs     : List of filenames

 Keywords    : SAT - satellite number of files we think we want
               NO_COMPLEMENT = set to not include non-matching satellites

 CALLS: ***
	TIME2FILE, TRIM, anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
	is_number [1], is_number [2], timegrid
 CALLED BY:
	RD_GOES_SDAC
 History     : Written 12 July 2005, S. Bansal, (SSAI/GSFC)
 15-Dec-2005, Kim. Rewrote and changed header doc.
 26-Dec-2005, Zarro (L-3Com/GSFC) - trapped missing or non-existent satellite
 27-Dec-2005, Zarro (L-3Com/GSFC) - added /NO_COMPLEMENT


GOES_FLUXES $SSW/gen/idl/goes/goes_fluxes.pro
[Previous] [Next]
 Project     : SDAC     
                   
 Name        : GOES_FLUXES
               
 Purpose     : This procedure calculates the expected fluxes from the GOES X-ray
		detectors in Watts/meter^2 (reported units) as a function of
		temperature and emission measure.
               
 Category    : GOES
               
 Explanation : This procedure utilizes the tables in GOES_TEM made with MAKE_GOES_RESP which
		have already calculated the fluxes in both GOES channels for GOES 6,7,8,9 and
		the others (with somewhat less confidence)
               
 Use         : GOES_FLUXES, Temperature, Emission_meas, Flong, Fshort 
    
 Inputs      : Temperature - temperature in MegaKelvin
		Emission_meas- Emission measure in units of 1e49 cm^-3
               
 Opt. Inputs : None
               
 Outputs     : Flong - flux in Watts/meter^2 in GOES 1-8 Angstrom channel
		Fshort- flux in Watts/meter^2 in GOES 0.5-4 Angstrom channel

 Opt. Outputs: None
               
 Keywords    : SATELLITE- GOES satellite number
		DATE- Time of observation in ANYTIM format, needed for GOES6 which changed
		its long wavelength averaged transfer constant used in reporting measured
		current as Watts/meter^2
 Calls       : ***
	GOES_TEM
 CALLED BY:
	GE_WINDOW [1]
 Common      : None
               
 Restrictions: Temperature between 1 and 98 MegaKelvin, 
               
 Side effects: None.
               
 Prev. Hist  : VERSION 1, RAS, 30-JAN-1997

 Modified    : 


GOES_GET_CHIANTI_EM $SSW/gen/idl/goes/goes_get_chianti_em.pro
[Previous] [Next]
 Project:
     SDAC
 Name:
     GOES_GET_CHIANTI_EM

 Usage:
     goes_get_chianti_em, fl, temperature, emission_meas, sat=goes, /photospheric

Purpose:
     Called by GOES_CHIANTI_TEM to derive temperature and emission measures.
     This procedures computes the emission measure of solar plasma from the
     temperature derived from the B4/B8 ratio together with the flux B8 in the
     1-8 Angstrom channel using CHIANTI spectral models with coronal or
     photospheric abundances
     WARNING: fluxes are asssumed to be TRUE fluxes, so corrections
     such as the (0.70,0.85) scaling of GOES 8-12 must be applied before 
     use of this routine. GOES_CHIANTI_TEM applies these corrections.

Category:
     GOES, SPECTRA

Method:
     From the temperature the emission measure per unit B8 flux is computed
     from a spline fit from a lookup table for 101 temperatures logT=.02 apart

Inputs:
     FL - GOES long wavelength flux in Watts/meter^2
     TEMP - GOES temperature derived from GOES_GET_CHIANTI_TEMP in units of MK

Keywords:
     sat  - GOES satellite number, needed to get the correct response
     photospheric - use photospheric abundances rather than the default
             coronal abundnaces

Outputs:
     Emission_meas - Emission measure in units of cm-3 (i.e., NOT scaled)

 CALLED BY:
	GOES_CHIANTI_TEM
Common Blocks:
     None.

Needed Files:
     None

 MODIFICATION HISTORY:
     Stephen White, 24-Mar-2004: Initial version based on CHIANTI 4.2
     This routine created 11/28/06 using CHIANTI version 5.2

 Contact     : Richard.Schwartz@gsfc.nasa.gov


GOES_GET_CHIANTI_TEMP $SSW/gen/idl/goes/goes_get_chianti_temp.pro
[Previous] [Next]
 Project:
     SDAC
 Name:
     GOES_GET_CHIANTI_TEMP

 Usage:
     goes_get_chianti_temp, ratio, temperature, sat=goes, /photospheric

Purpose:
     Called by GOES_CHIANTI_TEM to derive temperature and emission measures.
     This procedures computes the temperature of solar plasma from the
     ratio B4/B8 of the GOES 0.5-4 and 1-8 Angstrom fluxes
     using CHIANTI spectral models with coronal or photospheric abundances
     All background subtraction, smoothing, etc, is done outside (before)
     this routine. Default abundances are coronal.
     WARNING: fluxes are asssumed to be TRUE fluxes, so corrections
     such as the (0.70,0.85) scaling of GOES 8-12 must be applied before
     use of this routine. GOES_CHIANTI_TEM applies these corrections.

Category:
     GOES, SPECTRA

Method:
     From the ratio the temperature is computed
     from a spline fit from a lookup table for 101 temperatures logT=.02 apart.

Inputs:
     RATIO - Ratio of GOES channel fluxes, B4/B8

Keywords:
     sat  - GOES satellite number, needed to get the correct response
     photospheric - use photospheric abundances rather than the default
             coronal abundances

Outputs:
     TEMP - GOES temperature derived from GOES_GET_CHIANTI_TEMP in units of MK

 CALLED BY:
	GOES_CHIANTI_TEM
Common Blocks:
     None.

Needed Files:
     None

 MODIFICATION HISTORY:
     Stephen White, 24-Mar-2004: Initial version based on CHIANTI 4.2
     This routine created 11/28/06 using CHIANTI version 5.2

 Contact     : Richard.Schwartz@gsfc.nasa.gov


GOES_GET_CHIANTI_VERSION $SSW/gen/idl/goes/goes_get_chianti_version.pro
[Previous] [Next]
 Project:
     SDAC
 Name:
     GOES_GET_CHIANTI_VERSION

 Usage:
     print, goes_get_chianti_version()

Purpose:
     Return chianti version used in goes_get_chianti_temp and goes_get_chianti_em

Category:
     GOES, SPECTRA

Method:
     Anyone who updates goes_get_chianti_temp and goes_get_chianti_em to use a newer
     version of chianti should modify this appropriately.

 CALLED BY:
	GOES__DEFINE
 MODIFICATION HISTORY:
     Kim Tolbert, 13-Dec-2005
     Kim, 30-Nov-2006.  Changed to 5.2 after onlining new tables from S. White


goes_grid [1] $SSW/gen/idl/goes/goes_grid.pro
[Previous] [Next]
   Name: goes_grid

   Purpose: draw grid on previously drawn goes plot (assume utplot)

 CALLED BY:
	goes_plot [1], goes_plot [2], goes_plot [3], goes_plot [4], goes_plot [5]
   History:
      1-sep-1992 (circa) (SLF)
      7-Dec-1992 (use normalized coords)
     13-Sep-1994 added grid_thick to control grid thickness
     14-Sep-1994 guard against  undefined grid_thick


GOES_MEWE_TEM $SSW/gen/idl/goes/goes_mewe_tem.pro
[Previous] [Next]
 Project:
   SDAC
 Name:
   GOES_MEWE_TEM

 Usage:
   goes_tem, fl, fs, temperature, emission_meas [, thomas=thomas, goes8=goes8]


Purpose:
   This procedures computes the temperature and emission measure of the
   solar soft X-ray plasma measured with the GOES ionization chambers.
   It uses the MEWE/MEYER spectral model.

Category:
   GOES, SPECTRA

Method:
   From the ratio of the two channels the temperature is computed either
   from the parameterized fit in Thomas et al (Solar Physics v95, 1983)
   or by interpolating from a lookup table computed by folding the
   GOES transfer functions with the MEWE emission line and continuum
   spectrum calculated by MEWE_SPEC.PRO.  The responses of the GOES ionization
   chamber were obtained from Donnelly et al 1977.  The responses for GOES8+
   were obtained by a private communication from Howard Garcia to Hugh Hudson
   subsequently passed along to Richard Schwartz and implemented in July 1996.
   Tables for GOES6 and GOES7 were communicated by Garcia to Schwartz on
   10 Oct 1996.  The most recent version, Nov 22 1996, corrects the Thomas
   parameterization by including the change in definition for the
   transmission-averaged short wavelength flux which occurred from GOES4 onward.
   These are reported in the GBAR_TABLE produced by GOES_TRANSFER.PRO
   While there are real changes in the response between versions of GOES, this
   was a simple change of divisor from (4-0.5) to (3-0.5) and not in any real
   difference between detectors such as a change in thickness of the beryllium
   window.  This change of definition results in the
   higher values found in Table 1 of Garcia, Sol Phys, v154, p275.  This issue is
   disussed on page 284 in paragraph 2 of section 3.1 of Garcia.

   An alternative interpolation table was created by Howard Garcia and reported
   by private communication and partially published in Solar Physics v154, p275.
   The tables for GOES2, GOES6, GOES7, and GOES8 have been renormalized to 1e49 cm-3
   and the ratio taken the ratio of the long current divided by the short current
   as given by Garcia.



Inputs:
   FL - GOES long wavelength flux in Watts/meter^2
   FS - GOES short wavelength flux
   This procedure will also work where Fl and Fs may be passed in as
   undefined or zero with the Temperature and Emission_meas set to scalars
   or arrays then Fl and Fs are returned.  Not valid for /thomas or /garcia!
Keywords:
   Thomas- if set then use the Thomas et al parameterization.
   GARCIA - if set, interpolate on Garcia generated tables from Raymond
       TEST- If set, a figure is plotted showing the difference in the algorithms
   The following keywords control the choice of satellite, if not
   selected the default is GOES6.  The choice of satellite applies
   to all three techniques.
   GOES10 - if set, use response for GOES10
   GOES8  - if set, use response for GOES8
   GOES9  - if set, use response for GOES9
   GOES6  - Use response for GOES6
   GOES7  - Use response for GOES7
   SATELLITE - Alternative to GOESN keyword, supply the GOES satellite
   number, i.e. for GOES6==> SATELLITE=6, range from 0-9
   DATE   - ANYTIM format, used for GOES6 where the constant used to
   scale the reported long-wavelength channel flux was changed on 28-Jun-1993
   from 4.43e-6 to 5.32e-6, all the algorithms assume 5.32 so FL prior
   to that date must be rescaled as FL = FL*(4.43/5.32)
Outputs:
   Temperature   - Plasma temperature in units of 1e6 Kelvin
   Emission_meas - Emission measure in units of 1e49 cm-3
   Currents      - a 2x Number_of_samples array of the currents in the
   long and short wavelength channels, respectively.
 CALLS: ***
	BREAK_PATH [1], BREAK_PATH [2], BREAK_PATH [3], CHECKVAR [1], CHKLOG [1]
	CHKLOG [2], FCHECK, GOES_TEM, GOES_TRANSFER, INTERPOL, LEGEND [1], LEGEND [2]
	LEGEND [3], LOC_FILE [1], LOC_FILE [2], LOC_FILE [3], anytim [1], anytim [2]
	anytim [3], anytim [4], anytim [5], checkvar [2], curdir [1], curdir [2]
	linecolors [1], linecolors [2], restgen [1], restgen [2]
 CALLED BY:
	GOES_TEM
Common Blocks:
   GOES_RESP_COM - Used to store response function values between calls

Needed Files:
   Stored lookup table stored in goes_resp2.dat
   goes_resp2.dat will usually be in the same directory as goes_tem.pro
   so will be found by loc_file

 MODIFICATION HISTORY:
   RAS, 93/2/10
   ras, 18-dec-1995, added loc_file for goes_resp.dat
   ras, 22-jul-1996, added GOES8 response
   VERSION 5, ras, 3-jul-1996, added GOES9 response
   VERSION 6, ras, 11-sep-1996, added Garcia response tables
   Also, output of emission_meas is 1-d vector just as for temperature
   Version 7, ras, 22-nov-1996, corrected Thomas parameterization for the
   GBARs for each of GOES(N).  GOES1 is very different from 6-9!!, therefore
   the formula is better applied to current ratios to obtain temperatures,
   then scaled to obtain emission measure. Also, returns vectors in
   all instances even when scalar fl and fs entered
   Version 8, ras, 25-nov-1996, SATELLITE keyword added,
   default satellite is GOES6
   Version 9, ras, 29-jan-1997, enable temperature and emission_meas to
   be outputs for non-garcia and non-thomas
   Version 10, ras, 2-feb-1997, sort the input ratio prior to interpolating
   to markedly increase speed of interpolation algorithm
   Version 11, RAS, 4-feb-1997, write the goes resp into a comprehensive structure
   to increase speed when switching between responses of GOES satellites!
     Concommitant changes implemented in MAKE_GOES_RESP.PRO
   Version 12, RAS, 5-feb-1997, using savegen and restgen for the saved response file
     Concommitant changes implemented in MAKE_GOES_RESP.PRO
   Version 13, RAS, 10-feb-1997, Table 1 values from Bornmann et al 1996 SPIE have
     been included.  This table claims that SEL has modified the GOES reported
     fluxes over and above the transfer functions
     reported by Garcia in Solar Phys 1994.
     Ultimately, the Bornman table should be merged into
     the transfer functions for GOES 8 and 9 where while the change
     in transfer function for GOES6 is already included.  The table
     herein doesn't include the GOES6 correction since it is already
     included.
   Version 14, RAS, 8-apr-1997, moved GOES6 time check until after Fl defined from Fl_in
   Version 15, RAS, 7-may-1997, check to see if input values, fl_in/fs_in or temperature,
    are already sorted if so, then no further sorting is performed.
   Version 16, RAS, 22-jul-1997 added current positional argument.
   Version 17, RAS, 3-aug-1998 added goes10 keyword argument.
   18-May-2004, RAS, force response to GOES10 for all satellites ge 10.
   183-Dec-2005, Kim. Renamed to goes_mewe_tem from goes_tem. Now goes_tem calls this.

 Contact     : Richard.Schwartz@gsfc.nasa.gov


goes_oplot $SSW/gen/idl/goes/goes_oplot.pro
[Previous] [Next]
 Name: goes_oplot

 Purpose: Overlay a GOES plot with bad points and level information.

 Explanation:  An X is drawn on the Y curve at the location of elements that
   had to be interpolated because of glitches.  The letter A,B,C, etc is drawn
   to the right of the Y axis at the level of that indicator (A=1.e-8, etc).

   This is called via the addplot_name, addplot_args mechanism from
   the xyplot plot object.  All of the arguments (xcept dim1_xxx) were put
   into the addplot_args structure, which was set into the xyplot object.
   When this is called from the xyplot object, it joins the structure of
   its own properties with this structure - that's where dim1_xxx comes from.

 Input Keywords:
   markbad - If set, mark bad points with Xs
   showclass - If set, display A,B,C,M,X indicators at right of plot
   tarray    - array of times
   ydata - yarray of plot (may be ntimes or ntimesx2channels)
   ybad - elements in ydata that were bad
   dim1_use - channel we're plotting (if ydata is (ntx2), dim1_use
     may be 0, or 1, or [0,1] )
   dim1_colors - color for each channel (blank string array if none)

 Written: Kim Tolbert 25-Aug-2005

 Modifications:
 12-Jan-2006, Kim.  Use dim1_colors from xyplot object for colors of bad points
 CALLS:


goes_plot [1] $SSW/gen/idl/goes/plot_goes.pro
[Previous] [Next]
   Name: goes_plot

   Purpose: plot goes x-ray data (Yohkoh structure) 

   Input Parameters:
      input1 - user start time or goes xray data record structure array
      input2 - user stop time

   Optional Keyword Paramters:
      fem - if set, overplot Yohko ephemeris grid (call fem_grid)
      fillnight - (pass to fem_grid) - polyfill Yohkoh nights
      fillsaa   - (pass to fem_grid) - polyfill Yohkoh saas
      saa       - (pass to fem_grid) - show saa events overlay grid
      low 	 - if set, only plot low energy
      high      - if set, only plot high energy
      title     - user title (appended to default title predicate)
      nodeftitle- if set, dont append default title predicate
	color    - color of lines
      ascii     - if set, use sec ascii files in $SSWDB/goes/xray/

   Calling Sequence:
      plot_goes,'5-sep-92'		; start time + 24 hours
      plot_goes,'5-sep-92',/three	; same, but use 3 second data
      plot_goes,'5-sep-92',6		; start time +  6 hours
      plot_goes,'5-sep-92','7-sep-92'  ; start time / stop time
      plot_goes,gxtstr			; input goes records from rd_gxt
      plot_goes,'5-sep',/fem		; overplot Yohkoh ephemeris grid
      plot_goes,'5-sep',/fillnight	; ditto, but fill in Yohkoh nights 
      plot_goes,'1-jun','30-jul',/low  ; only plot low energy

      plot_goes,t1,t2,/one_minute	; one minute averages (default)
      plot_goes,t1,t2,/five_minute	; five minute averages 
      plot_goes,t1,t2,/auto		; use environmental goes_auto_range
      plot_goes,t1,t2,auto=[.25,1.,5]  ; auto range (3 second/1 min/5 min)
      plot_goes,t1,t2,/hc or /hardcopy	; PS hardcopy (default orient=landscape)
      plot_goes,t1,t2,/portrait	; PS hardcopy (orient=portrait)

   History: slf 22-sep-1992
	     slf 11-oct-1992 - added low and high keywords, add documentation
	     slf 26-oct-1992 - added nodeftitle keyword
            slf 15-mar-1993 - return on no data
	     mdm 24-Mar-1993 - corrected error due to integer overflow
	     slf 19-Jul-1993 - implemented LO and HI keyword function
	     slf 29-jul-1993 - added max_value keyword (pass to utplot)
	     slf  4-sep-1993 - add charsize, no6, no7 keywords
	     slf 22-Nov-1993 - added lots of plot keyowords
	     jrl  1-dec-1993 - added thick, charthick, xtitle keywords
	     slf  5-dec-1993 - set default xstyle = 1
	     slf, 7-dec-1993 - a) added three (second) keyword and functions
			       c) gave up on any and all hopes for clean logic
	     slf 15-dec-1993 - a) yrange w/gxt input b) check deriv(valid)
			       cleanup the input logic a little.
	     ras 17-aug-1994 - no longer use call procedure by setting proc to 
			       'utplot' or 'utplot_io' by just calling utplot and
			       setting ytype as needed
            slf, 19-aug-94  - make no6 default if start time after 17-aug
            dmz 21-Aug-1994 - lumped all plot keywords into _EXTRA
                              so that keyword inheritance will work with
                              UTPLOT. Also replaced OUTPLOT by OPLOT and
                              fixed potential bug in DVALID
            slf, 25-aug-94 - merged divergent changes (19-aug / 21-aug)
			      add /fast switch (use saved version if avail)
	     gal, 13-aug-94 - added grid_thick switch to control goes grids.
	     mdm, 20-Sep-94 - Added TIMERANGE option
            slf,  9-oct-94 - Added NOYLAB keyword
            slf, 30-aug-95 - add ONE_MINUTE and FIVE_MINUTE keywords
			      add auto_ranging (via environ= goes_auto_range)
			      preferentially use G71 instead of GXT if availble
            slf, 26-sep-95 - protect against missing G6 
	     slf, 28-sep-95 - add HC, HARDCOPY, LANDSCAPE, and PORTRAIT switches
            slf, 5-oct-95  - add STATUS keyword (1=some data, 0=none)
            jmm, 8-aug-96  - Fixed bugs to allow for the plotting of input
                             data structures, changed a reference to GXR_DATA_REC
                             to GXD_DATA_REC.    
            slf, 13-aug-96 - make GOES 9 default after 1-july-1996
	                      (replace GOES 7 , no goes7 after 14-aug-96)
            slf, 18-aug-96 - add goes91/95 to the ydb_exist check
            slf, 30-Jul-98 - GOES 9 off , make GOES8 the default
            slf, 24-apr-99 - enable COLOR
            Zarro, 4-Nov-99 - fixed vector bug when plotting input data
            slf, 3-Jan-1999 - put wrapper around 'input1/input2' - pseudo Y2K 
            slf, 16-apr-2003 - add GOES12, get time dependent default sat# from get_goes_defsat.pro
            Zarro, 23 Apr-2004 - add check for GXRIN
 CALLS: ***
	ADDTIME [1], ADDTIME [2], CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], EXIST
	FILE_EXIST [2], GETUTBASE [1], GETUTBASE [2], LOADCT, PLOT_GOES, STR2ARR [1]
	STR2ARR [2], UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5], UTPLOT [6]
	WDEF [1], WDEF [2], anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
	anytim2ints [1], anytim2ints [2], concat_dir [4], data_chk [1], data_chk [2]
	deriv_arr [1], deriv_arr [2], fem_grid [1], fem_grid [2], file_exist [1]
	file_exist [3], fl_goesplot [1], fl_goesplot [2], fl_goesplot [3], fmt_tim [1]
	fmt_tim [2], get_goes_defsat [1], get_goes_defsat [2], get_logenv [1]
	get_logenv [2], goes_grid [1], goes_grid [2], gt_day [1], gt_day [2]
	int2secarr [1], int2secarr [2], pprint [1], pprint [2], prstr [1], prstr [2]
	rd_goesx_ascii, rd_gxd [1], rd_gxd [2], rd_gxd [3], rd_gxt, syst2ex [1], syst2ex [2]
	syst2ex [3], tbeep [1], tbeep [2], tbeep [3], ut_time [1], ut_time [2]
	ydb_exist [1], ydb_exist [2], ydb_exist [3], ydb_exist [4]
  Side Effects:
     /fast switch causes color table 15 load


goes_plot [2] $SSW/gen/idl_fix/soft/old240/plot_goes.pro
[Previous] [Next]
   Name: goes_plot

   Purpose: plot goes x-ray data (Yohkoh structure) 

   Input Parameters:
      input1 - user start time or goes xray data record structure array
      input2 - user stop time

   Optional Keyword Paramters:
      fem - if set, overplot Yohko ephemeris grid (call fem_grid)
      fillnight - (pass to fem_grid) - polyfill Yohkoh nights
      fillsaa   - (pass to fem_grid) - polyfill Yohkoh saas
      saa       - (pass to fem_grid) - show saa events overlay grid
      low 	 - if set, only plot low energy
      high      - if set, only plot high energy
      title     - user title (appended to default title predicate)
      nodeftitle- if set, dont append default title predicate
	color    - color of lines

   Calling Sequence:
      plot_goes,'5-sep-92'		; start time + 24 hours
      plot_goes,'5-sep-92',/three	; same, but use 3 second data
      plot_goes,'5-sep-92',6		; start time +  6 hours
      plot_goes,'5-sep-92','7-sep-92'  ; start time / stop time
      plot_goes,gxtstr			; input goes records from rd_gxt
      plot_goes,'5-sep',/fem		; overplot Yohkoh ephemeris grid
      plot_goes,'5-sep',/fillnight	; ditto, but fill in Yohkoh nights 
      plot_goes,'1-jun','30-jul',/low  ; only plot low energy
      

 CALLS: ***
	ADDTIME [1], ADDTIME [2], CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], EXIST
	FILE_EXIST [2], GETUTBASE [1], GETUTBASE [2], LOADCT, PLOT_GOES, STR2ARR [1]
	STR2ARR [2], UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5], UTPLOT [6]
	WDEF [1], WDEF [2], anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
	anytim2ints [1], anytim2ints [2], concat_dir [4], data_chk [1], data_chk [2]
	deriv_arr [1], deriv_arr [2], fem_grid [1], fem_grid [2], file_exist [1]
	file_exist [3], fl_goesplot [1], fl_goesplot [2], fl_goesplot [3], fmt_tim [1]
	fmt_tim [2], get_goes_defsat [1], get_goes_defsat [2], get_logenv [1]
	get_logenv [2], goes_grid [1], goes_grid [2], gt_day [1], gt_day [2]
	int2secarr [1], int2secarr [2], pprint [1], pprint [2], prstr [1], prstr [2]
	rd_goesx_ascii, rd_gxd [1], rd_gxd [2], rd_gxd [3], rd_gxt, syst2ex [1], syst2ex [2]
	syst2ex [3], tbeep [1], tbeep [2], tbeep [3], ut_time [1], ut_time [2]
	ydb_exist [1], ydb_exist [2], ydb_exist [3], ydb_exist [4]
   History: slf 22-sep-1992
	     slf 11-oct-1992 - added low and high keywords, add documentation
	     slf 26-oct-1992 - added nodeftitle keyword
            slf 15-mar-1993 - return on no data
	     mdm 24-Mar-1993 - corrected error due to integer overflow
	     slf 19-Jul-1993 - implemented LO and HI keyword function
	     slf 29-jul-1993 - added max_value keyword (pass to utplot)
	     slf  4-sep-1993 - add charsize, no6, no7 keywords
	     slf 22-Nov-1993 - added lots of plot keyowords
	     jrl  1-dec-1993 - added thick, charthick, xtitle keywords
	     slf  5-dec-1993 - set default xstyle = 1
	     slf, 7-dec-1993 - a) added three (second) keyword and functions
			       c) gave up on any and all hopes for clean logic
	     slf, 11-dec-1993 - removed max form current rev so this could
				run under old versions of idl (w/new features)


goes_plot [3] $SSW/gen/idl_fix/soft/old310/plot_goes.pro
[Previous] [Next]
   Name: goes_plot

   Purpose: plot goes x-ray data (Yohkoh structure) 

   Input Parameters:
      input1 - user start time or goes xray data record structure array
      input2 - user stop time

   Optional Keyword Paramters:
      fem - if set, overplot Yohko ephemeris grid (call fem_grid)
      fillnight - (pass to fem_grid) - polyfill Yohkoh nights
      fillsaa   - (pass to fem_grid) - polyfill Yohkoh saas
      saa       - (pass to fem_grid) - show saa events overlay grid
      low 	 - if set, only plot low energy
      high      - if set, only plot high energy
      title     - user title (appended to default title predicate)
      nodeftitle- if set, dont append default title predicate
	color    - color of lines

   Calling Sequence:
      plot_goes,'5-sep-92'		; start time + 24 hours
      plot_goes,'5-sep-92',/three	; same, but use 3 second data
      plot_goes,'5-sep-92',6		; start time +  6 hours
      plot_goes,'5-sep-92','7-sep-92'  ; start time / stop time
      plot_goes,gxtstr			; input goes records from rd_gxt
      plot_goes,'5-sep',/fem		; overplot Yohkoh ephemeris grid
      plot_goes,'5-sep',/fillnight	; ditto, but fill in Yohkoh nights 
      plot_goes,'1-jun','30-jul',/low  ; only plot low energy
      plot_goes,/fast			; (site dependeent) plot saved image
      

 CALLS: ***
	ADDTIME [1], ADDTIME [2], CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], EXIST
	FILE_EXIST [2], GETUTBASE [1], GETUTBASE [2], LOADCT, PLOT_GOES, STR2ARR [1]
	STR2ARR [2], UTPLOT [1], UTPLOT [2], UTPLOT [3], UTPLOT [4], UTPLOT [5], UTPLOT [6]
	WDEF [1], WDEF [2], anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
	anytim2ints [1], anytim2ints [2], concat_dir [4], data_chk [1], data_chk [2]
	deriv_arr [1], deriv_arr [2], fem_grid [1], fem_grid [2], file_exist [1]
	file_exist [3], fl_goesplot [1], fl_goesplot [2], fl_goesplot [3], fmt_tim [1]
	fmt_tim [2], get_goes_defsat [1], get_goes_defsat [2], get_logenv [1]
	get_logenv [2], goes_grid [1], goes_grid [2], gt_day [1], gt_day [2]
	int2secarr [1], int2secarr [2], pprint [1], pprint [2], prstr [1], prstr [2]
	rd_goesx_ascii, rd_gxd [1], rd_gxd [2], rd_gxd [3], rd_gxt, syst2ex [1], syst2ex [2]
	syst2ex [3], tbeep [1], tbeep [2], tbeep [3], ut_time [1], ut_time [2]
	ydb_exist [1], ydb_exist [2], ydb_exist [3], ydb_exist [4]
   History: slf 22-sep-1992
	     slf 11-oct-1992 - added low and high keywords, add documentation
	     slf 26-oct-1992 - added nodeftitle keyword
            slf 15-mar-1993 - return on no data
	     mdm 24-Mar-1993 - corrected error due to integer overflow
	     slf 19-Jul-1993 - implemented LO and HI keyword function
	     slf 29-jul-1993 - added max_value keyword (pass to utplot)
	     slf  4-sep-1993 - add charsize, no6, no7 keywords
	     slf 22-Nov-1993 - added lots of plot keyowords
	     jrl  1-dec-1993 - added thick, charthick, xtitle keywords
	     slf  5-dec-1993 - set default xstyle = 1
	     slf, 7-dec-1993 - a) added three (second) keyword and functions
			       c) gave up on any and all hopes for clean logic
	     slf 15-dec-1993 - a) yrange w/gxt input b) check deriv(valid)
			       cleanup the input logic a little.
	     ras 17-aug-1994 - no longer use call procedure by setting proc to 
			       'utplot' or 'utplot_io' by just calling utplot and
			       setting ytype as needed
	     slf, 19-aug-94  - make no6 default if start time after 17-aug
            slf, 24-sep-94  - allow /fast switch (site specific)

            slf, 12-oct-94  - add noylab and intlab switches to allow
			       firstlight format under old idl (flareN...)


GOES_SAT $SSW/gen/idl/goes/goes_sat.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GOES_SAT

 Purpose     : convenient list of GOES satellite names

 Category    : synoptic gbo

 Syntax      : IDL> print, goes_sat()

 Inputs      : None

 Outputs     : GOES10 GOES8 GOES9 GOES7 GOES6

 Keywords    : NUMBER = return GOES satellite numbers

 CALLS: ***
	is_number [1], is_number [2]
 CALLED BY:
	GOES__DEFINE, RD_GOES, RD_GOES_SDAC
 History     : Written 18 June 2002, D. Zarro, LAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GOES_SDAC_SERVER $SSW/gen/idl/goes/goes_sdac_server.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GOES_SDAC_SERVER

 Purpose     : return available SDAC GOES FITS data server

 Category    : synoptic sockets

 Inputs      : None

 Outputs     : SERVER = SDAC GOES data server name

 Keywords    : FULL - If set, return full url
               NETWORK = returns 1 if network to that server is up
               PATH = path to data

 CALLS: ***
	HAVE_NETWORK
 CALLED BY:
	GOES_SERVER
 History     : Written  29-Dec-2001, Zarro (EITI/GSFC)
               Modified 1-Jun-2005, Zarro (L-3Com/GSFC)
               - added sdac keyword, and set server to hesperia for sdac.
               - added full keyword to return full http://name .
               - don't check sohowww alternate server if sdac is
                 selected.
               Modified 15-Nov-2006, Zarro (ADNET/GSFC) 
               - added UMBRA as primary SDAC server
               - added PATH return keyword
               - removed SDAC keyword

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GOES_SERVER $SSW/gen/idl/goes/goes_server.pro
[Previous] [Next]
 Project     : HINODE/EIS

 Name        : GOES_SERVER

 Purpose     : return available GOES data server

 Category    : synoptic sockets

 Inputs      : None

 Outputs     : SERVER = GOES server name

 Keywords    : SDAC = return server for SDAC GOES FITS files

 CALLS: ***
	GOES_SDAC_SERVER, GOES_YOHKOH_SERVER
 CALLED BY:
	GOES__DEFINE, RD_GOES_SDAC, rd_week_file [2], weekid [2], ydb_exist [2]
 History     : Written 16-Nov-2006, Zarro (ADNET/GSFC)

 Contact     : DZARRO@SOLAR.STANFORD.EDU


GOES_TEM $SSW/gen/idl/goes/goes_tem.pro
[Previous] [Next]
 Name:
	GOES_TEM
 Purpose:
     Drop-in replacement for old TEM_CALC that allows abundance choices.
	TEM_CALC calculates the temperature and emission measure from the GOES ionization X-ray chambers.

 	The data array must already be cleaned of gain change spikes.  The background
	in each channel is input through avback or bkarray calling argument.

 Explanation:
	This procedure organizes the inputs and outputs into the GOES_MEWE_TEM and GOES_CHIANTI_TEM procedures.
   GOES_MEWE_TEM interpolates on
	the ratio between the long and short wavelength channel fluxes using pre-calcuated tables for the
	fluxes at a series of temperatures for fixed emission measure.  Note that ratios which lie outside of
	the default lower limits for the fluxes,
	and particularly negative values in the case of background subtracted inputs, are
	returned with fixed values of 4.0 MegaKelvin and 1.0e47 cm-3 for the temperature and emission measure.
	Normally, those limits are 1e-7 and 1e-9 for the long and short wavelength channel inputs.

 Keywords:
  Mandatory Inputs:
	TARRAY- time array
	YCLEAN-  GOES data cleaned of spikes.

  Optional Inputs:
   AVBACK - A single background value for each channel
   BKARRAY - An array of background values for each channel (matches yclean array)
	NOBACKSUB- If set, no background is subtracted
	SAVESAT  - Number of GOES satellite, calibration changes at 8
	DATE - date in anytim format if tarray is not fully qualified (only sec of day)
  Outputs:

	NOSUBTEMPR-temperature in Megakelvin, if background not subtracted.
	NOSUBEMIS-emission measure in 1e49 cm-3, if background subtracted.

	TEMPR- temperature in Megakelvin, if background subtracted.
	EMIS-emission measure in 1e49 cm-3, if background subtracted.
	ADUND-abundances to use: 0=coronal, 1=photospheric, 2=Meyer
 CALLED BY:
	GOES_FLUXES, GOES_MEWE_TEM, GOES__DEFINE, goes_reducer [1], goes_teem
	goesem_eqn [1], goest_eqn [1]
 Common Blocks:
	None
 Calls: ***
	AVERAGE, GOES_CHIANTI_TEM, GOES_MEWE_TEM, anytim [1], anytim [2], anytim [3]
	anytim [4], anytim [5]
 History:
	Kim Tolbert 11/92
	Documented RAS, 15-May-1996,
	changed cutoff limits, changed default response
	to GOES_TEM, eback and sback removed as keywords since they did nothing.
	ras, 22-july-1996, add savesat
	ras, 20-nov-1996, added GOES6 and GOES7 as GOES_TEM was upgraded
	ras, 29-jan-1997, add date keyword needed for correct GOES6 calculation!
	ras, 4-aug-1998, richard.schwartz@gsfc.nasa.gov, integrate GOES10 and future GOESN.
	smw, 14-feb-2005, add abundance keyword , calls to chianti routines for
                       photospheric or coronal abundance cases
   Kim, 13-Dec-2005, This was called sw_tem_calc by smw.  Change to goes_tem and
      change the routine it calls for mewe (previously goes_tem) to goes_mewe_tem. Also
      put avback in calling arguments instead of in common.
   Kim, 9-Jan-2006.  Added bkarray keyword, and setting avback_ch0


GOES_TEMP_DIR $SSW/gen/idl/goes/goes_temp_dir.pro
[Previous] [Next]
 Project     : HESSI
                  
 Name        : GOES_TEMP_DIR
               
 Purpose     : return name of temporary directory for caching of local GOES data
                             
 Category    : synoptic utility
               
 Syntax      : IDL> dir=goes_temp_dir()
                                        
 Outputs     : dir= directory name
                   
 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], GET_TEMP_DIR, TEST_DIR
	concat_dir [4]
 CALLED BY:
	GOES__DEFINE, RD_GOES_SDAC, rd_week_file [2], weekid [2], ydb_exist [2]
 History     : 15 Apr 2002, Zarro (L-3Com/GSFC)

 Contact     : dzarro@solar.stanford.edu


GOES_TF $SSW/gen/idl/goes/make_goes_chianti_response.pro
[Previous] [Next]
 NAME:    GOES_TF 
 
 PURPOSE: 
 This procedure returns the fitted Transfer Functions for one pair of 
 GOES XRS soft X-ray spectrometers, depending on which satellite is 
 selected (the default is GOES-1).  Note that the returned functions 
 are identical for GOES-1 through GOES-5, though individual G-bar values 
 are given for each satellite in the GOES series (except GOES-3, for 
 which data are not available; GOES-2 values are returned for it). 
 The Transfer Function fits must first be computed by GOES_TF_COEFF. 
 
 CATEGORY: 
  GOES, SPECTRAL ANALYSIS 
 
 CALLING SEQUENCE: 
  goes_tf, sat_number, date='1988/11/22', wavescale=w, $ 
         tfshort=ts, tflong=tl, gbshort=gs, gblong=gl, $ 
         file='C:\Data\goes_tf_coeff.sav' 
 
 
 INPUTS:  SAT_NUMBER    GOES satellite number to be used. [ default = 1 ] 
 
 KEYWORD PARAMETERS: 
  WAVESCALE     The wavelength scale [in A] for both Transfer Functions. 
                 (If not provided, a default wavelength set is returned.) 
  TFSHORT       Transfer function [in Amp/(Watt/meter^2)] for short channel. 
  TFLONG        Transfer function [in Amp/(Watt/meter^2)] for long channel. 
  GBSHORT       Conversion parameter (G-bar) for short channel. 
  GBLONG        Conversion parameter (G-bar) for long channel. 
  FILE          Filename in which results of GOES_TF_COEFF are stored 
                   [ def = 'C:\Data\goes_tf_coeff.sav' ] 
  DATE          Time in ANYTIM format, used for GOES-6 which had a change 
                   in its value of GBLONG on 1983 June 28. [ def = after ] 
 OUTPUTS: 
  In keyword format, so that the output order does not matter. 
 
 CALLED BY:
	GOES_TF_COEFF, make_goes_chianti_response [1]
	make_goes_chianti_response [2], make_goes_chianti_response [3]
	make_goes_chianti_response [4]
 PROCEDURE: 
 Transfer Functions are defined in five wavelength segments, as follows: 
   Seg 0    wave lt W1              TF_short = 10^(poly(wave,coeff(sat-1,0,*))) 
   Seg 1    wave ge W1 and lt W2    TF_short = 10^(poly(wave,coeff(sat-1,1,*))) 
   Seg 2    wave ge W2              TF_short = 10^(poly(wave,coeff(sat-1,2,*))) 
   Seg 3    wave lt W3              TF_long  = 10^(poly(wave,coeff(sat-1,3,*))) 
   Seg 4    wave ge W3              TF_long  = 10^(poly(wave,coeff(sat-1,4,*))) 
 
  where  W1,W2,W3, & COEFF  are restored from a file created by GOES_TF_COEFF. 
 
 CALLS: ***
	CHIANTI_VERSION, CH_SYNTHETIC, DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4]
	FCHECK, FILE_EXIST [2], FOLD_SPEC_RESP, GENERATE_SPECTRA, GET_ENVIRON
	GOES_TF_COEFF, INT_TABULATED, MAKE_CHIANTI_SPEC, POLY, POLY_FIT, TABLES_02_TO_PRO
	TODAY, anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], delvarx [5]
	file_exist [1], file_exist [3], make_goes_chianti_response [1]
	make_goes_chianti_response [2], make_goes_chianti_response [3]
	make_goes_chianti_response [4], restgen [1], restgen [2], savegen [1]
	savegen [2]
 COMMON BLOCKS:  None. 
 
 MODIFICATION HISTORY: 
  Roger.J.Thomas@nasa.gov, 2003 July 25. 
  S White: added GOES 12 June 2004


GOES_TF_COEFF $SSW/gen/idl/goes/make_goes_chianti_response.pro
[Previous] [Next]
 NAME:    GOES_TF_COEFF 
   Richard/Roger's goes_tf_coeff with GOES 11, 12 calibration added
   using reports supplied by Rodney Viereck, NOAA, and minor
   corrections to typos in GOES 10 array
   [ Note:  Some input values deleted by RJT due to errors in original! ] 
 
 PURPOSE: 
 This procedure returns absorption-edge wavelenghts, polynomial coefficients 
  of fits to the log10 measured transfer-functions, and G-bar values for all 
  available GOES XRS soft X-ray spectrometers (up to GOES-10).  Note that 
  the returned coefficients are identical for GOES-1 through GOES-5, though 
  individual G-bar values are given for each satellite (except GOES-3, for 
  which data are not available; GOES-2 values are returned for it). 
 
 CATEGORY: 
  GOES, SPECTRAL ANALYSIS 
 
 CALLING SEQUENCE: 
  goes_tf_coeff,date='1988/11/22',edge=e,coeff=c,gbshort=s,gblong=l 
             [ ,/new , file='C:\Data\goes_tf_coeff.sav' ] 
 
 INPUTS:  None. 
 
 KEYWORD PARAMETERS: 
  DATE          Time in ANYTIM format, used for GOES-6 which had a change 
                  in its value of GBLONG on 1983 June 28. [ def = after ] 
  EDGE          Wavelength edges for both channels [in units of A]. 
  COEFF         Coefficients for polynomial fits to transfer functions. 
  GBSHORT       Conversion parameters (G-bar) for short channels. 
  GBLONG        Conversion parameters (G-bar) for long channels. 
  NEW           Saves results, if set. Otherwise, results are restored. 
  FILE          File used to store/restore results. 
                  [ def = 'C:\Data\goes_tf_coeff.sav' ] 
 OUTPUTS: 
  Arrays in keyword format, so that the output order does not matter. 
 
 CALLED BY:
	GOES_TF, make_goes_chianti_response [1], make_goes_chianti_response [2]
	make_goes_chianti_response [3], make_goes_chianti_response [4]
 PROCEDURE: 
  All of the original GOES transfer function values [in Amp/(Watt/meter^2)] are 
  taken from VERSION 6 of GOES_TRANSFER, and are said to be from R.F. Donnelly, 
  R.N. Grubb, & F.C. Cowley (1977), NOAA Tech.Memo. ERL SEL-48 (for GOES-1) and 
  from Howard Garcia, private communications to Richard Schwartz (for GOES-2 
  through GOES-10).  However, Roger J. Thomas has deleted a number of these  
  values which were clearly in error, as indicated below. 
 
  These transfer functions allow one to integrate over a solar spectrum to 
  get the response of the GOES detectors.  Reported GOES values of solar 
  X-ray fluxes (in units Watt/meter^2) have been converted from the actual 
  measurements (in units of Amp) by means of the wavelength-averaged transfer 
  function constants, here called GBSHORT and GBLONG, for the 0.5-4.0 and 
  1.0-8.0 Angstrom channels, respectively. 
 
 EDGE is in the form [W1,W2,W3], COEFF is in the form [SatIndex,Segment,Param]. 
 GBSHORT & GBLONG are in the form [GOES1value, GOES2value, ..., GOES10value]. 
 Transfer Functions are defined in five wavelength segments, as follows: 
   Seg 0    wave lt W1              TF_short = 10^(poly(wave,coeff(sat-1,0,*))) 
   Seg 1    wave ge W1 and lt W2    TF_short = 10^(poly(wave,coeff(sat-1,1,*))) 
   Seg 2    wave ge W2              TF_short = 10^(poly(wave,coeff(sat-1,2,*))) 
   Seg 3    wave lt W3              TF_long  = 10^(poly(wave,coeff(sat-1,3,*))) 
   Seg 4    wave ge W3              TF_long  = 10^(poly(wave,coeff(sat-1,4,*))) 
 
 CALLS: ***
	CHIANTI_VERSION, CH_SYNTHETIC, DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4]
	FCHECK, FILE_EXIST [2], FOLD_SPEC_RESP, GENERATE_SPECTRA, GET_ENVIRON, GOES_TF
	INT_TABULATED, MAKE_CHIANTI_SPEC, POLY, POLY_FIT, TABLES_02_TO_PRO, TODAY
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5], delvarx [5]
	file_exist [1], file_exist [3], make_goes_chianti_response [1]
	make_goes_chianti_response [2], make_goes_chianti_response [3]
	make_goes_chianti_response [4], restgen [1], restgen [2], savegen [1]
	savegen [2]
 COMMON BLOCKS:  None. 
 
 MODIFICATION HISTORY: 
  Roger.J.Thomas@nasa.gov, 2003 July 25. 
  Based heavily on VERSION 6 of GOES_TRANSFER written by Richard A. Schwartz  
  SDAC/GSFC/HSTX 1998 August 03.  But the GOES-6 conversion date was corrected  
  from 1993 June 28 to 1983 June 28.  Also, a number of Transfer-Function values 
  in GOES_TRANSFER were found to be in error; they have been deleted here. 
  All such changes from GOES_TRANSFER are summarized below. 
 
  GOES-6 date-test is changed from 4.5722880e+08 to 1.416096e8. 
  The following Transfer Function values have been deleted: 
 
                               Wave-Dependant Transfer Function Values 
                               ---------------------------------------    
     SatNum  Chan   Wavelength   Original    RJT-Estimate    Action: 
      1-5     S       0.7        2.03e-6       4.11e-6       Deleted 
      6,7     S       6.2        3.70e-8       2.11e-8       Deleted 
      6,7     S       6.4        2.80e-8       9.61e-9       Deleted 
       6      L       3.8-       5.63e-6       5.74e-6       Deleted 
       6      L       3.8+       3.92e-6       4.00e-6       Deleted 
       7      L      16.0        3.40e-11      5.00e-12      Deleted 
      10      S       7.0        1.70e-11      7.28e-10      Deleted 

 S. White, 2004: added GOES 12.


GOES_TRANSFER $SSW/gen/idl/goes/goes_transfer.pro
[Previous] [Next]
 PROJECT: SDAC

 NAME:    GOES_TRANSFER
                                                                                                            
 PURPOSE:                                                                                                   
 This procedure computes the transfer functions for the                                                     
 GOES XRS soft-xray spectrometers.                                                                          
                                                                                                            
 CATEGORY:                                                                                                  
  GOES, SPECTRAL ANALYSIS                                                                                   
                                                                                                            
 CALLING SEQUENCE:                                                                                          
  GOES_TRNFR, gshort_trnfr=gshort_trnfr, gshort_lambda=gshort_lambda, $                                     
         glong_trnfr=glong_trnfr, glong_lambda=glong_lambda, $                                              
         bar_gshort=bar_gshort, bar_glong=bar_glong                                                         
                                                                                                            
 INPUTS:                                                                                                    
 None.                                                                                                      
                                                                                                            
 KEYWORD PARAMETERS:                                                                                        
 GSHORT_TRNFR-   Transfer function for short wavelengths.                                                   
 GSHORT_LAMBDA-  Wavelengths for which the transfer fnc is defined.                                         
 GLONG_TRNFR-    Transfer function for long wavelengths.                                                    
 GLONG_LAMBDA-   Wavelengths for which the transfer fnc is defined.                                         
 BAR_GSHORT-     Wavelength averaged transfer function for short wavelength.                                
 BAR_GLONG-      Wavelength averaged transfer function for long wavelength.                                 
 GOES6-          If set, use GOES6 response.                                                                
 GOES7-          If set, use GOES7 response.                                                                
 GOES8-          If set, use GOES8 response.                                                                
 GOES9-          If set, use GOES9 response.                                                                
 GBAR_TABLE-     A structure which gives the Wavelength averaged transfer function for
                 each GOES included for both channels
 DATE-           Time in ANYTIM format, used for GOES6 which changes the value
                 of gbar.short on 28 June 1993
 OUTPUTS:                                                                                                   
 In keyword format, so you don't have to remember the output order.                                         
                                                                                                            
 CALLED BY:
	GOES_MEWE_TEM, MAKE_GOES_RESP
 PROCEDURE:                                                                                                 
 The GOES-1 transfer functions defined on the wavelengths in                                                
 Donnelly et al 1977.                                                                                       
 Transfer functions are given in units of amp /watt meter^2                                                 
                                                                                                            
 Transfer functions allow you to integrate over a solar spectrum to                                         
 get the response of the GOES detectors.  Units of GOES detectors already                                   
 has had its current in AMP converted to Watts/meter^2 using the                                            
 wavelength averaged transfer functions, here called BAR_GSHORT and                                         
 BAR_GLONG for the 0.5-4.0 and 1.0-8.0 Angstroms channels, respectively.                                    
 
 CALLS: ***
	FCHECK, anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
 COMMON BLOCKS:
	GBAR_TABLE                                                            

 MODIFICATION HISTORY:                                                                                      
 VERSION 2, RAS SDAC/GSFC/HSTX 25-JULY-1996                                                                 
       Mod. 08/12/96 by RCJ. Cleaned up documentation.                                                      
 Version 4, RAS, 20-nov-1996, goes6 & goes7                                                                 
 Version 5, richard.schwartz@gsfc.nasa.gov, 22-jul-1997, change in
	transfer function on 28 June 1993 is for GOES 6 only!
	Previously, it had changed all of the long wavelength transfer functions.
	The date is not used in make_goes_resp so the interpolation tables were
	not affected and GOES_TEM should still produce a correct result.
	The change in transfer function value on this date is explicitly coded
	into GOES_TEM.     
 Version 6, richard.schwartz@gsfc.nasa.gov, 3-aug-1998, added goes10                             


goes_value2class $SSW/gen/idl/solar/goes_value2class.pro
[Previous] [Next]
   Name: goes_value2class

   Purpose: convert GOES low energy values -> GOES XRay Class

   Input Parameters:
      gvalues - GOES low energy channel values (or GXD structures)

 CALLS: ***
	BOX_MESSAGE, STR2ARR [1], STR2ARR [2], data_chk [1], data_chk [2], gt_tagval [1]
	gt_tagval [2], ssw_strsplit
   History:
      20-sep-2002 - S.L.Freeland - must be out there already, but...
      20-oct-2003 - S.L.Freeland - fix long standing X+ problem
                    (override ids/rsi default string formats since
                     different for values > 1e-4 (X flares)


GOES_Y_AVERAGE $SSW/gen/idl/goes/goes_y_average.pro
[Previous] [Next]
 PROJECT:
	SDAC
 NAME:
	GOES_Y_AVERAGE

 PURPOSE:
       Get the average value of an array of displayed y values during a selected
	interval.

 CATEGORY:
       UTILITY, GEN, GRAPHICS

 CALLING SEQUENCE:
       GOES_Y_AVERAGE, Tarray, Yarray, Average

 CALLS: ***
	get_uniq
 INPUTS:
   Tarray:		X-axis array
	Yarray:		Y-axis array

 OUTPUTS:
   Average:	Average of y values in specified interval.
	More outputs in keyword format.

 KEYWORDS:
       STIME_STR:      Interval starting time string: 'dd-Mon-yy hh:mm:ss.xxx' (output).
	ETIME_STR:	Interval ending time string: 'dd-Mon-yy hh:mm:ss.xxx' (output).
	WMESSAGE:       If set, instructions on marking using mouse with
			non-X device will be displayed.	(input)
	ERROR:          0 if no error, 1 if error (output).

 PROCEDURE:
	goes_y_average gets the average value of an array of y values during a
	specified interval.  Assumes that a time plot has been drawn.
	mark_region is called to bring up cursor to allow user to specify
	start and end time of region. Result is returned in average.

 MODIFICATION HISTORY:
       Written by ??
	Mod. 08/13/96 by RCJ. Added documentation.
	ras, 3-3-2003, change variable average to yaverage
   Sandhia Bansal - 07/07/2005, added kind as a counter to the where clause in the
                                   for loop where we are searching for tarray inside
                                   the bck_interval array.
   Kim, 14-nov-2005.  Got rid of kind counter - only reflected most recent where count
     Instead, start with ind=-1, append indices within times, then sort and get rid of -1.
 CONTACT:
	richard.schwartz@gsfc.nasa.gov


GOES_YOHKOH_SERVER $SSW/gen/idl/goes/goes_yohkoh_server.pro
[Previous] [Next]
 Project     : HESSI

 Name        : GOES_YOHKOH_SERVER

 Purpose     : return available Yohkoh GOES data server

 Category    : synoptic sockets

 Inputs      : None

 Outputs     : SERVER = Yohkoh GOES data server name

 Keywords    : FULL - If set, return full url
               NETWORK = returns 1 if network to that server is up
               PATH = path to data

 CALLS: ***
	HAVE_NETWORK
 CALLED BY:
	GOES_SERVER
 History     : Written 15-Nov-2006, Zarro (ADNET/GSFC) 

 Contact     : DZARRO@SOLAR.STANFORD.EDU


goesplot $SSW/gen/idl/goes/goesplot.pro
[Previous] [Next]
 Name:  goesplot

 Purpose: Dummy routine.  goesplot is obsolete

 Category:

 Calling Sequence:

 Explanation: goesplot was used in the old goes workbench.  This was replaced
  by a new goes workbench that uses the new goes object in December 2005.

 Inputs:

 Outputs:

 CALLS: ***
	prstr [1], prstr [2]
 CALLED BY:
	FS_ACC_GOES, PLOTBATSE, PLOTBATSE_QL
 History:  Kim Tolbert, 20-Dec-2005


GOOD_PIXELS $SSW/gen/idl/image/good_pixels.pro
[Previous] [Next]
 Project     : SOHO - CDS

 Name        : 
	GOOD_PIXELS()
 Purpose     : 
	Returns all the good (not missing) pixels in an image.
 Explanation : 
	Returns a vector array containing only those pixels that are finite
	(e.g. not NaN), and not equal to the missing pixel flag value.  Mainly
	used for statistical purposes, e.g. PLOT_HISTO,GOOD_PIXELS(A).  The
	missing pixel flag can be set either with the MISSING keyword, or with
	the SETFLAG,MISSING=...  command.
 Use         : 
	Result = GOOD_PIXELS( ARRAY, <keywords> )
 Inputs      : 
	ARRAY	= Array to extract pixels from.
 Opt. Inputs : 
	None.
 Outputs     : 
	Result of function is a linear array containing the values of all
	pixels that are not flagged as missing.
 Opt. Outputs: 
	None.
 Keywords    : 
	MISSING = Value flagging missing pixels.
 Calls       : ***
	GET_IM_KEYWORD
 CALLED BY:
	ADJUST, BSCALE, CDS_SNAPSHOT, FORM_INT, FORM_VEL, HISCAL, SNAP_MOVIE
 Common      : 
	None.
 Restrictions: 
	In general, the SERTS image display routines use several non-standard
	system variables.  These system variables are defined in the procedure
	IMAGELIB.  It is suggested that the command IMAGELIB be placed in the
	user's IDL_STARTUP file.

	Some routines also require the SERTS graphics devices software,
	generally found in a parallel directory at the site where this software
	was obtained.  Those routines have their own special system variables.

 Side effects: 
	If no pixels are missing, then the original undisturbed array is
	returned.
 Category    : 
	Utilities, Image_display.
 Prev. Hist. : 
	William Thompson, July 1991.
	William Thompson, August 1992, renamed BADPIXEL to MISSING.
 Written     : 
	William Thompson, GSFC, July 1991.
 Modified    : 
	Version 1, William Thompson, GSFC, 13 May 1993.
		Incorporated into CDS library.
	Version 2, William Thompson, GSFC, 30 April 1996
		If there are no non-missing pixels, then return the missing
		pixel flag value.
       Version 3, William Thompson, GSFC, 29 April 2005
               Also use FINITE() function.
 Version     : 
	Version 3, 29 April 2005


GRAPHICS [1] $SSW/gen/idl/fund_lib/sdac/graphics_page.pro
[Previous] [Next]
 PROJECT:
       SDAC
 	
 NAME:
	GRAPHICS

 PURPOSE:
 	This procedure switches to graphics from alpha page under Tektronix.

 CATEGORY:
	Graphics.

 calling sequence: 
	GRAPHICS

 INPUTS:
	None

 OUTPUTS:
	None

 CALLS: ***
	GRAPHICS_PAGE
 SIDE EFFECTS:
	Issues a carriage return if called.

 RESTRICTIONS:

 PROCEDURE:
	A command string (string(29b)) is issued through print to switch the terminal
	

 MODIFICATION HISTORY:
 	Written by:	AKT
	Version 2:	RAS, 23-Mar-1995, only called for Tektronix
	Version 3, richard.schwartz@gsfc.nasa.gov, 7-sep-1997, more documentation


GREP $SSW/gen/idl/string/grep.pro
[Previous] [Next]
 PROJECT:
       SOHO - CDS

 NAME:
       GREP

 PURPOSE:
       Search for string through a string array (cf grep in Perl)

 CATEGORY: String utility

 CALLING SEQUENCE:
       Result = GREP(str, strarray)

 INPUTS:
       STR      - Target string to be searched for
       STRARRAY - String array over which the string is seached

 OPTIONAL INPUTS:
       None.

 OUTPUTS:
       Result   - String array of elements from STRARRAY which contains
                  the searched string STR. A null string will be returned if
                  no elements in STRARRAY match STR.

 OPTIONAL OUTPUTS:
       INDEX    - Index of elements in STRARRAY which match the target string

 KEYWORD PARAMETERS:
       SENSITIVE - Make the search pattern case sensitive, if set
       EXACT     - Requires exact match (instead of substring match)
       EXCLUDE   - Set this keyword to return string array that does 
                   not contain string STR
       START     - match at start of string

 PREVIOUS HISTORY:
       Written December 15, 1994, Liyun Wang, GSFC/ARC

 CALLED BY:
	ADD_UDP_HEAD, CHECK_FTP, EIS_IMAGE_TOOL_EVENT [1], EIS_IMAGE_TOOL_EVENT [2]
	EIS_LOAD_IMAGE [1], EIS_LOAD_IMAGE [2], EIT_DAILY, EXIST_JOB, FIND_COMPRESSED
	GET_MAP_PROP, GET_PID, GET_RES_NAME, GET_SOHO_INST, GET_SOHO_MAP, GET_SUMER_FILES
	HAVE_TAG, HESSI PACKET CLASS DEFINITION, HSI_CALC_IMAGE_ERROR, HSI_IMAGE_ERROR
	HSI_SPECTRUM__DEFINE, HTML_SPLAN, IMAGE_TOOL_EVENT, IMAGE_TOOL_HLP, ITOOL2MAP
	ITOOL_COPY_TO_PIX, ITOOL_GET_SRC, ITOOL_GET_TYPE, ITOOL_IMG_SRC, ITOOL_IMG_TYPE
	ITOOL_LOAD_IMAGE, ITOOL_RD_GIF, ITOOL_SET_CSI, JSMOVIE, JSMOVIE2, LIST_OTHER_RES
	LIST_RESOURCE, MK_CDS_PLAN, MK_PLAN_CUSTOM, MK_PLAN_EXIST, MK_PLAN_READ, MK_SOHO
	MK_SOHO_CUSTOM, MK_SOHO_EDP, PATH_DIR, PEEK, PLOT_SPLAN, RD_CDS_POINT, RESOLVE_ALL
	RHESSI IMAGE SINGLE CLASS DEFINITION, Radio Spectrogram FITS File reader
	Radiospectrogram FITS File reader [1]
	Radiospectrogram FITS File reader [2], SELECTD, SMART_FTP
	SPECTRUM CLASS DEFINITION, SQL_QUERY, STR_CHOP, STR_FUZZY, ST_UPDATE_FIELD
	UNIVERSAL SUPERCLASS DEFINITION, WHICH, XCLONE_PLAN, XSEL_LIST [1]
	XSEL_LIST [2], XSHOW_HELP, XSPECT, db_gbo, hsi_get_alg_name, hsi_image__plot [2]
	ihy_db, is_open
 MODIFICATION HISTORY:
       Version 2, Liyun Wang, GSFC/ARC, January 20, 1995
          Added the INDEX keyword
       Version 3, July 26, 1995, Liyun Wang, GSFC/ARC
          Made it return a null string if error occurs (instead of
             stopping the program.
       Version 4, April 7, 1996, Liyun Wang, GSFC/ARC
          Used intrinsic function WHERE; thanks to Richard Schwartz
       Version 5, March 12, 1997, Liyun Wang, NASA/GSFC
          Added the EXCLUDE keyword
       Version 6, August 22, 2000, Zarro (EIT/GSFC)
          Removed DATATYPE calls
       Version 7, June 19, 2002, Zarro (LAC/GSFC)
          Added /START


grid_data [1] $SSW/gen/idl/genutil/grid_data.pro
[Previous] [Next]
   Name: grid_data

   Purpose: return gridded subset of input (~fixed cadence if no gaps)

   Input Parametrs:
      index - generally, an index or roadmap array - any SSW standard time

   Keyword Parameters:
      seconds, hours, minutes, days (one) - desired cadence passed to timegrid.pro
      non_uniq - if set, return duplicates (default is uniq matches)
      oindex -   if set, return index(SS) - default is subscripts (SS)
      delta (output) - delta seconds for data set/grid matches

   Output Parameters:
      function returns SS vector of index records closest to grid times
      if /OINDEX is set, return INDEX(SS); ie, reduced structure array

   Calling Examples:
      gdata=grid_data(index, min=5)	       ;return SS vector, cad.=5minutes
      gdata=grid_data(rmap, hour=6],/oindex)  ;return index(SS), cad.= 6 hours
      evt_grid,grid_data(rmap,min=5,/oindex,tickpos=.9)  ; overlay on utplot

   Method: calls timegrid.pro and tim2dset

 CALLS: ***
	BOX_MESSGE, UNIQ [1], UNIQ [2], UNIQ [3], anytim [1], anytim [2], anytim [3]
	anytim [4], anytim [5], tim2dset [1], tim2dset [2], timegrid
 CALLED BY:
	TRACE_SSWHERE [1], eit_fulldisk, eit_proton_summary, image2movie, plot_fov [1]
	plot_ssw_fov, special_movie, ssw_track_demo, sxt2mpeg, trace_cosmic2hist_accum
	trace_last_movie [1], trace_last_movie [3], trace_make_vignette
	trace_special_movie [1], trace_special_movie [2], trace_special_movie [3]
	trace_special_movie2, trace_sswhere [2], trace_sswhere [3], trace_sswhere [4]
   History:
      19-may-1995 (S.L.Freeland) - allow tasting (sampling) files at low cadence
       5-mar-1997 (SLF) -> SSW
      16-Sep-1998 - S.L.Freeland - add NSAMP and pass->timegrid
      12-Nov-1998 - S.L.Freeland - put an anytim wrapper on input
      18-sep-2000 - S.L.Freeland - added DAYS keyword (->timegrid)


GRID_MAP $SSW/gen/idl/mapping/grid_map.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GRID_MAP

 Purpose     : Regrid an image map 

 Category    : imaging

 Syntax      : gmap=grid_map(map,gx,gy)

 Inputs      : MAP = image map structure
               GX,GY = new grid dimensions

 Outputs     : GMAP = regridded map

 Keywords    : SPACE = [sx,sy] = new grid spacing [def= auto determine]
                or
               DX=DX, DY=DY
               INTERPOLATE = us interpolation instead of rebin

 CALLS: ***
	EXIST, GET_ARR_CENTER, GET_MAP_XP, GET_MAP_YP, GRID_XY, MERGE_STRUCT, PR_SYNTAX
	REBIN_MAP, REP_TAG_VALUE, RESPACE_MAP, UNPACK_MAP, VALID_MAP, interp2d [1]
	interp2d [2], interp2d [3]
 CALLED BY:
	ssw_fov_context, trace_movie_context
 History     : Written 22 August 1997, D. Zarro, ARC/GSFC
               Modified 11 March 2005, Zarro (L-3Com/GSFC)

 Contact     : dzarro@solar.stanford.edu


GRID_XY $SSW/gen/idl/mapping/grid_xy.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GRID_XY

 Purpose     : Make a uniform 2d X-Y grid of coordinates

 Category    : imaging

 Syntax      : grid_xy,x,y,xg,yg

 Inputs      : X,Y = input coordinate arrays

 Outputs     : xg,yg = gridded arrays

 Keywords    : space = grid spacing [def= determine from inputs]
               size    = grid size [def = determine from spacing]
               preserve_area = adjust size to preserve area
               center  = [xc,yc] = center of image

 CALLS: ***
	EXIST, MAKE_XY, PR_SYNTAX, WHERE_VECTOR
 CALLED BY:
	DROT_MAP, GRID_MAP, MERGE_MAP, ROT_MAP
 History     : Written 22 August 1997, D. Zarro, ARC/GSFC
               Modified, 19 May 2004, Zarro (L-3Com/GSFC) - added /PRESERVE

 Contact     : dzarro@solar.stanford.edu


GROUP $SSW/gen/idl_libs/astron/idlphot/group.pro
[Previous] [Next]
 NAME:
      GROUP
 PURPOSE:
      Assign stars with non-overlapping PSF profiles into distinct groups
 EXPLANATION:
      Part of the IDL-DAOPHOT sequence

 CALLING SEQUENCE:
      GROUP, X, Y, RCRIT, NGROUP

 INPUTS:
      X - vector, giving X coordinates of a set of stars.
      Y - vector, giving Y coordinates of a set of stars.
           If X and Y are input as integers, then they will be converted to 
           floating point
      RCRIT - scalar, giving minimum distance between stars of two
               distinct groups.  Stars less than this distance from
               each other are always in the same group.    Stetson suggests
               setting the critical distance equal to the PSF radius +
               the Fitting radius.

 OUTPUTS:
      NGROUP - integer vector, same number of elements as X and Y,
               giving a group number for each star position.  Group
               numbering begins with 0.

 METHOD:
      Each position is initially given a unique group number.  The distance
      of each star is computed against every other star.   Those distances
      less than RCRIT are assigned the minimum group number of the set.   A
      check is then made to see if any groups have merged together.

 PROCEDURES USED:
      REM_DUP()

 REVISION HISTORY:
      Written W. Landsman  STX                  April, 1988
      Major revision to properly merge groups together  W. Landsman   Sep 1991
      Work for more than 32767 points    W. Landsman  March 1997
      Converted to IDL V5.0   W. Landsman   September 1997
      Avoid overflow if X and Y are integers      W. Landsman  Feb. 1999   
 CALLS:
 CALLED BY
	T_GROUP


GRWCH_ST $SSW/gen/idl/fund_lib/sdac/grwch_st.pro
[Previous] [Next]

 NAME: 
	GRWCH_ST

 PURPOSE:
	This function returns the apparent RA of the meridian at Greenwich in degrees
	at the input time.

 CATEGORY:
	GEN, EPHEMERIDES

 CALLING SEQUENCE:
	RA = GRWCH_ST( UT )

 CALLS: ***
	anytim [1], anytim [2], anytim [3], anytim [4], anytim [5]
 INPUTS:
       UT - time in ANYTIM format.

 OPTIONAL INPUTS:
	none

 OUTPUTS:
       Function returns the right ascencion in degrees.

 OPTIONAL OUTPUTS:
	none

 KEYWORDS:
	none
 CALLED BY:
	HXRBS_OCC
 COMMON BLOCKS:
	none

 SIDE EFFECTS:
	none

 RESTRICTIONS:
	none

 PROCEDURE:
	Uses a formula which may have been taken from the Astronomical Almanac.
 	print, grwch_st('1-jan-86 00:00:00.000')
 	100.35282  ;degrees

 MODIFICATION HISTORY:
  	Version 1 documented 29 May 1996, first written ~1987


GSSS_STDAST $SSW/gen/idl_libs/astron/astrom/gsss_stdast.pro
[Previous] [Next]
 NAME:
      GSSS_STDAST

 PURPOSE:
      Insert the closest tangent projection astrometry into an GSSS Image
   
 DESCRIPTION:
       This procedure takes a header with GSSS (ST Guide Star Survey) 
       astrometry and writes a roughly equivalent tangent projection 
       astrometry into the header.     One might want to do this if (1)
       one needs to use software which does not recognize the GSSS astrometric
       parameters or (2) if the the image to be transformed, since the 
       highly nonlinear GSSS solution does not transform easily.  

 CALLING SEQUENCE:
       GSSS_STDAST, H, [Xpts, Ypts]

 INPUT - OUTPUT:
       H -  FITS header (string array) containing GSSS astrometry.  
       GSSS_STDAST will write the roughly equivalent tangent projection 
               astrometry solution into H.
 OPTIONAL INPUTS:
       xpts, ypts -- Vectors giving the X and Y positions of the three 
               reference points used to find approximate tangent projection.
               Default is Xpts = [0.2,0.8,0.5], Ypts = [0.2, 0.4, 0.8]
 METHOD:
       The procedures GSSSXYAD is used to exactly determine the RA and Dec
       at 3 reference points.    STARAST is then used to find the tangent
       projection astrometry that best matches these reference points.

 NOTES:
       Images from the STScI server (http://archive.stsci.edu/dss/ )contain
       both a GSSS polynomial plate solution and an approximate WCS tangent
       projection.    The value  of the WCSNAME keyword in the FITS header 
       is 'DSS'.    If WCSNAME = "DSS' then the more accurate DSS astrometry
       is extracted by EXTAST    This procedure changes the value of WCSNAME  
       to 'DSS_TANGENT' to indicate that the tangent solution should be used.
    
       Some early GSSS images (before the 1994 CD-Rom) used keywords CRPIXx
       rather than CNPIXx.    The GSSS astrometry in these images could be
       corrupted by this procedure as the CRPIXx values will be altered.

       The tangent is only a approximation of the nonlinear GSSS astrometry,
       but is generally accurate to about 0.1 pixels on a 1024 x 1024 image.

 PROCEDURES USED:
       GSSSEXTAST, GSSSXYAD, STARAST, PUTAST, SXADDHIST, SXDELPAR

 CALLS: ***
	GSSSEXTAST, GSSSXYAD, STARAST, SXADDHIST [1], SXADDHIST [2], SXADDPAR [1]
	SXADDPAR [2], SXADDPAR [3], SXDELPAR [1], SXDELPAR [2], SXDELPAR [3], SXPAR [1]
	SXPAR [2], SXPAR [3]
 CALLED BY:
	ATV, GETROT, HASTROM, HCONGRID, HEULER, HPRECESS, HREBIN, HROT, HROTATE, IMCONTOUR
 HISTORY:
       13-AUG-91 Version 2 written from MAKEASTGSSS  Eric Deutsch (STScI)
       Delete CDELT* keywords from header   W. Landsman      May 1994
       Remove call to BUILDAST  W. Landsman                  Jan, 1995
       Added optional Xpts, Ypts parameters   E. Deutsch     Oct, 1995
       Add WCSNAME   W. Landsman                             Nov 2006


GSSSADXY $SSW/gen/idl_libs/astron/astrom/gsssadxy.pro
[Previous] [Next]
 NAME:
      GSSSADXY
 PURPOSE:
       Converts RA and DEC (J2000) to (X,Y) for an STScI GuideStar image.   
 EXPLANATION:
       The sky coordinates may be printed and/or returned in variables.

 CALLING SEQUENCE:
       GSSSADXY, GSA, Ra,Dec, [ X, Y, /Print ] 

 INPUT:
       GSA - the GSSS Astrometry structure created by GSSSEXTAST
       RA  - the RA coordinate(s) in *degrees*, scalar or vector
       DEC - the DEC coordinate(s) in *degrees*, scalar or vector

 CALLS: ***
	ASTDISP, DELVARX [1], DELVARX [2], DELVARX [3], DELVARX [4], delvarx [5]
 CALLED BY:
	ADXY, ARCBAR, ATV, HASTROM, IMDBASE, XYXY
 OPTIONAL KEYWORD INPUT:
       /PRINT - If this keyword is set and non-zero, then coordinates will be
               displayed at the terminal
 OUTPUT:
       X - the corresponding X pixel coordinate(s), double precision
       Y - the corresponding Y pixel coordinate(s), double precision

       X and Y will be in IDL convention (first pixel 0,0)
 EXAMPLE:
       Given a FITS header, hdr, from the STScI Guidestar Survey, determine
       the X,Y coordinates of 3C 273 (RA = 12 29 6.7  +02 03 08)

       IDL> GSSSEXTAST, hdr, gsa          ;Extract astrometry structure
       IDL> GSSSADXY, gsa, ten(12,29,6.7)*15,ten(2,3,8),/print

 NOTES:
       For most purpose users can simply use ADXY, which will call GSSSADXY
       if it is passed a GSSS header.

 PROCEDURES CALLED:
       ASTDISP - Print RA, Dec in standard format
 HISTORY:
       10-JUL-90 Version 1 written by Eric W. Deutsch
               Derived from procedures written by Brian McLean
       Vectorized code   W. Landsman        March, 1991
       14-AUG-91 Fixed error which caused returned X and Y to be .5 pixels too
               large.  Now X,Y follows same protocol as ADXY.
       June 1994 - Dropped PRFLAG parameter, added /PRINT  W. Landsman (HSTX)
       Converted to IDL V5.0   W. Landsman   September 1997
       29-JUN-99 Added support for AMD[X,Y]1[2-3] for DSS images by E. Deutsch
       Reduce memory requirements for large arrays D. Finkbeiner April 2004


GSSSEXTAST $SSW/gen/idl_libs/astron/astrom/gsssextast.pro
[Previous] [Next]
 NAME: 
      GSSSEXTAST

 PURPOSE:
      Extract IDL astrometry structure from a ST Guide Star Survey FITS header

 EXPLANATION:
      This procedure extracts the astrometry information from a ST Guide
      Star Survey FITS header and places it in an IDL structure for 
      subsequent use with GSSSxyad and GSSSadxy.

 CALLING SEQUENCE:
      GSSSExtast, hdr, astr, noparams
 INPUT:
      h - the GSSS FITS header
 OUTPUT:
      astr  - Structure containing the GSSS Astrometry information
               .CTYPE  =  ['RA---GSS','DEC--GSS'] 
               .CRVAL = plate center Ra, Dec (from PLTRAH, PLTRAM etc.)
               .XLL,.YLL = offsets lower lefthand corner
               .AMDX, .AMDY = 12 transformation coefficients
               .XSZ,.YSZ = X and Y pixel size in microns
               .PLTSCL = plate scale in arc sec/mm
               .PPO3, .PPO6 - orientation coefficients
 NOTES:
      Most users should use EXTAST rather than this procedure.   EXTAST will
      call GSSSEXTAST if supplied with GSSS FITS header.

 PROCEDURES CALLED:
      SXPAR() - Extract parameter values from a FITS header
 CALLS: ***
	SXPAR [1], SXPAR [2], SXPAR [3]
 CALLED BY:
	EXTAST, GSSS_STDAST
 HISTORY:
       01-JUL-90 Version 1 written by Eric W. Deutsch
       Code derived from Software by Brian McLean
       20-AUG-91 Modified to Double Precision Variables.  E. Deutsch
       June 94 Change astrometry tags to better agree with EXTAST  W. Landsman
       Converted to IDL V5.0   W. Landsman   September 1997
       29-JUN-99 Added support for AMD[X,Y]1[2-3] for DSS images by E. Deutsch
       Eliminate use of obsolete !ERR  W. Landsman    February 2000


GSSSXYAD $SSW/gen/idl_libs/astron/astrom/gsssxyad.pro
[Previous] [Next]
 NAME:
       GSSSXYAD
 PURPOSE:
       Convert (X,Y) coordinates in a STScI Guide Star image to RA and Dec
 EXPLANATION:
       The sky coordinates may be printed and/or returned in variables.

 CALLING SEQUENCE:
       GSSSxyad, gsa, x, y, ra, dec, [ /PRINT ]
 INPUT:
       GSA  - The GSSS Astrometry structure extracted from a FITS header 
              by GSSSEXTAST
       X - The X pixel coordinate(s) of the image, scalar or vector
       Y - The Y pixel coordinate(s) of the image, scalar or vector

 OUTPUT:
       RA - The RA coordinate of the given pixel(s) in *degrees*
       DEC - The DEC coordinate of the given pixel(s) in *degrees*

       Both RA and Dec will be returned as double precision

 CALLS: ***
	ASTDISP
 CALLED BY:
	CURVAL, GSSS_STDAST, HASTROM, IMDBASE, XYXY
 OPTIONAL KEYWORD INPUT:
       /PRINT - If this keyword is set and non-zero, then coordinates will be
               displayed at the terminal
 EXAMPLE:
       Given a FITS header,hdr, from a GSSS image, print the astronomical
       coordinates of (X,Y) = (200.23, 100.16) at the terminal

       IDL> GSSSExtast, hdr, gsa        ;Extract astrometry structure
       IDL> GSSSxyad, gsa, 200.23, 100.16, /print

 NOTES:
       For most purpose users can simply use XYAD, which will call GSSSXYAD
       if it is passed a GSSS header.

 PROCEDURES CALLED:
       ASTDISP - print RA, Dec in a standard format
 HISTORY:
       01-JUL-90 Version 1 written by Eric W. Deutsch
       Vectorized Code   W. Landsman        March, 1991
       14-AUG-91 Fixed error which caused returned RA and DEC to be off by
       -.5 pixels in both X,Y.  Now X,Y follows same protocol as ADXY.
       20-AUG-91 Modified to use AstDisp procedure.
       June 94 Added /PRINT keyword instead of PRFLAG W. Landsman June 94
       Converted to IDL V5.0   W. Landsman   September 1997
       29-JUN-99 Added support for AMD[X,Y]1[2-3] for DSS images by E. Deutsch


gt2exe [1] $SSW/gen/idl/util/gt2exe.pro
[Previous] [Next]
   Name: gt2exe
 
   Purpose: convert gt function shorthand to valid calls (for use w/execute)

   Input Parameters:
      input - string of form "<item> <relation> <value>"
              <item>     = function name OR structure/fits field
                           {filta, filtb, expmode, dpe, percentd, etc}
              <relation> = { = , >, <, >=, <=, <>}
              <value>    = value, list (ex: 1,2,5) or range (ex: 4~10)
   Keyword Parameters:
      string_fields - optional list of variables which should be
      treated as strings
               
 CALLS: ***
	ARR2STR [1], Arr2Str [2], BOX_MESSAGE, STR2ARR [1], STR2ARR [2], data_chk [1]
	data_chk [2], is_member [1], is_member [2], is_number [1], is_number [2]
	str_replace [1], str_replace [2], strextract, strmids [1], strmids [2]
 CALLED BY:
	TRACE_SSWHERE [1], mk_sfc [1], mk_sfc [2], mk_spd, plot_fov [1], struct_where
	sxt_where, trace_sswhere [2], trace_sswhere [3], trace_sswhere [4], trace_where
   Examples:
      IDL> print,gt2exe('dpe=[12~20]',/addind)
      IDL> gt_dpe(index(ss)) ge 12 AND gt_dpe(index(ss)) le 20

      IDL> print,gt2exe('filta=[2,5]', /addind)
      IDL> gt_filta(index(ss)) eq 2 OR gt_filta(index(ss)) eq 5
      IDL> print,gt2exe('crpix1=[256,512,1024]')
           gt_tagval(index(ss),/crpix1) eq 256 OR
           gt_tagval(index(ss),/crpix1) eq 512 OR
           gt_tagval(index(ss),/crpix1) eq 1024

   History:
      Circa jan-93 (S.L.Freeland) - for spd files
      22-mar-1995  (SLF) - add range and list (expanded for obs searches)
      13-jan-1998  (SLF) - make unmapped functions a call to 'gt_tagval'
                           made ADDIND the default
      26-Feb-1998  (SLF) - define some default strings (ssw standards)
      22-apr-1998  (SLF) - added some stuff
                           if value includes wild card/?? use wc_where  
      13-May-1998  (SLF) - add RANGE_DELIM and made default= '~'
       8-Sep-1998  (CED) - Add '==' as synonym for 'eq'
       8-Sep-1998  (SLF) - &&/AND and ||/OR recursion
      20-Jan-1999  (SLF) - remove 'percentd' from gt_xxx list
      21-apr-2005  (SLF) - add string_fields keyword + function
                           add auto addition of non-numbers to string algorithm
      28-sep-2006 (SLF) - use strmatch for strings, protect against seaarch strings which
                          include embedded reserve words (like, Gband and for for example...)
                                                                  ^^^      ^^


GT_BSC_BINCAL [1] $SSW/gen/idl/fund_lib/yohkoh/gt_bsc_bincal.pro
[Previous] [Next]
 NAME:
      GT_BSC_BINCAL
 PURPOSE:
       to get BCS crystal bin calibration data from CALFILEs 
       (wavelength dispersion, sensitivity, etc)
 CALLING SEQUENCE:
       BINCAL=GT_BSC_BINCAL(CHAN_STRUCT,MODEID)
 INPUTS:
       CHAN_STRUCT   - BCS channels (as vector or in index)
 OPTIONAL INPUT
       MODEID        - Mode ID for channel grouping plan
 OUTPUTS:
       BINCAL        - structure with fields:
       .CHAN         - channel #
       .NBINS        - number of bins per channel
       .WAVE         - wavelength array (start edges)
       .PHYSPOS      - physical positions of right hand edges
                       of grouped bins
       .MODEID       - modeid 
       .SENSIT       - mean sensitivity of grouped bins
       .W0           - start wavelength of detector
       .DW           - dispersion (A/bin)
       .BINARC       - angle to bin conversion (bin/arcmin)
       .ROCKW        - rocking width (A)
       .GAUSSW       - guassian detector width (A)
       .EFAREA       - effective area (cm^2)
       .NSTART       - first valid bin
       .NEND         - last valid bin
       .VERSION      - version number of CAL file used
 OPTIONAL KEYWORDS:
        NOVALID      - do not extract valid channels
        SMM          - if set, extract SMM BCS calibration info
 CALLS: ***
	BCS_GRP_PLAN, BSC_CHECK [1], BSC_CHECK [2], GT_BSC_CHAN [1], GT_BSC_CHAN [2]
	RD_BCSCAL [1], RD_BCSCAL [2]
 CALLED BY:
	BSC_ERRCAL [1], BSC_ERRCAL [2], BSC_FLUXCAL, BSC_VALID, BSC_WAVECAL, BSC_XCORR
	CV_BSC2BSD, GET_BSC, GT_BSC_WAVE [1], GT_BSC_WAVE [2], WBDA [1], WBDA [2]
	WBSC_SPC_EV [1], WBSC_SPC_EV [2], bcs_broad [1], bcs_broad [2], bsc_bin2w
	bsc_bincor
 PROCEDURE:
       Reads crystal curvature sensitivity and wavelength info.
       Applies grouping plan to ungrouped CALFIL measurements
       Group sensitivities by weighting them wrt to physical separation
       of bins, e.g. (for double binning):

   Sgroup = (S1+S2)/(B1+B2) where S1, S2 are individual sensitivities
   which are equivalent to the counts produced by a flatfield normalized
   to an average unit bin, and B1,B2 are the physical bin widths.

 HISTORY:
       Written Nov. 1992 by D. Zarro (Applied Research Corp).
       Modified Aug'93 (D. Zarro) -- speeded up using common block
       Modified Sep'93 (D. Zarro) -- to extract valid wavelengths
       Modified May'94 (DMZ) -- fixed potential bug in NSTART, NEND usage
                             -- added FORCE keyword to force re-read of CAL files


GT_BSC_CHAN [1] $SSW/gen/idl/fund_lib/yohkoh/gt_bsc_chan.pro
[Previous] [Next]
 NAME:
       GT_BSC_CHAN
 PURPOSE:
       extract channel nos and/or channel IDs BSC index
 CALLING SEQUENCE:
       chans=gt_bsc_chan(bsc_index,string=string)
 INPUTS:
       bsc_index = bsc_index structure or array of indicies
 OUTPUTS:
       chans = array of channel nos (or ion names) in index
 KEYWORDS
       string    = if set, then return channels as ion names
	uniq	  = if set, only return unique channel values
       smm       = if set, return SMM BCS channel values
 CALLS: ***
	BSC_CHECK [1], BSC_CHECK [2], DATATYPE [1], DATATYPE [2], DATATYPE [3], UNIQ [1]
	UNIQ [2], UNIQ [3]
 CALLED BY:
	BCS, BSC_CHAN, BSC_ERRCAL [1], BSC_ERRCAL [2], BSC_FLUXCAL, BSC_RASTER, BSC_VALID
	BSC_WAVECAL, BSC_XCORR, GT_BSC_BINCAL [1], GT_BSC_BINCAL [2], GT_BSC_CRATE
	GT_BSC_TIME, GT_BSC_WAVE [1], GT_BSC_WAVE [2], PLOT_BSC [1], PLOT_BSC [2], SEL_BSC
	WBSC [1], WBSC [2], WBSC_LTC_EV [1], WBSC_LTC_EV [2], bcs_broad [1], bcs_broad [2]
	bcs_line, bcs_spec, bcs_velres, bsc_vturb, cal_bsc, first_bcs, fit_bsc, fit_bsc_as
	fit_bsc_plot, get_atomic [1], get_atomic [2], get_bcscal, get_bsc_anno
 HISTORY:
    11-Sep-93, D. Zarro (ARC), Written
     3-Feb-94, Zarro, added SMM capability
    15-Mar-94, Zarro, added /CONT to message for invalid channels
    1-Sep-94, Zarro, fixed potential bug with UNIQ


GT_BSC_WAVE [1] $SSW/gen/idl/fund_lib/yohkoh/gt_bsc_wave.pro
[Previous] [Next]
 NAME:
       GT_BSC_WAVE
 PURPOSE:
       return nominal wavelength arrays for BSC spectra
 CALLING SEQUENCE:
       WAVE=GT_BSC_WAVE(BSC_INDEX,BSC_DATA)
 INPUTS:
       BSC_INDEX    - BSC index structure or channel array 
       BSC_DATA     - BSC data
 KEYWORDS:
       SMM - set for SMM-BCS wavelengths
       NOZERO - extract nonzero wavelengths
 OUTPUTS:
       WAVE         - wavelength array (A)
 CALLS: ***
	BSC_CHECK [1], BSC_CHECK [2], DATATYPE [1], DATATYPE [2], DATATYPE [3]
	GT_BSC_BINCAL [1], GT_BSC_BINCAL [2], GT_BSC_CHAN [1], GT_BSC_CHAN [2]
	bda_wave [1], bda_wave [2]
 CALLED BY:
	GET_BSC, SEL_BSC, bcs_spec
 HISTORY:
       Written Aug'93 by D. Zarro (ARC)
       Modified Mar'94, D. Zarro, added SMM keyword
       Modified Jan'95, D. Zarro, added NOZERO keyword


gt_conv2str [1] $SSW/gen/idl/genutil/gt_conv2str.pro
[Previous] [Next]
NAME:
	gt_conv2str
PURPOSE:
	After a "GT" routine has extracted the relevant information, optionally
	convert the information to a string.
METHOD:
INPUT:
	item	- An integer scalar or array.  Any check on it's proper range
		  should have been done in the calling routine.
	str_long
	str_short
	header_array - A list of the header strings available.
			header_array(0) - used by /string and /fmt 
					  and /spaces options
			header_array(1) - used by /short option
OPTIONAL INPUT:
	string	- If present, return the string nemonic for the
		  filter (long notation)
	short	- If present, return the short string nemonic for
		  the filter
	spaces	- If present, place that many spaces before the output
		  string.  The long notation is used unless /short
		  is specified.
	fmt	- Format statement to be used if /string, /short, or
		  /spaces option is used.
OUTPUT:
	returns	- If requested to make a conversion, then return the string
		  equivalent of the input.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLED BY:
	get_info [3], get_info [4], gt_EITfilter, gt_EITsector, gt_adoor, gt_comp
	gt_corner_cmd, gt_dp_mode [1], gt_dp_mode [2], gt_dp_rate [1], gt_dp_rate [2]
	gt_dpe, gt_entry, gt_expdur [1], gt_expdur [2], gt_expmode, gt_filta, gt_filtb
	gt_grs1, gt_grs2, gt_hxs [1], gt_hxs [2], gt_hxt_hk_temp, gt_mbe [1], gt_mbe [2]
	gt_obsregion, gt_or_expnum, gt_percentd, gt_percentover, gt_pfi_ffi, gt_rbmsc
	gt_rbmsd, gt_res, gt_seq_num, gt_seq_tab, gt_shape, gt_shape_cmd, gt_sum_h [1]
	gt_sum_h [2], gt_sum_l [1], gt_sum_l [2], gt_sum_m1 [1], gt_sum_m1 [2]
	gt_sum_m2 [1], gt_sum_m2 [2], gt_sxs1 [1], gt_sxs1 [2], gt_sxs2 [1], gt_sxs2 [2]
	gt_temp_ccd, gt_temp_hk, gt_total_cnts [1], gt_total_cnts [2], hxt_hk_temp
	sxt_fits_info
HISTORY:
	Written 13-Nov-91 by M.Morrison
	 3-Jun-93 (MDM) - Modified to use a LONG variable for the for loop


gt_day [1] $SSW/gen/idl/genutil/gt_day.pro
[Previous] [Next]
NAME:
	gt_day
PURPOSE:
	To extract the word corresponding to day and optionally
       return a string variable for that item.  If the item passed is an
       integer type, it is assumed to be the 7-element external representation
       of the time.
CALLING SEQUENCE:
	x = gt_day(roadmap)
	x = gt_day(index)
	x = gt_day(index.sxt, /space)		;put single space before string
	x = gt_day(index, space=3)		;put 3 spaces
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
                               (or)
                The "standard" 7 element external representation
                of time (HH,MM,SS,MSEC,DD,MM,YY)
 CALLS: ***
	Int2Ex [1], Int2Ex [2], anytim2ints [1], anytim2ints [2], tbeep [1], tbeep [2]
	tbeep [3]
 CALLED BY:
	ALIGN_AR, ARC2LEN, ATIME [1], ATIME [2], BCS_ACCUM [1], BCS_ACCUM [2], BCS_DP_CHECK
	BCS_DT_INTERP [1], BCS_DT_INTERP [2], BSC_TIM2DSET, CCCA, CHKTERM, DATAGET3_GRS
	DATAGET3_HXS, EIT_GBO, FIX_OLD_ATT [1], FIX_OLD_ATT [2], F_ATIME [1], F_ATIME [2]
	GETCAL_ATT [1], GETCAL_ATT [2], GET_FRAME_TIME, GET_POINTS, GET_SUNCENTER [1]
	GET_SUNCENTER [2], GET_YOHKOH_POS, GT_BSC_TIME, HXAXY2SXT, HXT2SXSPC, HXT_4CHPLOT
	HXT_DUMP, INF_STR, IRUHXASCAN2SXT [1], IRUHXASCAN2SXT [2], LIST_BDA, LIST_BSC [1]
	LIST_BSC [2], LIST_GEV, LIST_NAR, MAKE_VTRANGE, MDI_GBO, MK_GRSPCH, MK_GRSPCL
	MK_GRSPHH1, MK_GRSPHH2, MK_GRSPHL1, MK_GRSPHL2, MK_HXI_MAP, MK_HXSPC, MK_HXSPH
	MK_RBMPC, MK_SXT_MAP, NORP_RDT2DATA_17G, NORP_RDT2DATA_1G, NORP_RDT2DATA_2G
	NORP_RDT2DATA_35G, NORP_RDT2DATA_4G, NORP_RDT2DATA_80G, NORP_RDT2DATA_9G
	OUT_GRSPHL1, OUT_GRSPHL2, OUT_HXSPH, OVER_THE_LIMB, PLOT_GRSPCH, PLOT_GRSPCL
	PLOT_GRSPHH, PLOT_GRSPHL, PLOT_HXSPC, PLOT_HXSPH, PRINT_GEV, PRINT_NAR, RD_AR, RES_FFI
	SEL_AR, SPLINE_LC, SPLINE_PLOT, SSDA, SXI_GBO, SXT2HXAXY, SXT_ECLIPSE, SXT_OBSRPT
	SXT_TEEM1 [1], SXT_TEEM1 [2], SXT_TEEM1 [3], TRACE_GBO, WBDA [1], WBDA [2], WBSC [1]
	WBSC [2], WBS_DB, anystr2tim [1], anystr2tim [2], anytim [1], anytim [2], anytim [3]
	anytim [4], anytim [5], anytim2ex [1], anytim2ex [2], anytim2ints [1]
	anytim2ints [2], anytim2weekid [1], anytim2weekid [2], auto_toban, bbso_copy [1]
	bbso_copy [2], bcs_survey, bcs_trange, cam_run_sum, carr2btime [2]
	cdrom_files [2], check_sci5k_trunc, cnvt [2], cont2time [1], cont2time [2]
	contacts [1], contacts [2], db_gbo, do_ads, doy2ex [1], doy2ex [2], dpc_img_summary
	dsn_input, eit_fulldiskdb, eitoversxt, exp_scale min_exp max_exp [1]
	filetimes [1], filetimes [2], fits_disp_month [1], fits_disp_month [2]
	fl_goesplot [1], fl_goesplot [2], fl_goesplot [3], fl_mktext, fmt_pass
	fmt_tim [1], fmt_tim [2], function timeintervalab, get_ar, get_dc_image [2]
	get_dc_image [3], get_leak_image [1], get_leak_image [2], get_leak_image [3]
	get_linearity sig e_min e_max, get_selsis, get_visible, goes3sec_copy, goes_gaps
	goes_plot [1], goes_plot [2], goes_plot [3], goes_plot [4], goes_plot [5]
	goes_summary, grs_plot, gtab_file, hsi_gbo, html_form_addtime [1]
	html_form_addtime [2], html_form_addtime [3], hxt_images2ps, hxt_impulsivness
	hxt_mcaccum, hxtimg_accum, int2sec [1], int2sec [2], ipcom, iperr_sea
	jitter_gif_xyimg, killold [1], killold [2], last_lc, list_nrt_times, ltc, mdipict
	mk_bsa_interv [1], mk_bsa_interv [2], mk_desat_wl, mk_gev [1], mk_gev [2], mk_gx
	mk_hst_summary, mk_imgsum_html, mk_limb_pixmap, mk_mdi_iap, mk_nar [1], mk_nar [2]
	mk_orbit_files, mk_ptv_title, mk_sdmi, mk_sfd [1], mk_sfd [2], mk_sfd [3]
	mk_sfd [4], mk_sfw, mk_syn_sfc [1], mk_syn_sfc [2], mk_title [2], mk_week_file [1]
	mk_week_file [2], mk_ydbtab, monitor_center [1], nob_img_copy, obs_summary
	plot_ref, pr_conf, pr_dates_warm [1], pr_dates_warm [2], pr_mdihk_trans [1]
	pr_mdihk_trans [2], pr_nar, pr_trav_summ, pr_visible
	pro interpretfemfemfemtimefemflgfemstrfemstrverboseverbose
	pro loadopfemfiletimeOGfemverboseverbose
	pro loadoptextfiletimeOGverboseverbose, pro showaoslosgdfemtimefemflg
	rd_raw_station_plan, rd_sci5k, rd_selsis, rd_sfd_carr, rd_so_at_ftr
	rd_station_plan, rd_therm_rs232, rd_week_file [1], rd_week_file [2]
	rd_week_file [3], rd_week_file [4], read_eit, read_ltc file, redo_mon_sci5k
	reltime [1], reltime [2], res_freq, ret_day, run_dsnfil, sda2fits, selsis_copy [1]
	selsis_copy [2], seq_run_sum [1], seq_run_sum [2], show_contacts
	soon_search [1], soon_search [3], sxt_align, sxt_combine, sxt_composite [1]
	sxt_composite [2], sxt_composite [3], sxt_images2ps, sxt_mauna
	sxt_sff_composite [1], sxt_sff_composite [2], tim2dow, tim2dset [1]
	tim2dset [2], time_add1s, time_addxa, timeline, timeline2html, tr_decode_head [1]
	tr_decode_head [2], usertimes_event, weekid [2], wrt_fits_bin_exten [2]
	wrtsxtmap, xdate [1], xdate [2], xhkplot, xread_hist, ydb_exist [2]
OPTIONAL KEYWORD INPUT:
	string	- If present, return the string mnemonic (long notation)
	spaces	- If present, place that many spaces before the output
		  string.
	leadzero - If present, put a leading zero for dates 1 thru 9
	lower	- If present, have the characters after the lead character be in
		  lower case.
	longmonth - If present, then use the full length month name
       fits    - If present, then use the old FITS slash format of the type DD/MM/YY (obsolete)
	y2k	- If present, then use 4-digit years.  Ignored if /FITS is used.
OUTPUT:
	returns	- The day, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
		  Sample String: 12-OCT-91
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
HISTORY:
	Written 13-Nov-91 by M.Morrison
	 4-Jun-92 (MDM) - Added "leadzero" option
	21-Oct-92 (MDM) - Added "lower" option
	10-Mar-93 (MDM) - Added "longmonth" option
	16-May-93 (MDM) - Modified to accept string time as input
	27-May-93 (MDM) - Modified to handle years after 1999
        4-Aug-95 (MDM) - Added /FITS keyword
	14-Nov-97 (MDM) - Changed FOR loop to use long integer
	07-Feb-2002, William Thompson, added keyword Y2K


gt_exptime [1] $SSW/gen/idl/genutil/gt_exptime.pro
[Previous] [Next]
   Name: gt_exptime

   Purpose: return exposusure time from input 

   Input Parameters:
      struct - input structure 

   Calling Sequence:
      exptime=gt_exptime(struct [,str_pattern=pattern, /string, $
              convert=convert_function)

 CALLS: ***
	CONCAT_DIR [1], CONCAT_DIR [2], CONCAT_DIR [3], DATATYPE [1], DATATYPE [2]
	DATATYPE [3], FILE_EXIST [2], FXBCLOSE [1], FXBCLOSE [2], FXBOPEN [1], FXBOPEN [2]
	FXBOPEN [3], FXPAR [1], FXPAR [2], QLMGR, concat_dir [4], file_exist [1]
	file_exist [3]
 CALLED BY:
	CDS_SATURATE, GIS_CALIB_EXTRACT, GIS_CALIB_FF_LTGD, GIS_ERROR, GT_DURATION
   History:
      9-jun-1995 (SLF) 


gt_hxs [1] $SSW/gen/idl/fund_lib/yohkoh/gt_hxs.pro
[Previous] [Next]
NAME:
	gt_hxs
PURPOSE:
	To extract the word corresponding to the HXS counts.  The units
	are cnts/sec
CALLING SEQUENCE:
	x = gt_hxs(roadmap)
	x = gt_hxs(index)
	x = gt_hxs(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The hxs counts per sec, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	OBS_PLOT, last_lc, plott_wda, ploty [1], ploty [2]
HISTORY:
	Written 7-Mar-92 by M.Morrison
       20-Mar-92 (MDM) - Added "title" option
        6-Jun-92 (MDM) - Corrected observing log extraction (data type prob)
	12-Oct-92 (MDM) - Modified to correct for integer*2 overflow
        7-Jan-94 (MDM) - Updated title


gt_sum_h [1] $SSW/gen/idl/fund_lib/yohkoh/gt_sum_h.pro
[Previous] [Next]
NAME:
	gt_sum_h
PURPOSE:
	To extract the word corresponding to the SUM_H.  It is the HXT
	low channel counts per second.
CALLING SEQUENCE:
	x = gt_sum_h(roadmap)
	x = gt_sum_h(index)
	x = gt_sum_h(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The sum_h counts per sec, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	HXT_DUMP, OBS_PLOT, last_lc, lchda, plott_hda, ploty [1], ploty [2]
HISTORY:
	Written 7-Mar-92 by M.Morrison
       20-Mar-92 (MDM) - Added "title" option
        6-Jun-92 (MDM) - Corrected observing log extraction (data type prob)
	20-Jan-93 (MDM) - Updated energies listed in title


gt_sum_l [1] $SSW/gen/idl/fund_lib/yohkoh/gt_sum_l.pro
[Previous] [Next]
NAME:
	gt_sum_l
PURPOSE:
	To extract the word corresponding to the SUM_L.  It is the HXT
	low channel counts per second.
CALLING SEQUENCE:
	x = gt_sum_l(roadmap)
	x = gt_sum_l(index)
	x = gt_sum_l(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The sum_l counts per sec, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	HXT_DUMP, OBS_PLOT, last_lc, lchda, obs_summary, plott_hda, ploty [1], ploty [2]
HISTORY:
	Written 7-Mar-92 by M.Morrison
       20-Mar-92 (MDM) - Added "title" option
        6-Jun-92 (MDM) - Corrected observing log extraction (data type prob)
       20-Jan-93 (MDM) - Updated energies listed in title


gt_sum_m1 [1] $SSW/gen/idl/fund_lib/yohkoh/gt_sum_m1.pro
[Previous] [Next]
NAME:
	gt_sum_m1
PURPOSE:
	To extract the word corresponding to the SUM_M1.  It is the HXT
	low channel counts per second.
CALLING SEQUENCE:
	x = gt_sum_m1(roadmap)
	x = gt_sum_m1(index)
	x = gt_sum_m1(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The sum_m1 counts per sec, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	HXT_DUMP, OBS_PLOT, last_lc, lchda, plott_hda
HISTORY:
	Written 7-Mar-92 by M.Morrison
       20-Mar-92 (MDM) - Added "title" option
        6-Jun-92 (MDM) - Corrected observing log extraction (data type prob)
       20-Jan-93 (MDM) - Updated energies listed in title


gt_sum_m2 [1] $SSW/gen/idl/fund_lib/yohkoh/gt_sum_m2.pro
[Previous] [Next]
NAME:
	gt_sum_m2
PURPOSE:
	To extract the word corresponding to the SUM_M2.  It is the HXT
	low channel counts per second.
CALLING SEQUENCE:
	x = gt_sum_m2(roadmap)
	x = gt_sum_m2(index)
	x = gt_sum_m2(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The sum_m2 counts per sec, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	HXT_DUMP, OBS_PLOT, last_lc, lchda, plott_hda, ploty [1], ploty [2]
HISTORY:
	Written 7-Mar-92 by M.Morrison
       20-Mar-92 (MDM) - Added "title" option
        6-Jun-92 (MDM) - Corrected observing log extraction (data type prob)
       20-Jan-93 (MDM) - Updated energies listed in title


gt_sxs1 [1] $SSW/gen/idl/fund_lib/yohkoh/gt_sxs1.pro
[Previous] [Next]
NAME:
	gt_sxs1
PURPOSE:
	To extract the word corresponding to the SXS1 counts.  The units
	are cnts/sec
CALLING SEQUENCE:
	x = gt_sxs1(roadmap)
	x = gt_sxs1(index)
	x = gt_sxs1(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The SXS1 counts per sec, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	OBS_PLOT, last_lc, plott_wda, ploty [1], ploty [2]
HISTORY:
	Written 7-Mar-92 by M.Morrison
       20-Mar-92 (MDM) - Added "title" option
	 6-Jun-92 (MDM) - Corrected observing log extraction (data type prob)
       12-Oct-92 (MDM) - Modified to correct for integer*2 overflow
	 7-Jan-94 (MDM) - Updated title


gt_sxs2 [1] $SSW/gen/idl/fund_lib/yohkoh/gt_sxs2.pro
[Previous] [Next]
NAME:
	gt_sxs2
PURPOSE:
	To extract the word corresponding to the SXS2 counts.  The units
	are cnts/sec
CALLING SEQUENCE:
	x = gt_sxs2(roadmap)
	x = gt_sxs2(index)
	x = gt_sxs2(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The sxs2 counts per sec, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	OBS_PLOT, obs_summary, plott_wda
HISTORY:
	Written 7-Mar-92 by M.Morrison
       20-Mar-92 (MDM) - Added "title" option
        6-Jun-92 (MDM) - Corrected observing log extraction (data type prob)
       12-Oct-92 (MDM) - Modified to correct for integer*2 overflow
        7-Jan-94 (MDM) - Updated title


gt_tagval [1] $SSW/gen/idl/struct/gt_tagval.pro
[Previous] [Next]
   Name: gt_tagval

   Purpose: return value stored in specified tag - (nested N-deep struct OK)

   Input Parameters:
      item       - structure or vector structure OR FITS header
      tag/field  - tag to search for (may use /TAG instead)
      
   Optional Keyword Parameters:
      str_pattern (input) -  optional match pattern in structure name
      /XXXXX      (input) -  TAG may be passed via KEYWORD INHERITANCE
      missing     (input) -  Fill Value for missing tags (implies type)
      default     (input) -  Synonym for MISSING (fill or default values)
      struct 	   (output) -  structure name at match level 
      level       (output) -  nest level where match found 
		   [ -1 -> not found, 0 -> top level, 1 -> nested one down, etc)
      found       (boolean) - true if found (level ne -1)

   Calling Sequence:
      tag_val=gt_tagval(item, tagname [,str_patt='pattern', struct=struct, $
					level=level, found=found)

   Calling Examples:
      tagval=gt_tagval(structures,'tagname', found=found) ; extract str.TAG
      tagval=gt_tagval(structures,/tagname,  found=found) ; same as above
      fitval=gt_tagval(fitsheader,/parameter,found=found) ; FITs header

   Method:
      recursive for nested structures (calls str_tagval)

 CALLS: ***
	data_chk [1], data_chk [2], tag_index [1], tag_index [2], wc_where [1]
	wc_where [2]
 CALLED BY:
	EIT_FXPAR, GET_FITS_CDELT, GET_FITS_CEN, HSI_EVENTLIST_TO_SPECTROGRAM [1]
	HSI_EVENTLIST_TO_SPECTROGRAM [2], HSI_FOVBOX, HSI_HIST_GROUP, HSI_RMAP_DIM
	HSI_SPECTROGRAMCHAN_OVERLAP_FIX, HSI_SPECTROGRAM_DECIM_CORRECT
	HSI_SPECTROGRAM_DECIM_TABLE, MDI__DEFINE, READ_ANALIST
	SPECTROGRAM CLASS DEFINITION, SPEX_DATA_GENX [1], SPEX_DATA_GENX [2]
	TRACE_LIST_INDEX, TRACE_PREP, TRACE_SSWHERE [1], TR_DARK_SUB, TR_EXT_SUBIMG
	TR_FLAT_SUB, eit_fulldiskdb, eit_gt_filter, eit_gt_wave, eit_proton_summary
	get_history, get_infox, get_solar_indices, goes_value2class, gt_yo_station
	gtt_info, hsi_spectrogramACCBIN [2], hsi_spectrogram__define [1]
	hsi_spectrogram__define [2], hsi_spectrogram__define [3]
	hsi_spectrogram__get_obs [1], hsi_spectrogram__livetime [1], index2fov
	les_archive_info, map2index, mreadfits, mreadfits_fixup, mreadfits_sxig12
	mxf_decomp_data, mxf_dset_map, mxf_read_data, mxfdset_map, mxfread, plot_ace
	plot_fov [1], plot_goesp, pr_his_index [1], pr_his_index [2], pr_his_index [3]
	rd_mdi [1], rd_mdi [2], read_eit, read_lapalma, read_soon, read_sxt, read_trace
	required_tags, return  a solar disk mask using SSW standard keywords
	return solar disk mask constrained by XY limits using SSW standards
	ssw_apkpbar, ssw_build_trace, ssw_contrib_info, ssw_contrib_monitor
	ssw_contrib_ok2online, ssw_expand_times, ssw_findstuff2html, ssw_flare_locator
	ssw_fov_context, ssw_fs_maskdbase, ssw_getdst, ssw_install [1], ssw_install [2]
	ssw_nar2armurl, ssw_pos2zenith, ssw_subimage, ssw_track_fov, sswstruct_fill [1]
	sxt_his_info [2], sxt_mornint, sxt_orhis, sxt_prep [1], sxt_prep [2], sxt_prep [3]
	tr_head_info, tr_mech_summary_img month, tr_wrt_fits_i1 [2], trace_bin_struct
	trace_cat2cosmic, trace_cat2data, trace_cen2pix, trace_comsmic_norm
	trace_cosmic2filename, trace_get1www_image, trace_get_vignette
	trace_jpeg_dbase, trace_jpeg_decomp, trace_last_movie [1]
	trace_last_movie [3], trace_movies_prioritize [1]
	trace_movies_prioritize [2], trace_scale, trace_special_movie [1]
	trace_special_movie [2], trace_special_movie [3], trace_special_movie2
	trace_sswhere [2], trace_sswhere [3], trace_sswhere [4], trace_struct2filename
	trace_sub2point, trace_submit_request, trace_wave2point, trace_write_genxcat
	write_genxcat, write_trace_bin, xdisp_trace [1], yoh_orb_interp [1]
	yoh_orb_interp [2]
   History:
      Circa 1-dec-1995 S.L.Freeland  
      15-aug-1996   Just make this a synonym for str_tagval 
      28-oct-1996   S.L.Freeland - allow FITS header
      19-Feb-1998   S.L.Freeland - add MISSING and DEFAULT keywords (synonym)
      20-April-1998 Zarro (SAC/GSGC) - added check for single element vector
      25-Oct-1998   S.L.Freeland - allow MISSING/DEFAULT for 1 element case
      16-Nov-1998   Zarro (SM&A) - vectorized MISSING/DEFAULT

   Method: call <str_tagval> for structures, <fxpar> for FITs header


gt_time [1] $SSW/gen/idl/genutil/gt_time.pro
[Previous] [Next]
NAME:
	gt_time
PURPOSE:
	To extract the word corresponding to time and optionally
	return a string variable for that item.  If the item passed is an
	integer type, it is assumed to be the 7-element external representation
	of the time.
CALLING SEQUENCE:
	x = gt_time(roadmap)
	x = gt_time(index)
	x = gt_time(index.sxt, /space)		;put single space before string
	x = gt_time(index, space=3)		;put 3 spaces
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
				(or)
                The "standard" 7 element external representation
                of time (HH,MM,SS,MSEC,DD,MM,YY)
OPTIONAL INPUT:
	string	- If present, return the string mnemonic (long notation)
	spaces	- If present, place that many spaces before the output
		  string.
	msec	- If present, also print the millisec in the formatted 
		  output.
	nolead0	- If present, do not include a leading "0" on the hour string
		  for hours less than 10. (ie: return 9:00:00 instead of 09:00:00)
OUTPUT:
	returns	- The time, a integer value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector
                 Sample String: 23:25:10
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
 CALLS: ***
	Int2Ex [1], Int2Ex [2], anytim2ints [1], anytim2ints [2], tbeep [1], tbeep [2]
	tbeep [3]
 CALLED BY:
	ALIGN_AR, ATIME [1], ATIME [2], BCS_ACCUM [1], BCS_ACCUM [2], BCS_DP_CHECK
	BCS_DT_INTERP [1], BCS_DT_INTERP [2], BORN_AGAIN, BSC_TIM2DSET, CCCA
	CHECK_SFC_PNT, COVER_PAGE [1], COVER_PAGE [2], DATAGET3_GRS, DATAGET3_HXS, DAY_IN
	EIT_GBO, F_ATIME [1], F_ATIME [2], GETCAL_ATT [1], GETCAL_ATT [2], GET_FRAME_TIME
	GET_POINTS, GET_SUNCENTER [1], GET_SUNCENTER [2], GET_YOHKOH_POS, GT_BSC_TIME
	HXT_4CHPLOT, HXT_DUMP, INF_STR, IRU_OFFS, LIST_BDA, LIST_BSC [1], LIST_BSC [2]
	LIST_GEV, MAKE_VTRANGE, MDI_GBO, MK_GRSPCH, MK_GRSPCL, MK_GRSPHH1, MK_GRSPHH2
	MK_GRSPHL1, MK_GRSPHL2, MK_HXI_MAP, MK_HXSPC, MK_HXSPH, MK_RBMPC, MK_SXT_MAP
	NORH_PR_EVX [1], NORH_PR_EVX [2], ORB_EXTRAP, OUT_GRSPHL1, OUT_GRSPHL2, OUT_HXSPH
	OVER_THE_LIMB, PLOT_GRSPCH, PLOT_GRSPCL, PLOT_GRSPHH, PLOT_GRSPHL, PLOT_HXSPC
	PLOT_HXSPH, PLOT_HXT, PREFLARE_SEARCH, PRINT_GEV, RD_AR, RES_FFI, SEL_AR, SPLINE_LC
	SPLINE_PLOT, SSDA, SXI_GBO, SXTASEQ, SXT_HYST, SXT_OBSRPT, TIM2JD [1], TIM2JD [2]
	TIME_INFO, TRACE_GBO, TVF_SLICE, WBDA [1], WBDA [2], WBSC [1], WBSC [2]
	WBSC_LTC_EV [1], WBSC_LTC_EV [2], WBS_DB, WBS_DB2, anytim [1], anytim [2]
	anytim [3], anytim [4], anytim [5], anytim2ex [1], anytim2ex [2], anytim2ints [1]
	anytim2ints [2], auto_toban, bcs_survey, bcs_trange, cam_run_sum, carr2btime [2]
	cnvt [2], contacts [1], contacts [2], db_gbo, filetimes [1], filetimes [2], fmt_pass
	fmt_tim [1], fmt_tim [2], function timeintervalab, get_dc_image [2]
	get_dc_image [3], get_info_lp, get_leak_image [1], get_leak_image [2]
	get_leak_image [3], goes_summary, grs_plot, gtab_file, hsi_gbo, hxt_images2ps
	img_seq [1], int2sec [1], int2sec [2], ip_que_dmpver, jitter_gif_xyimg
	lastsfd [1], lastsfd [2], list_tfi, mdi_display, mk_bsa_interv [1]
	mk_bsa_interv [2], mk_desat_wl, mk_hxt_sum_64, mk_mdi_iap, mk_ptv_title, mk_sdmi
	mk_sfd [1], mk_sfd [2], mk_sfd [3], mk_sfd [4], mk_sfw, mk_title [1], mk_title [2]
	mk_title [3], mon_sci5k, obs_summary, op_bdr_opt, op_pass_sheets [1]
	op_pass_sheets [2], pass_sheets, plot_ref, pr_evn [2], pr_fdss_viewpd, pr_fem
	pr_gbe, pr_gev, pr_visible
	pro interpretfemfemfemtimefemflgfemstrfemstrverboseverbose
	pro loadopfemfiletimeOGfemverboseverbose
	pro loadoptextfiletimeOGverboseverbose
	pro optimizedbdrfileshowparamshowparam, pro showaoslosgdfemtimefemflg
	rd_raw_station_plan, rd_sci5k, rd_sfd_carr, rd_so_at_ftr, rd_station_plan
	rd_therm_rs232, read_eit, redo_disploi, redo_mon_sci5k, ret_day, sacpeak_image
	sda2fits, show_contacts, sxt_align, sxt_combine, sxt_composite [1]
	sxt_composite [2], sxt_composite [3], sxt_images2ps, sxt_sff_composite [1]
	sxt_sff_composite [2], tim2dset [1], tim2dset [2], tim2orbit [1], tim2orbit [2]
	tim2tfss, time_add1s, time_addxa, timeline, tr_decode_head [1], tr_decode_head [2]
	usertimes_event, wrtsxtmap, xhkplot, xread_hist, xy_raster [1], xy_raster [2]
	xy_raster [3]
HISTORY:
	Written 13-Nov-91 by M.Morrison
	15-Nov-91 (MDM) - Added "msec" and "nolead0" options.  Made the default
		 	  different from before for leading 0 (it will have a leading
			  zero unless the /nolead0 option is used)
       16-May-93 (MDM) - Modified to accept string time as input
	14-Nov-97 (MDM) - Changed FOR loop to use long integer


gt_total_cnts [1] $SSW/gen/idl/fund_lib/yohkoh/gt_total_cnts.pro
[Previous] [Next]
NAME:
	gt_total_cnts
PURPOSE:
	To extract the word corresponding to the BCS total counts (as 
	derived from the spectra).  Default output is cnts/sec.
CALLING SEQUENCE:
	x = gt_total_cnts(roadmap)
	x = gt_total_cnts(roadmap,1)
	x = gt_total_cnts(index,2)
	x = gt_total_cnts(index.sxt, /string)		;return variable as string type
METHOD:
	The input can be a structure or a scalar.  The structure can
	be the index, or roadmap, or observing log.
INPUT:
	item	- A structure or scalar.  It can be an array.  
OPTIONAL INPUT:
	ichan	- Channel number to extract (1,2,3,4) - if not present,
		  the output is an 4xN data array
	string	- If present, return the string mnemonic (long notation)
	short	- If present, return the short string mnemonic 
	spaces	- If present, place that many spaces before the output
		  string.
OUTPUT:
	returns	- The total counts per sec, a floating point value or a string
		  value depending on the switches used.  It is a vector
		  if the input is a vector.  If no channel was selected,
		  then the output is a 2-D array (4xN)
OPTIONAL OUTPUT:
       header  - A string that describes the item that was selected
                 to be used in listing headers.
	title	- A string that can be used with a plotting title.  If
		  no channel is specified, then title is an array of 4
		  elements.
 CALLS: ***
	gt_conv2str [1], gt_conv2str [2]
 CALLED BY:
	BCS_24HR_PLOT [1], BCS_24HR_PLOT [3], LCBDA, WBDA [1], WBDA [2], bcs_survey, get_bcs
	lcobs, mk_evn [1], mk_evn [2], plott_bda, ploty [1], ploty [2]
HISTORY:
	Written 7-Mar-92 by M.Morrison
	20-Mar-92 (MDM) - Added "title" option
	 4-Jun-92 (MDM) - The value being returned was NOT the counts/sec.
			  The normalization was not being done right.  
			  Previously the value returned was cnts/DGI.
	 1-Jul-92 (MDM) - Adjusted so that the counts returned were 
			  true counts/sec (perviously the *10 factor
			  was missing)
	24-Nov-92  RDB  - Made factor 10 a real to stop overflow...


GT_VMAP $SSW/gen/idl/mapping/gt_vmap.pro
[Previous] [Next]
 Project     : SOHO-CDS

 Name        : GT_VMAP

 Purpose     : Compute a velocity map from a fitted map structure that
               contains centroid information

 Category    : imaging

 Explanation : 

 Syntax      : vmap=gt_vmap(map,centroid,offset=offset,vrange=vrange)

 CALLED BY:
	UNPACK_MAP
 Examples    :

 Inputs      : MAP = map structure created by MK_MAP
               CENTROID = rest centroid value

 Opt. Inputs : None


 Outputs     : VMAP = velocity data map (in km/s)

 Opt. Outputs: 

 Keywords    : VRANGE = [min,max]; values outside this range set to zero

 CALLS: ***
	EXIST, PR_SYNTAX, TAG_EXIST [1], TAG_EXIST [2], VALID_MAP
 Common      : None

 Restrictions: None

 Side effects: None

 History     : Written 22 Jan 1997, D. Zarro, SAC/GSFC

 Contact     : dzarro@solar.stanford.edu


GUESS_FIT_PAR $SSW/gen/idl/fitting/guess_fit_par.pro
[Previous] [Next]
 Project     :  YOHKOH-BCS

 Name	      :  GUESS_FIT_PAR

 Purpose     :  Guess line parameters for fitting single and/or double component

 Explanation: Smoothes spectrum to find mean minimum flux for background
              then find maximum flux location for line.

 Category    : fitting

 Syntax      : guess_fit_par,wave,flux,fit_par

 Inputs      : wave - wavelength array
               flux - flux array

 Outputs     : fit_par =[fback,0,0,intens,wcent,doppw, intens2,wcent2,doppw2]
               wcent - wavelength center of strongest line in spectrum
               intens- peak line intensity
               doppw - doppler width of line (1/e half-width)
               fback - linear continuum background

 Opt. Outputs: sigmaa = sigma errors

 Keywords    : lrange - wavelength range to limit line search
               crange - wavelength range to limit continuum calculation
               sbin   - bin smoothing value 
               double - fit a second component
               plot   - plot results
               blue   - find a blueshifted second cmpt
               lineonly - fit line only
 CALLED BY:
	DVOIGT_FIT, FBLUE_FIT, GAUSS_FIT, cal_bsc
 Restrictions: 
               The peak or minimum of the Gaussian must be the largest
	        or smallest point in the Y vector.

 CALLS: ***
	AMEDIAN, FINDVAL, INTERPOL
 Side effects: None

 History     : Version 1,  17-July-1993,  D M Zarro.  Written

 Contact     : DZARRO@SOLAR.STANFORD.EDU


gzip $SSW/gen/idl/system/gzip.pro
[Previous] [Next]
 Project     : HESSI

 Name        : gzip 

 Purpose     : gzip/gunzip files

 Category    : utility,i/o

 Syntax      : IDL> gzip,files,gfiles

 Inputs      : FILES = file names to gzip

 Outputs     : GFILES = zipped/unzipped file names

 Keywords    : UNZIP = unzip files

 CALLED BY:
	SITE__DEFINE
 Restrictions: Unix and probably Windows

 CALLS: ***
	APPEND_ARR, ESPAWN, EXIST, HAVE_EXE, IS_COMPRESSED, IS_STRING, LOC_FILE [1]
	LOC_FILE [2], LOC_FILE [3], OS_FAMILY, rem_blanks, str_replace [1]
	str_replace [2]
 Side effects: Files are compressed and overwritten
               .Z files are decompressed and then gzip'ed (Unix only)

 History     : Written 6 July 2000, D. Zarro (EITI/GSFC)

 Contact     : dzarro@solar.stanford.edu