gtorbsim Help File

Generate spacecraft orbit and attitude data for a variety of pointing or survey mode strategies.

Usage: gtorbsim start_MJD stop_MJD Timeline EphemName EphemFunc Resolution Units Initial_Ra Initial_DEC OutPutFile saafile

The Orbit Simulator, gtorbsim, is a spacecraft attitude calculator based on the code already implemented in the general purpose scheduling and planning system TAKO (Timeline Assembler Keyword Oriented) at the Fermi Science Support Center. The simulator inherits many features of TAKO, but it does not have any scheduling capabilities. The main purpose of this simulator is:

  • To calculate spacecraft attitude, that is where the local body frame axes are oriented relative to the sky.
  • To determine when events such as entry/exit in South Atlantic Anomaly (SAA) will take place.

    The above must be accomplished starting with a series of pointing commands. The output of the orbit simulator is a FITS spacecraft data file.

Several Fermi Science tools such as gtobssim, gtltcube, gtlike, etc. require the spacecraft data file as input. You can use the spacecraft data file provided by the SLAC Data Portal, but in many cases you will probably need to generate that file if you want to perform a particular analysis of simulated data.

The first input required by gtorbsim is the observation mode strategy. Fermi has several operational modes, but the spacecraft acquires scientific data only in survey and pointed modes.

Sky survey mode. Sky survey mode is basically zenith pointed throughout the orbit and has two sub modes:

  • With rocking
  • Without rocking

Rocking provides more uniform sky coverage and allows for complete sky coverage within a shorter period of time. Different rocking profiles can be implemented, (square or sinusoid) with a basic 2-orbit period and a 60-degree maximum amplitude (above and below the orbit plane).

Pointed observation mode. In pointed observation mode, the Z-axis of the observatory is commanded to point at a celestial target. An observing sequence is implemented via a series of commanded targets. There are two sub modes for observing any given target:

  • Target tracking

Target tracking mode maintains a commanded celestial target within a 60-degree diameter field of view. The target is allowed to drift at about 1 degree/minute across this field of view during the non-occulted part of the orbit.

  • Target inertial

Target inertial mode maintains the Z-axis on the target to within the 2-degree control capability of the spacecraft. This mode may be interrupted for downlink transmissions of science data. In this mode, Earth avoidance is accomplished via stored commands that keep the field of view on the sky while the target is occulted. Alternatively, an automatic earth avoidance capability may be used.

LAT's large FOV. Even though it is possible to do pointed observations, the large FOV of the LAT provides such extensive data on individual sources that it is difficult to justify any observation modes other than sky survey. For that reason, it is expected that Fermi will operate in sky survey mode ~90% of the time.

Two survey mode options. With the gtorbsim tool you can choose to calculate the attitude in survey or pointed mode. In survey mode, you may chose between two options:

  • In fixed survey mode, the spacecraft does a sky survey with a specified offset with respect to its local zenith for one orbit, and then uses the opposite offset for the next orbit, and so on.

or

  • In profiled survey mode, the spacecraft observes in survey mode according to a specified profile consisting of 17 increasing times and 17 zenith offsets. The 17 increasing times (in seconds) are used to indicate the time that it takes during each cycle to go from a corresponding zenith offset to the next. The 17 angles (in degrees) are the zenith offsets reached at the end of the corresponding time interval. The first and last of these offsets must be identical in order for the profile to be repeated.

Pointed mode. In pointed mode the spacecraft stares at a specified location in the sky identified by an RA and DEC provided by the user.

Calculating the attitude. In order to properly calculate the attitude, the orbit simulator needs to know the spacecraft position in the entire interval of interest. Therefore, it must be capable of either reading in a file that contains the spacecraft ephemeris, or of calculating one on the fly.

Types of ephemeris files. The orbit simulator can handle three different types of ephemeris files:

  • NASA Flight Dynamic Facility (FDF) format, already used for missions such as RXTE.
  • Satellite Tool Kit (STK) format, already in use for SWIFT.

