home Forums # Technical Support Confused on how to use "not"

Viewing 2 posts - 1 through 2 (of 2 total)
• Author
Posts
• #2687
Anonymous
Inactive

So I’m a bit confused on how to use “not”.
If I had a InputVariable AAA that had a low, medium, high. And I want to write AAA != high. How do I do that?

Does “AAA is not high” work?
Or I’m supposed to write “AAA is low or AAA is medium”?

I did some tests and the results are different. I’m feeling that the latter is the proper way.

How about some other use of NOT for what should be simple logic?
I want to do “!(AAA = high or BBB = high or CCC = high)”. Which turns into “AAA != high and BBB != high and CCC != high” which would mean “(AAA = low or AAA = medium) and (BBB = low or BBB = medium) and (CCC = low or CCC = medium)”

From testing, these 3 should mean the same thing in terms of logic expressions, but they all give different results!
if not(AAA is high or BBB is high or CCC is high)
if AAA is not high and BBB is not high and CCC is not high
if (AAA is low or AAA is medium) and (BBB is low or BBB is medium) and (CCC is low or CCC is medium)

Again I think the final longest way is the one that fits my intention?

#2708

Hi,

thank you for your interesting post and questions.

The last one is what you want. The negation made by the `not` operator results in `1-x`, where `x` is the membership function value that indicates how much of that proposition is passed onto the consequent. With this in mind, the results you get are different for each of the cases, as you mentioned. Specifically, look at how the propositions get translated:

`1 - (a1 + b1 + c1) = if not(AAA is high or BBB is high or CCC is high)`
`(1-a1) * (1-b1) * (1-c1) = if AAA is not high and BBB is not high and CCC is not high`
`(a2+a3) * (b2+b3) * (c2+c3) = if (AAA is low or AAA is medium) and (BBB is low or BBB is medium) and (CCC is low or CCC is medium)`

where + refers to the S-Norm used for disjunction, and * refers to the T-Norm used for conjunction.

Cheers.

Viewing 2 posts - 1 through 2 (of 2 total)
• You must be logged in to reply to this topic.