Expand description
A collection of utility functions helpful in defining AIR’s.
Functions§
- add2
- Verify that
a = b + c mod 2^32
- add3
- Verify that
a = b + c + d mod 2^32
- andn
- Computes the arithmetic generalization of
andnot
. - checked_
andn - Compute
andnot
on a pair of boolean field elements. - checked_
xor - Compute
xor
on a list of boolean field elements. - pack_
bits_ le - Pack a collection of bits into a number.
- u32_
to_ bits_ le - Convert a 32-bit integer into an array of 32 0 or 1 field elements.
- u64_
to_ 16_ bit_ limbs - Convert a 64-bit integer into an array of four field elements representing the 16 bit limb decomposition.
- u64_
to_ bits_ le - Convert a 64-bit integer into an array of 64 0 or 1 field elements.
- xor
- Computes the arithmetic generalization of boolean
xor
. - xor3
- Computes the arithmetic generalization of a triple
xor
. - xor_
32_ shift - Verify that
a = (b ^ (c << shift))