KAP_CONTENTS $SSW/soho/gen/idl/plan/science/kap_contents.pro
[Previous] [Next]
 PROJECT:
       SOHO - CDS/SUMER

 NAME:
       KAP_CONTENTS()

 PURPOSE:
       Read in the latest KAP (or CAP or IAP) file for the given date

 CATEGORY:
       Science Planning

 EXPLANATION:

 SYNTAX:
       Result = kap_contents(date)

 INPUTS:
       DATE - Date for which the KAP file is read; can be in any CDS
              time format

 OPTIONAL INPUTS:
       None.

 OUTPUTS:
       result - String array containing contents of the KAP (default)
                or CAP or IAP file; a null string will be returned if
                error occurs for any reason

 OPTIONAL OUTPUTS:
       None.

 KEYWORDS:
       ERROR - Named variable containing any error message. If no
               error occurs, ERROR will be a null string
       IAP   - Set this keyword to read the latest IAP file
       CAP   - Set this keyword to read the latest CAP file
       VERSION - A named variable containing the file version

 CALLS: ***
	FIND_KAP_FILE, RD_ASCII [1], RD_ASCII [2]
 COMMON:
       None.

 RESTRICTIONS:
       None.

 SIDE EFFECTS:
       None.

 HISTORY:
       Version 1, August 21, 1995, Liyun Wang, GSFC/ARC. Written
       Version 2, September 1, 1995, Liyun Wang, GSFC/ARC
          Added keyword VERSION and keywords IAP, CAP so that CAP and
             IAP files can be read as well
       Version 3, July 28, 1997, Zarro (SAC/GSFC) - Modified to call 
          FIND_KAP_FILE

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


KAP_DATE $SSW/soho/gen/idl/plan/science/kap_date.pro
[Previous] [Next]
 Project     :	SOHO - CDS

 Name        :	KAP_DATE()

 Purpose     :	Returns the date of a KAP file

 Explanation :	This routine looks at the name of a KAP file, and determines
		the date it applies to.  It assumes a filename of the form
		"ECSyyyymmddvvv.KAP".

 Use         :	Date = KAP_DATE(FILENAME)

 Inputs      :	FILENAME = The name of the KAP file.

 Opt. Inputs :	None.

 Outputs     :	The result of the function is the date extracted from
		the filename, in CDS internal format.  If unable to determine a
		date, then -1 will be returned instead.  (For better error
		capturing, use the ERRMSG keyword.)

 Opt. Outputs:	None.

 Keywords    :	MJD	 = If set, then only the Modified Julian Day part of
			   the date will be returned.

		ERRMSG   = If defined and passed, then any error messages will
			   be returned to the user in this parameter rather
			   than being handled by 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 = ''
				Result = KAP_DATE( FILENAME, ERRMSG=ERRMSG )
				IF ERRMSG NE '' THEN ...

 Calls       : ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], DATATYPE [1], DATATYPE [2]
	DATATYPE [3], REMCHAR [1], REMCHAR [2], REMCHAR [3], STR2UTC [1], STR2UTC [2]
	STR2UTC [3], break_file [4]
 Common      :	None.

 Restrictions:	Only works if the filename has the correct format.

 Side effects:	None.

 Category    :	Planning, Activity plans

 Prev. Hist. :	None.

 Written     :	William Thompson, GSFC, 24 May 1995

 Modified    :	Version 1, William Thompson, GSFC, 24 May 1995
		Version 2, William Thompson, GSFC, 2 August 1995
			Made compatible with NFS on VMS computers.

 Version     :	Version 2, 2 August 1995


KAP_VERS $SSW/soho/gen/idl/plan/science/kap_vers.pro
[Previous] [Next]
 Project     :	SOHO - CDS

 Name        :	KAP_VERS()

 Purpose     :	Returns the version number of a KAP file

 Explanation :	This routine looks at the name of a KAP file, and determines
		the version number.  It assumes a filename of the form
		"ECSyyyymmddvvv.KAP".

 Use         :	Version = KAP_VERS(FILENAME)

 Inputs      :	FILENAME = The name of the KAP file.

 Opt. Inputs :	None.

 Outputs     :	The result of the function is the version number extracted from
		the filename.  If unable to determine a version number, then -1
		is returned instead.

 Opt. Outputs:	None.

 Keywords    :	None.

 Calls       : ***
	BREAK_FILE [1], BREAK_FILE [2], BREAK_FILE [3], DATATYPE [1], DATATYPE [2]
	DATATYPE [3], REMCHAR [1], REMCHAR [2], REMCHAR [3], VALID_NUM [1], VALID_NUM [2]
	VALID_NUM [3], break_file [4]
 CALLED BY:
	READ_KAP
 Common      :	None.

 Restrictions:	Only works if the filename has the correct format.

 Side effects:	None.

 Category    :	Planning, Activity plans

 Prev. Hist. :	None.

 Written     :	William Thompson, GSFC, 24 May 1995

 Modified    :	Version 1, William Thompson, GSFC, 24 May 1995
		Version 2, William Thompson, GSFC, 2 August 1995
			Made compatible with NFS on VMS computers.

 Version     :	Version 2, 2 August 1995


