Unary Operators in Istar
Page under construction.
Unary operators are applied to inference
relationships to modify the effect of the antecedent attribute before using it in the
inference. At present they only apply to inference relationships.
Normally a relationship starts off with no unary operator, except as
required by the inference method. For
instance, the Bayesian inference method requires that its links hold
bayesian weights, so in this case the indicated unary operator is
overridden.
The effect of most unary operators is given below, but there are two
exceptions that override those.
The highest priority is given to the CONTROL unary operator. If one of
these is found, and the antecedent is such that it can be converted into a
truth value (i.e. of types Boolean, Probability, Proportion, Bayesian,
Odds) then it might set the value of the consequent regardless of the other
antecedents; see below. If it is not one of these
types then the CONTROL is ignored.
The next highest priority is when the inference method of the consequent is
Bayesian Accumulation of evidence. Then the operation is different. See
below.
Otherwise, the operations are as follows:
No change (except when bayesian inference method.
Except when bayesian inference method:
- Integer, OZMO, Float: Takes negative of antecedent.
- Boolean: Takes boolean opposite.
- Probability: Takes probabilistic opposite (1 - p).
- Direction: Changes direction by 180 degrees.
- Otherwise: No change.
Except when bayesian inference method:
- Odds, Ratio: Exchanges numerator with denominator.
- Boolean: Takes boolean opposite.
- Probability: Takes probabilistic opposite (1 - p).
- Otherwise: No change.
Except when bayesian inference method:
- Integer, OZMO, Float: Takes absolute value of antecedent.
- Otherwise: No change.
Except when bayesian inference method:
- Integer, Float: Multiplies value by weight.
- Otherwise: No change. But in future e.g. Ratio might be affected.
Except when bayesian inference method:
- Integer, Float: Divides value by weight.
- Otherwise: No change.
Except when bayesian inference method:
- Integer, Float: Adds numeric value of weight.
- Otherwise: No change. But in future e.g. Ratio might be affected.
Except when bayesian inference method:
- Integer, Float: Subtracts numeric value of weight.
- Otherwise: No change. But in future e.g. Ratio might be affected.
Except when bayesian inference method:
- Probability, Proportion, Bayesian: Multiply the probability of the
antecedent by the weight taken as a probability.
- Boolean: Convert to Probability type and treat as above, giving the
value 0 if False and giving the weight value (taken as a Probability) if
True.
- Otherwise: No change.
Except when bayesian inference method:
- Probability, Proportion, Bayesian: Combine antecedent probability
value with that of weight as a probabilistic OR (p + q - pq).
- Boolean: Convert to Probability type and treat as above, giving the
value Unity if True and giving the weight value (taken as a Probability) if
False.
- Otherwise: No change.
Except when bayesian inference method:
- Integer only: Bitwise AND with weight bits.
- Otherwise: No change.
Except when bayesian inference method:
- Integer only: Bitwise OR with weight bits.
- Otherwise: No change.
Except when bayesian inference method:
- Integer only: Bitwise XOR with weight bits.
- Otherwise: No change.
Except when bayesian inference method:
- Integer: Randomly give a value that is between the antecedent value
and zero.
- Enumerated type, Ordinal: If the antecedent has an Ordinal Limit (as
most will, but a few from old KBs will not) then select a value from 1 to
the limit at random.
- Otherwise: No change.
If the antecedent is of the appropriate type, one that can be converted to
a truth value, then this unary operator takes precedence over all others.
It is normally when one attribute is made irrelevant by another (such as
"Are you ill?" would make "What illness do you have?" irrelevant if
answered with 'No'). It acts to control whether the consequent is relevant
or not, by taking the truth value of the antecedent and:
- If True, then the consequent attribute is deemed relevant, and its
inference proceeds as dictated by the inference method and the other
antecedents.
- If False, then the consequent attribute is deemed irrelevant, and it is
given an answered value found in the weight of this Control relationship.
When the inference method is Bayesian Accumulation of Evidence, then
special action is taken which overrides the above. The unary operator on
the relationship is replaced by one of these: INVWEIGHT being used if the
unary operator is NEGATE or INVERT, and the WEIGHT being used otherwise.
With these two unary operators:
- If the antecedent is of type Bayesian, Probability, Boolean, then it is
converted to Odds, using the weights found in the link, and the result is
used as an Odds multiplier for the consequent. If the unary operator is
(ie. has become) INVWEIGHT, then the weights are reversed before being
applied to generate the Odds.
- If the antecedent is Odds, then it is used directly as an Odds
multiplier for the consequent (and so INVWEIGHT and WEIGHT have the same
effect).
Copyright (c) Andrew
Basden 1998.