Spacecraft position in celestial coordinates (provided by the user). Initial spacecraft position in celestial coordinates should be provided by the user as an input parameter.

The South Atlantic Anomaly region (SAA):

The instrument high voltage power supplies will be protected when the spacecraft traverses the South Atlantic Anomaly region, which occurs about 15% of the time.

gtorbsim has the capability to handle SAA constraints. The SAA region is appoximated by a polygon, which is specified by the Longitude and Latitude of its vertices. It is passed to the program as an input file where the specification of the polygon is given. In cases where the
file is not available,
a default hard-coded table of longitude and latitude pairs of vertices is used.

Earth limb:

The Earth Limb Tracing maneuvering is an optional feature that can easily be enabled/disabled using the appropriate input parameter in gtorbsim. This maneuvering consists of tracing the Earth Limb if a target is Earth-occulted. Targets are assumed to be occulted if their Earth angle (Angle between target and the Earth's Limb) is smaller, or – at most – equal to 30 degrees.

Once the target is occulted by the Earth, the orbit simulator finds when it is visible again, and where it is coming out from the Earth's Limb. The simulator then finds the angular separation between the in-occult and out-occult position. And finally, the orbit simulator allows the local z-axis to sweep equal angles in equal times during its motion along the Earth's Limb.

Note: Generally, when using TAKO Science timelines, this step is not necessary, since the TAKO avoids scheduling any target during occultation time. However, in special cases, the occultation constraint in TAKO can be intentionally disabled to achieve some observational goal. Consequently, the orbit simulator calculates the occultation times, and then performs the Earth Limb tracing maneuvering. Occultation times are calculated using the same algorithm that TAKO uses.

Examples: gtorbsim

The orbit simulator is designed so that required inputs can be passed either using the existing Fermi Science Tools infrastructure; by answering a prompt or as a list in a command; or by using an input file. For this reason, the very first input of the simulator is the type of input, which can be either "console" or "file".

To be prompted for gtorbsim options, enter (at the command line): >gtorbsim You will be prompted for parameter values.

Be aware that not all parameter are prompted; some of the parameter are "hidden". If you want to change one of the "hidden" parameters, specify the values in the command line, or modify its mode by editing the parameter file.

For example. if you do not want to overwrite the existing output file, enter (at the command line prompt): gtorbsim clobber=no

An example of how to run the tool from the console for 55 days of survey mode operation is given below:

> gtorbsim
  Type of input {file or console}[console]
  Input Type is: console
  start MJD[] 54867
  stop MJD[] 54923
  Timeline Type {TAKO, ASFLOWN or SINGLE}[TAKO] SINGLE
  Timeline SINGLE Command[|SURVEY| +35.0 |]
  Ephemeredis file name[] FERMI_TLE_09033.78481577.tle
  Ephemeredis function name[xyzll_eph] tlederive
  Conversion factor to Km[1]
  Time resolution in minutes[1]
  Initial RA[0]
  Initial DEC[0]
  OutPut File[] FT2_FERMI_TLE_09033.78481577.fits
  SAA file definition[] L_SAA_2008198.03

The same task could be performed from an ini file like this:

  start_MJD = 54867
  stop_MJD = 54923
  TLType = SINGLE
  Timeline = |SURVEY|+35.0|
  EphemFunc = tlederive
  EphemName = FERMI_TLE_09033.78481577.tle
  Units = 1.0
  Resolution = 1
  Initial_RA = 0
  Initial_DEC = 0
  saafunc = saa
  saafile = L_SAA_2008198.03
  OutPutFile = FT2_FERMI_TLE_09033.78481577.fits 

Note: To generate a realistic pointed mode observation, a timeline generated by TAKO is needed. This tool is not provided with the Science Tools. If you need to run a realistic pointed mode observation, please contact the FSSC.


Last updated by: Chuck Patterson 02/16/2011