MAKCLK User's Guide =========================================================================== Last revised on 2021 JUN 23 by M. Costa Sitja. Abstract -------------------------------------------------------- MAKCLK is a program that converts a SCLKSCET (also known as SCLKvSCET) file to a SPICE spacecraft clock (SCLK) kernel file. Summary -------------------------------------------------------- MAKCLK is a NAIF utility program that converts a SCLKSCET file to a SPICE spacecraft clock (SCLK) kernel file. Within SPICE, SCLK kernel files are used to relate spacecraft clock time with other time systems, such as ephemeris time and UTC time, using routines available in the SPICE library contained in the SPICE toolkit. This program was created to be used for SCLKSCET to SCLK conversions on flight projects that produce SCLKSCET files for use in non-SPICE based ground system tools. But it has proven useful to missions that do not otherwise need to produce or use SCLKSCET files. This is because it is much easier to first convert clock correlation data into a SCLKSCET file and then use MAKCLK to convert the SCLKSCET file to a SCLK kernel than it is to write an application that will make an SCLK kernel from ``scratch''. Indeed in most cases a piece-wise linear clock correlation function derived from time correlation telemetry packets already has the same set of parameters as a SCLKSCET file -- reference UTC/on-board clock time pairs and clock drift rates -- and all that has to be done to make a SCLKSCET file from that data is to add a header and write the items in the format and order that the SCLKSCET definition calls for. NAIF encourages customers to use this two-step process to make an SCLK file -- construct a SCLKSCET file from your clock correlation data, then run that SCLKSCET file through MAKCLK to produce a SPICE SCLK file -- because making an SCLK file from scratch is rather difficult. NAIF does not have available any other utility programs for producing an SCLK file. Usage -------------------------------------------------------- To run the program users must prepare a setup file containing keyword-value assignments with all necessary setup information, start the program by typing the program's name on a shell command line, and provide the name of the setup file in response to the program's prompt, as follows: > makclk ------------------------------------------------------------------- MAKCLK SCLKSCET --> SPICE SCLK Conversion Utility Version 4.0.0, 11-MAR-2009 ------------------------------------------------------------------- Enter the name of the command file > [type setup file name here] ... Setup File -------------------------------------------------------- Setup File Syntax The keyword-value assignments in the setup file must be provided in the following form: KEYWORD = VALUE with the following syntactical rules applying to these assignments: 1. Each assignment statement is limited to one line (80 characters maximum). 2. White space is allowed before and after the equal sign. 3. A semi-colon and characters to the right of a semi-colon are ignored. 4. Value fields are treated as character strings; no single or double quotes are necessary. 5. The case of assignment statements is not significant. 6. The relative order of keyword-value pairs is not significant. 7. Duplicate keywords are not allowed. Setup Keywords Listed below is the set of keywords that may appear in the command file. All but IGNORE_RECORDS_BEFORE and PRESERVE_RATES are required. SCLKSCET_FILE OLD_SCLK_KERNEL FILE_NAME SPACECRAFT_ID LEAPSECONDS_FILE PARTITION_TOLERANCE IGNORE_RECORDS_BEFORE OUTPUT_DIGITS LOG_FILE A description of each of the above keywords is given below. SCLKSCET_FILE the name of a SCLKSCET file that conforms to the specifications given in reference 1 (see References at the end of the document) and briefly described in the ``SCLKSCET Format'' section below. OLD_SCLK_KERNEL the name of an existing SPICE SCLK kernel (also called an SCLK ``template'' file) for the spacecraft. Only the clock format specification data is needed from this file, so it doesn't need to contain any real clock calibration records. FILE_NAME the name of the new SPICE SCLK kernel to be generated by the program. This file must not exist before the program is run. SPACECRAFT_ID the NAIF ID of the spacecraft. For example, -74 for Mars Reconnaissance Orbiter. LEAPSECONDS_FILE the name of a current SPICE leapseconds kernel (LSK) file. Note that using an out-of-date LSK file frequently results in an incorrect output SCLK kernel. PARTITION_TOLERANCE the tolerance used by MAKCLK to determine when a new spacecraft clock partition occurs. The units must be in ticks, the smallest increment of the spacecraft clock. IGNORE_RECORDS_BEFORE the time constraint used to specify which SCLKSCET data must be processed. All SCLKSCET data records whose UTC time is earlier than this time will be ignored by the program. This keyword is optional; if it is not provided, all SCLKSCET data records are processed. PRESERVE_RATES the flag indicating whether the rates from the SCLKSCET file should not be adjusted to enforce continuity at the points that are not partition boundaries (as determined using the value provided in PARTITION_TOLERANCE). Allowed values are YES and NO. This keyword is optional; if it is not provided, the rates are adjusted. OUTPUT_DIGITS the number of significant digits in the values of the SCLK_PARTITION_START_x, SCLK_PARTITION_END_x, and SCLK01_COEFFICIENTS_x keywords in the output SCLK kernel file. The value of this keyword must be between 14 and 17. This keyword is optional; if it is not provided, the number of significant digits is set to 14. To decide whether specifying more than 14 digits is needed or not, determine the number of digits needed to accommodate the maximum integer number of ticks that the clock will count by the end of the mission. If this number is greater than 14, use this keyword to specify a number that is large enough to hold such a tick count without rounding. LOG_FILE the name of the log file where partition boundary discontinuity information will be recorded. This file will keep a record of all the clock discontinuities found in the SCLKSCET file that are larger than the value specified in the PARTITION_TOLERANCE keyword. For each clock discontinuity, the SCET time of the discontinuity, the given and expected SCLK times, and the absolute difference in SCLK times are recorded. This file must not exist before the program is run. To make MAKCLK prompt for a value of any given keyword, a question mark can be placed in the value field of the assignment statement. For example, for MAKCLK to prompt for the name of the new SCLK kernel file, the FILE_NAME assignment should be given in the command file as shown below: FILE_NAME = ? Setup File Example Below is an example setup file for MRO: SCLKSCET_FILE = MRO_SCLKSCET.00028 OLD_SCLK_KERNEL = mro_template.tsc FILE_NAME = MRO_SCLKSCET.00028.tsc NAIF_SPACECRAFT_ID = -74 LEAPSECONDS_FILE = naif0009.tls PARTITION_TOLERANCE = 10 LOG_FILE = MRO_SCLKSCET.00028.log SCLKSCET Format -------------------------------------------------------- The program can process SCLKSCET files that have the following format: CCSD3ZS00001$$sclk$$NJPL3KS0L015$$scet$$ ... CCSD3RE00000$$scet$$NJPL3IS00613$$data$$ ... <title line n> <data line 1> ... <data line m> CCSD3RE00000$$data$$CCSD3RE00000$$sclk$$ The lines starting with ``CCSD'' are the required file section separator lines. All three must be provided and must look exactly as shown above. The ``SFDU keyword lines'' are the lines containing SFDU header keyword-value assignments. Normally the following keywords are included in the SCLKSCET SFDU headers: MISSION_NAME = <mission name>; SPACECRAFT_NAME = <spacecraft name>; DATA_SET_ID = SCLK_SCET; FILE_NAME = <SCLKSCET file name>; PRODUCT_CREATION_TIME= <date/time in ISO date or DOY format>; PRODUCT_VERSION_ID = <product version number>; PRODUCER_ID = <producer name>; APPLICABLE_START_TIME = <date/time in ISO date or DOY format>; APPLICABLE_STOP_TIME = <date/time in ISO date or DOY format>; MISSION_ID = <DSN mission ID>; SPACECRAFT_ID = <DSN spacecraft ID>; These lines are ignored by MAKCLK but are required for other tools that use SCLKSCET files. The ``title lines'' are the lines identifying columns in the data section. At least one ``title line'' must be provided. All ``title lines'' must begin with the ``*'' character. Normally only one ``title line'' is provided and it looks like this: *____SCLK0_______ ____SCET0____________ _DUT__ _SCLKRATE___ These lines are used by MAKCLK only to identify the beginning of the data section of the file. The ``data lines'' contain the clock correlation data that MAKCLK converts to equivalent data stored in the output SCLK kernels. The data lines must have the following format: SCLK SCET DUT SCLKRATE where SCLK is a character representation of the spacecraft clock, with no reference to a partition; SCET is the UTC time associated with the spacecraft clock time, provided in ISO date (``YYYY-MM-DDTHR:MN:SC.FFF'') or ISO DOY (``YYYY-DOYTHR:MN:SC.FFF'') format; DUT is the leapseconds correction time (this field will not be parsed in the conversion, since SPICELIB accounts for this using data from the provided LSK file); SCLKRATE is the number of Terrestrial Dynamic Time (TDT) seconds that occur in one major SCLK count. Blank lines may be present in any section of a SCLKSCET file -- they will be ignored by MAKCLK. Any lines with a zero or negative SCLKRATE are also ignored by the program. The first record in any pair of records whose SCETs are less that 0.002 milliseconds apart will also be ignored. Below is an example of a complete SCLKSCET file, flc_sclkscet.00007, for a fictional spacecraft named Falcon with DSN ID 77, launched on July 6, 2008: CCSD3ZS00001$$sclk$$NJPL3KS0L015$$scet$$ MISSION_NAME=FALCON; SPACECRAFT_NAME=FALCON; DATA_SET_ID=SCLK_SCET; FILE_NAME=flc_sclkscet.00007; PRODUCT_CREATION_TIME=2009-04-07T12:39:55; PRODUCT_VERSION_ID=00007; PRODUCER_ID=NAIF; APPLICABLE_START_TIME=2000-001T11:58:56; APPLICABLE_STOP_TIME=2020-001T00:00:00; MISSION_ID=77; SPACECRAFT_ID=77; CCSD3RE00000$$scet$$NJPL3IS00613$$data$$ *____SCLK0_____ ________SCET0________ _DUT__ __SCLKRATE__ 0.000 2000-001T11:58:55.816 64.184 1.000000000 189345665.000 2006-001T00:00:00.816 64.184 0.000010000 189345666.000 2006-001T00:00:00.817 65.184 1.000000000 268620868.000 2008-188T12:53:23.211 65.184 0.999998631 276588129.000 2008-280T18:00:53.314 65.184 0.999999788 281552200.000 2008-338T04:55:23.270 65.184 1.000000029 284040077.000 2009-001T00:00:00.341 65.184 0.000010000 284040078.000 2009-001T00:00:00.342 66.184 1.000000029 287261113.000 2009-038T06:43:55.535 66.184 1.000000131 291848718.000 2009-091T09:04:01.136 66.184 1.000000166 CCSD3RE00000$$data$$CCSD3RE00000$$sclk$$ While this is not a real SCLKSCET file, it illustrates a number of ``features'' commonly seen in real SCLKSCET files, specifically: -- the first record (SCLK 0.000) indicates that the Falcon's clock start epoch is set to the zero epoch of Ephemeris Time (ET), namely 2000-001T11:58:55.816 UTC. A ``round'' or otherwise ``special'' initial epoch is frequently picked as the starting point for on-board clocks for convenience and/or consistency reasons. Note that the clock rate of this first pre-launch record is the nominal, perfect ``1'' meaning one TDT second in one SCLK second. -- the second (SCLK 189345665) and third (SCLK 189345666) records are special records needed to account for the positive leapsecond that occurred on January 1, 2006. Note that while SCLK advances by 1 second from the second record to the third, the SCET advances by just 1 millisecond. Also note that the value of the DUT field is incremented by 1 and that the correlation ``continues'' with the nominal perfect rate (the rate in the third record). Since the SCET difference between these two records is less than 0.002 seconds, MAKCLK ignores the second record when it processes the file. -- the fourth record (SCLK 268620868) is the first actual correlation record added post-launch. Its rate is no longer the perfect 1. If the third record (SCLK 189345666) is extrapolated to the reference time of the fourth record, there will be a discontinuity of about 395 milliseconds. Such ``launch'' discontinuity is commonly seen in real clock correlations because of the difficulty setting the actual spacecraft clock to the desired nominal value. In some cases ``launch'' discontinuities reach multiple seconds in magnitude. -- the fifth (SCLK 276588129) and sixth (SCLK 281552200) records are just regular correlation update records. As a common artifact of time correlation software at their reference epochs they have small discontinuities of about 12 and 8 milliseconds with respect the previous records. -- the seventh (SCLK 284040077) and eighth (SCLK 284040078) records are special records needed to account for the positive leapsecond that occurred on January 1, 2009. Just as with the records for the January 1, 2006 leapsecond, these records have SCLK advancing by 1 second, SCET advancing by 1 millisecond (making MAKCLK ignore the seventh record), and DUT incremented by 1. The reference times for these records are usually computed using the last actual pre-leapsecond record. The rate of the post-leapsecond record (eighth, SCLK 284040078) is simply set to the rate of the last actual pre-leapsecond record (sixth, SCLK 281552200). -- the final two records -- the ninth (SCLK 287261113) and tenth (SCLK 291848718) -- are again regular correlation update records, but for sake of example one of them (ninth, SCLK 287261113) has a larger discontinuity, about 98 milliseconds, with respect to the previous trend. Such larger discontinuities are sometimes seen when a special event -- a safe mode or a planned flight computer reboot -- ``delays'' the on-board clock. The discontinuity at the tenth record is small, about 4 milliseconds. Note that the fractional part in SCLK times in the example is set to zero. This is not a requirement but a common practice that allows for greater flexibility in interpreting what that fraction means without introducing an error due to misinterpretation. For example, no matter whether the zero fractional part is treated as a decimal fraction, a count of ticks of 1/256 of a second in duration, or a count of ticks of 1/65536 of a second in duration, since it's at the integer second boundary the result will be the same. This wouldn't be true if the value of the fractional part was, for example, ``128''. Please note that all CCSDS separator lines and SFDU header lines must start in the first column (left-justified). The complete SCLKSCET example file provided above, flc_sclkscet.00007 is indented by 6 spaces, which must be removed before it can be used in a MAKCLK run exercise. Sample MAKCLK Execution -------------------------------------------------------- This section shows a sample MAKCLK run. The program is run to convert the Falcon SCLKSCET file described above to an SCLK kernel for a clock with attributes defined by the following SCLK ``template'' file, flc_template.tsc: KPL/SCLK \begindata SCLK_KERNEL_ID = ( @2009-04-07/12:00 ) SCLK_DATA_TYPE_77 = ( 1 ) SCLK01_TIME_SYSTEM_77 = ( 2 ) SCLK01_N_FIELDS_77 = ( 2 ) SCLK01_MODULI_77 = ( 4294967296 256 ) SCLK01_OFFSETS_77 = ( 0 0 ) SCLK01_OUTPUT_DELIM_77 = ( 1 ) SCLK_PARTITION_START_77 = ( 0.0000000000000E+00 ) SCLK_PARTITION_END_77 = ( 1.0995116277750E+12 ) SCLK01_COEFFICIENTS_77 = ( 0.0000000000000E+00 0.0000000000000E+00 1.0000000000000E+00 ) \begintext This template defines a type 1 clock (DATA_TYPE=1) with two fields (N_FIELDS=2) -- integer seconds and fractional seconds given as ticks of 1/256 of a second (MODULI=4294967296,256) -- with the correlation function relative to TDT (TIME_SYSTEM=2), as required by MAKCLK because the rates in the SCLKSCET files relate TDT to SCLK. (For more information about SCLK file format and contents refer to the SCLK Required Reading document, sclk.req.) The setup file, flc_sclkscet.00007.setup, used in this run has the following contents: SCLKSCET_FILE = flc_sclkscet.00007 OLD_SCLK_KERNEL = flc_template.tsc FILE_NAME = flc_sclkscet.00007.tsc NAIF_SPACECRAFT_ID = -77 LEAPSECONDS_FILE = naif0009.tls PARTITION_TOLERANCE = 10 LOG_FILE = flc_sclkscet.00007.log The input SCLKSCET and SCLK ``template'' keywords point to the files shown above -- flc_sclkscet.00007 and flc_template.tsc. The output SCLK kernel file and log file keywords point to flc_sclkscet.00007.tsc and flc_sclkscet.00007.log; neither of these two files can exist before the run. The LSK file keyword points to the latest LSK at the time of this run -- naif0009.tls. The spacecraft ID is set to -77, the ID that is used in the keywords in the SCLK template file. The partition tolerance is set to 10 SCLK ticks (= 10 * 1/256 second = 0.039 seconds) to make the output SCLK kernel have a new partition at each record boundary where the discontinuity is greater than 10 ticks. Neither of the two optional keywords -- IGNORE_RECORDS_BEFORE and PRESERVE_RATES -- is used, telling the program to process all records from the input SCLKSCET file and to adjust input rates to force continuity at the record boundaries. The program is run either by typing its name on the command line and providing the name of the setup file in response to the interactive prompt: % makclk ..... Enter the name of the command file > flc_sclkscet.00007.setup flc_sclkscet.00007.tsc created. % or non-interactively, by ``echo''ing the setup file name into the program's standard input, like this: % echo flc_sclkscet.00007.setup | makclk ... flc_sclkscet.00007.tsc created. % This run created two files -- the output SCLK file, flc_sclkscet.00007.tsc, and the log file, flc_sclkscet.00007.log. The log file has the following contents (slightly modified to fit the width of the page), listing times and magnitudes of discontinuities that triggered introduction of new partitions: This is a log file produced by the NAIF utility program MAKCLK. Listed below are all the clock discontinuities that MAKCLK encountered while converting the SCLKSCET file flc_sclkscet.00007 into the SPICE SCLK kernel file flc_sclkscet.00007.tsc This log file was generated only to show that the SCLKSCET to SCLK conversion went as intended. It should not be distributed with the SCLK kernel and is not meant to be processed by any SPICELIB software. SCET0 time Giv. SCLK time Exp. SCLK time Abs. Diff --------------------- -------------- -------------- -------------- 2008-188T12:53:23.211 0268620868.000 0268620868.101 0000000000.101 2009-038T06:43:55.535 0287261113.000 0287261113.025 0000000000.025 As seen in the log the program found two discontinuities larger than 10 ticks (39 milliseconds) -- 101 ticks (~395 milliseconds) at the ``launch'' record (SCET 2008-188) and 25 ticks (~98 milliseconds) at the first actual record in 2009 (SCET 2009-038). The output SCLK kernel, flc_sclkscet.00007.tsc, has the following contents (slightly modified to fit the width of the page): KPL/SCLK This file is a SPICE spacecraft clock (SCLK) kernel. This file was generated by the NAIF MOSPICE utility program MAKCLK, version 4.0.0, 11-MAR-2009. Please refer to the SCLK Required Reading file, NAIF document number 222, and the MAKCLK User's Guide, NAIF document number 267, for information regarding this kernel file. \begindata SCLK_KERNEL_ID = ( @2009-04-07/11:45:12.00 ) SCLK_DATA_TYPE_77 = ( 1 ) SCLK01_TIME_SYSTEM_77 = ( 2 ) SCLK01_N_FIELDS_77 = ( 2 ) SCLK01_MODULI_77 = ( 4294967296 256 ) SCLK01_OFFSETS_77 = ( 0 0 ) SCLK01_OUTPUT_DELIM_77 = ( 1 ) SCLK_PARTITION_START_77 = ( 0.0000000000000E+00 6.8766942208000E+10 7.3538844928000E+10 ) SCLK_PARTITION_END_77 = ( 6.8766942309000E+10 7.3538844953000E+10 1.0995116277750E+12 ) SCLK01_COEFFICIENTS_77 = ( 0.0000000000000E+00 -3.5763036976733E-10 1.0000000000053E+00 4.8472490496000E+10 1.8934566600100E+08 9.9999999999330E-01 6.8766942309000E+10 2.6862086839500E+08 9.9999863227777E-01 7.0806561125000E+10 2.7658811849800E+08 9.9999978968874E-01 7.2077363301000E+10 2.8155218845400E+08 1.0000000289403E+00 7.2714260069000E+10 2.8404006652600E+08 1.0000000296004E+00 7.3538845054000E+10 2.8726110171900E+08 1.0000001318771E+00 7.4713271934000E+10 2.9184870732400E+08 1.0000001660000E+00 ) \begintext As seen above, the output SCLK kernel defines the clock with the same attributes as those from the SCLK ``template'' file (keywords DATA_TYPE to OUTPUT_DELIM), with three partitions (an initial one plus two for the two discontinuities found by MAKCLK), and with the correlation function including eight segments (since two pre-leapsecond records with SCET deltas less than 0.002 seconds were ignored by the program). Note none of the rates in the correlation records except for the very last one match those in the input SCLKSCET file because the program adjusted the input rates to force continuity at the record boundaries. Partitions or No Partitions -------------------------------------------------------- As seen in the example in the previous section, picking the ``right'' value for the PARTITION_TOLERANCE keyword is very important because it determines the number of partitions that the output SCLK kernel will have. Picking a PARTITION_TOLERANCE value that is too tight will result in introducing partitions for very small discontinuities that were simply an artifact of an imperfect time correlation solution. For example, for PARTITION_TOLERANCE = 0 the run from the example above will create an SCLK kernel with six partitions (initial partition, one partition for each actual correlation record except the last, and none for leapsecond records): ... SCLK_PARTITION_START_77 = ( 0.0000000000000E+00 6.8766942208000E+10 7.0806561024000E+10 7.2077363200000E+10 7.3538844928000E+10 7.4713271808000E+10 ) SCLK_PARTITION_END_77 = ( 6.8766942309000E+10 7.0806561027000E+10 7.2077363202000E+10 7.3538844953000E+10 7.4713271809000E+10 1.0995116277750E+12 ) ... and the following list of discontinuities in the log file: ... SCET0 time Giv. SCLK time Exp. SCLK time Abs. Diff --------------------- -------------- -------------- -------------- 2008-188T12:53:23.211 0268620868.000 0268620868.101 0000000000.101 2008-280T18:00:53.314 0276588129.000 0276588129.003 0000000000.003 2008-338T04:55:23.270 0281552200.000 0281552200.002 0000000000.002 2009-038T06:43:55.535 0287261113.000 0287261113.025 0000000000.025 2009-091T09:04:01.140 0291848718.000 0291848718.001 0000000000.001 On the other hand, picking a PARTITION_TOLERANCE value that is too large will result in not introducing partitions for larger discontinuities corresponding to actual clock resets or jumps. For example, for PARTITION_TOLERANCE = 2560 which corresponds to 10 minutes, the run from the example above will create an SCLK kernel with a single partition -- the initial partition -- and no partitions for the ``launch'' or ``special'' event discontinuities: ... SCLK_PARTITION_START_77 = ( 0.0000000000000E+00 ) SCLK_PARTITION_END_77 = ( 1.0995116277750E+12 ) ... and the log file listing no discontinuities: ... SCET0 time Giv. SCLK time Exp. SCLK time Abs. Diff --------------------- -------------- -------------- -------------- Ideally it is desirable to have SCLKs with partitions only the times when a clock reset or jump has happened. Unfortunately the SCLKSCET format provides no way of determining if a discontinuity is due to a clock reset/jump or due to a not-so-perfect correlation solution. Knowing ahead of time how large might be any discontinuities due to imperfect correlation and picking a number a few times bigger than that is a good practical approach. For example if it is known that the clock correlation has to be accurate to 20 millisecond (per project requirements), it is reasonable to assume that the largest non-reset discontinuity will be close to or less than that value. Then, 100 (5 * 20 milliseconds) milliseconds expressed in ticks can be picked for the PARTITION_TOLERANCE value. Adjust Rates or Not Adjust Rates -------------------------------------------------------- As seen in the example in the ``Sample MAKCLK Execution'' section the rates written to the SCLK kernel when PRESERVE_RATES=YES is not specified in the setup file are sightly different from the rates in the input SCLKSCET file. In many cases adjusting the rates to make the function continuous and eliminate small discontinuities resulting from an imperfect correlation solution is desirable and can actually produce a correlation function that better represents reality. In other cases though it is not desirable because full consistency between SCLKSCET and SCLK kernel correlations is sought, or discontinuities are so large than adjusting rates may produce a grossly incorrect correlation, or backward compatibility of the correlation is required. In cases when the original SCLKSCET rates need to be preserved PRESERVE_RATES = YES should be included in the setup file. For example, if PRESERVE_RATES=YES is added to the setup the run from the ``Sample MAKCLK Execution'' example will create an SCLK kernel with the following rates: ... SCLK01_COEFFICIENTS_77 = ( 0.0000000000000E+00 -3.5763036976733E-10 1.0000000000000E+00 4.8472490496000E+10 1.8934566600100E+08 1.0000000000000E+00 6.8766942309000E+10 2.6862086839500E+08 9.9999863100000E-01 7.0806561125000E+10 2.7658811849800E+08 9.9999978800000E-01 7.2077363301000E+10 2.8155218845400E+08 1.0000000290000E+00 7.2714260069000E+10 2.8404006652600E+08 1.0000000290000E+00 7.3538845054000E+10 2.8726110171900E+08 1.0000001310000E+00 7.4713271934000E+10 2.9184870732400E+08 1.0000001660000E+00 ) ... which match exactly the rates from the input SCLKSCET file: ... *____SCLK0_____ ________SCET0________ _DUT__ __SCLKRATE__ 0.000 2000-001T11:58:55.816 64.184 1.000000000 189345665.000 2006-001T00:00:00.816 64.184 0.000010000 189345666.000 2006-001T00:00:00.817 65.184 1.000000000 268620868.000 2008-188T12:53:23.211 65.184 0.999998631 276588129.000 2008-280T18:00:53.314 65.184 0.999999788 281552200.000 2008-338T04:55:23.270 65.184 1.000000029 284040077.000 2009-001T00:00:00.341 65.184 0.001000000 284040078.000 2009-001T00:00:00.342 66.184 1.000000029 287261113.000 2009-038T06:43:55.535 66.184 1.000000131 291848718.000 2009-091T09:04:01.140 66.184 1.000000166 Tricks of the Trade -------------------------------------------------------- This section provides some ``off the wall'' advise to the program users. Using ``0'' PARTITION_TOLERANCE to See Discontinuity Magnitudes Often one needs to find out the magnitudes of discontinuities at the record boundaries in a given SCLKSCET file. A way to do this is to run MAKCLK to convert the file to an SCLK kernel while specifying PARTITION_TOLERANCE = 0 in the setup and then examine the output log file to see discontinuity times and magnitudes, as shown in the ``Partitions or No Partitions'' section. Using Large PARTITION_TOLERANCE to Re-compute Rates MAKCLK's ability to adjust rates to make the correlation function continuous may be put to an interesting use -- to determine rates from given reference time pairs. If a SCLKSCET file containing actual SCLK/SCET pairs but nominal rates is given to the program and a very large PARTITION_TOLERANCE is specified in the setup file, the program will create an SCLK file with adjusted rates that will ``connect'' the reference time points. Literature References -------------------------------------------------------- 1. ``SFOC Software Interface Specification: SFOC-1-DPS-Any-SCLKvSCET'', June 4, 1993. 2. ``SCLK Required Reading'' (sclk.req). 3. ``Time Required Reading'' (time.req).