KDATE $SSW/soho/lasco/idl/util/kdate.pro
[Previous] [Next]
 NAME:
	KDATE

 PURPOSE:
	This procedure converts a k index (modified julian date) into the
	day, month and year

 CATEGORY:
	UTIL

 CALLING SEQUENCE:
	KDATE,K,Id,Im,Iy

 INPUTS:
	K:	The k-index (modified julian date)

 OUTPUTS:
	Id:	The date of month
	Im:	The number of the month (1..12)
	Iy:	The year

 CALLS: ***
	GET_UTC, UTC2STR
 CALLED BY:
	INCREASEDAY
 MODIFICATION HISTORY:
 	Written by:	RA Howard, 1975

	@(#)kdate.pro	1.2 10/17/96 LASCO IDL LIBRARY


KDAY $SSW/soho/lasco/idl/util/kday.pro
[Previous] [Next]
 NAME:
	KDAY

 PURPOSE:
	This procedure converts a calendar date to the corresponding serial
	day number.  

 CATEGORY:
	UTIL

 CALLING SEQUENCE:
	KDAY,Id,Im,Iy,K

 INPUTS:
	Id:	The day of month (1..31)
	Im:	The number of month (1..12)
	Iy:	The year, either as a two or four digit number

 OUTPUTS:
	K:	The serial day number.  To obtain the Julian Day number (valid 
		at noon), add 2415079

 CALLS: ***
	STR2UTC [1], STR2UTC [2], STR2UTC [3]
 CALLED BY:
	INCREASEDAY, getcputime
 MODIFICATION HISTORY:
 	Written by:	RA Howard, NRL, 1975.

	@(#)kday.pro	1.3 05/09/98 LASCO IDL LIBRARY


KeySea [1] $SSW/soho/mdi/idl_old/gen/ys_sxt_widget/keysea.pro
[Previous] [Next]
	Name:
		KeySea
	Purpose:
		Decode item, operator, and value from 'key' parameter,
		apply the search to the input data vectors and return
		the success indices of the input data vector.  A single 
		success index vector is always  returned for each call.
		A multiple item search begins with the first item in 
		the list which is "AND" to the
		results of the next item search and so on.
	CALLING SEQUENCE:
		idx = KeySea(key, vec)
	Input:
		key 	item, operator and value for Search
		invec	data vector to be searched 
	RETURNED:
		idx	list of success indices for the search key.
 CALLS: ***
	Ck_Item, ParsKey, STR2ARR [1], STR2ARR [2], SXTKaySea [1], SXTKaySea [2]
 CALLED BY:
	RdObsDat, mk_key, mk_sdl
	History:
		written 16-Oct-91 by GAL from 20-Aug-91 version of
			KeySearch procedure.
			17-Oct-91, deleted keywords and add internal
			checks for input structure-type (ie sxt or bcs)
			for future use with other instruments.
			21-Oct-91, Minor correction to way the index
			list is being made-- MDM and GAL
			10-Jan-92, GAL opt and xray searches use gt
			functions, see SXTKaysea.
			


kill_ftp [1] $SSW/soho/mdi/idl_old/gen/ys_util/kill_ftp.pro
[Previous] [Next]
NAME:
	kill_ftp
PURPOSE:
	To monitor FTP jobs that have hung up and are eating up CPU
HISTORY:
	Written 13-Sep-93 by M.Morrison
	19-Oct-93 (MDM) - Modified how ftp jobs were recognized
       18-Mar-94 (SLF) - Trained to kill


kpmag2mdi $SSW/soho/mdi/idl/ops/kpmag2mdi.pro
[Previous] [Next]
NAME:
	kpmag2mdi
PURPOSE:
	To FTP copy Kitt Peak magnetogram FITS images, convert them
	to the size/shape of MDI, and to save them as FITS files.
SAMPLE CALLING SEQUENCE:
	.run kpmag2mdi
HISTORY:
	Written 27-Apr-95 by M.Morrison
	27-Apr-95 (MDM) - Changed the directory to /mdisw/dbase/ops/synoptic
			- Changed the output file name
			- Added some informational print statements
	 1-Aug-95 (MDM) - Changed output directory to /mdisw/data/ops/synoptic
			- Fixed up the FTP_COPY call
	 2-Aug-95 (MDM) - Fixed up the FTP_COPY call some more
	 4-Aug-95 (MDM) - Modified to save the high resolution equivalent image
			- Changed the time format of the FITS DATE-OBS field


kpmag2mdix $SSW/soho/mdi/idl/ops/kpmag2mdix.pro
[Previous] [Next]
NAME:
	kpmag2mdix
PURPOSE:
	To FTP copy Kitt Peak magnetogram FITS images, convert them
	to the size/shape of MDI, and to save them as FITS files.
SAMPLE CALLING SEQUENCE:
	.run kpmag2mdi
HISTORY:
	Written 27-Apr-95 by M.Morrison
	27-Apr-95 (MDM) - Changed the directory to /mdisw/dbase/ops/synoptic
			- Changed the output file name
			- Added some informational print statements
	 1-Aug-95 (MDM) - Changed output directory to /mdisw/data/ops/synoptic
			- Fixed up the FTP_COPY call
	 2-Aug-95 (MDM) - Fixed up the FTP_COPY call some more
	 4-Aug-95 (MDM) - Modified to save the high resolution equivalent image
			- Changed the time format of the FITS DATE-OBS field