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

Table of contents
Abstract
I/O
Parameters
Examples
Particulars
Exceptions
Files
Restrictions
Required_Reading
Literature_References
Author_and_Institution
Version
Index_Entries


Abstract


   CSPICE_PL2NVP returns a unit normal vector and point that define a
   specified plane.

I/O


   Given:

      plane    a SPICE plane.

               help, plane
                  STRUCT = CSPICE_PLANE

               The structure has the fields:

                  normal:   [3-array double]
                  constant: [scalar double]

   the call:

      cspice_pl2nvp, plane, normal, point

   returns:

      normal,
      point    respectively, a unit normal vector and point that define the
               geometric plane represented by `plane'.

               help, normal
                  DOUBLE = Array[3]
               help, point
                  DOUBLE = Array[3]

               Let the symbol < a, b > indicate the inner product of vectors
               `a' and `b'; then the geometric plane is the set of vectors
               `x' in three-dimensional space that satisfy

                  < x - point, normal >  =  0.

               `point' is always the closest point in the input
               plane to the origin. `point' is always a
               non-negative scalar multiple of `normal'.

Parameters


   None.

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.

   1) A trivial example of plane creation and  decomposition. Create a
      plane via the definition point in the plane. Convert the plane to
      a normal vector, point representation.

      Example code begins here.


      PRO pl2nvp_ex1

         ;;
         ;; Create a plane via the definition
         ;; of a plane normal and constant, determine a
         ;; point in the plane.
         ;;
         plane_norm = [ 2.44d, -5.d/3.d, 11.d/9.d ]
         const      = 3.141592654d

         ;;
         ;; Construct the SPICE plane.
         ;;
         cspice_nvc2pl, plane_norm, const, plane
         print, 'Input plane:'
         print, FORMAT='("  Normal vector   :", 3F16.11)', $
                                             plane.normal
         print, FORMAT='("  Constant        :", F16.11)',  $
                                             plane.constant

         ;;
         ;; Convert the plane to a normal vector, point
         ;; representation, 'point' lies in the plane.
         ;;
         cspice_pl2nvp, plane, norm_vec, point
         print, FORMAT='("Unit normal vector:", 3F16.11)', norm_vec
         print, FORMAT='("Point             :", 3F16.11)', point

      END


      When this program was executed on a Mac/Intel/IDL8.x/64-bit
      platform, the output was:


      Input plane:
        Normal vector   :   0.76305143916  -0.52120999942   0.38222066624
        Constant        :   0.98245770323
      Unit normal vector:   0.76305143916  -0.52120999942   0.38222066624
      Point             :   0.74966576436  -0.51206677893   0.37551563788


Particulars


   Icy geometry routines that deal with planes use the `plane'
   data type to represent input and output planes. This data type
   makes the routine interfaces simpler and more uniform.

   The Icy routines that produce SPICE planes from data that
   define a plane are:

      cspice_nvc2pl ( Normal vector and constant to plane )
      cspice_nvp2pl ( Normal vector and point to plane    )
      cspice_psv2pl ( Point and spanning vectors to plane )

   The Icy routines that convert SPICE planes to data that
   define a plane are:

      cspice_pl2nvc ( Plane to normal vector and constant )
      cspice_pl2nvp ( Plane to normal vector and point    )
      cspice_pl2psv ( Plane to point and spanning vectors )

Exceptions


   1)  The input plane MUST have been created by one of the Icy
       routines

          cspice_nvc2pl ( Normal vector and constant to plane )
          cspice_nvp2pl ( Normal vector and point to plane    )
          cspice_psv2pl ( Point and spanning vectors to plane )

       Otherwise, the results of this routine are unpredictable.

   2)  If the input argument `plane' is undefined, an error is
       signaled by the IDL error handling system.

   3)  If the input argument `plane' is not of the expected type, or
       it does not have the expected dimensions and size, an error is
       signaled by the Icy interface.

   4)  If any of the output arguments, `normal' or `point', is not a
       named variable, an error is signaled by the Icy interface.

Files


   None.

Restrictions


   None.

Required_Reading


   ICY.REQ
   PLANES.REQ

Literature_References


   [1]  G. Thomas and R. Finney, "Calculus and Analytic Geometry,"
        7th Edition, Addison Wesley, 1988.

Author_and_Institution


   J. Diaz del Rio     (ODC Space)
   E.D. Wright         (JPL)

Version


   -Icy Version 1.0.2, 13-AUG-2021 (JDR)

       Edited the header to comply with NAIF standard. Added example's
       problem statement and reformatted example's output.

       Added -Parameters, -Exceptions, -Files, -Restrictions,
       -Literature_References and -Author_and_Institution sections.

       Removed reference to the routine's corresponding CSPICE header from
       -Abstract section.

       Added arguments' type and size information in the -I/O section.

   -Icy Version 1.0.1, 16-AUG-2010 (EDW)

       Expanded and improved -I/O and -Particulars sections.

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

Index_Entries


   plane to normal vector and point



Fri Dec 31 18:43:06 2021