Index Page
cspice_wncard
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_WNCARD returns the cardinality (current number of intervals) 
   of a double precision window.

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

I/O

   
   Given:

       window   a scalar double precision window containing zero or more 
                intervals. 'window' must be created as a window structure
                via a cspice_celld call. 

   the call:

      card = cspice_wncard( window )
   
   returns:

      card   a scalar integer describing the cardinality
             (current number of intervals) of the input 'window'

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.

   The window cardinality function cspice_wncard is typically used to
   process each of the intervals of a window.

      ;; 
      ;; Create a cell containing a double
      ;; precision 8-vector.
      ;;
      win1 = cspice_celld( 8 )

      ;;
      ;; Define a window with three intervals (six values).
      ;;
      darray = [ [ 1.d, 3.0], [ 7.0, 11.0], [23.0, 27.0] ]

      ;;
      ;; Insert the window data to the cell.
      ;;
      for i=0, 2 do begin

         cspice_wninsd, darray[0,i], darray[1,i], win1

      endfor

      ;;
      ;; What's the window cardinality of 'win1'?
      ;;
      cardinality = cspice_wncard(win1)

      ;;
      ;; Print the window cardinality (this out to show "3" ).
      ;;
      print, 'Number of intervals in the window: ', cardinality

   IDL outputs:

      Number of intervals in the window:            3

Particulars


   This function returns the value of cspice_card(window)/2.
   

Required Reading


   ICY.REQ
   CELLS.REQ

Version


   -Icy Version 1.0.1, 23-SEP-2008, EDW (JPL)

      Eliminated error in English.
      Corrected typo in 'window' I/O description.

   -Icy Version 1.0.0, 03-DEC-2007, EDW (JPL)

Index_Entries

 
   cardinality of a d.p. window
 



Wed Apr  5 17:58:04 2017