next up previous contents index
Next: Comparison Functions Up: Scalar Functions Previous: Scalar Functions

Logical Functions

All the logical functions work on either integers or booleans. In the case of integers, they work bitwise over the bit representation of the integer.

not(a) {a tex2html_wrap_inline9888 a :: (a in logical)}
  Returns the logical inverse of the argument. For integers, this is the ones complement.

a or b {(a, a) tex2html_wrap_inline9890 a :: (a in logical)}
  Returns the inclusive or of the two arguments.

a and b {(a, a) tex2html_wrap_inline9892 a :: (a in logical)}
  Returns the logical and of the two arguments.

a xor b {(a, a) tex2html_wrap_inline9894 a :: (a in logical)}
  Returns the exclusive or of the two arguments.

a nor b {(a, a) tex2html_wrap_inline9896 a :: (a in logical)}
  Returns the inverse of the inclusive or of the two arguments.

a nand b {(a, a) tex2html_wrap_inline9898 a :: (a in logical)}
  Returns the inverse of the and of the two arguments.



Jonathan Hardwick
Tue Nov 28 13:57:00 EST 1995