NAME

xatrendtemp - Calculate the quartz clock frequency vs. temperature relation for the on-board clock on XRISM

USAGE

xatrendtemp infile frqtemfile outtemp outfile

DESCRIPTION

The task xatrendtemp calculates the quartz clock frequency vs. temperature relation using in-flight data. The output of this task is used to monitor any deviation of the same relation derived from ground data and stored in the calibration database. The input files are: a) the general HK file (see parameter 'infile'; a single file or a list of files are accepted), and b) the CalDB clock frequency vs. temperature file (see parameter 'frqtemfile'). The frequency vs. temperature relation is obtained by reading the frequencies corresponding to a temperature variation (see parameter 'tempresol') at a given time, and averaging the frequencies in the delta temperature interval. The frequencies and temperatures are located in two separate extensions in the HK file and may be specified by the parameters 'quartzext' and 'tempext', respectively. The extension names for the GPS and temperature, as well as the column names, depend on which on-board computer, SMU (A or B), is disseminating the timing information. The timing information associated with the frequency and temperature is read for columns that may be specified in the parameters 'stimecol', 'l32ticol', and 'u32ticol'. The FITS output file (see parameter 'outfile') is created by cloning the format of the CalDB frequency vs. temperature file. The output file contains the following columns: TEMP (the clock temperature in Celsius), FREQ (the average frequency of the clock in Hz), and NPTTEMP (number of frequency points per temperature). The task xatrendtemp also outputs a temporary ASCII file (see parameter 'outtemp'), to which all non-averaged frequencies and temperatures are written.

PARAMETERS

infile [filename]
Name of the general HK file that contains the quartz clock and temperature extensions. This file is named xa{seq#}gen_a0.hk1, where "{seq#}" is the sequence number of the observation. The task accepts either a string corresponding to a single FITS file, or a string preceded by "@" corresponding to a text file containing a list of FITS files.

frqtemfile = CALDB [filename CALDB|file name]
Name of the calibration file containing the frequency vs. temperature relation. If 'frqtemfile=CALDB', the frequency vs. temperature in the calibration database is used.

outtemp [filename]
Name of the output ASCII file to which all the non-averaged frequencies and temperatures are written.

outfile [filename]
Name of output file to which the averaged frequencies and temperature are written. This is a FITS file with the same format as 'frqtempfile'.

(starttime = ALL) [string ALL|YYYY-MM-DDThh:mm:ss]
The time at which to begin including data in the calculation. The time format should be entered as YYYY-MM-DDThh:mm:ss. If 'starttime' is set to ALL, the start time is effectively the earliest time in each HK file.

(stoptime = ALL) [string ALL|YYYY-MM-DDThh:mm:ss]
The time at which to stop including data in the calculation. The time format should be entered as YYYY-MM-DDThh:mm:ss. If 'stoptime' is set to ALL, the stop time is effectively the latest time in each HK file.

(quartzext = HK_SMU_A_DHFS_TI_MNG_block_get_ti_mng) [string HK_SMU_A_DHFS_TI_MNG_block_get_ti_mng|HK_SMU_B_DHFS_TI_MNG_block_get_ti_mng]
Name of the extension in the general HK file (see 'infile') that contains the frequency information (quartz clock). This is HK_SMU_A_DHFS_TI_MNG_block_get_ti_mng or HK_SMU_B_DHFS_TI_MNG_block_get_ti_mng for the SMUA or SMUB, respectively.

(tempext = HK_SMU_A_AUX_HCE_HK2) [string HK_SMU_A_AUX_HCE_HK2|HK_SMU_B_AUX_HCE_HK3]
Name of the extension in the general HK file (see 'infile') containing the temperature information. This is HK_SMU_A_AUX_HCE_HK2 or HK_SMU_B_AUX_HCE_HK3 for the SMUA or SMUB, respectively.

(quartzcol = SMU_A_DHFS_TI_MNG_TIM_TCAL_INF) [string SMU_A_DHFS_TI_MNG_TIM_TCAL_INF|SMU_B_DHFS_TI_MNG_TIM_TCAL_INF]
Name of the column that contains the frequency information (quartz clock count) in the frequency extension. This is SMU_A_DHFS_TI_MNG_TIM_TCAL_INF or SMU_B_DHFS_TI_MNG_TIM_TCAL_INF for the SMUA or SMUB, respectively.

(l32ticol = L32TI) [string]
Name of the column containing the L32TI times in the frequency extension.

(u32ticol = SMU_A_DHFS_TI_MNG_TIM_TCAL_TIME) [string SMU_A_DHFS_TI_MNG_TIM_TCAL_TIME]|SMU_B_DHFS_TI_MNG_TIM_TCAL_TIME]
Name of the column containing the U32TI times in the frequency extension. This is SMU_A_DHFS_TI_MNG_TIM_TCAL_TIME or SMU_B_DHFS_TI_MNG_TIM_TCAL_TIME for the SMUA or SMUB, respectively.

(tempcol = HCE_A_SENS_SMU_A_TEMP_CAL) [string HCE_A_SENS_SMU_A_TEMP_CAL|HCE_B_SENS_SMU_B_TEMP_CAL]
Name of the column containing quartz temperature in the temperature extension. This is HCE_A_SENS_SMU_A_TEMP_CAL or HCE_B_SENS_SMU_B_TEMP_CAL for SMUA or SMUB, respectively.

(stimecol = S_TIME) [string]
Name of the column containing the S_TIME time values present in both the frequency and temperature extensions.

(leapsecfile = REFDATA) [filename REFDATA|CALDB|file name]
Name of the file giving the table of leap seconds. If set to CALDB or REFDATA, the file is read from the calibration database, CalDB, or the REFDATA area, respectively.

(tempresol = 1.0) [double]
Delta temperature [Celsius] over which the frequencies are averaged.

(stimemax = 500.) [double]
This parameter is an upper limit on the difference between an S_TIME value in the quartz clock extension and immediately adjacent (lower or upper) values of S_TIME in the temperature extension of the input file(s). If the difference, or "delta S_TIME" between either the lower or upper adjacent values is greater than 'stimemax', the data are not used.

(averagemode = 1) [integer]
Mode for computing average frequencies. Currently only a simple average is supported ('averagemode=1').

(buffer = -1) [integer -1|0|N]
Rows to buffer (-1=auto, 0=none, N>0=number of rows).

(clobber = no) [boolean yes|no]
Overwrites the existing output file if set to yes.

(chatter = 1) [integer 0|1|2|3]
Chatter level for output. Set to 0 to suppress output, or to 1, 2, or 3 for increasing the chatter of the output.

(logfile = !DEFAULT) [string DEFAULT|NONE|file name]
Log file name. If set to DEFAULT, uses the name of the task and, if preceded by "!", overwrites the file if it exists. If set to NONE, no log file is created.

(debug = no) [boolean yes|no]
Diagnostic output is printed to the screen if set to yes.

(history = yes) [boolean yes|no]
Records task parameters in HISTORY.

EXAMPLES

  1. Calculate the frequency vs. temperature using the HK file gen.hk and the CalDB file for the frequency vs. temperature relation. The outputs are written to the FITS file freqtemp.caldb.out and to the ASCII file dat.out.
       xatrendtemp infile=xa100050020gen_a0.hk frqtemfile=CALDB outfile=xa100050020_freqtemp_caldb_out.fits outtemp=xa100050020_freqtemp_caldb_out.txt
    

LAST MODIFIED

June 1, 2023