EXPORT







Syntax




   EXPORT[export] @name[schedule] (0:1){ TO @word[as] }


Description




The EXPORT command writes (stores) the contents of a schedule in a disk file. Schedules that require considerable resources to develop (for instance, the occultations of a particular satellite during the course of a year) may be saved in files, and restored (with the IMPORT command) for use during later sessions.



Optional arguments



You may specify both the name of the schedule to be stored and the name of the file to be written:

   EXPORT jmax TO jupiter_max_diam.sch;
However, you may omit the name of the file, in which case one will be constructed by appending `.sch' onto the name of the schedule:

   EXPORT jmax;
Thus, the command shown above stores schedule JMAX as file jmax.sch in the current working directory.

The type specification `.sch' is added to the name of each schedule selected from the menu. For example, selecting the schedules shown above is equivalent to entering the following commands:

   export europa_and_io         to europa_and_io.sch
   export europa_clear          to europa_clear.sch
   export europa_not_eclipsed   to europa_not_eclipsed.sch


Schedule files



The EXPORT command uses a simple format to store the contents of a schedule. The following is an example of a file created by the EXPORT command.

 
   '1984 SEP 23 00:00:00'   '1984 SEP 23 00:36:15'   2175.0
   '1984 SEP 24 16:55:53'   '1984 SEP 24 19:05:04'   7751.0
   '1984 SEP 26 11:25:17'   '1984 SEP 26 13:33:58'   7721.0
   '1984 SEP 28 05:53:31'   '1984 SEP 28 08:02:36'   7745.0
   '1984 SEP 30 00:21:44'   '1984 SEP 30 02:31:35'   7791.0
   '1984 OCT 01 18:51:03'   '1984 OCT 01 21:00:23'   7760.0
   '1984 OCT 03 13:19:21'   '1984 OCT 03 15:28:52'   7771.0
The endpoints of each interval are stored in calendar format, UTC. Endpoints are delimited by apostrophes. The right endpoint of each interval is followed by the length of each interval in seconds. Intervals are listed one interval per line, as shown above.

Schedules written with the EXPORT command may be read with the IMPORT command.



Examples




In the following example, schedules containing mutual satellite events are stored as soon as the schedules are created. Immediately storing schedules that require significant resources to compute is a good habit to get into, since a system crash or the detection of an error during a batch run will cause any schedules not already stored to be lost.

   INQUIRE YEAR;
   INQUIRE SAT;
   INQUIRE PLN;
   INQUIRE STEPSIZE;
   DEFINE  DROP FORGET SCHEDULE;
 
   SET BOUNDS FROM 1 JAN YEAR TO 31 DEC YEAR;
 
   FIND  OCC OCCULTATION OF SAT BY PLN FROM EARTH
   STEP SIZE STEPSIZE;
 
   EXPORT OCC TO occultations.sch;
 
   FIND  ECL ECLIPSE OF SAT BY PLN FROM EARTH
   STEP SIZE STEPSIZE;
   EXPORT ECL TO eclipses.sch;
 
   FIND  TRN TRANSIT OF SAT ACROSS PLN FROM EARTH
   STEP SIZE STEPSIZE;
 
   EXPORT TRN TO transits.sch;
 
   LET SAT_OBSCURRED = OCC + ECL
   LET SAT_OBSCURRED = TRN + SAT_OBSCURRED
 
   EXPORT SAT_OBSCURED;
 
   DROP OCC;
   DROP ECL;
   DROP TRN;
   DROP SAT_OBSCURED;
The procedure shown above causes the following files to be created in the current default directory:

   occultations.sch
   eclipses.sch
   transits.sch
   sat_obscured.sch


Related Topics




  1. Import
  2. About Schedules
  3. The Percy Help System