public interface SignedSet
plus() and negative minus() components,
both of which are UnsignedSets.
A signed set can be seen as a partial map from the universe of elements
to a sign { −, + }, see sign(Label).
These are a key concept in the Oriented Matroid literature.
These are immutable.Bibliography.björnerEtAl1999| Modifier and Type | Method and Description |
|---|---|
SignedSet |
compose(SignedSet b)
Signed set composition.
|
boolean |
conformsWith(SignedSet x)
Does this conform with
x?
i.e. |
boolean |
equalsIgnoreSign(SignedSet s)
Either s is equal to this, or to the opposite of this.
|
boolean |
equalsOpposite(SignedSet s)
This is a short hand for
s.equals(opposite()). |
boolean |
isRestrictionOf(SignedSet x)
Is this a restriction of
x?
i.e. |
UnsignedSet |
minus()
The negative component.
|
SignedSet |
opposite()
Swaps the positive and negative components
|
UnsignedSet |
plus()
The positive component.
|
SignedSet |
restriction(UnsignedSet x)
The restriction of this to
x. |
UnsignedSet |
separation(SignedSet b)
The set of elements that have different sign in this and b.
|
int |
sign(Label e)
Returns 1, -1 or 0 depending on whether e is in the positive,
the negative or neither component respectively.
|
int |
size()
The number of elements which have a sign in this signed set.
|
UnsignedSet |
support()
The union of the positive and negative components.
|
SignedSet opposite()
UnsignedSet plus()
UnsignedSet minus()
boolean equalsIgnoreSign(SignedSet s)
equals(s) || equalsOpposite(s).s - The signed set to compare with.boolean equalsOpposite(SignedSet s)
s.equals(opposite()).s - The signed set to compare withUnsignedSet separation(SignedSet b)
b - The signed set to compare withSignedSet compose(SignedSet b)
bb - The signed set to compose withint size()
boolean conformsWith(SignedSet x)
x?
i.e. is the positive part of this disjoint with the negative part of x,
and the negative part of this disjoint with the positive part of x,x - The signed set to compare with.x.isRestrictionOf(SignedSet)UnsignedSet support()
int sign(Label e)
e - the label to look upboolean isRestrictionOf(SignedSet x)
x?
i.e. is the positive part of this a subset of the positive part of x,
and the negative part of this a subset of the negative part of x,x - The signed set to compare with.conformsWith(SignedSet)SignedSet restriction(UnsignedSet x)
x.
We retain only the positive and negative elements
that are in x.x - The unsigned set to intersect with.x