Exclusionary syntax
- Last Updated: June 9, 2021
- 2 minute read
- Corticon.js
- Documentation
The following examples are logically equivalent:
Notice that the last example uses the unary function not, described in more detail in the Rule
Language Guide, to negate the value 747 selected
from the values set.
Once again, you can see that the same rule can be expressed in different
ways on the Rulesheet, with identical results. The rule modeler decides which way of
expressing the rule is preferable in a given situation. Progress recommends, however,
avoiding double negatives. Most people find it easier to understand attribute=T instead of attribute<>F,
even though logically the two expressions are equivalent.
Note: This discussion of Boolean logic assumes
bi-value logic. If tri-value logic is assumed (such as, for a non-mandatory attribute),
meaning the null value is available in addition to true and false, then these two
expressions are not equivalent. If attribute = null, then the truth value of
attribute<>F is true while that of attribute=T is false.