# NOT: Bitwise Logical Compliment

### The NOT function is used to toggle the specified bits of its argument.

• used to of argument:
• result = NOT( argument )
• argument is converted to the nearest integer NINT(argument)
• precision is a normalized 53-bit fraction of the 8-byte IEEE T_floating format
• result = NOT( 4 ) ! result is -6:
• 5 == 0000000000000000000000000000000000000000000000000000000000000101
• -6 == 1111111111111111111111111111111111111111111111111111111111111010
• to set bit n :
• result = IOR(argument, 2^n) ! with n = 0 ... 53
• bits0and2 = IOR(2^0, 2^2) ! is set to 1 + 4 = 5
• to test bit n :
• result = IAND(argument, 2^n) /= 0 ! with n = 0 ... 53
• bit3set = IAND( bits0and2, 2^3) ! evaluates to 0
• to clear bit n :
• result = IAND(argument, NOT(2^n)) ! with n = 0 ... 53
• clearbit0 = IAND( bits0and2, NOT(2^0) ) ! evaluates to 4
• to bitwise either-or x and y:
• result = IEOR( x, y )
the bit-by-bit result-bit is 1 if x-bit and y-bit differ, and is 0 if x-bit and y-bit are equal:
• result = IEOR( 3, 10 ) ! result is 9

Support HicEst   ⇾ Impressum