| wndifd |
|
Table of contents
Procedure
WNDIFD ( Difference two DP windows )
SUBROUTINE WNDIFD ( A, B, C )
Abstract
Place the difference of two double precision windows into
a third window.
Required_Reading
WINDOWS
Keywords
WINDOWS
Declarations
IMPLICIT NONE
INTEGER LBCELL
PARAMETER ( LBCELL = -5 )
DOUBLE PRECISION A ( LBCELL:* )
DOUBLE PRECISION B ( LBCELL:* )
DOUBLE PRECISION C ( LBCELL:* )
Brief_I/O
VARIABLE I/O DESCRIPTION
-------- --- --------------------------------------------------
A,
B I Input windows.
C O Difference of A and B.
Detailed_Input
A,
B are SPICE windows, each of which contains zero or more
intervals.
Detailed_Output
C is the output SPICE window, containing the difference
of A and B --- every point contained in A, but not
contained in B.
C must be distinct from both A and B.
Parameters
None.
Exceptions
1) If the difference of the two windows results in an excess of
elements, the error SPICE(WINDOWEXCESS) is signaled.
2) The cardinality of the input windows must be even. Left
endpoints of stored intervals must be strictly greater than
preceding right endpoints. Right endpoints must be greater
than or equal to corresponding left endpoints. Invalid window
data are not diagnosed by this routine and may lead to
unpredictable results.
Files
None.
Particulars
Mathematically, the difference of two windows contains every
point contained in the first window but not contained in the
second window.
Fortran offers no satisfactory floating point representation
of open intervals. Thus, for floating point windows we must
return the closure of the set theoretical difference: that is,
the difference plus the endpoints of the first window that are
contained in the second window.
Examples
Let A contain the intervals
[ 1, 3 ] [ 7, 11 ] [ 23, 27 ]
and B contain the intervals
[ 2, 4 ] [ 8, 10 ] [ 16, 18 ]
Then the difference of A and B contains the intervals
[ 1, 2 ] [ 7, 8 ] [ 10, 11 ] [ 23, 27 ]
Restrictions
None.
Literature_References
None.
Author_and_Institution
N.J. Bachman (JPL)
J. Diaz del Rio (ODC Space)
H.A. Neilan (JPL)
W.L. Taber (JPL)
I.M. Underwood (JPL)
Version
SPICELIB Version 2.1.0, 24-AUG-2021 (JDR) (NJB)
Added IMPLICIT NONE statement.
Edited the header to comply with NAIF standard. Fixed I/O type
of argument C in $Brief_I/O table.
Added entry #2 in $Exceptions section.
SPICELIB Version 2.0.0, 16-SEP-1998 (WLT)
The previous version did not work when removing
singletons. This has been corrected.
SPICELIB Version 1.0.1, 10-MAR-1992 (WLT)
Comment section for permuted index source lines was added
following the header.
SPICELIB Version 1.0.0, 31-JAN-1990 (WLT) (IMU) (HAN)
|
Fri Dec 31 18:37:07 2021