Wikifunctions:Catalogue/Boolean operations
Appearance

These are the basic blocks from which to build logic states.
Boolean pairwise functions
| Name | ZID | Value |
|---|---|---|
| nullary false | Z10206 | F |
| nullary true | Z10210 | T |
| Name | ZID | F | T |
|---|---|---|---|
| unary false | Z10214 | F | F |
| identity | Z10215 | F | T |
| not | Z10216 | T | F |
| unary true | Z10217 | T | T |
| Name | ZID | F ∗ F | F ∗ T | T ∗ F | T ∗ T |
|---|---|---|---|---|---|
| binary false | Z10257 | F | F | F | F |
| and | Z10174 | F | F | F | T |
| not (A → B) | Z10962 | F | F | T | F |
| A | Z10265 | F | F | T | T |
| not (B → A) | Z10964 | F | T | F | F |
| B | Z10298 | F | T | F | T |
| xor | Z10237 | F | T | T | F |
| or | Z10184 | F | T | T | T |
| nor | Z10231 | T | F | F | F |
| xnor/eqv | Z844 | T | F | F | T |
| not B | Z10306 | T | F | T | F |
| B → A | Z10348 | T | F | T | T |
| not A | Z10272 | T | T | F | F |
| A → B | Z10329 | T | T | F | T |
| nand | Z10243 | T | T | T | F |
| binary true | Z10287 | T | T | T | T |
Other Boolean functions
- and (quaternary) (Z11828): takes four boolean inputs and returns true if and only if they are all true
- and (octonary) (Z11849): takes eight boolean inputs and returns true if and only if they are all true
- is truthy (Z15684): returns True if the argument is truthy
- are all true? (Z12684): returns true if every list item is true/truthy
- is any true (Z12698): checks whether in a list of Boolean any is true
- are all false (Z13445): returns true if every list item is false
- is any false (Z16798): checks whether any member in a Boolean list is false
- Boolean to Sign (Z17053): Return positive if true, or negative if false
Search for
Functions expecting or returning an explicit Boolean object, singly or in a list
Kleenean functions
- Kleenean identity (Z22120): This checks whether the two values have the same identity. For the Kleenean notion of equality, a different function is available.
- Kleenean inequality (Z22231): returns true only if both inputs are different
- and (Kleenean) (Z22143): Description missing
- or (Kleenean) (Z22168): Description missing
- if (Kleenean) (Z22202): Description missing
- is Kleenean True? (Z22131): conservative conversion between Kleenean and Boolean, such that Maybe is called false
- is Kleenean not False? (Z29661): conversion to Boolean where Maybe is considered truthy
- Boolean as Kleenean (Z22126): Description missing
- not (Kleenean) (Z22207): negates a Kleenean value
- equality of Kleenean and Boolean (Z22257): only true if the Kleenean is True or False, and the Boolean is equal to it
Search for
Functions expecting or returning an explicit Kleenean object, singly or in a list
Byte functions
Functions about the type Byte (Z80): Description missing
Conversions
Numbers
Strings
- byte as hex string (Z15702): Description missing
- Byte as prefixed hexadecimal string (Z22883): Prefix is "0x". Uses capitals for the hex digits.
- read Byte from string (Z22858): lenient default (language-independent) reader to convert user input to a Byte value
- hex string as Byte (Z22800): take a two character hex string (00-FF) and return a byte
- byte as binary string (Z22448): Description missing
- binary string as byte (Z22946): reads an 8 digit binary string consisting of 0s and 1s as a byte
Lists
- byte as list of Booleans (Z22654): Returns a byte as a list of eight Boolean values
- list of Booleans to Byte (Z22672): constructs a Byte object from a list of Booleans
- list of bytes to string (UTF-8) (Z14576): Description missing
- list of bytes to hex (lowercase) (Z14573): Description missing
- list of bytes to list of Natural numbers (Z14570): Description missing
Operations
- bitwise not (Z22529): converts every 1 in a byte into a 0, and every 0 into a 1
- bitwise and (Z13651): Description missing
- bitwise or (Z13652): Description missing
- bitwise xor (Z13653): Description missing
- bitwise NAND (Z24716): Description missing
- next byte (Z22380): Returns the next byte. At overflow, it starts at 0 again.
- previous byte (Z24669): Returns the previous byte. At overflow, it starts at 255 again.
- reverse byte (Z25585): Reverses a byte.
Search for
Functions expecting or returning an explicit Byte object, singly or in a list