Thread Links Date Links
Thread Prev Thread Next Thread Index Date Prev Date Next Date Index

cancelMinus and cancelPlus at Level 2: a query



P1788

This is a query especially to the elementary function experts. Recall
    zz = cancelMinus(xx,yy) 
solves the problem "recover zz, given that one knows xx was computed as the sum yy + zz".

Question: is there any point in having a decorated version of it? IMO, No for the following reasons.

The Level 1 definition is
> For any two bounded intervals xx and yy, the value of cancelMinus(xx,yy) is the tightest interval zz such that
>     yy + zz \supseteq xx
> if such a zz exists. Otherwise it has no value at Level 1.

"No value" occurs in these 3 cases:
  xx nonempty and yy empty.
  xx  and yy nonempty bounded, but width(xx) < width(yy).
  Either xx or yy is unbounded.

At Level 2, "no value" is not allowed. The operation must return something, which I chose to be Entire. Reason: Entire can never (assuming an inf-sup interval type) be the genuine value of zz, even if overflow occurs, so it can be used as a diagnostic value.

So the possible Level 2 cases for zz are
  Empty                if xx = Empty
  nonempty bounded     interesting case, no overflow
  nonempty unbounded   interesting case, overflow 
                       e.g. cancelMinus([M,M],[-M,-M]) = [M,oo] where M=REALMAX
  Entire               if no value at Level 1

cancelMinus isn't a normal arithmetic operation so a decorated version can't do anything sensible with its input decorations. So the only use for an output decoration is diagnostic; which Entire does nicely for the bare version already.

John Pryce