Index Page
A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W  X 

Required Reading


   CSPICE_SPKGPS computes the geometric position 3-vector 
   of a target body relative to an observing body. 

   For important details concerning this module's function, please refer to
   the CSPICE routine spkgps_c.


      targ    the NAIF integer ID of the target body (the
              observed body)
      et      the double precision ephemeris time (ET) epoch
              for the observation of interest

      ref     the string name of the reference frame in
              which to output the state 6-vector.

      obs     the NAIF integer ID of the observer (the
              observing body) 
   the call:
      cspice_spkgps, targ, et, `ref', obs, pos, ltime
      pos     a double precision 3-vector containing the 
              position of 'targ' with respect to 'obs' 
              as seen in the 'ref'

      ltime   a double precision scalar describing the
              one-way light time between 'targ' and 'obs'
              Please note, CSPICE documentation and source code 
              uniformly uses the variable name 'lt' to designate
              the light-time between an observer and target. IDL 
              uses "lt" as the less-than numeric comparison 
              operator and so does not allow "lt" as a variable name. 
              Therefore, Icy documentation uses the name 'ltime' 
              for the light-time value. 
   Note: The position vector returned by cspice_spkgps represents the
   geometric position of the target from the observer. The routine
   applies no corrections to account for stellar aberration or the
   finite speed of light.


   Any numerical results shown for this example may differ between
   platforms as the results depend on the SPICE kernels used as input
   and the machine specific arithmetic implementation.

      ;; Load a set of kernels: an SPK file, a PCK
      ;; file and a leapseconds file. Use a meta
      ;; kernel for convenience.
      cspice_furnsh, ''
      ;; Define parameters for a position lookup:
      ;; Return the position vector of Mars (499) as seen from
      ;; Earth (399) in the J2000 frame
      ;; using aberration correction LT+S (light time plus
      ;; stellar aberration) at the epoch 
      ;; July 4, 2003 11:00 AM PST.
      target   = 499
      epoch    = 'July 4, 2003 11:00 AM PST'
      frame    = 'J2000'
      observer = 399
      ;; Convert the epoch to ephemeris time.
      cspice_str2et, epoch, et
      ;; Look-up the state for the defined parameters.
      cspice_spkgps, target, et, frame, observer, $
                     pos, ltime
      ;; Output...
      print, 'The position of    : ', target
      print, 'As observed from   : ', observer
      print, 'In reference frame : ', frame
      print, 'At epoch           : ', epoch
      print, 'R (kilometers)     : ', pos
      print, 'Light time (secs) between observer and target: ', ltime
   IDL outputs:
      The position of    :      499
      As observed from   :      399
      In reference frame : J2000 
      At epoch           : July 4, 2003 11:00 AM PST
      R (kilometers)     :   73826216.  -27128031.  -18741974.
      Light time (secs) between observer and target:  269.70265



Required Reading



   -Icy Version 1.0.0, 16-JUN-2003, EDW (JPL)


   geometric position of one body relative to another 

Wed Apr  5 17:58:03 2017