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

Abstract
I/O
Examples
Particulars
Required Reading
Version
Index_Entries

Abstract


   CSPICE_GDPOOL returns the value of a double precision kernel
   variable (scalar or array) from the kernel pool.

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

I/O


   Given:

      name     the scalar string name of a pool variable associated
               to double precision values.

      start    a scalar integer value for the index indicating the
               first component of the data vector assigned
               to 'name' for return (index 0 for all elements).

      room     the scalar integer specifying the maximum number of components
               that can return for 'name'.

   the call:

      cspice_gdpool, name, start, room, values, found

   returns:

      values   a double precision array of the values copied from
               the kernel pool data assigned to 'name' beginning at
               index 'start'.

      found    a scalar boolean that flags whether 'name' exists in
               the kernel pool and has double precision type.

               'values' has a size of 'room' or less.

Examples


   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 kernel containing the variable assignments:
      ;;
      ;;   CTEST_VAL = ('LARRY', 'MOE', 'CURLY' )
      ;;
      ;;   ITEST_VAL = ( 3141, 186, 282 )
      ;;
      ;;   DTEST_VAL = ( 3.1415, 186. , 282.397 )
      ;;
      cspice_furnsh, 'pool_t.tm'

      ;;
      ;; Retrieve up-to 'ROOM' character entries for
      ;; kernel pool variable named 'DTEST_VAL' to
      ;; the array named 'cvals'. The first index to return,
      ;; 'START', has value 0 (this returns all components).
      ;;
      VAR    = 'DTEST_VAL'
      ROOM   = 25
      START  = 0

      cspice_gdpool, VAR, START, ROOM, values, found

      if (found) then begin

         print, 'Found ' + VAR + ' in the kernel pool'

         for i=0, n_elements(values)-1 do begin
            print, '   Element ' + string(i) + ' of ' + VAR + ': ', values[i]
         endfor

      endif else begin
         print, 'Failed to find  ' + VAR + ' in the kernel pool'
      endelse

      ;;
      ;; Unload the test kernel.
      ;;
      cspice_unload, 'pool_t.tm'

   IDL outputs:

      Found DTEST_VAL in the kernel pool
         Element        0 of DTEST_VAL:        3.1415000
         Element        1 of DTEST_VAL:        186.00000
         Element        2 of DTEST_VAL:        282.39700

Particulars


   None.

Required Reading


   ICY.REQ
   KERNEL.REQ

Version


   -Icy Version 1.0.2, 26-AUG-2016, EDW (JPL), JDR (ODC Space)

      Edit to example code. Typos in kernel names; "pool_t.ker"
      and "pool_t.pro" rather than "pool_t.tm."

   -Icy Version 1.0.1, 03-JAN-2007, EDW (JPL)

      Edit to I/O section for 'room' and 'start' to improve clarity.

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

Index_Entries


   RETURN the d.p. value of a pooled kernel variable
   RETURN the numeric value of a pooled kernel variable




Wed Apr  5 17:58:01 2017