Would ~(< 1 >)[1] return (infinity-1) or 0? And ~(< 1,1 >)[1] (infinity-2)?
It would probably be more useful to view multisets as sets when negating them. I think. That is, (~(< 1 >))[1] is 0.
/ Per Hedbor ()
Previous text:
2003-02-06 14:00: Subject: Xor
As said before, an ordinary multiset can be viewed as a mapping that assigns a non-negative integer to each object, and which assigns the value zero to all but a finite number of objects (i.e. zero is the default value).
An inverted multiset can be viewed as a mapping that assigns a non-negative number, or the special value +infinity, and with +infinity as the default value. I.e. there are only a finite number of objects with a value less than +infinity. Note that *both* zero and +infinity can occur, so one can't just change the meaning of zero.
/ Niels Möller ()